Advisory

RUSTSEC-2024-0402

Also known as: GHSA-wwq9-3cpr-mm53

Summary

Borsh serialization of HashMap is non-canonical

Details

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.

Severity

Not rated by the source.

Dates

Published
2024-10-11 12:00 UTC
Modified
2025-10-28 06:29 UTC

Affected packages and fixes

hashbrown

crates.io · All systems

Affected

  • introduced 0.15.0, fixed 0.15.1 (semver)

Fixed versions

0.15.1

Fix

  • Fixed version 0.15.1
    cargo update -p hashbrown --precise 0.15.1

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: RustSec Advisory Database · CC0-1.0

Sources & licences