/// Creates a TOML file that contains encrypted master and returns `Keys` derived from it.
Creates a TOML file that contains encrypted master and returns `Keys` derived from it.
Creates a TOML file that contains encrypted master and returns ` Keys ` derived from it .
pub fn generate_keys<P: AsRef<Path>>(path: P, passphrase: &[u8]) -> Result<Keys, failure::Error> {
    let tree = SecretTree::new(&mut thread_rng());
    save_master_key(path, passphrase, tree.seed())?;
    generate_keys_from_master_password(tree)
        .ok_or_else(|| format_err!("Error deriving keys from master key."))
}
pub fn generate_keys < P : AsRef < Path > > ( path : P , passphrase : & [ u8 ] ) -> Result < Keys , failure :: Error > { let tree = SecretTree :: new ( & mut thread_rng ( ) ) ; save_master_key ( path , passphrase , tree . seed ( ) ) ? ; generate_keys_from_master_password ( tree ) . ok_or_else ( | | format_err ! ( " " ) ) }
Creates a TOML file that contains encrypted master and returns `Keys` derived from it.
Creates a TOML file that contains encrypted master and returns ` Keys ` derived from it .
path
P
passphrase
&[u8]