zeroize
Securely clear secrets from memory with a simple trait built on stable Rust primitives which guarantee memory is zeroed using an operation will not be 'optimized away' by the compiler. Uses a portable pure Rust implementation that works everywhere, even WASM!
1.9.0
636M downloads/mo
#143 most downloaded on crates.io
RustCrypto/utils
What this package is like to depend on
Last release 2 months ago
12 Jun 2026
Release timing varies
gaps range from 3 weeks to 1.3 years
Nearly every release is documented
notes for 19 of 19 stable releases
27 versions withdrawn
withdrawn after publishing
8 years old
46 releases · first in 2018
2 releases in the last 12 months
see the full history below
Release timeline
46 releases · Oct 2018 to Jun 2026Releases
latest 46-
1.9.012 Jun 2026Release notes
Open source →Added
Zeroizingis nowrepr(transparent)(#1253)optimization_barrierfunction (#1261)Zeroizingnow supports?Sized(#1318)zeroize_stackfunction (#1331)
Changed
Release notes
Open source →Added
Zeroizingis nowrepr(transparent)(#1253)optimization_barrierfunction (#1261)Zeroizingnow supports?Sized(#1318)zeroize_stackfunction (#1331)
Changed
-
1.8.229 Sep 2025 -
1.8.125 May 2024Release notes
Open source →Changed
- Feature-gate AVX-512 support under
simd; restores MSRV 1.60 (#1073)
- Feature-gate AVX-512 support under
-
1.8.024 Apr 2024 withdrawn -
1.7.016 Nov 2023 -
1.6.115 Nov 2023 withdrawnRelease notes
Open source →NOTE: yanked because #900 bumped MSRV to 1.60, which vioates our MSRV policy.
Added
- Impl
ZeroizeforMaybeUninit(#900)
Removed
- Unnecessary
cfgs on SIMD type impls (#930)
- Impl
-
1.6.026 Mar 2023 -
1.5.720 Jul 2022 -
1.5.629 Jun 2022 -
1.5.501 May 2022Release notes
Open source → -
1.5.417 Mar 2022 -
1.5.325 Feb 2022 -
1.5.231 Jan 2022 withdrawn -
1.5.127 Jan 2022 withdrawn -
1.5.014 Jan 2022 withdrawn -
1.5.0-pre07 Jan 2022 pre-release withdrawnNothing published for this version
-
1.4.305 Nov 2021Release notes
Open source →Added
- Implement
ZeroizeforNonZeroX
Changed
- Moved to
RustCrypto/utilsrepository
- Implement
-
1.4.221 Sep 2021 -
1.4.120 Jul 2021 -
1.4.018 Jul 2021Release notes
Open source →NOTE: This release includes an MSRV bump to Rust 1.51. Please use
zeroize = "1.3.0"if you would like to support older Rust versions.Added
- Use const generics to impl
Zeroizefor[Z; N]; MSRV 1.51 Zeroizing::clone_fromnow zeroizes the destination before cloning
- Use const generics to impl
-
1.3.019 Apr 2021Release notes
Open source →Added
- impl
ZeroizeforBox<[Z]> - Clear residual space within
Option
Changed
- Ensure
OptionisNonewhen zeroized - Bump MSRV to 1.47
- impl
-
1.2.009 Dec 2020Release notes
Open source →Added
Zeroizesupport for x86(-64) SIMD registers
Changed
- Simplify
String::zeroize - MSRV 1.44+
-
1.1.115 Sep 2020Release notes
Open source →- Add
doc_cfg - zeroize entire capacity of
String - zeroize entire capacity of
Vec
- Add
-
1.1.003 Dec 2019Release notes
Open source →- Add
TryZeroizetrait - Add
From<Z: Zeroize>impl forZeroizing<Z> - Remove
bytes-previewfeature
- Add
-
1.0.013 Oct 2019Release notes
Open source →- Initial 1.0 release 🎉
- zeroize_derive: Remove legacy
no_dropattribute support - Rename
bytesfeature tobytes-preview - Further relax
Zeroizetrait bounds forVec - Derive
Clone,Debug, andEqforZeroizing
-
1.0.0-pre30 Sep 2019 pre-release withdrawn -
0.10.103 Sep 2019 withdrawn -
0.10.020 Aug 2019 withdrawnRelease notes
Open source →Barring unforeseen circumstances, this release aims to be the last
0.xrelease prior to azeroize1.0 release.- Disable
zeroize_deriveCargo feature by default - Remove
stdfeature in favor ofalloc; MSRV 1.36+ - Deprecate
#[zeroize(no_drop)]attribute - Use 1.0
proc-macro2,quote, andsyncrates
- Disable
-
0.9.327 Jul 2019 withdrawn -
0.9.228 Jun 2019 withdrawn -
0.9.105 Jun 2019 withdrawn -
0.9.004 Jun 2019 withdrawnRelease notes
Open source →NOTICE: This release changes the default behavior of
derive(Zeroize)to no longer derive aDropimpl. If you wish to deriveDrop, you must now explicitly add a#[zeroize(drop)]attribute on the type for which you are derivingZeroize.- Remove CPU fences
- Remove scary language about undefined behavior
- Bound blanket array impls on
Zeroizeinstead ofDefaultIsZeroes - Require
zeroize(drop)orzeroize(no_drop)attributes when derivingZeroize. - Support stabilized 'alloc' crate
-
0.8.020 May 2019 withdrawn -
0.7.019 May 2019 withdrawnRelease notes
Open source →- Use synstructure for custom derive
- Add explicit array impls for
DefaultIsZeroes - Remove
nightlyfeature - Add
Zeroizing<Z>to zeroize values on drop
-
0.6.023 Mar 2019 withdrawnRelease notes
Open source →- Add ZeroizeOnDrop marker trait + custom derive
- Custom derive support for
Zeroize - Rename
ZeroizeWithDefaulttoDefaultIsZeroes
-
0.5.225 Dec 2018 withdrawn -
0.5.124 Dec 2018 withdrawn -
0.5.024 Dec 2018 withdrawnRelease notes
Open source →This release is a rewrite which replaces FFI bindings to OS-specific APIs with a pure Rust solution.
- Use
core::sync::atomicfences - Test wasm target
- Rewrite using
core::ptr::write_volatile
- Use
-
0.4.228 Nov 2018 withdrawn -
0.4.128 Nov 2018 withdrawn -
0.4.012 Oct 2018 withdrawn -
0.3.012 Oct 2018 withdrawn -
0.2.011 Oct 2018 withdrawn -
0.1.203 Oct 2018 withdrawn -
0.1.103 Oct 2018 withdrawn -
0.1.003 Oct 2018 withdrawn