ransack is vulnerable to Denial of Service (DoS)
75
High Risk
Ransack's collapse_multiparameter_attributes! method in lib/ransack/search.rb assigns a user supplied multiparameter position value directly as an array index without validating its size. A crafted query key such as q[created_at(100000000000i)]=1 makes Ruby allocate an array of that size, consuming multiple gigabytes of RAM and crashing the worker process. Any endpoint that calls ransack on request parameters is reachable this way, giving an unauthenticated memory exhaustion denial of service from a single request. The fix validates the position index and rejects out of range values before allocation.
You are affected if you are using a version that falls within the vulnerable range.
ransack is vulnerable to Denial of Service (DoS) in versions 0.1.0 - 4.4.1 and 5.0.0 - 5.0.0.
Upgrade the ransack library to the patch version.
Connect your repositories to instantly see whether vulnerable or malicious packages exist in your codebase.
Free. No credit card required.

I consent to receiving marketing communications based on Aikido’s Privacy Policy.
SOC 2Compliant
ISO 27001Compliant
ISO 42001Compliant© All Intel data is openly available and commercially licensed.