{"id":"GHSA-9c8r-76f3-m426","aliases":["GHSA-9c8r-76f3-m426","RUSTSEC-2026-0499"],"related":[],"kind":"vulnerability","state":"published","title":"Signature::from_der reads a signature with bytes after it, a wrong sequence length or an unneeded zero as the signature","summary":"`Signature::from_der` read a DER-encoded ECDSA signature leniently. It read as\nthe signature: the signature followed by other bytes; a sequence length\nshorter than its contents, or longer with bytes after them (a length byte with\nits high bit set among them); and an R or S preceded by a zero byte it did not\nneed. It read a lone-zero R or S as zero.\n\n`messages::verify`, `compat::bsm::verify_message_der`,\n`auth::Certificate::verify`, `auth::VerifiableCertificate::verify`,\n`wallet::ProtoWallet::verify_signature` and\n`kvstore::KVStoreInterpreter::verify_signature` read through it, and each\nverified such a form of a valid signature. Given one signature a key holder\nmade, anyone could produce other byte strings that verify as that signature\nover the same data. No form verifies over other data: an application that acts\non the verdict alone is not affected; one that compares, hashes or stores a\nsignature's bytes is.\n\n0.8.6 refuses each form as `Error::InvalidSignature`. A signature's bytes are\nstill not unique after the patch: the same signature with S replaced by n - S\nverifies, so an application that keys on the bytes also requires\n`Signature::is_low_s()`.","summaryFormat":"markdown","summarySource":"rustsec","descriptions":[{"lang":"en","text":"`Signature::from_der` read a DER-encoded ECDSA signature leniently. It read as\nthe signature: the signature followed by other bytes; a sequence length\nshorter than its contents, or longer with bytes after them (a length byte with\nits high bit set among them); and an R or S preceded by a zero byte it did not\nneed. It read a lone-zero R or S as zero.\n\n`messages::verify`, `compat::bsm::verify_message_der`,\n`auth::Certificate::verify`, `auth::VerifiableCertificate::verify`,\n`wallet::ProtoWallet::verify_signature` and\n`kvstore::KVStoreInterpreter::verify_signature` read through it, and each\nverified such a form of a valid signature. Given one signature a key holder\nmade, anyone could produce other byte strings that verify as that signature\nover the same data. No form verifies over other data: an application that acts\non the verdict alone is not affected; one that compares, hashes or stores a\nsignature's bytes is.\n\n0.8.6 refuses each form as `Error::InvalidSignature`. A signature's bytes are\nstill not unique after the patch: the same signature with S replaced by n - S\nverifies, so an application that keys on the bytes also requires\n`Signature::is_low_s()`.","format":"markdown","source":"rustsec"}],"published":"2026-11-11T12:00:00.000Z","modified":"2026-11-12T08:00:03.174Z","severity":{"scorer":"RustSec Advisory Database","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N","score":5.3,"rating":"MEDIUM"},"severities":[{"scorer":"RustSec Advisory Database","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N","score":5.3,"rating":"MEDIUM"}],"cwes":[],"affected":[{"ranges":[{"type":"semver","introduced":"0.0.0-0","status":"affected","fixed":"0.8.6"},{"type":"semver","introduced":"0.9.0-beta.1","status":"affected","fixed":"0.9.0-beta.7.0"}],"ecosystem":"crates.io","package":"bsv-rs","purl":"pkg:cargo/bsv-rs","source":"rustsec"}],"references":[{"url":"https://crates.io/crates/bsv-rs","tags":["package"],"sources":["rustsec"]},{"url":"https://rustsec.org/advisories/RUSTSEC-2026-0499.html","tags":["advisory"],"sources":["rustsec"]},{"url":"https://github.com/Calhooon/bsv-rs/blob/v0.8.6/CHANGELOG.md","tags":["web"],"sources":["rustsec"]},{"url":"https://github.com/Calhooon/bsv-rs/issues/842","tags":["report"],"sources":["rustsec"]},{"url":"https://github.com/Calhooon/bsv-rs/pull/846","tags":["web"],"sources":["rustsec"]}],"credits":[],"sources":[{"source":"rustsec","name":"RustSec Advisory Database","id":"RUSTSEC-2026-0499","url":"https://rustsec.org/advisories/RUSTSEC-2026-0499.html","licence":"CC0-1.0","modified":"2026-11-12T08:00:03.174Z"}],"updatedAt":"2026-11-25T22:56:43.488Z"}