//! Hierarchical deterministic key derivation for OpenSSH and X.509.

mod error;
mod node;
mod openssh;
mod path;
mod seed;
pub mod x509;

pub use error::{Error, PathError, SeedError};
pub use node::{Ed25519Material, Node};
pub use openssh::{encode_private_key, format_authorized_key};
pub use path::{parse_path, Path};
pub use seed::{init_seed, last_mnemonic};
pub use x509::{X509Certificate, X509Params};

/// Creates a new master node from the provided seed bytes.
pub fn master(seed: &[u8]) -> Result<Node, Error> {
    Node::master(seed)
}
