OpenPGP - Perl
Posted in Perl, on July 1, 2013 at 13:49
#!/usr/bin/perl


use Crypt::OpenPGP;
my $pgp = Crypt::OpenPGP->new;
$string = "encrypt this data";
$pass = "this is the passphrase";
$key_id = "E1773983";

#This Works:
my $ciphertext = $pgp->encrypt(
Data => $string,
Passphrase => $pass,
Recipients => $key_id,
Armour => 1
);

print "Content-type: text/html\n\n";
print "$ciphertext";

Share this code

| More

Use the link below to share the code:
HTML
BBCode