surrealpatch/core/src/iam/base.rs
Rushmore Mushambi 690dd55a86
Extract core lib into a standalone crate (#3423)
Co-authored-by: Gerard Guillemas Martos <gerard.guillemas@surrealdb.com>
2024-02-02 22:10:47 +00:00

12 lines
463 B
Rust

use base64_lib::alphabet::STANDARD;
use base64_lib::engine::general_purpose::GeneralPurpose;
use base64_lib::engine::general_purpose::GeneralPurposeConfig;
use base64_lib::engine::DecodePaddingMode;
pub use base64_lib::Engine;
pub const BASE64: GeneralPurpose = GeneralPurpose::new(&STANDARD, CONFIG);
pub const CONFIG: GeneralPurposeConfig = GeneralPurposeConfig::new()
.with_encode_padding(false)
.with_decode_padding_mode(DecodePaddingMode::Indifferent);