CVE-2022-24759: @chainsafe/libp2p noise Failure To Validate Signature During Vulnerability
HIGHCVE-2022-24759 is a HIGH (CVSS 8.1) failure to validate signature during vulnerability (CWE-347: Improper Verification of Cryptographic Signature) affecting @chainsafe/libp2p noise libraries in the npm ecosystem. The issue involves failure to validate signature during handshake. Remediation is available by upgrading affected packages to version 4.1.2, 5.0.3.
CVE-2022-24759 at a Glance
Security Impact
CVSS: 8.1
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H).
How to Fix CVE-2022-24759
To remediate this vulnerability, upgrade all affected @chainsafe/libp2p noise 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 @chainsafe/libp2p-noise@4.1.2
npm install @chainsafe/libp2p-noise@5.0.3
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
npm ls @chainsafe/libp2p-noise
How to Check if You Are Affected
To determine whether your Node.js application is affected by CVE-2022-24759, inspect your project dependencies using npm:
npm ls @chainsafe/libp2p-noise
Analyze the terminal output to locate any version of @chainsafe/libp2p noise in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 4.1.2), your application is affected.
Note: The npm ls @chainsafe/libp2p-noise 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 CWE-347: Improper Verification of Cryptographic Signature, where the product does not verify, or incorrectly verifies, the cryptographic signature for data. In @chainsafe/libp2p noise, 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-2022-24759 Affected @chainsafe/libp2p noise Versions
2 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
@chainsafe/libp2p-noise
|
npm |
< 4.1.2
|
4.1.2
|
|
@chainsafe/libp2p-noise
|
npm |
≥ 5.0.0
< 5.0.3
|
5.0.3
|
References
Frequently Asked Questions
What is CVE-2022-24759?
Which @chainsafe/libp2p noise versions are affected?
What version fixes CVE-2022-24759?
Is @chainsafe/libp2p-noise affected?
What is the CVSS score of CVE-2022-24759?
What CWE is associated with CVE-2022-24759?
How can I check npm dependencies for CVE-2022-24759?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-j3ff-xp6c-6gcc",
"modified" : "2022-03-18T18:57:53Z",
"published" : "2022-03-18T18:57:53Z",
"aliases" : [ "CVE-2022-24759" ],
"summary" : "Failure to validate signature during handshake",
"details" : "### Impact\n`@chainsafe/libp2p-noise` before 4.1.2 and 5.0.3 was not correctly validating signatures during the handshake process.\nThis may allow a man-in-the-middle to pose as other peers and get those peers banned.\n\n### Patches\nUsers should upgrade to 4.1.2 or 5.0.3\n\n### Workarounds\nNo workarounds, just patch upgrade\n\n### References\nhttps://github.com/ChainSafe/js-libp2p-noise/pull/130\n",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "npm",
"name" : "@chainsafe/libp2p-noise"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "4.1.2"
} ]
} ]
}, {
"package" : {
"ecosystem" : "npm",
"name" : "@chainsafe/libp2p-noise"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "5.0.0"
}, {
"fixed" : "5.0.3"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/ChainSafe/js-libp2p-noise/security/advisories/GHSA-j3ff-xp6c-6gcc"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2022-24759"
}, {
"type" : "WEB",
"url" : "https://github.com/ChainSafe/js-libp2p-noise/pull/130"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/ChainSafe"
}, {
"type" : "WEB",
"url" : "https://github.com/ChainSafe/js-libp2p-noise/releases/tag/v5.0.3"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-347" ],
"severity" : "HIGH",
"github_reviewed" : true,
"github_reviewed_at" : "2022-03-18T18:57:53Z",
"nvd_published_at" : "2022-03-17T17:15:00Z"
}
}