fn generate_nonce(len: usize) -> String {
    // Loop 24 times to create 24-byte String of random numbers.
    // Use OsRng to generate more "secure" random randomness.
    let mut nonce = String::new();
    for _ in 0..len {
        let rn = OsRng.gen_range(0, 9);
        nonce.push_str(&rn.to_string());
    }
    // Ship it
    nonce
}
// Generates a 24-byte string of random numbers.
Generates a 24-byte string of random numbers.
Generates a 24 - byte string of random numbers .
fn generate_nonce(len: usize) -> String {
    // Loop 24 times to create 24-byte String of random numbers.
    // Use OsRng to generate more "secure" random randomness.
    let mut nonce = String::new();
    for _ in 0..len {
        let rn = OsRng.gen_range(0, 9);
        nonce.push_str(&rn.to_string());
    }
    // Ship it
    nonce
}
fn generate_nonce ( len : usize ) -> String { // Loop 24 times to create 24-byte String of random numbers. // Use OsRng to generate more "secure" random randomness. let mut nonce = String :: new ( ) ; for _ in 0 .. len { let rn = OsRng . gen_range ( 0 , 9 ) ; nonce . push_str ( & rn . to_string ( ) ) ; } // Ship it nonce }
Generates a 24-byte string of random numbers.
Generates a 24 - byte string of random numbers .
len
usize
len
usize