Trait CoapClientCryptoProvider

Source
pub trait CoapClientCryptoProvider: Debug {
    // Required methods
    fn provide_key_for_hint(
        &mut self,
        hint: &CoapCryptoPskIdentity,
    ) -> CoapCryptoProviderResponse<Box<CoapCryptoPskData>>;
    fn provide_default_info(&mut self) -> CoapCryptoPskInfo;
}
Expand description

Trait implemented by types that can provide cryptographic information to CoapContexts and associated sessions when needed.

Required Methods§

Source

fn provide_key_for_hint( &mut self, hint: &CoapCryptoPskIdentity, ) -> CoapCryptoProviderResponse<Box<CoapCryptoPskData>>

Provide the appropriate cryptographic information for the given hint supplied by the server.

Return a CoapCryptoProviderResponse corresponding to the cryptographic information that should be used.

Note: Unsupported by the MBedTLS DTLS backend.

Source

fn provide_default_info(&mut self) -> CoapCryptoPskInfo

Provide the initial cryptographic information for client-side sessions associated with this provider.

Implementors§