Expand description
Optional serde integration for base64-ng.
This crate keeps serialization support out of the core package. It provides
explicit wrappers and #[serde(with = "...")] modules so applications must
choose the alphabet and padding policy at the field boundary.
§Security
Deserialization helpers in this crate use base64_ng::Engine::decode_vec,
the strict timing-variable decoder. They map decode failures to redacted
error classes, but they are not constant-time-oriented secret decoders. Do
not use these serde modules for API keys, bearer tokens, private keys, or
other secret-bearing fields when malformed-input timing matters. Decode
those values explicitly with base64_ng::ct or with
base64_ng_sanitization::CtDecodeSanitizationExt instead.
Modules§
- mime
- Serde helpers for MIME Base64 fields with 76-column CRLF wrapping.
- pem
- Serde helpers for PEM Base64 fields with 64-column LF wrapping.
- standard
- Serde helpers for strict standard padded Base64 fields.
- standard_
no_ pad - Serde helpers for strict standard unpadded Base64 fields.
- url_
safe - Serde helpers for URL-safe padded Base64 fields.
- url_
safe_ no_ pad - Serde helpers for URL-safe unpadded Base64 fields.
Structs§
- Base64
Standard - Owned bytes serialized as strict standard padded Base64.
- Base64
UrlSafe NoPad - Owned bytes serialized as URL-safe unpadded Base64.