Symantec::PCAnywhere::Profile::CIF - Encodes and decodes Symantec pcAnywhere connection profiles
use Symantec::PCAnywhere::Profile::CIF; # Load CIF file from file my $cif = new Symantec::PCAnywhere::Profile::CIF(filename => $filename); # Load CIF data directly my $cif = new Symantec::PCAnywhere::Profile::CIF(data => $data); my %results = $cif->get_attrs( CallerName, CallerPassword, DisplayName ); while (my ($attr, $value) = each (%results)) { print "$attr\t= $value\n"; } # Create an empty CIF my $cif = new Symantec::PCAnywhere::Profile::CIF; $cif->set_attrs( CallerName => 'JohnDoe', CallerPassword => 'acw938nrh!' ); # Print the binary CIF file print $cif->encode;
This module is responsible for decoding of a pcAnywhere .CIF file that describes a caller that can connect to a pcAnywhere Host. CIF files seem to always be the same size (10504 bytes), which is helpful for decoding.
See this module's base class (Symantec::PCAnywhere::Profile) for more information on the decoding mechanism.
Version 0.06
Here is the public API; see this module's base class documentation for more information on the inner workings of the encoding and decoding process, as well as additional useful methods.
my $cif = new Symantec::PCAnywhere::Profile::CIF; my $cif = new Symantec::PCAnywhere::Profile::CIF(-filename => $filename); my $cif = new Symantec::PCAnywhere::Profile::CIF(filename => $filename); my $cif = new Symantec::PCAnywhere::Profile::CIF(-data => $cifdata); my $cif = new Symantec::PCAnywhere::Profile::CIF(data => $cifdata);
The "new" constructor takes any number of arguments and sets the appropriate flags internally before returning a new object. The arguments are considered as a list of key-value pairs which are inserted into the object data.
Provided with XOR-encoded CIF data, un-obscure the whole thing into the "clear" format. The return value is the same length as the input string, but after XOR decoding.
Provided with XOR-unencoded CIF data, obscure the whole thing into the "encrypted" format. The return value is the same length as the input string, but after XOR encoding.
This module is based very heavily on the work of Stephen Friedl at http://www.unixwiz.net/tools/pcainfo.html.
Based on http://www.cpan.org/modules/00modlist.long.html#ID2_Guidelinesf, refactor code to pass references to lists instead of lists.
They're in there somewhere. Let me know what you find.
Darren Kulp, <kulp@thekulp.com>, based on code from Stephen J. Friedl, (http://unixwiz.net/)
This code is in the public domain. Contains code placed in the public domain 2002 by Stephen Friedl.
"Symantec" and "pcAnywhere" are trademarks of Symantec Corp.
To install Symantec::PCAnywhere::Profile, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Symantec::PCAnywhere::Profile
CPAN shell
perl -MCPAN -e shell install Symantec::PCAnywhere::Profile
For more information on module installation, please visit the detailed CPAN module installation guide.