CVE-2022-23495: ipfs go-merkledag
Vulnerability summary
CVE-2022-23495 is a high (CVSS 7.5) vulnerability in ipfs go-merkledag. EPSS estimates a 1.38% chance of exploitation in the next 30 days, higher than 71.7% of scored vulnerabilities.
Timeline
- 08-12-2022PublishedVulnerability first disclosed.
- 23-04-2025Last modifiedVulnerability information updated.
Description
go-merkledag implements the 'DAGService' interface and adds two ipld node types, Protobuf and Raw for the ipfs project. A `ProtoNode` may be modified in such a way as to cause various encode errors which will trigger a panic on common method calls that don't allow for error returns. A `ProtoNode` should only be able to encode to valid DAG-PB, attempting to encode invalid DAG-PB forms will result in an error from the codec. Manipulation of an existing (newly created or decoded) `ProtoNode` using the modifier methods did not account for certain states that would place the `ProtoNode` into an unencodeable form. Due to conformance with the [`github.com/ipfs/go-block-format#Block`](https://pkg.go.dev/github.com/ipfs/go-block-format#Block) and [`github.com/ipfs/go-ipld-format#Node`](https://pkg.go.dev/github.com/ipfs/go-ipld-format#Node) interfaces, certain methods, which internally require a re-encode if state has changed, will panic due to the inability to return an error. This issue has been addressed across a number of pull requests. Users are advised to upgrade to version 0.8.1 for a complete set of fixes. Users unable to upgrade may attempt to mitigate this issue by sanitising inputs when allowing user-input to set a new `CidBuilder` on a `ProtoNode` and by sanitising `Tsize` (`Link#Size`) values such that they are a reasonable byte-size for sub-DAGs where derived from user-input.
CVSS metrics
3 scores · 3 sources · 1 version- OSV · GoEcosystem advisory · calculated7.5HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
- NVDNIST7.5HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
EPSS trend
Probability
1.38%
Chance of exploitation in the next 30 days
Percentile
72%
Versus all other CVEs
30-day change
+0.07 pp
From 1.31% on 19-09-2026
Known exploited
Compare KEV catalogsNot in any of the 3 tracked catalogs.
Public exploits
0 foundNo public exploits indexed.
Weaknesses
CWE · root causeAffected systems
Github.com/ipfs1 product
- go-merkledag≥ 0.4.0, < 0.8.1
Ipfs1 product
- go-merkledag≥ 0.4.0, < 0.8.1
Protocol1 product
- go-merkledag≥ 0.4.0, < 0.8.1
3 vendors · 3 products
References
12 links- github.com/ipfs/go-merkledag/security/advisories/GHSA-x39j-h85h-3f46X Refsource CONFIRMWEBAdvisoryThird Party Advisory
- en.wikipedia.org/wiki/Directed_acyclic_graphX Refsource MISCWEBTechnical DescriptionThird Party Advisory
- github.com/ipfs/go-merkledag/releases/tag/v0.8.0X Refsource MISCWEBRelease NotesThird Party Advisory
- github.com/ipfs/go-merkledag/releases/tag/v0.8.1X Refsource MISCWEBRelease NotesThird Party Advisory
Show all 12 references
- github.com/ipfs/go-merkledagPACKAGE