You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by "Tim O\\'Brien" <to...@discursive.com> on 2006/01/07 21:34:48 UTC
Changing the Base64 Alphabet for Filename and URL safety
http://issues.apache.org/bugzilla/show_bug.cgi?id=31961
Old bug, but the problem is still relevant. Essentially, if you've ever tried
to use Base64 to encode anything meant for a URL, you've probably run into the
fact that Base64 includes "+" which tends to throw a spanner in the works. One
way to get around this is to just post process the result and replace the
offending character, but the RFC suggests an alternate alphabet.
http://www.ietf.org/rfc/rfc3548.txt see section 4
I think this merits some work, so I'm going to take a stab making base64Alphabet
and lookUpBase64Alphabet instance variables instead of being static variables
initialized in a (eek) static block.
Of course, this should be done without changing the released contract.
Tim O'Brien
tobrien@discursive.com
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org