pub struct FrostP256;Expand description
FROST-P256 Shamir primitives + single-party ECDSA-P256 sign.
Implementations§
Source§impl FrostP256
impl FrostP256
pub fn into_reference(val: FrostP256, env: Env) -> Result<Reference<FrostP256>>
pub fn into_instance(self, env: Env) -> Result<ClassInstance<FrostP256>>
Source§impl FrostP256
impl FrostP256
Sourcepub fn generate_keypair() -> NapiResult<FrostKeypair>
pub fn generate_keypair() -> NapiResult<FrostKeypair>
Generate a fresh P-256 keypair. Returns {privateKey, publicKey}
as 32-byte + 65-byte buffers respectively.
Trait Implementations§
Source§impl FromNapiMutRef for FrostP256
impl FromNapiMutRef for FrostP256
Source§unsafe fn from_napi_mut_ref(
env: napi_env,
napi_val: napi_value,
) -> Result<&'static mut Self>
unsafe fn from_napi_mut_ref( env: napi_env, napi_val: napi_value, ) -> Result<&'static mut Self>
Safety Read more
Source§impl FromNapiRef for FrostP256
impl FromNapiRef for FrostP256
Source§unsafe fn from_napi_ref(
env: napi_env,
napi_val: napi_value,
) -> Result<&'static Self>
unsafe fn from_napi_ref( env: napi_env, napi_val: napi_value, ) -> Result<&'static Self>
Safety Read more
Source§impl FromNapiValue for &FrostP256
impl FromNapiValue for &FrostP256
Source§unsafe fn from_napi_value(env: napi_env, napi_val: napi_value) -> Result<Self>
unsafe fn from_napi_value(env: napi_env, napi_val: napi_value) -> Result<Self>
Safety Read more
fn from_unknown(value: JsUnknown) -> Result<Self, Error>
Source§impl FromNapiValue for &mut FrostP256
impl FromNapiValue for &mut FrostP256
Source§unsafe fn from_napi_value(env: napi_env, napi_val: napi_value) -> Result<Self>
unsafe fn from_napi_value(env: napi_env, napi_val: napi_value) -> Result<Self>
Safety Read more
fn from_unknown(value: JsUnknown) -> Result<Self, Error>
Source§impl ToNapiValue for FrostP256
impl ToNapiValue for FrostP256
Source§unsafe fn to_napi_value(env: napi_env, val: FrostP256) -> Result<napi_value>
unsafe fn to_napi_value(env: napi_env, val: FrostP256) -> Result<napi_value>
Safety Read more
Source§impl ValidateNapiValue for &FrostP256
impl ValidateNapiValue for &FrostP256
Source§unsafe fn validate(env: napi_env, napi_val: napi_value) -> Result<napi_value>
unsafe fn validate(env: napi_env, napi_val: napi_value) -> Result<napi_value>
Safety Read more
Source§impl ValidateNapiValue for &mut FrostP256
impl ValidateNapiValue for &mut FrostP256
Source§unsafe fn validate(env: napi_env, napi_val: napi_value) -> Result<napi_value>
unsafe fn validate(env: napi_env, napi_val: napi_value) -> Result<napi_value>
Safety Read more
Auto Trait Implementations§
impl Freeze for FrostP256
impl RefUnwindSafe for FrostP256
impl Send for FrostP256
impl Sync for FrostP256
impl Unpin for FrostP256
impl UnsafeUnpin for FrostP256
impl UnwindSafe for FrostP256
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more