Possible Strong Parameters Bypass in ActionPack
Published 26 May 2020 · Updated 16 Feb 2024
Is your project on an affected actionpack?
Look after several Rails or Ruby apps? Indie watches up to 15 repos, private ones too, for $5 a month. See Indie
Affected packages
- Affected
- >=5.0.0 <5.2.4.3
- Fixed in
- 5.2.4.3
bundle update --conservative actionpack # Gemfile: '>= 5.2.4.3'- Affected
- >=6.0.0 <6.0.3.1
- Fixed in
- 6.0.3.1
bundle update --conservative actionpack # Gemfile: '>= 6.0.3.1'Details
There is a strong parameters bypass vector in ActionPack.
Versions Affected: rails <= 6.0.3 Not affected: rails < 5.0.0 Fixed Versions: rails >= 5.2.4.3, rails >= 6.0.3.1
Impact
------
In some cases user supplied information can be inadvertently leaked from
Strong Parameters. Specifically the return value of each, or each_value,
or each_pair will return the underlying "untrusted" hash of data that was
read from the parameters. Applications that use this return value may be
inadvertently use untrusted user input.
Impacted code will look something like this:
def update
# Attacker has included the parameter: `{ is_admin: true }`
User.update(clean_up_params)
end
def clean_up_params
params.each { |k, v| SomeModel.check(v) if k == :name }
endNote the mistaken use of each in the clean_up_params method in the above
example.
Workarounds
-----------
Do not use the return values of each, each_value, or each_pair in your
application.
Is GHSA-8727-m6gj-mc37 in any of your client repos?
Checking one package by hand is fine. Checking it across forty client projects is not. NPMscan reads the lockfiles in every GitHub repo you pick, finds each project with an affected actionpack, and gives you the command that fixes it.
More advisories for actionpack
- MediumCVE-2026-126072Action Pack: Possible DoS vulnerability in Action Controller Live streaming · 12 Nov 2026
- MediumCVE-2026-126077Action Pack: Possible sensitive session information leak in Active Storage proxy mode · 12 Nov 2026
- HighCVE-2026-126081Action Pack: Possible Strong Parameters Bypass in Parameters#each_key · 12 Nov 2026
- MediumCVE-2026-126073Action Pack: Possible cache poisoning in Action Pack content negotiation · 10 Nov 2026
- LowCVE-2026-126067Action Pack: Missing SameSite attribute on session cookies from Action Pack session stores · 10 Nov 2026
- HighCVE-2026-126083Action Pack: Possible IP spoofing in Action Dispatch RemoteIp · 10 Nov 2026
References
- Advisorynvd.nist.gov/vuln/detail/CVE-2020-8164
- Linkhackerone.com/reports/292797
- Packagegithub.com/rails/rails
- Linkgithub.com/rubysec/ruby-advisory-db/blob/master/gems/actionpack/CVE-2020-8164.yml
- Linkgroups.google.com/forum/#!topic/rubyonrails-security/f6ioe4sdpbY
- Linkgroups.google.com/g/rubyonrails-security/c/f6ioe4sdpbY
- Linklists.debian.org/debian-lts-announce/2020/06/msg00022.html
- Linklists.debian.org/debian-lts-announce/2020/07/msg00013.html
- Linkwww.debian.org/security/2020/dsa-4766
- Linklists.opensuse.org/opensuse-security-announce/2020-09/msg00089.html
- Linklists.opensuse.org/opensuse-security-announce/2020-09/msg00093.html
- Linklists.opensuse.org/opensuse-security-announce/2020-09/msg00107.html
Advisory data from OSV.dev (opens OSV.dev in a new tab), refreshed daily.