GHSA-78xj-cgh5-2h22

Suggest an improvement
Source
https://github.com/advisories/GHSA-78xj-cgh5-2h22
Import Source
https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2024/02/GHSA-78xj-cgh5-2h22/GHSA-78xj-cgh5-2h22.json
JSON Data
https://api.test.osv.dev/v1/vulns/GHSA-78xj-cgh5-2h22
Aliases
Related
Published
2024-02-08T18:30:39Z
Modified
2024-09-11T06:13:09.752080Z
Summary
NPM IP package incorrectly identifies some private IP addresses as public
Details

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.

Database specific
{
    "nvd_published_at": "2024-02-08T17:15:10Z",
    "cwe_ids": [
        "CWE-918"
    ],
    "severity": "LOW",
    "github_reviewed": true,
    "github_reviewed_at": "2024-02-09T15:03:18Z"
}
References

Affected packages

npm / ip

Package

Affected ranges

Type
SEMVER
Events
Introduced
2.0.0
Fixed
2.0.1

Affected versions

2.*

2.0.0

npm / ip

Package

Affected ranges

Type
SEMVER
Events
Introduced
0Unknown introduced version / All previous versions are affected
Fixed
1.1.9