Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

(tye)Re2: Compact MD5 representation

by tye (Sage)
on Mar 21, 2001 at 00:42 UTC ( [id://65811]=note: print w/replies, xml ) Need Help??


in reply to Re: Re: (tye)Re: Compact MD5 representation
in thread Compact MD5 representation

OK, I'm (relatively) lazy. Looking at the source code for one Perl MD5 implementation, I see that the base64 output consists of A-Za-z0-9+/. Where does "=" come in? Why do you need to use 65 different characters?

        - tye (but my friends call me "Tye")

Replies are listed 'Best First'.
Re: (tye)Re2: Compact MD5 representation
by chipmunk (Parson) on Mar 21, 2001 at 01:06 UTC
    According to the docs for Mime::Base64, '=' is used to pad a Base64 encoded string to a multiple of four bytes.

    For MD5 hashes, they're always a multiple of four bytes anyway, so the '=' isn't needed. This is definitely good to know!

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://65811]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (2)
As of 2024-04-25 20:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found