NAME
PerlIO::via::CBC - PerlIO layer for reading/writing CBC encrypted files
SYNOPSIS
use PerlIO::via::Crypt;
PerlIO::via::Crypt->config(
'key' => 'my secret key',
'cipher' => 'Blowfish',
'iv' => '$KJh#(}q',
'regenerate_key' => 0, # default true
'padding' => 'space',
'prepend_iv' => 0,
'pcbc' => 1 #default 0
);
open(my $fh, '>:via(PerlIO::via::CBC)', $file)
or die "Can't open $file for encryption: $!\n";
print $fh $lots_of_secret_data;
close($fh)
or die "Error closing file: $!\n";
open(my $fh, '<:via(PerlIO::via::CBC)', $file)
or die "Can't open $file for decryption: $!\n";
print <$fh>;
close($fh)
or die "Error closing file: $!\n";
DESCRIPTION
This module implements a PerlIO layer that can read and read CBC encrypted files. It uses Crypt::CBC to do the CBC. So check Crypt::CBC for more information.
config(%args)
Allows the configuration of the CBC. Check Crypt::CBC->new() for more information.
REQUIRED MODULES
Crypt::CBC (any)
SEE ALSO
AUTHOR
Sascha Kiefer<lt>perl@intertivityNOSP4M.com<gt>
COPYRIGHT AND LICENSE
Copyright (C) 2005 by Sascha Kiefer
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.4 or, at your option, any later version of Perl 5 you may have available.