2015-10-16

[SOLVED]md5 checksum

md5perl
#File name: md5perl
#! /usr/bin/perl
use Digest::MD5;
 use IO::File;
 my $chk = Digest::MD5->new();
 foreach my $file (@ARGV)
 {
         $chk->addfile(IO::File->new($file));
         print "$file -> ",$chk->hexdigest,"\n";
 }




md5sum
root@srv030:/opt# md5sum mailserver
64bea36753fd33ad820b5c1717358c5c  mailserver
root@srv030:/opt# cat mailserver.md5
64bea36753fd33ad820b5c1717358c5c *mailserver
root@srv030:/opt# 








No comments:

Post a Comment