{"id":"RUSTSEC-2026-0590","summary":"`Fixed` and `Dynamic` secret wrappers were not zeroized on drop","details":"In affected versions, the `Fixed\u003cT\u003e` and `Dynamic\u003cT\u003e` wrappers (and the\n`FixedNoClone` / `DynamicNoClone` variants in 0.6.x) did not wipe their contents\nwhen dropped. The types implemented the `zeroize::ZeroizeOnDrop` marker trait,\nwhich has no methods and does nothing by itself, but had no `Drop` implementation.\nThe documentation stated that secrets were zeroized on drop.\n\nA secret held in one of these wrappers stayed in the freed stack or heap memory\nafter the wrapper went out of scope, where it could be read by anything able to\nobserve that memory later, such as a core dump, swap, or a separate memory\ndisclosure bug.\n\nVersions before 0.5.0 are not affected: with the default `zeroize` feature they\nstored the secret in `secrecy::SecretBox` or `zeroize::Zeroizing`, both of which\nwipe on drop.\n\nThe flaw was fixed by making `zeroize` a required dependency, bounding the\nwrappers on `T: Zeroize`, and adding `Drop` implementations that call\n`zeroize()`. The first published release with the fix is 0.8.0-rc.1; the first\nstable release is 0.8.0. All affected versions have been yanked from crates.io.","modified":"2026-11-22T10:00:02.272887190Z","published":"2026-03-17T12:00:00Z","database_specific":{"license":"CC0-1.0"},"references":[{"type":"PACKAGE","url":"https://crates.io/crates/secure-gate"},{"type":"ADVISORY","url":"https://rustsec.org/advisories/RUSTSEC-2026-0590.html"},{"type":"WEB","url":"https://github.com/Slurp9187/secure-gate/blob/main/SECURITY.md#past-advisory"}],"affected":[{"package":{"name":"secure-gate","ecosystem":"crates.io","purl":"pkg:cargo/secure-gate"},"ranges":[{"type":"SEMVER","events":[{"introduced":"0.5.0"},{"fixed":"0.8.0-rc.1"}]}],"ecosystem_specific":{"affects":{"os":[],"functions":[],"arch":[]},"affected_functions":null},"database_specific":{"source":"https://github.com/rustsec/advisory-db/blob/osv/crates/RUSTSEC-2026-0590.json","informational":null,"categories":["memory-exposure"],"cvss":null}}],"schema_version":"1.9.2"}