Basic ASCII encoding and decoding ================================= Rev 0.12: Changed bytelength to length (thx Steve R) Rev 0.11: Slightly simplified calling sequence, based on CriTcl 0.30 Rev 0.10: Initial release Implementation of base64 encoding and decoding. Low-level commands are: set text [ascenc::b2a_64 bytes] convert string to base64 (input size must be multiple of 3) set bytes [ascenc::a2b_64 text] convert base64 to string (input size must be multiple of 4) Built on top, the following commands deal with "full" base64 conversion: set text [ascenc::b64encode bytes] convert binary string to base64, in lines of 64 chars set bytes [ascenc::b64decode text] convert base64 to binary string, ignoring newlines and padding