Lucene search

K
githubGitHub Advisory DatabaseGHSA-78XJ-CGH5-2H22
HistoryFeb 08, 2024 - 6:30 p.m.

NPM IP package incorrectly identifies some private IP addresses as public

2024-02-0818:30:39
CWE-918
GitHub Advisory Database
github.com
489
npm
ip package
ispublic function
private ip
sensitive code paths
ssrf
versions 1.1.9
2.0.1
security issue

9.8 High

CVSS3

Attack Vector

NETWORK

Attack Complexity

LOW

Privileges Required

NONE

User Interaction

NONE

Scope

UNCHANGED

Confidentiality Impact

HIGH

Integrity Impact

HIGH

Availability Impact

HIGH

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

9.6 High

AI Score

Confidence

High

0.001 Low

EPSS

Percentile

35.9%

The isPublic() function in the NPM package ip doesn’t correctly identify certain private IP addresses in uncommon formats such as 0x7F.1 as private. Instead, it reports them as public by returning true. This can lead to security issues such as Server-Side Request Forgery (SSRF) if isPublic() is used to protect sensitive code paths when passed user input. Versions 1.1.9 and 2.0.1 fix the issue.

Affected configurations

Vulners
Node
ipRange<1.1.9
OR
ipMatch2.0.0
CPENameOperatorVersion
iplt1.1.9
ipeq2.0.0

9.8 High

CVSS3

Attack Vector

NETWORK

Attack Complexity

LOW

Privileges Required

NONE

User Interaction

NONE

Scope

UNCHANGED

Confidentiality Impact

HIGH

Integrity Impact

HIGH

Availability Impact

HIGH

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

9.6 High

AI Score

Confidence

High

0.001 Low

EPSS

Percentile

35.9%