CVE-2024-28103: Actionpack Missing Security Headers Vulnerability

MODERATE
Advisory Identifier: GHSA-fwhr-88qx-h9g7
CVSS 5.4
CWE-20
Published
Advisory Summary

CVE-2024-28103 is a MODERATE (CVSS 5.4) missing security headers vulnerability (CWE-20: Improper Input Validation) affecting Actionpack libraries in the RubyGems ecosystem. The issue involves missing security headers in action pack on non-html responses. Remediation is available by upgrading affected packages to version 6.1.7.8, 7.0.8.4, 7.1.3.4, 7.2.0.beta2.

CVE-2024-28103 at a Glance

CVE Identifier CVE-2024-28103
GHSA Identifier GHSA-fwhr-88qx-h9g7
Severity MODERATE
CVSS v3.1 Base Score 5.4
CWE Classification CWE-20: Improper Input Validation
Affected Product Actionpack
Package Ecosystem RubyGems
Published Date
Last Updated

Security Impact

CVSS: 5.4

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction Required (UI:R)
Scope Unchanged (S:U)
Confidentiality Low (C:L)
Integrity Low (I:L)
Availability None (A:N)

How to Fix CVE-2024-28103

To remediate this vulnerability, upgrade all affected Actionpack dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

actionpack fixed: 6.1.7.8
Upgrade actionpack to 6.1.7.8
actionpack fixed: 7.0.8.4
Upgrade actionpack to 7.0.8.4
actionpack fixed: 7.1.3.4
Upgrade actionpack to 7.1.3.4
actionpack fixed: 7.2.0.beta2
Upgrade actionpack to 7.2.0.beta2
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for actionpack

How to Check if You Are Affected

To determine whether your application is affected by CVE-2024-28103, inspect your project dependencies for Actionpack:

inspect dependencies for actionpack

Analyze the terminal output to locate any version of Actionpack in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 6.1.7.8), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-20: Improper Input Validation, where the product receives input or data, but it does not validate or incorrectly validates that the input has the properties that are required to process the data safely and correctly. In Actionpack, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

# Permissions-Policy is Only Served on HTML Content-Type The application configurable Permissions-Policy is only served on responses with an HTML related Content-Type. This has been assigned the CVE identifier CVE-2024-28103. Versions Affected: >= 6.1.0 Not affected: < 6.1.0 Fixed Versions: 6.1.7.8, 7.0.8.4, and 7.1.3.4 Impact ------ Responses with a non-HTML Content-Type are not serving the configured Permissions-Policy. There are certain non-HTML Content-Types that would benefit from having the Permissions-Policy enforced. Releases -------- The fixed releases are available at the normal locations. Workarounds ----------- N/A Patches ------- To aid users who aren't able to upgrade immediately we have provided patches for the supported release series in accordance with our [maintenance policy](https://guides.rubyonrails.org/maintenance_policy.html#security-issues) regarding security issues. They are in git-am format and consist of a single changeset. * 6-1-include-permissions-policy-header-on-non-html.patch - Patch for 6.1 series * 7-0-include-permissions-policy-header-on-non-html.patch - Patch for 7.0 series * 7-1-include-permissions-policy-header-on-non-html.patch - Patch for 7.1 series Credits ------- Thank you [shinkbr](https://hackerone.com/shinkbr) for reporting this!

CVE-2024-28103 Affected Actionpack Versions

4 component(s)
Fixed Versions:
6.1.7.87.0.8.47.1.3.47.2.0.beta2
Product / Package Ecosystem Affected Versions Fixed Version
actionpack
RubyGems
≥ 6.1.0
< 6.1.7.8
6.1.7.8
actionpack
RubyGems
≥ 7.0.0
< 7.0.8.4
7.0.8.4
actionpack
RubyGems
≥ 7.1.0
< 7.1.3.4
7.1.3.4
actionpack
RubyGems
≥ 7.2.0.beta1
< 7.2.0.beta2
All 1 versions
7.2.0.beta1
7.2.0.beta2

References

Frequently Asked Questions

