pub fn deserialize_option_secret_string<'de, D>(
deserializer: D,
) -> Result<Option<SecretString>, D::Error>where
D: Deserializer<'de>,Expand description
Helper function to deserialize optional secrets from encrypted base64 storage.
Supports three formats for backwards compatibility:
- Encrypted format (v2): base64(encrypted data with AAD)
- Legacy encrypted format (v1): base64(encrypted data without AAD)
- Plain text format: unencrypted plain string (for data stored before encryption was added)
Uses EncryptionContext for v2 decryption if set.