App::Eduard - GnuPG email sign/encrypt testing bot
use App::Eduard; my ($status, %params) = process_message '/path/to/message'; if ($status eq 'signencrypt') { say 'This message is encrypted and signed with key ', $params{keyid}, ' from ', $params{email}; say 'Its contents are: ', $params{plaintext}; } elsif ($status eq 'encrypt') { say 'This message is encrypted but not signed'; say 'Its contents are: ', $params{plaintext}; } elsif ($status eq 'encrypt_error') { say 'This message is encrypted but I was unable to decrypt it. GnuPG output: ', $params{message}; } elsif ($status eq 'sign') { say 'This message is signed with key ', $params{keyid}, ' from ', $params{email}; } elsif ($status eq 'sign_error') { say 'This message is signed but I was unable to verify the signature. GnuPG output: ', $params{message}; } elsif ($status eq 'plain') { say 'This message is neither signed nor encrypted'; } elsif ($status eq 'error') { say 'There was an error processing the message: ', $params{message}; }
Eduard is Ceata's reimplementation of the Edward reply bot referenced in https://emailselfdefense.fsf.org/.
None by default.
Scan a message for PGP public keys, and import them. $entity is a MIME::Entity to scan, $gpg is a Mail::GnuPG instance.
Returns a list of fingerprints of keys found.
Analyze a message, looking for PGP signatures and encryption. $message can be:
\*STDIN
The function returns a status followed by a hash. Possible results:
The message is neither signed nor encrypted.
The message is signed but the signature could not be verified. GnuPG output is $message.
The message is signed with key $keyid from $email. GnuPG output is $message.
The message is encrypted and unable to be decrypted. GnuPG output is $message.
The message is encrypted and unsigned. $plaintext is the decrypted message as plain text, while $decrypted is a MIME::Entity representing the decrypted message. GnuPG output is $message.
The message is encrypted and signed with key $keyid from $email. $plaintext is the decrypted message as plain text, while $decrypted is a MIME::Entity representing the decrypted message. GnuPG output is $message.
There was an error while processing the message. The error can be found in $message.
This module is configured via the %ENV hash. See the eduard(1) manpage for more information.
eduard(1), http://ceata.org/proiecte/eduard
Marius Gavrilescu, <marius@ceata.org>
Copyright (C) 2014 by Fundația Ceata
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.18.2 or, at your option, any later version of Perl 5 you may have available.
To install App::Eduard, copy and paste the appropriate command in to your terminal.
cpanm
cpanm App::Eduard
CPAN shell
perl -MCPAN -e shell install App::Eduard
For more information on module installation, please visit the detailed CPAN module installation guide.