pub struct Provider { /* private fields */ }Expand description
CryptoAuthLib provider structure
Implementations§
Source§impl Provider
impl Provider
Sourcepub fn set_access_keys(
&self,
access_keys_file_name: Option<String>,
) -> Option<AtcaStatus>
pub fn set_access_keys( &self, access_keys_file_name: Option<String>, ) -> Option<AtcaStatus>
Read access keys from a configuration file and setup the CALib to use them.
Source§impl Provider
impl Provider
Sourcepub fn generate_iv(&self) -> Result<Vec<u8>>
pub fn generate_iv(&self) -> Result<Vec<u8>>
Generate random non-zero initialization vector
Source§impl Provider
impl Provider
Sourcepub const DEFAULT_PROVIDER_NAME: &'static str = "cryptoauthlib-provider"
pub const DEFAULT_PROVIDER_NAME: &'static str = "cryptoauthlib-provider"
The default provider name for cryptoauthlib provider
Sourcepub const PROVIDER_UUID: &'static str = "b8ba81e2-e9f7-4bdd-b096-a29d0019960c"
pub const PROVIDER_UUID: &'static str = "b8ba81e2-e9f7-4bdd-b096-a29d0019960c"
The UUID for this provider
Trait Implementations§
Source§impl Provide for Provider
impl Provide for Provider
Source§fn describe(&self) -> Result<(ProviderInfo, HashSet<Opcode>)>
fn describe(&self) -> Result<(ProviderInfo, HashSet<Opcode>)>
Return a description of the current provider. Read more
Source§fn list_keys(
&self,
application_identity: &ApplicationIdentity,
_op: Operation,
) -> Result<Result>
fn list_keys( &self, application_identity: &ApplicationIdentity, _op: Operation, ) -> Result<Result>
Lists all keys belonging to the application.
Source§fn list_clients(&self, _op: Operation) -> Result<Result>
fn list_clients(&self, _op: Operation) -> Result<Result>
Lists all clients currently having data in the service.
Source§fn psa_generate_random(&self, op: Operation) -> Result<Result>
fn psa_generate_random(&self, op: Operation) -> Result<Result>
Execute a GenerateRandom operation.
Source§fn psa_generate_key(
&self,
application_identity: &ApplicationIdentity,
op: Operation,
) -> Result<Result>
fn psa_generate_key( &self, application_identity: &ApplicationIdentity, op: Operation, ) -> Result<Result>
Execute a GenerateKey operation. Read more
Source§fn psa_destroy_key(
&self,
application_identity: &ApplicationIdentity,
op: Operation,
) -> Result<Result>
fn psa_destroy_key( &self, application_identity: &ApplicationIdentity, op: Operation, ) -> Result<Result>
Execute a DestroyKey operation. Read more
Source§fn psa_import_key(
&self,
application_identity: &ApplicationIdentity,
op: Operation,
) -> Result<Result>
fn psa_import_key( &self, application_identity: &ApplicationIdentity, op: Operation, ) -> Result<Result>
Execute an ImportKey operation. Read more
Source§fn psa_sign_hash(
&self,
application_identity: &ApplicationIdentity,
op: Operation,
) -> Result<Result>
fn psa_sign_hash( &self, application_identity: &ApplicationIdentity, op: Operation, ) -> Result<Result>
Execute a SignHash operation. This operation only signs the short digest given but does not
hash it.
Source§fn psa_verify_hash(
&self,
application_identity: &ApplicationIdentity,
op: Operation,
) -> Result<Result>
fn psa_verify_hash( &self, application_identity: &ApplicationIdentity, op: Operation, ) -> Result<Result>
Execute a VerifyHash operation.
Source§fn psa_cipher_encrypt(
&self,
application_identity: &ApplicationIdentity,
op: Operation,
) -> Result<Result>
fn psa_cipher_encrypt( &self, application_identity: &ApplicationIdentity, op: Operation, ) -> Result<Result>
Encrypt a short message with a symmetric cipher.
Source§fn psa_cipher_decrypt(
&self,
application_identity: &ApplicationIdentity,
op: Operation,
) -> Result<Result>
fn psa_cipher_decrypt( &self, application_identity: &ApplicationIdentity, op: Operation, ) -> Result<Result>
Decrypt a short message with a symmetric cipher.
Source§fn psa_sign_message(
&self,
application_identity: &ApplicationIdentity,
op: Operation,
) -> Result<Result>
fn psa_sign_message( &self, application_identity: &ApplicationIdentity, op: Operation, ) -> Result<Result>
Sign a message with a private key.
Source§fn psa_verify_message(
&self,
application_identity: &ApplicationIdentity,
op: Operation,
) -> Result<Result>
fn psa_verify_message( &self, application_identity: &ApplicationIdentity, op: Operation, ) -> Result<Result>
Verify the signature of a message using a public key.
Source§fn psa_export_public_key(
&self,
application_identity: &ApplicationIdentity,
op: Operation,
) -> Result<Result>
fn psa_export_public_key( &self, application_identity: &ApplicationIdentity, op: Operation, ) -> Result<Result>
Execute an ExportPublicKey operation.
Source§fn psa_export_key(
&self,
application_identity: &ApplicationIdentity,
op: Operation,
) -> Result<Result>
fn psa_export_key( &self, application_identity: &ApplicationIdentity, op: Operation, ) -> Result<Result>
Execute an ExportKey operation.
Source§fn psa_aead_encrypt(
&self,
application_identity: &ApplicationIdentity,
op: Operation,
) -> Result<Result>
fn psa_aead_encrypt( &self, application_identity: &ApplicationIdentity, op: Operation, ) -> Result<Result>
Execute an AeadEncrypt operation.
Source§fn psa_aead_decrypt(
&self,
application_identity: &ApplicationIdentity,
op: Operation,
) -> Result<Result>
fn psa_aead_decrypt( &self, application_identity: &ApplicationIdentity, op: Operation, ) -> Result<Result>
Execute an AeadDecrypt operation.
Source§fn psa_raw_key_agreement(
&self,
application_identity: &ApplicationIdentity,
op: Operation,
) -> Result<Result>
fn psa_raw_key_agreement( &self, application_identity: &ApplicationIdentity, op: Operation, ) -> Result<Result>
Execute a RawKeyAgreement operation.
Source§fn list_providers(&self, _op: Operation) -> Result<Result>
fn list_providers(&self, _op: Operation) -> Result<Result>
List the providers running in the service.
Source§fn list_opcodes(&self, _op: Operation) -> Result<Result>
fn list_opcodes(&self, _op: Operation) -> Result<Result>
List the opcodes supported by the given provider.
Source§fn list_authenticators(&self, _op: Operation) -> Result<Result>
fn list_authenticators(&self, _op: Operation) -> Result<Result>
List the authenticators supported by the given provider.
Source§fn delete_client(
&self,
_application_identity: &ApplicationIdentity,
_op: Operation,
) -> Result<Result>
fn delete_client( &self, _application_identity: &ApplicationIdentity, _op: Operation, ) -> Result<Result>
Delete all data a client has in the service..
Source§fn ping(&self, _op: Operation) -> Result<Result>
fn ping(&self, _op: Operation) -> Result<Result>
Execute a Ping operation to get the wire protocol version major and minor information. Read more
Source§fn psa_asymmetric_encrypt(
&self,
_application_identity: &ApplicationIdentity,
_op: Operation,
) -> Result<Result>
fn psa_asymmetric_encrypt( &self, _application_identity: &ApplicationIdentity, _op: Operation, ) -> Result<Result>
Execute an AsymmetricEncrypt operation.
Source§fn psa_asymmetric_decrypt(
&self,
_application_identity: &ApplicationIdentity,
_op: Operation,
) -> Result<Result>
fn psa_asymmetric_decrypt( &self, _application_identity: &ApplicationIdentity, _op: Operation, ) -> Result<Result>
Execute an AsymmetricDecrypt operation.
Source§fn can_do_crypto(
&self,
_application_identity: &ApplicationIdentity,
_op: Operation,
) -> Result<Result>
fn can_do_crypto( &self, _application_identity: &ApplicationIdentity, _op: Operation, ) -> Result<Result>
Check if the crypto operation is supported by provider.
Source§fn prepare_key_attestation(
&self,
_application_identity: &ApplicationIdentity,
_op: Operation,
) -> Result<Result>
fn prepare_key_attestation( &self, _application_identity: &ApplicationIdentity, _op: Operation, ) -> Result<Result>
Prepare a key attestation operation.
Source§fn attest_key(
&self,
_application_identity: &ApplicationIdentity,
_op: Operation,
) -> Result<Result>
fn attest_key( &self, _application_identity: &ApplicationIdentity, _op: Operation, ) -> Result<Result>
Attest a key.
Auto Trait Implementations§
impl !Freeze for Provider
impl !RefUnwindSafe for Provider
impl !UnwindSafe for Provider
impl Send for Provider
impl Sync for Provider
impl Unpin for Provider
impl UnsafeUnpin for Provider
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