#ascii #binary-data #bases #convert #variety #base58 #base64

basen

Convert binary data to ASCII with a variety of supported bases

1 unstable release

0.1.0 Aug 2, 2022

#1987 in Text processing

Download history 297/week @ 2024-07-29 246/week @ 2024-08-05 150/week @ 2024-08-12 118/week @ 2024-08-19 251/week @ 2024-08-26 161/week @ 2024-09-02 184/week @ 2024-09-09 229/week @ 2024-09-16 167/week @ 2024-09-23 149/week @ 2024-09-30 206/week @ 2024-10-07 131/week @ 2024-10-14 162/week @ 2024-10-21 188/week @ 2024-10-28 104/week @ 2024-11-04 236/week @ 2024-11-11

698 downloads per month
Used in snug

MIT/Apache

11KB
208 lines

BaseN

Convert binary data to ASCII with a variety of supported bases.

assert_eq!(BASE58.encode_const_len(&1557596383284252235u64), "4chjCmhbVFY");
assert_eq!(BASE58.decode_const_len("4chjCmhbVFY"), Some(1557596383284252235u64));

Characters required (without padding):

bits 32 64 128 256 512
Base10 10 20 39 78 155
Base16 8 16 32 64 128
Base32 7 13 26 52 103
Base36 7 13 25 50 100
Base58 6 11 22 44 88
Base62 6 11 22 43 86
Base64 6 11 22 43 86

No runtime deps