What is CVE-2024-28103?
CVE-2024-28103 is a security vulnerability in Actionpack involving Missing security headers in Action Pack on non-HTML responses under CWE-20: Improper Input Validation.
Which Actionpack versions are affected?
Affected versions include releases prior to 6.1.7.8, 7.0.8.4, 7.1.3.4, 7.2.0.beta2 across affected packages: actionpack.
What version fixes CVE-2024-28103?
Upgrading to 6.1.7.8, 7.0.8.4, 7.1.3.4, 7.2.0.beta2 (or the latest patched release for your respective branch) resolves the vulnerability.
Is actionpack affected?
Yes, actionpack is affected in releases prior to 6.1.7.8, 7.0.8.4, 7.1.3.4, 7.2.0.beta2. Upgrade your dependency to 6.1.7.8, 7.0.8.4, 7.1.3.4, 7.2.0.beta2 or later.
What is the CVSS score of CVE-2024-28103?
CVE-2024-28103 has a CVSS v3.1 base score of 5.4 (MODERATE) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N.
What CWE is associated with CVE-2024-28103?
CVE-2024-28103 is classified under CWE-20: Improper Input Validation (The product receives input or data, but it does not validate or incorrectly validates that the input has the properties that are required to process the data safely and correctly.).
How can I check RubyGems dependencies for CVE-2024-28103?
Run the dependency tree command: 'inspect dependencies for actionpack'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-fwhr-88qx-h9g7",
  "modified" : "2024-12-06T15:31:19Z",
  "published" : "2024-06-04T22:26:24Z",
  "aliases" : [ "CVE-2024-28103" ],
  "summary" : "Missing security headers in Action Pack on non-HTML responses",
  "details" : "# Permissions-Policy is Only Served on HTML Content-Type\n\nThe application configurable Permissions-Policy is only served on responses\nwith an HTML related Content-Type.\n\nThis has been assigned the CVE identifier CVE-2024-28103.\n\n\nVersions Affected:  >= 6.1.0\nNot affected:       < 6.1.0\nFixed Versions:     6.1.7.8, 7.0.8.4, and 7.1.3.4\n\nImpact\n------\nResponses with a non-HTML Content-Type are not serving the configured Permissions-Policy. There are certain non-HTML Content-Types that would benefit from having the Permissions-Policy enforced.\n\n\nReleases\n--------\nThe fixed releases are available at the normal locations.\n\nWorkarounds\n-----------\nN/A\n\nPatches\n-------\nTo aid users who aren't able to upgrade immediately we have provided patches for\nthe supported release series in accordance with our \n[maintenance policy](https://guides.rubyonrails.org/maintenance_policy.html#security-issues)\nregarding security issues. They are in git-am format and consist of a\nsingle changeset.\n\n* 6-1-include-permissions-policy-header-on-non-html.patch - Patch for 6.1 series\n* 7-0-include-permissions-policy-header-on-non-html.patch - Patch for 7.0 series\n* 7-1-include-permissions-policy-header-on-non-html.patch - Patch for 7.1 series\n\n\n\nCredits\n-------\n\nThank you [shinkbr](https://hackerone.com/shinkbr) for reporting this!",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "RubyGems",
      "name" : "actionpack"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "6.1.0"
      }, {
        "fixed" : "6.1.7.8"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "RubyGems",
      "name" : "actionpack"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "7.0.0"
      }, {
        "fixed" : "7.0.8.4"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "RubyGems",
      "name" : "actionpack"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "7.1.0"
      }, {
        "fixed" : "7.1.3.4"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "RubyGems",
      "name" : "actionpack"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "7.2.0.beta1"
      }, {
        "fixed" : "7.2.0.beta2"
      } ]
    } ],
    "versions" : [ "7.2.0.beta1" ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/rails/rails/security/advisories/GHSA-fwhr-88qx-h9g7"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2024-28103"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/rails/rails/commit/35858f1d9d57f6c4050a8d9ab754bd5d088b4523"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/rails/rails"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/rubysec/ruby-advisory-db/blob/master/gems/actionpack/CVE-2024-28103.yml"
  }, {
    "type" : "WEB",
    "url" : "https://security.netapp.com/advisory/ntap-20241206-0002"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-20" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2024-06-04T22:26:24Z",
    "nvd_published_at" : "2024-06-04T20:15:10Z"
  }
}