Module data_conversion

Module data_conversion 

Source
Expand description

data_conversion.rs

Utility functions for converting data between common formats like hexadecimal, Base64, and byte arrays.

Functionsยง

base64_to_bytes
Converts a Base64 encoded string to a byte vector. Uses the standard Base64 alphabet and padding.
base64url_nopad_to_bytes
Converts a Base64 encoded string (URL-safe, no padding) to a byte vector.
bytes_to_base64
Converts a byte slice to a Base64 encoded string. Uses the standard Base64 alphabet and padding.
bytes_to_base64url_nopad
Converts a byte slice to a Base64 encoded string (URL-safe, no padding).
bytes_to_hex
Converts a byte slice to a hexadecimal string.
hex_to_bytes
Converts a hexadecimal string to a byte vector.