diff options
author | 1999-09-29 04:35:07 +0000 | |
---|---|---|
committer | 1999-09-29 04:35:07 +0000 | |
commit | 913ec974266f8a62ab2e5ca34a31d6e6f75b3cf0 (patch) | |
tree | 62c001f84cb6413a049c5c811a08bfbe7c747b77 /lib/libssl/src/perl/cipher.pl | |
parent | fix byte counters; imain@netidea.com (diff) | |
download | wireguard-openbsd-913ec974266f8a62ab2e5ca34a31d6e6f75b3cf0.tar.xz wireguard-openbsd-913ec974266f8a62ab2e5ca34a31d6e6f75b3cf0.zip |
OpenSSL 0.9.4 merge
Diffstat (limited to 'lib/libssl/src/perl/cipher.pl')
-rw-r--r-- | lib/libssl/src/perl/cipher.pl | 39 |
1 files changed, 0 insertions, 39 deletions
diff --git a/lib/libssl/src/perl/cipher.pl b/lib/libssl/src/perl/cipher.pl deleted file mode 100644 index e774bceed22..00000000000 --- a/lib/libssl/src/perl/cipher.pl +++ /dev/null @@ -1,39 +0,0 @@ -#!/usr/bin/perl - -use ExtUtils::testlib; - -use SSLeay; - -$md=SSLeay::MD::new("md5"); - -foreach (@SSLeay::Cipher::names) - { - ($c=SSLeay::Cipher::new($_)) || - die "'$_' is an unknown cipher algorithm\n"; - - - $data="012345678abcdefghijklmnopqrstuvwxyz"; - $c->init("01234567abcdefghABCDEFGH","zyxwvut",1); - - $in =$c->update(substr($data, 0, 5)); - $in.=$c->update(substr($data, 5,10)); - $in.=$c->update(substr($data,15,1)); - $in.=$c->update(substr($data,16)); - - $in.=$c->final(); - - $c->init("01234567abcdefghABCDEFGH","zyxwvut",0); - $out=$c->update($in); - $out.=$c->final(); - - ($out eq $data) || die "decrypt for $_ failed:$!\n"; - - $md->init(); - $md->update($in); - $digest=$md->final(); - - print unpack("H*",$digest); - printf " %2d %2d %2d %s\n", $c->key_length(), $c->iv_length(), - $c->block_size(), $c->name(); - } - |