pub struct MemoryInstance { /* private fields */ }Trait Implementations§
Source§impl Default for MemoryInstance
impl Default for MemoryInstance
Source§fn default() -> MemoryInstance
fn default() -> MemoryInstance
Returns the “default value” for a type. Read more
impl Send for MemoryInstance
Source§impl StoreInstance for MemoryInstance
impl StoreInstance for MemoryInstance
Source§fn put_secret(
&mut self,
module: &str,
app: &str,
key_id: &str,
key: *mut c_void,
) -> Result<()>
fn put_secret( &mut self, module: &str, app: &str, key_id: &str, key: *mut c_void, ) -> Result<()>
Insert a secret key into the private compartment, indexed by
key_id.Source§fn get_secret(
&self,
module: &str,
app: &str,
key_id: &str,
) -> Result<*mut c_void>
fn get_secret( &self, module: &str, app: &str, key_id: &str, ) -> Result<*mut c_void>
Fetch a secret key from the private compartment by
key_id.
Returns crate::error::Error::ValueNotFound if absent.Source§fn put_public(
&mut self,
module: &str,
app: &str,
identity: &str,
key: *mut c_void,
sig: &[u8],
) -> Result<()>
fn put_public( &mut self, module: &str, app: &str, identity: &str, key: *mut c_void, sig: &[u8], ) -> Result<()>
Insert a public key into the public compartment, indexed by
identity, with a detached signature over the identity.Source§fn get_public(
&self,
module: &str,
app: &str,
identity: &str,
) -> Result<(*mut c_void, Vec<u8>)>
fn get_public( &self, module: &str, app: &str, identity: &str, ) -> Result<(*mut c_void, Vec<u8>)>
Fetch a public key from the public compartment by
identity.
Returns the key handle and the stored signature bytes.Source§fn enumerate(
&self,
module: &str,
app: &str,
compartment: Compartment,
) -> Result<Vec<(*mut c_void, String)>>
fn enumerate( &self, module: &str, app: &str, compartment: Compartment, ) -> Result<Vec<(*mut c_void, String)>>
Enumerate entries in one compartment of one
(module, app)
scope. Each entry is the opaque key handle paired with its index
string (key_id for private, canonical identity for public).Source§fn sign(
&self,
_module: &str,
_app: &str,
_key_id: &str,
_algorithm: &str,
_message: &[u8],
) -> Result<Vec<u8>>
fn sign( &self, _module: &str, _app: &str, _key_id: &str, _algorithm: &str, _message: &[u8], ) -> Result<Vec<u8>>
Sign
message with the remote key named by key_id, using the
provider-specific algorithm name (e.g. "ECDSA_SHA_256" on
AWS KMS, "EC_SIGN_P256_SHA256" on Cloud KMS, "ES256" on Key
Vault). Input is the raw message — providers that sign digests
hash it themselves or the backend does. This is the remote-sign
half of the sign-with-handle contract: backends that hold keys
out-of-process (cloud KMS, PKCS#11, TPM) implement it; local
backends keep the default.impl Sync for MemoryInstance
Auto Trait Implementations§
impl Freeze for MemoryInstance
impl RefUnwindSafe for MemoryInstance
impl Unpin for MemoryInstance
impl UnsafeUnpin for MemoryInstance
impl UnwindSafe for MemoryInstance
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