Comments on: Get a md5 of a string on a command line http://www.terminally-incoherent.com/blog/2007/01/10/get-a-md5-of-a-string-on-a-command-line/ I will not fix your computer. Tue, 04 Aug 2020 22:34:33 +0000 hourly 1 https://wordpress.org/?v=4.7.26 By: Utku Can Ölmez http://www.terminally-incoherent.com/blog/2007/01/10/get-a-md5-of-a-string-on-a-command-line/#comment-13481 Wed, 04 Nov 2009 00:00:05 +0000 http://www.terminally-incoherent.com/blog/2007/01/10/get-a-md5-of-a-string-on-a-command-line/#comment-13481

You can do it without openssl & dont forget to use ‘-n’ with echo.

#!/bin/sh
echo -n $* | md5sum

Reply  |  Quote
]]>
By: Utku Can Ölmez http://www.terminally-incoherent.com/blog/2007/01/10/get-a-md5-of-a-string-on-a-command-line/#comment-13480 Tue, 03 Nov 2009 23:57:49 +0000 http://www.terminally-incoherent.com/blog/2007/01/10/get-a-md5-of-a-string-on-a-command-line/#comment-13480

You can do it without openssl.

#!/bin/sh
echo -n $* | md5sum

Reply  |  Quote
]]>
By: Utku Can Ölmez http://www.terminally-incoherent.com/blog/2007/01/10/get-a-md5-of-a-string-on-a-command-line/#comment-13479 Tue, 03 Nov 2009 23:46:07 +0000 http://www.terminally-incoherent.com/blog/2007/01/10/get-a-md5-of-a-string-on-a-command-line/#comment-13479

echo -n test | md5sum

Reply  |  Quote
]]>
By: Luke http://www.terminally-incoherent.com/blog/2007/01/10/get-a-md5-of-a-string-on-a-command-line/#comment-2406 Thu, 11 Jan 2007 16:30:16 +0000 http://www.terminally-incoherent.com/blog/2007/01/10/get-a-md5-of-a-string-on-a-command-line/#comment-2406

Heh – I didn’t even think of that. I like yours better than mine now!

I think what we have here is programmer vs. admin way of thinking.

Programmer automatically goes “hey, I bet there is a [some-language] module/library for that somewhere…” when admin goes “I bet there is a tool for that somewhere…” :P

Reply  |  Quote
]]>
By: Craig Betts http://www.terminally-incoherent.com/blog/2007/01/10/get-a-md5-of-a-string-on-a-command-line/#comment-2405 Thu, 11 Jan 2007 15:55:17 +0000 http://www.terminally-incoherent.com/blog/2007/01/10/get-a-md5-of-a-string-on-a-command-line/#comment-2405

Here is my version of the same thing . . .

#!/bin/sh

echo $* | openssl dgst -md5

I always seem to have openssl, but not always Digest::MD5.

Reply  |  Quote
]]>