Crypt-CBC
view release on metacpan or search on metacpan
regenerate the IV in a short header that is emitted at the start of the
encrypted stream, or outputting a headerless encryption stream. In the
first case, Crypt::CBC will be able to decrypt the stream given just the
original key or passphrase. In the second case, you will have to provide
the original IV as well as the key/passphrase.
The -cipher option specifies which block cipher algorithm to use to
encode each section of the message. This argument is optional and will
default to the secure Crypt::Cipher::AES algorithm. You may use any
compatible block encryption algorithm that you have installed.
Currently, this includes Crypt::Cipher::AES, Crypt::DES,
Crypt::DES_EDE3, Crypt::IDEA, Crypt::Blowfish, Crypt::CAST5 and
Crypt::Rijndael. You may refer to them using their full names
("Crypt::IDEA") or in abbreviated form ("IDEA").
Instead of passing the name of a cipher class, you may pass an
already-created block cipher object. This allows you to take advantage
of cipher algorithms that have parameterized new() methods, such as
Crypt::Eksblowfish:
my $eksblowfish = Crypt::Eksblowfish->new(8,$salt,$key);
my $cbc = Crypt::CBC->new(-cipher=>$eksblowfish);
AUTHOR
Lincoln Stein, lstein@cshl.org
LICENSE
This module is distributed under the ARTISTIC LICENSE v2 using the same
terms as Perl itself.
SEE ALSO
perl(1), CryptX, Crypt::FileHandle, Crypt::Cipher::AES, Crypt::Blowfish,
Crypt::CAST5, Crypt::DES, Crypt::IDEA, Crypt::Rijndael
lib/Crypt/CBC.pm view on Meta::CPAN
the encrypted stream, or outputting a headerless encryption stream. In
the first case, Crypt::CBC will be able to decrypt the stream given
just the original key or passphrase. In the second case, you will have
to provide the original IV as well as the key/passphrase.
The B<-cipher> option specifies which block cipher algorithm to use to
encode each section of the message. This argument is optional and
will default to the secure Crypt::Cipher::AES algorithm.
You may use any compatible block encryption
algorithm that you have installed. Currently, this includes
Crypt::Cipher::AES, Crypt::DES, Crypt::DES_EDE3, Crypt::IDEA, Crypt::Blowfish,
Crypt::CAST5 and Crypt::Rijndael. You may refer to them using their
full names ("Crypt::IDEA") or in abbreviated form ("IDEA").
Instead of passing the name of a cipher class, you may pass an
already-created block cipher object. This allows you to take advantage
of cipher algorithms that have parameterized new() methods, such as
Crypt::Eksblowfish:
my $eksblowfish = Crypt::Eksblowfish->new(8,$salt,$key);
my $cbc = Crypt::CBC->new(-cipher=>$eksblowfish);
lib/Crypt/CBC.pm view on Meta::CPAN
Lincoln Stein, lstein@cshl.org
=head1 LICENSE
This module is distributed under the ARTISTIC LICENSE v2 using the
same terms as Perl itself.
=head1 SEE ALSO
perl(1), CryptX, Crypt::FileHandle, Crypt::Cipher::AES,
Crypt::Blowfish, Crypt::CAST5, Crypt::DES, Crypt::IDEA,
Crypt::Rijndael
=cut
#!/usr/bin/perl -w
use lib './lib','./blib/lib';
eval "use Crypt::DES()";
if ($@) {
print "1..0 # Skipped: Crypt::DES not installed\n";
exit;
}
print "1..33\n";
sub test {
local($^W) = 0;
my($num, $true,$msg) = @_;
print($true ? "ok $num\n" : "not ok $num $msg\n");
}
( run in 0.243 second using v1.01-cache-2.11-cpan-9a3d99fc6dc )