Perl Implementation

MIME::Base64 is a Perl module for base-64 encoding and decoding. You can read about this module at http://www.perldoc.com/perl5.6.1/lib/MIME/Base64.html.

You can encode and decode strings using the MIME::Base64 encode_base64 and decode_base64 methods:

use MIME::Base64;

$encoded = encode_base64('Aladdin:open sesame');
$decoded = decode_base64($encoded); 

Get HTTP: The Definitive Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.