pub trait EncryptionProvider: Send + Sync {
// Required methods
fn encrypt(&self, plaintext: &str) -> Result<(String, String), String>;
fn decrypt(
&self,
ciphertext_b64: &str,
nonce_b64: &str,
) -> Result<String, String>;
fn is_enabled(&self) -> bool;
}Required Methods§
fn encrypt(&self, plaintext: &str) -> Result<(String, String), String>
fn decrypt( &self, ciphertext_b64: &str, nonce_b64: &str, ) -> Result<String, String>
fn is_enabled(&self) -> bool
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".