CVE-2020-5217

Source
https://nvd.nist.gov/vuln/detail/CVE-2020-5217
Import Source
https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2020-5217.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2020-5217
Aliases
Related
Published
2020-01-23T03:15:10Z
Modified
2024-10-12T06:36:15.786251Z
Severity
  • 5.8 (Medium) CVSS_V3 - CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:N/I:L/A:N CVSS Calculator
Summary
[none]
Details

In Secure Headers (RubyGem secureheaders), a directive injection vulnerability is present in versions before 3.8.0, 5.1.0, and 6.2.0. If user-supplied input was passed into append/overridecontentsecuritypolicydirectives, a semicolon could be injected leading to directive injection. This could be used to e.g. override a script-src directive. Duplicate directives are ignored and the first one wins. The directives in secureheaders are sorted alphabetically so they pretty much all come before script-src. A previously undefined directive would receive a value even if SecureHeaders::OPT_OUT was supplied. The fixed versions will silently convert the semicolons to spaces and emit a deprecation warning when this happens. This will result in innocuous browser console messages if being exploited/accidentally used. In future releases, we will raise application errors resulting in 500s. Depending on what major version you are using, the fixed versions are 6.2.0, 5.1.0, 3.8.0.

References

Affected packages

Debian:11 / ruby-secure-headers

Package

Name
ruby-secure-headers
Purl
pkg:deb/debian/ruby-secure-headers?arch=source

Affected ranges

Type
ECOSYSTEM
Events
Introduced
0Unknown introduced version / All previous versions are affected
Fixed
6.3.1-1

Ecosystem specific

{
    "urgency": "not yet assigned"
}

Debian:12 / ruby-secure-headers

Package

Name
ruby-secure-headers
Purl
pkg:deb/debian/ruby-secure-headers?arch=source

Affected ranges

Type
ECOSYSTEM
Events
Introduced
0Unknown introduced version / All previous versions are affected
Fixed
6.3.1-1

Ecosystem specific

{
    "urgency": "not yet assigned"
}

Debian:13 / ruby-secure-headers

Package

Name
ruby-secure-headers
Purl
pkg:deb/debian/ruby-secure-headers?arch=source

Affected ranges

Type
ECOSYSTEM
Events
Introduced
0Unknown introduced version / All previous versions are affected
Fixed
6.3.1-1

Ecosystem specific

{
    "urgency": "not yet assigned"
}

Git / github.com/github/secure_headers

Affected ranges

Type
GIT
Repo
https://github.com/github/secure_headers
Events
Introduced
0 Unknown introduced commit / All previous commits are affected
Fixed
Type
GIT
Repo
https://github.com/twitter/secure_headers
Events
Introduced
0 Unknown introduced commit / All previous commits are affected
Fixed

Affected versions

2.*

2.0.0
2.2.0
2.2.1
2.2.2
2.2.3
2.2.4
2.3.0
2.4.0
2.4.1
2.4.2
2.4.3
2.4.4

v.*

v.2.0.0.pre2

v0.*

v0.4.2
v0.4.3

v1.*

v1.1.1
v1.3.2
v1.3.3
v1.3.4

v2.*

v2.0.0.pre
v2.0.1
v2.0.2
v2.1.0

v3.*

v3.0.0
v3.0.0.rc1
v3.0.1
v3.0.2
v3.0.3
v3.1.0
v3.1.1
v3.1.2
v3.2.0
v3.3.0
v3.3.1
v3.3.2
v3.4.0
v3.4.1
v3.5.0
v3.5.0.pre
v3.5.1
v3.6.0
v3.6.1
v3.6.3
v3.6.4
v3.6.5
v3.6.7
v3.7.0
v3.7.1
v3.7.2
v3.7.3
v3.7.4

v4.*

v4.0.0
v4.0.0.alpha01
v4.0.0.alpha02
v4.0.0.alpha03
v4.0.0.alpha04
v4.0.1

v5.*

v5.0.0.alpha01
v5.0.1
v5.0.2
v5.0.3
v5.0.4
v5.0.5