Description
@libp2p/gossipsub through 17.2.3 contains a prototype pollution vulnerability in PeerScore that allows remote gossipsub peers to modify Object.prototype by sending messages on the __proto__ topic. Attackers can send invalid or valid messages on that topic to set inherited invalidMessageDeliveries or firstMessageDeliveries properties to NaN across the victim Node.js process.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| libp2p | @libp2p/gossipsub | 0 ≤17.2.3 | — |
References
- https://github.com/libp2p/js-libp2p/blob/gossipsub-v17.2.3/packages/gossipsub/src/score/peer-score.ts#L540-L546
- https://github.com/libp2p/js-libp2p/blob/gossipsub-v17.2.3/packages/gossipsub/src/score/peer-score.ts#L457-L465
- https://www.vulncheck.com/advisories/libp2p-gossipsub-through-17.2.3-prototype-pollution-via-proto-topic-in-peer-scoring