in reply to Re^3: Base64 and byte arrays
in thread Base64 and byte arrays
If you're going to use string xor, why do it a character at a time?
Why indeed?
use MIME::Base64 qw( decode_base64 ); my $orig = decode_base64( $_ ); $orig ^= substr $orig, 1;
And your solution doesn't work. It appends a junk character.
joec_'s explaination didn't say what to do with the last byte so I left it in.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^5: Base64 and byte arrays
by ikegami (Patriarch) on Feb 05, 2009 at 05:01 UTC |