1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
//! Securely zero memory using core or OS intrinsics. This crate wraps
//! facilities specifically designed to securely zero memory in a common,
//! safe API.
//!
//! This crate deliberately avoids use of `cc`, C shims, and other "tricks"
//! to "securely" zero memory, preferring to use the appropriate intrinsic
//! on nightly, or on stable using FFI bindings to specifically designed
//! OS APIs for securely zeroing memory.
extern crate std;
// nightly: use `volatile_set_memory`
pub use secure_zero_memory;
// stable: use OS-specific APIs
pub use secure_zero_memory;