GHSA-wwq9-3cpr-mm53 Borsh serialization of HashMap is non-canonical

Not scored Published

Non-canonical HashMap serialization in Borsh can cause consensus splits and treat equivalent objects as distinct, impacting blockchain or distributed systems.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Over the internet
Victim action needed
Not needed
Fix
Available

What is GHSA-wwq9-3cpr-mm53?

GHSA-wwq9-3cpr-mm53 is a vulnerability in hashbrown, published on 11 Oct 2024. An attacker can exploit it over the internet without logging in, with no action from the victim.

Official description

The borsh serialization of the HashMap did not follow the borsh specification. It potentially produced non-canonical encodings dependent on insertion order. It also did not perform canonicty checks on decoding.

This can result in consensus splits and cause equivalent objects to be considered distinct.

This was patched in 0.15.1.

Which versions are affected by GHSA-wwq9-3cpr-mm53?

3 open source packages ship an affected version, including hashbrown.

PackageAffectedFixed in
hashbrown crates.ioFrom 0.15.00.15.1
hashbrown crates.ioFrom 0.15.00.15.1
hashbrown crates.ioFrom 0.15.00.15.1

How do I fix GHSA-wwq9-3cpr-mm53?

Upgrade hashbrown to 0.15.1 or later.

Is GHSA-wwq9-3cpr-mm53 being exploited?

There is no known exploitation of GHSA-wwq9-3cpr-mm53 in the wild and no public exploit code.

Sources

Also known as RUSTSEC-2024-0402.

Is GHSA-wwq9-3cpr-mm53 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free