Module std.base64
Support for Base64 encoding and decoding.
This module provides two default implementations of Base64 encoding,
 Base64 with a standard encoding alphabet, and a variant
 Base64URL that has a modified encoding alphabet designed to be
 safe for embedding in URLs and filenames.
 Both variants are implemented as instantiations of the template
 Base64Impl. Most users will not need to use this template
 directly; however, it can be used to create customized Base64 encodings,
 such as one that omits padding characters, or one that is safe to embed
 inside a regular expression.
Example
ubyte[] data = [0x14, 0xfb, 0x9c, 0x03, 0xd9, 0x7e];
const(char)[] encoded = Base64The range API is supported for both encoding and decoding:
Example
// Create MIME Base64 with CRLF, per line 76.
File f = File("./text.txt", "r");
scope(exit) fReferences
Classes
| Name | Description | 
|---|---|
| 
									Base64Exception
								 | Exception thrown upon encountering Base64 encoding or decoding errors. | 
Templates
| Name | Description | 
|---|---|
| 
									Base64Impl
								 | Template for implementing Base64 encoding and decoding. | 
Aliases
| Name | Type | Description | 
|---|---|---|
| Base64 |  | Implementation of standard Base64 encoding. | 
| Base64URL |  | Variation of Base64 encoding that is safe for use in URLs and filenames. | 
| Base64URLNoPadding |  | Unpadded variation of Base64 encoding that is safe for use in URLs and filenames, as used in RFCs 4648 and 7515 (JWS/JWT/JWE). | 
Authors
Masahiro Nakagawa, Daniel Murphy (Single value Encoder and Decoder)