Affected versions of yargs-parser are vulnerable to prototype pollution. Arguments are not properly sanitized, allowing an attacker to modify the prototype of Object, causing the addition or modification of an existing property that will exist on all objects. Parsing the argument --foo.__proto__.bar baz' adds a bar property with value baz to all objects. This is only exploitable if attackers have control over the arguments being passed to yargs-parser.
:heavy_check_mark: This issue was automatically closed by Mend because the vulnerable library in the specific branch(es) was either marked as ignored or it is no longer part of the Mend inventory.
WS-2020-0068 - High Severity Vulnerability
Vulnerable Libraries - yargs-parser-9.0.2.tgz, yargs-parser-11.1.1.tgz, yargs-parser-13.1.0.tgz, yargs-parser-10.1.0.tgz
yargs-parser-9.0.2.tgz
the mighty option parser used by yargs
Library home page: https://registry.npmjs.org/yargs-parser/-/yargs-parser-9.0.2.tgz
Path to dependency file: /tmp/ws-scm/shipengine-request/package.json
Path to vulnerable library: /tmp/ws-scm/shipengine-request/node_modules/npm/node_modules/yargs-parser/package.json
Dependency Hierarchy: - semantic-release-15.13.15.tgz (Root Library) - npm-5.1.7.tgz - npm-6.9.0.tgz - libnpx-10.2.0.tgz - yargs-11.0.0.tgz - :x: **yargs-parser-9.0.2.tgz** (Vulnerable Library)
yargs-parser-11.1.1.tgz
the mighty option parser used by yargs
Library home page: https://registry.npmjs.org/yargs-parser/-/yargs-parser-11.1.1.tgz
Path to dependency file: /tmp/ws-scm/shipengine-request/package.json
Path to vulnerable library: /tmp/ws-scm/shipengine-request/node_modules/yargs-parser/package.json
Dependency Hierarchy: - jest-24.8.0.tgz (Root Library) - jest-cli-24.8.0.tgz - yargs-12.0.5.tgz - :x: **yargs-parser-11.1.1.tgz** (Vulnerable Library)
yargs-parser-13.1.0.tgz
the mighty option parser used by yargs
Library home page: https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.0.tgz
Path to dependency file: /tmp/ws-scm/shipengine-request/package.json
Path to vulnerable library: /tmp/ws-scm/shipengine-request/node_modules/semantic-release/node_modules/yargs-parser/package.json
Dependency Hierarchy: - semantic-release-15.13.15.tgz (Root Library) - yargs-13.2.4.tgz - :x: **yargs-parser-13.1.0.tgz** (Vulnerable Library)
yargs-parser-10.1.0.tgz
the mighty option parser used by yargs
Library home page: https://registry.npmjs.org/yargs-parser/-/yargs-parser-10.1.0.tgz
Path to dependency file: /tmp/ws-scm/shipengine-request/package.json
Path to vulnerable library: /tmp/ws-scm/shipengine-request/node_modules/ts-jest/node_modules/yargs-parser/package.json
Dependency Hierarchy: - ts-jest-24.0.2.tgz (Root Library) - :x: **yargs-parser-10.1.0.tgz** (Vulnerable Library)
Found in HEAD commit: 33c0fb6c814968ec780d9f6f13693e298fc48d26
Vulnerability Details
Affected versions of yargs-parser are vulnerable to prototype pollution. Arguments are not properly sanitized, allowing an attacker to modify the prototype of Object, causing the addition or modification of an existing property that will exist on all objects. Parsing the argument --foo.__proto__.bar baz' adds a bar property with value baz to all objects. This is only exploitable if attackers have control over the arguments being passed to yargs-parser.
Publish Date: 2020-05-01
URL: WS-2020-0068
CVSS 3 Score Details (7.5)
Base Score Metrics: - Exploitability Metrics: - Attack Vector: Adjacent - Attack Complexity: High - Privileges Required: None - User Interaction: None - Scope: Unchanged - Impact Metrics: - Confidentiality Impact: High - Integrity Impact: High - Availability Impact: High
For more information on CVSS3 Scores, click here.Suggested Fix
Type: Upgrade version
Origin: https://www.npmjs.com/package/yargs-parser
Release Date: 2020-05-04
Fix Resolution: https://www.npmjs.com/package/yargs-parser/v/18.1.2,https://www.npmjs.com/package/yargs-parser/v/15.0.1
Step up your Open Source Security Game with WhiteSource here