version 1.1, 2007/01/28 16:17:54 |
version 1.4, 2007/08/10 05:13:31 |
|
|
#!/usr/bin/perl |
#!/usr/bin/perl |
|
# $RedRiver: example2.pl,v 1.3 2007/01/31 04:17:15 andrew Exp $ |
use strict; |
use strict; |
use warnings; |
use warnings; |
use diagnostics; |
|
|
|
use lib 'lib'; |
use Palm::PDB; |
use Palm::Keyring; |
use Palm::Keyring; |
|
|
my $pdb = new Palm::Keyring; |
my $pdb = new Palm::PDB; |
|
|
use YAML; |
$pdb->Load("Keys-Gtkr-example.PDB"); |
|
$pdb->Password('12345'); |
|
|
$pdb->Load("Keys-GtkrNEW.PDB"); |
foreach my $rec (@{ $pdb->{records} }) { |
$pdb->Decrypt('12345'); |
my $acct = $pdb->Decrypt($rec); |
|
|
print Dump $pdb; |
my $d = $acct->{3}->{data}; |
|
my $date = ($d->{year} + 1900) . '/' . ($d->{month} + 1) . '/' . $d->{day}; |
|
print join ":", $acct->{0}->{data} , $acct->{1}->{data}, |
|
$acct->{2}->{data}, $date, $acct->{255}->{data}; |
|
print "\n"; |
|
} |