Struct iop_keyvault_wasm::JsSeed
source · [−]pub struct JsSeed { /* private fields */ }
Expand description
The seed used for BIP32 derivations. A seed cannot be turned back into a phrase, because there is salted hashing involed in creating it from the BIP39 mnemonic phrase.
Implementations
sourceimpl JsSeed
impl JsSeed
sourcepub fn new(bytes: &[u8]) -> Result<JsSeed, JsValue>
pub fn new(bytes: &[u8]) -> Result<JsSeed, JsValue>
Creates seed from a raw 512-bit binary seed
sourcepub fn demo_phrase() -> String
pub fn demo_phrase() -> String
A BIP39 phrase we use in most of the demo videos and proof-of-concept applications. Do not use it in production code.
sourcepub fn legacy_password() -> String
pub fn legacy_password() -> String
Legacy password used in the 0.0.1 version of the crate. Since 0.0.2 the crate always requires a password, which should be “” by default when the user does not provide one. (BIP39 standard for “25th word”)
Trait Implementations
sourceimpl FromWasmAbi for JsSeed
impl FromWasmAbi for JsSeed
sourceimpl IntoWasmAbi for JsSeed
impl IntoWasmAbi for JsSeed
sourceimpl OptionFromWasmAbi for JsSeed
impl OptionFromWasmAbi for JsSeed
sourceimpl OptionIntoWasmAbi for JsSeed
impl OptionIntoWasmAbi for JsSeed
sourceimpl RefFromWasmAbi for JsSeed
impl RefFromWasmAbi for JsSeed
type Anchor = Ref<'static, JsSeed>
type Anchor = Ref<'static, JsSeed>
The type that holds the reference to Self
for the duration of the
invocation of the function that has an &Self
parameter. This is
required to ensure that the lifetimes don’t persist beyond one function
call, and so that they remain anonymous. Read more
sourceunsafe fn ref_from_abi(js: Self::Abi) -> Self::Anchor
unsafe fn ref_from_abi(js: Self::Abi) -> Self::Anchor
Recover a Self::Anchor
from Self::Abi
. Read more
sourceimpl RefMutFromWasmAbi for JsSeed
impl RefMutFromWasmAbi for JsSeed
Auto Trait Implementations
impl RefUnwindSafe for JsSeed
impl Send for JsSeed
impl Sync for JsSeed
impl Unpin for JsSeed
impl UnwindSafe for JsSeed
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ReturnWasmAbi for T where
T: IntoWasmAbi,
impl<T> ReturnWasmAbi for T where
T: IntoWasmAbi,
type Abi = <T as IntoWasmAbi>::Abi
type Abi = <T as IntoWasmAbi>::Abi
Same as IntoWasmAbi::Abi
sourcefn return_abi(self) -> <T as ReturnWasmAbi>::Abi
fn return_abi(self) -> <T as ReturnWasmAbi>::Abi
Same as IntoWasmAbi::into_abi
, except that it may throw and never
return in the case of Err
. Read more