pub trait HostEncryptionKey: Send {
// Required methods
fn algorithm_name(
&mut self,
self_: Resource<EncryptionKey>,
) -> Result<String>;
fn algorithm_hash(
&mut self,
self_: Resource<EncryptionKey>,
) -> Result<Option<String>>;
fn algorithm_length(
&mut self,
self_: Resource<EncryptionKey>,
) -> Result<Option<u32>>;
fn algorithm_public_exponent(
&mut self,
self_: Resource<EncryptionKey>,
) -> Result<Option<Vec<u8>>>;
}Required Methods§
Sourcefn algorithm_name(&mut self, self_: Resource<EncryptionKey>) -> Result<String>
fn algorithm_name(&mut self, self_: Resource<EncryptionKey>) -> Result<String>
The registry name of the algorithm family this key is bound
to, e.g. "RSA-OAEP" (WebCrypto’s KeyAlgorithm.name).
Sourcefn algorithm_hash(
&mut self,
self_: Resource<EncryptionKey>,
) -> Result<Option<String>>
fn algorithm_hash( &mut self, self_: Resource<EncryptionKey>, ) -> Result<Option<String>>
The digest bound at mint, e.g. "SHA-256".
Sourcefn algorithm_length(
&mut self,
self_: Resource<EncryptionKey>,
) -> Result<Option<u32>>
fn algorithm_length( &mut self, self_: Resource<EncryptionKey>, ) -> Result<Option<u32>>
The key’s length in bits for algorithms parameterized by one (the RSA modulus length).
Sourcefn algorithm_public_exponent(
&mut self,
self_: Resource<EncryptionKey>,
) -> Result<Option<Vec<u8>>>
fn algorithm_public_exponent( &mut self, self_: Resource<EncryptionKey>, ) -> Result<Option<Vec<u8>>>
The public exponent for RSA-family keys, as WebCrypto’s
RsaKeyAlgorithm.publicExponent denominates it: the
exponent’s big-endian bytes ([1, 0, 1] for 65537). none
for algorithms without one.
Implementations on Foreign Types§
Source§impl<_T: HostEncryptionKey + ?Sized + Send> HostEncryptionKey for &mut _T
impl<_T: HostEncryptionKey + ?Sized + Send> HostEncryptionKey for &mut _T
Source§fn algorithm_name(&mut self, self_: Resource<EncryptionKey>) -> Result<String>
fn algorithm_name(&mut self, self_: Resource<EncryptionKey>) -> Result<String>
The registry name of the algorithm family this key is bound
to, e.g. "RSA-OAEP" (WebCrypto’s KeyAlgorithm.name).
Source§fn algorithm_hash(
&mut self,
self_: Resource<EncryptionKey>,
) -> Result<Option<String>>
fn algorithm_hash( &mut self, self_: Resource<EncryptionKey>, ) -> Result<Option<String>>
The digest bound at mint, e.g. "SHA-256".
Source§fn algorithm_length(
&mut self,
self_: Resource<EncryptionKey>,
) -> Result<Option<u32>>
fn algorithm_length( &mut self, self_: Resource<EncryptionKey>, ) -> Result<Option<u32>>
The key’s length in bits for algorithms parameterized by one (the RSA modulus length).
Source§fn algorithm_public_exponent(
&mut self,
self_: Resource<EncryptionKey>,
) -> Result<Option<Vec<u8>>>
fn algorithm_public_exponent( &mut self, self_: Resource<EncryptionKey>, ) -> Result<Option<Vec<u8>>>
The public exponent for RSA-family keys, as WebCrypto’s
RsaKeyAlgorithm.publicExponent denominates it: the
exponent’s big-endian bytes ([1, 0, 1] for 65537). none
for algorithms without one.