md5 on a string

To get the md5 hash of a string from the command line, do e.g. this:

echo -n hallo | md5sum

It is important to do “echo -n” to prevent echo from outputting the trailing new line. Otherwise the newline will be included in the hash.

Leave a Reply