Function readpassphrase::clear_passphrase[][src]

pub fn clear_passphrase(pass: &mut str)
Expand description

Convenience function to securely clear a passphrase

Example:

let mut passphrase = "super secret password".to_string();
clear_passphrase(&mut passphrase);
assert_eq!(passphrase.as_bytes(), [0; 21].as_ref());