Vulnerabilities in pkg:gem/sprockets
PACKAGECVE-2018-3760 is a HIGH (CVSS 7.5) path traversal vulnerability (CWE-200: Exposure of Sensitive Information to an Unauthorized Actor) affecting Sprockets libraries in the RubyGems ecosystem. The issue involves sprockets path traversal leads to information leak. Remediation is available by upgrading affected packages to version 3.7.2, 4.0.0.beta8, 2.12.5.
pkg:gem/sprockets
Vulnerability advisories affecting package pkg:gem/sprockets. Select an advisory below to view technical details or fixes.
| Advisory ID | CVE / NVD | Severity | Summary |
|---|---|---|---|
| GHSA-pr3h-jjhj-573x | CVE-2018-3760 | HIGH | Sprockets path traversal leads to information leak |
| GHSA-33pp-3763-mrfp | CVE-2014-7819 | MODERATE | sprockets vulnerable to Path Traversal |
| GHSA-r4x3-g983-9g48 | - | MODERATE | Moderate severity vulnerability that affects sprockets |
CVE-2018-3760 at a Glance
Security Impact
CVSS: 7.5
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N).
How to Fix CVE-2018-3760
To remediate this vulnerability, upgrade all affected Sprockets dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade sprockets to 3.7.2
Upgrade sprockets to 4.0.0.beta8
Upgrade sprockets to 2.12.5
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for sprockets
How to Check if You Are Affected
To determine whether your application is affected by CVE-2018-3760, inspect your project dependencies for Sprockets:
inspect dependencies for sprockets
Analyze the terminal output to locate any version of Sprockets in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 3.7.2), 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-200: Exposure of Sensitive Information to an Unauthorized Actor, where the product exposes sensitive information to an actor that is not explicitly authorized to have access to that information. In Sprockets, 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
CVE-2018-3760 Affected Sprockets Versions
3 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
sprockets
|
RubyGems |
≥ 3.0.0
< 3.7.2
|
3.7.2
|
|
sprockets
|
RubyGems |
≥ 4.0.0.beta1
< 4.0.0.beta8
|
4.0.0.beta8
|
|
sprockets
|
RubyGems |
< 2.12.5
|
2.12.5
|
References
Frequently Asked Questions
What is CVE-2018-3760?
Which Sprockets versions are affected?
What version fixes CVE-2018-3760?
Is sprockets affected?
What is the CVSS score of CVE-2018-3760?
What CWE is associated with CVE-2018-3760?
How can I check RubyGems dependencies for CVE-2018-3760?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-pr3h-jjhj-573x",
"modified" : "2023-09-05T21:05:18Z",
"published" : "2018-06-20T22:18:58Z",
"aliases" : [ "CVE-2018-3760" ],
"summary" : "Sprockets path traversal leads to information leak",
"details" : "Specially crafted requests can be used to access files that exist on the filesystem that is outside an application's root directory, when the Sprockets server is used in production.\n \nAll users running an affected release should either upgrade or use one of the work arounds immediately.\n \n### Workaround:\n \nIn Rails applications, work around this issue, set `config.assets.compile = false` and `config.public_file_server.enabled = true` in an initializer and precompile the assets.\n\nThis work around will not be possible in all hosting environments and upgrading is advised.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "RubyGems",
"name" : "sprockets"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "3.0.0"
}, {
"fixed" : "3.7.2"
} ]
} ]
}, {
"package" : {
"ecosystem" : "RubyGems",
"name" : "sprockets"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "4.0.0.beta1"
}, {
"fixed" : "4.0.0.beta8"
} ]
} ],
"database_specific" : {
"last_known_affected_version_range" : "<= 4.0.0.beta7"
}
}, {
"package" : {
"ecosystem" : "RubyGems",
"name" : "sprockets"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "2.12.5"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2018-3760"
}, {
"type" : "WEB",
"url" : "https://github.com/rails/sprockets/commit/18b8a7f07a50c245e9aee7854ecdbe606bbd8bb5"
}, {
"type" : "WEB",
"url" : "https://github.com/rails/sprockets/commit/9c34fa05900b968d74f08ccf40917848a7be9441"
}, {
"type" : "WEB",
"url" : "https://github.com/rails/sprockets/commit/c09131cf5b2c479263939c8582e22b98ed616c5f"
}, {
"type" : "WEB",
"url" : "https://access.redhat.com/errata/RHSA-2018:2244"
}, {
"type" : "WEB",
"url" : "https://access.redhat.com/errata/RHSA-2018:2245"
}, {
"type" : "WEB",
"url" : "https://access.redhat.com/errata/RHSA-2018:2561"
}, {
"type" : "WEB",
"url" : "https://access.redhat.com/errata/RHSA-2018:2745"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/rails/sprockets"
}, {
"type" : "WEB",
"url" : "https://groups.google.com/d/msg/rubyonrails-security/ft_J--l55fM/7roDfQ50BwAJ"
}, {
"type" : "WEB",
"url" : "https://www.debian.org/security/2018/dsa-4242"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-200", "CWE-22" ],
"severity" : "HIGH",
"github_reviewed" : true,
"github_reviewed_at" : "2020-06-16T21:49:53Z",
"nvd_published_at" : null
}
}