From: ijackson Date: Wed, 23 Mar 2016 15:58:24 +0000 (+0000) Subject: cope with new Digest::MD5 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ijackson/git?a=commitdiff_plain;h=947a0745cd8a5a02824ea4fcc247fd6a99a36511;p=bcp5-registry.git cope with new Digest::MD5 --- diff --git a/passwords.pl b/passwords.pl index 430b414..419b2ca 100644 --- a/passwords.pl +++ b/passwords.pl @@ -16,7 +16,7 @@ # License along with this file; if not, write to the Free Software # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. -use MD5; +use Digest::MD5 qw(md5); sub check_password () { my ($pw); @@ -41,7 +41,7 @@ sub calc_password ($$) { $keyhex =~ m/^[0-9a-f]+$/ or die "$keyhex ?"; $key= pack('H*',$keyhex); - $digest= MD5->hash("BCP5Registry password 1 $id ".$key); + $digest= md5("BCP5Registry password 1 $id ".$key); return unpack('H20',$digest); }