VDB

CVE-2020-5216

CVE-2020-5216 PUBLISHED CVSS 4.4 MEDIUM

Reported by github_m · Published January 23, 2020

secure_headers is fixed in 6.3.0, 5.2.0 and 3.9.0 (RubyGems)

In Secure Headers (RubyGem secure_headers), a directive injection vulnerability is present in versions before 3.9.0, 5.2.0, and 6.3.0. If user-supplied input was passed into append/override_content_security_policy_directives, a newline could be injected leading to limited header injection. Upon seeing a newline in the header, rails will silently create a new Content-Security-Policy header with the remaining value of the original string. It will continue to create new headers for each newline. This has been fixed in 6.3.0, 5.2.0, and 3.9.0.

Fixed versions

Upgrade to a fixed version or later. Language registries are listed first, then Linux distributions, then vendor products.

PackageEcosystemFixed in
secure_headersRubyGems6.3.0, 5.2.0, 3.9.0

Risk scores

CVSS 3.1
4.4
CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:C/C:L/I:L/A:N

Affected products

VendorProductVersions
Twittersecure_headers< 3.9.0, >= 5.0.0, < 5.2.0, >= 6.0.0, < 6.3.0
RubyGemssecure_headers0, 5.0.0, 6.0.0
Twittersecure_headers0, 5.0.0, 6.0.0

Timeline

  • Jan 23, 2020 CVE Published
  • Jan 23, 2020 PoC Published
  • Apr 14, 2021 EPSS Score (30 in total, the first dated here)
  • May 16, 2023 CVE Updated
  • Mar 17, 2026 Security Advisory
  • Aug 30, 2026 Coalition ESS Score

Query this with the API

The same record, from the CLI:

vulnetix vdb vuln CVE-2020-5216
vulnetix vdb fixes CVE-2020-5216

Or with curl, using the org id and key from your account page:

curl -s -H "Authorization: ApiKey ${VULNETIX_ORG_ID}:${VULNETIX_API_KEY}" \
  "https://api.vdb.vulnetix.com/v2/vuln/CVE-2020-5216/fixes/registry"

The Community plan is free and allows 50 queries a day. Get a free API key · API quickstart

References

Look up in the Resolve Platform →
$ Lookup Community · 50/day Open Lookup ›