use Digest::MD5; my $fh; if (@ARGV) { my $file = shift; open $fh, $file or die "error: could not open $file: $!\n"; binmode $fh; } else { $fh = *STDIN; } printf "%08x\n", unpack "N", Digest::MD5->new->addfile($fh)->digest;
In reply to md5 short hash by thrig
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |