GHSA-hxf5-mg84-pj4m: Moment Moderate Severity Vulnerability That Affects Vulnerability
MODERATEGHSA-hxf5-mg84-pj4m is a MODERATE moderate severity vulnerability that affects vulnerability (General Security Weakness) affecting Moment libraries in the npm ecosystem. The issue involves moderate severity vulnerability that affects moment. Remediation is available by upgrading affected packages to version 2.11.2.
GHSA-hxf5-mg84-pj4m at a Glance
How to Fix GHSA-hxf5-mg84-pj4m
To remediate this vulnerability, upgrade all affected Moment dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
npm install moment@2.11.2
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
npm ls moment
How to Check if You Are Affected
To determine whether your Node.js application is affected by GHSA-hxf5-mg84-pj4m, inspect your project dependencies using npm:
npm ls moment
Analyze the terminal output to locate any version of Moment in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.11.2), your application is affected.
Note: The npm ls moment command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under General Security Weakness. In Moment, 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
GHSA-hxf5-mg84-pj4m Affected Moment Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
moment
|
npm |
< 2.11.2
|
2.11.2
|
References
Frequently Asked Questions
What is GHSA-hxf5-mg84-pj4m?
Which Moment versions are affected?
What version fixes GHSA-hxf5-mg84-pj4m?
Is moment affected?
What CWE is associated with GHSA-hxf5-mg84-pj4m?
How can I check npm dependencies for GHSA-hxf5-mg84-pj4m?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-hxf5-mg84-pj4m",
"modified" : "2020-06-17T15:14:53Z",
"published" : "2018-07-31T23:03:17Z",
"withdrawn" : "2020-06-17T15:14:53Z",
"aliases" : [ ],
"summary" : "Moderate severity vulnerability that affects moment",
"details" : "Withdrawn, accidental duplicate publish.\n\nThe duration function in the moment package before 2.11.2 for Node.js allows remote attackers to cause a denial of service (CPU consumption) via a long string, aka a \"regular expression Denial of Service (ReDoS).\"",
"severity" : [ ],
"affected" : [ {
"package" : {
"ecosystem" : "npm",
"name" : "moment"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "2.11.2"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2016-4055"
}, {
"type" : "ADVISORY",
"url" : "https://github.com/advisories/GHSA-hxf5-mg84-pj4m"
} ],
"database_specific" : {
"cwe_ids" : [ ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2020-06-17T15:14:53Z",
"nvd_published_at" : null
}
}