X-Git-Url: https://codewiz.org/gitweb?a=blobdiff_plain;ds=sidebyside;f=src%2Fshare%2Fkeytrans;h=f9288fa7740774e888e5fd569f31e244f4f392c2;hb=80d903a7cacc0c5c60adfb86067e7c348f83e4c2;hp=8b2e2ea52b926a006896de9b1adee71eea6b1f32;hpb=15d752f93a3a9807430fe8b3cd6e16f3cede8e7c;p=monkeysphere.git diff --git a/src/share/keytrans b/src/share/keytrans index 8b2e2ea..f9288fa 100755 --- a/src/share/keytrans +++ b/src/share/keytrans @@ -1,4 +1,4 @@ -#!/usr/bin/perl -w -T +#!/usr/bin/perl -T # keytrans: this is an RSA key translation utility; it is capable of # transforming RSA keys (both public keys and secret keys) between @@ -195,11 +195,11 @@ my $keyserver_prefs = { nomodify => 0x80 ########### Math/Utility Functions ############## -# see the bottom of page 43 of RFC 4880 +# see the bottom of page 44 of RFC 4880 (http://tools.ietf.org/html/rfc4880#page-44) sub simple_checksum { my $bytes = shift; - return unpack("%32W*",$bytes) % 65536; + return unpack("%16C*",$bytes); } # calculate the multiplicative inverse of a mod b this is euclid's