GHSA-jg6f-48ff-5xrw: IBC-Go has Non-deterministic JSON Unmarshalling of IBC Acknowledgement
Noroxi assessment
Priority: Monitor (action score 0/100)
- The sources we track (CISA KEV, Exploit-DB, Metasploit, Nuclei, GitHub) show no public exploit code or exploitation in the wild.
- Anyone who can reach it over the internet can trigger it. No account or password is required. No user action is required. No special conditions are required; it is repeatable.
- Fixed version: github.com/cosmos/ibc-go/v7 (Go) 7.9.2; github.com/cosmos/ibc-go/v8 (Go) 8.6.1.
Low priority for now. Upgrade to github.com/cosmos/ibc-go/v7 (Go) 7.9.2; github.com/cosmos/ibc-go/v8 (Go) 8.6.1 or later.
Generated automatically from the record's data: CVSS (NVD and CNA), CISA KEV and SSVC, FIRST EPSS, exploit sources, fixed versions. How we calculate it
Primary sources: OSV
Name: ASA-2025-004: Non-deterministic JSON Unmarshalling of IBC Acknowledgement can result in a chain halt Component: IBC-Go Criticality: Critical (Considerable Impact; Almost Certain Likelihood per [ACMv1.2](https://github.com/interchainio/security/blob/main/resources/CLASSIFICATION_MATRIX.md)) Affected versions: IBC-Go >= v7; Earlier IBC-Go versions may also be affected. Affected users: Validators, Full nodes, IBC Middleware authors ### Description An issue was discovered in IBC-Go's deserialization of acknowledgements that results in non-deterministic behavior which can halt a chain. Any user that can open an IBC channel can introduce this state to the chain ### Patches The new IBC-Go releases below address this issue: * [v7.9.2](https://github.com/cosmos/ibc-go/releases/tag/v7.9.2) * [v8.6.1](https://github.com/cosmos/ibc-go/releases/tag/v8.6.1) ### Workarounds To prevent this state from being introduced to a chain, it is possible to permission Channel Opening as a workaround. ### Notes on Re-Release #### Is this state breaking? Probably not but it depends on your transfer middlewares This patch is not state breaking unless you depend on transfer middlewares that deserialize and serialize acknowledgement packets before passing them to the transfer handler. As far as we can tell, these middlewares are rare. For example, packet-forward-middleware and ibc-hooks, do not serialize ack packets in this way and therefore aren't broken by this patch. So if these are the only transfer middlewares you depend on, you can safely apply this patch in a rolling manner (and we've already cut new versions of these for you). #### What to do if you do depend on ack-serializing middleware In the unlikely case that you depend on middlewares that serialize ack packets and you do not update them when you apply this patch, all transfers that are handled by the middleware will fail (or experience other unexpected behavior) if the serialization approach differs from the transfer app's. If you have such dependencies and do not update them, validators who apply the patch in a rolling manner will halt when they upgrade, and transfers processed by the middleware will just fail once everyone has upgraded. To update these middlewares and avoid failing transfers or a chain halt, you will simply need to change the serialization approach in the middleware to use ibc-go's codec: `transfertypes.ModuleCdc.[Must]MarshalJSON`, rather than whatever you're doing today. For example: ``` import transfertypes "github.com/cosmos/ibc-go/v10/modules/apps/transfer/types" transfertypes.ModuleCdc.[Must]MarshalJSON func MarshalAsIBCDoes(ack channeltypes.Acknowledgement) ([]byte, error) { return transfertypes.ModuleCdc.MarshalJSON(&ack) } ``` When you do make a change to the serialization approach, this will make the patch state breaking and you will need a coordinated upgrade. So for absolute clarity: chains with these ack-serializing middlewares must do coordinated upgrades #### Why we retracted the earlier patch in favor of this approach We retracted the releases of ibc-go we cut earlier today because these broke all transfer middlewares that deserialized then re-serialized receive packets differently than the transfer app. It turned out that this was a common pattern (unlike serializing/deserializing ack packets), so widely used middlewares, including packet-forward-middleware, broke unexpectedly. In the new set of patches, we removed this constraint on how middlewares serialize receive packets, preventing this breakage. Only the serialization requirement on acknowledgement packets remains. This is convenient because this is the only constraint we had to add to fix the vulnerability, and middlewares that deserialize and serialize ack packets are much less common than ones that do so for receive packets. The constraint on receive packets was added for defense in depth. #### Testing we have done to gain more confidence in this release * In addition to testing ibc-go, we also did the following: * Tested pfm v7 and v8 after bumping dependencies * Tested ibc-hooks v7 and v8 after bumping dependencies * Ran a patched node on mainnet on the cosmos hub and triggered failing and successful transactions that used PFM * Ran a patched node on osmosis and triggered failing and successful transactions that used ibc-hooks This is a more thorough process than before, so we have higher confidence. ### Timeline * February 18, 2025, 4:54am PST: Issue reported to the Cosmos Bug Bounty program * February 18, 2025, 6:56am PST: Issue triaged by Amulet on-call, and distributed to Core team * February 18, 2025, 8:15am PST: Core team completes validation of issue * February 25, 2025, 8:00am PST / 17:00 CET: Pre-notification delivered * February 27, 2025, 8:00am PST / 17:00 CET: Patch made available * February 27, 2025, 1:00pm PST: Patch re-release made available This issue was reported to the Cosmos Bug Bounty Program by swelf19 on HackerOne on February 18, 2025. If you believe you have found a bug in the Interchain Stack or would like to contribute to the program by reporting a bug, please see https://hackerone.com/cosmos. If you have questions about Interchain security efforts, please reach out to our official communication channel at [security@interchain.io](mailto:security@interchain.io). For more information about the Interchain Foundation’s engagement with Amulet, and to sign up for security notification emails, please see https://github.com/interchainio/security. A Github Security Advisory for this issue is available in the IBC-Go [repository](https://github.com/cosmos/ibc-go/security/advisories/GHSA-jg6f-48ff-5xrw).
- Published
- Feb 28, 2025
- Updated
- Mar 5, 2025
- EPSS
- —
- CWE
- CWE-502
Report tools
Action score
0
Low priority for now.
- CVSS
- 0 / 40 · —
- CISA KEV
- 0 / 30 · Not listed
- EPSS
- 0 / 30 · —
Get told when this record changes
- Not in KEV: no record of exploitation in the wild
- No public exploit code on record
- A fix has been released
If any of these changes, we'll tell you in the daily email digest.
Is your version affected? Check itNoroxi analysis
What does it mean in your environment?
The assessment above is generated automatically from the record's data; it doesn't know your environment. Our team verifies on your systems whether this vulnerability is actually exploitable and which mitigation is enough.
We use this product, ask for helpAffected systems
Is your version affected?
Pick the product and type the version you run. It's compared with this record's version ranges in your browser; the version isn't sent anywhere.
| Vendor | Product | CPE |
|---|---|---|
| Go | github.com/cosmos/ibc-go | pkg:golang/github.com/cosmos/ibc-go |
| Go | github.com/cosmos/ibc-go/v2 | pkg:golang/github.com/cosmos/ibc-go/v2 |
| Go | github.com/cosmos/ibc-go/v3 | pkg:golang/github.com/cosmos/ibc-go/v3 |
| Go | github.com/cosmos/ibc-go/v4 | pkg:golang/github.com/cosmos/ibc-go/v4 |
| Go | github.com/cosmos/ibc-go/v5 | pkg:golang/github.com/cosmos/ibc-go/v5 |
| Go | github.com/cosmos/ibc-go/v6 | pkg:golang/github.com/cosmos/ibc-go/v6 |
| Go | github.com/cosmos/ibc-go/v7 | pkg:golang/github.com/cosmos/ibc-go/v7 |
| Go | github.com/cosmos/ibc-go/v8 | pkg:golang/github.com/cosmos/ibc-go/v8 |
Package-level exposure
OSV and GitHub Advisory data: ecosystem, package and range. SBOM matching uses this table.
| Ecosystem | Package | Affected range | Fix |
|---|---|---|---|
| Go | github.com/cosmos/ibc-go | from 0 | — |
| Go | github.com/cosmos/ibc-go/v2 | from 0 | — |
| Go | github.com/cosmos/ibc-go/v3 | from 0 | — |
| Go | github.com/cosmos/ibc-go/v4 | from 0 | — |
| Go | github.com/cosmos/ibc-go/v5 | from 0 | — |
| Go | github.com/cosmos/ibc-go/v6 | from 0 | — |
| Go | github.com/cosmos/ibc-go/v7 | before 7.9.2 | 7.9.2 |
| Go | github.com/cosmos/ibc-go/v8 | before 8.6.1 | 8.6.1 |
Same product
Go: all recordsOther highest-scoring records for the same primary product.
- GO-2025-3517Non-deterministic JSON Unmarshalling of IBC Acknowledgement can result in a chain halt in github.com/cosmos/ibc-go0Monitor
- GHSA-4wf3-5qj9-368vIBC-Go: Non-deterministic JSON Unmarshalling of IBC Acknowledgement can result in a chain halt0Monitor
- GO-2025-3494IBC-Go has Non-deterministic JSON Unmarshalling of IBC Acknowledgement in github.com/cosmos/ibc-go0Monitor
Published before and after this one in the same product
- ← EarlierGO-2024-2694May 20, 2024 · Potential Reentrancy using Timeout Callbacks in ibc-hooks in github.com/cosmos/ibc-go0Monitor
- ← EarlierGO-2024-2874May 23, 2024 · Inter-Blockchain Communication (IBC) protocol "Huckleberry" vulnerability in github.com/cosmos/ibc-go0Monitor
Remediation
Which version to upgrade to
Fix versions compiled from the vendor, package registries and Microsoft. Verify the vendor's note before upgrading.
| Product / package | Fixed version | Source |
|---|---|---|
| Go:github.com/cosmos/ibc-go/v7 | 7.9.2 | Package registry (OSV) |
| Go:github.com/cosmos/ibc-go/v8 | 8.6.1 | Package registry (OSV) |
Exploit status
No known public exploit
No public exploit has been observed yet. That doesn't mean you're safe, only that the bar is a little higher.
Research context
For pentesters and researchers: attack profile, score disagreement, timeline, patch commits, credits, variant and chain candidates, bug bounty scope. All derived from existing data; no exploit code.
Timeline
From publication to today: proof of concept, Metasploit module, CISA KEV and fix record. Dates are as reported by the sources.
No dated events beyond publication.
Patch and commit links
Commit, PR and diff links among the references. A starting point for patch-diffing and variant hunting; fixes, not exploits.
Not on record for this CVE: EPSS history · researcher credit · variant or chain candidate · public bounty program.
Technical details
Attack conditions
- Anyone who can reach it over the internet can trigger it.
- No account or password is required.
- No user action is required.
- No special conditions are required; it is repeatable.
If successful
- Confidentiality
- Integrity
- Availability
- Attack vector
- Network
- Attack complexity
- Low
- Privileges required
- None
- User interaction
- None
Weakness class (CWE)
CWE-502 · Deserialization of Untrusted DataCVSS vector
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
osv
Root cause
Data received over the network is deserialized into the language’s native object format without verifying its source. Code paths inside the object can be triggered during deserialization.
The bug in code
The whole CWE-502 classA representative example of this vulnerability class. Not the vendor's source code; it shows the faulty pattern and its fix.
Vulnerable
payload = sock.recv(65536)
job = pickle.loads(payload)Fixed
payload = sock.recv(65536)
if not hmac.compare_digest(sign(payload), header_sig):
raise PermissionError("invalid signature")
job = JobSchema.validate(json.loads(payload))Attack context
MITRE CAPEC attack patterns and ATT&CK techniques for this weakness class (CWE). A starting point for detection rules and threat hunting.
Attack patterns (CAPEC)
ATT&CK techniques
—
Change log (2)
- Fix✗ → ✓
- CVSS9.5 → —
For records you follow, these changes also arrive as notifications. →
References
Show all references (3 more)Show less
Vendor advisories and official records. Exploit/PoC links are deliberately left out.