[prev] [thread] [next] [lurker] [Date index for 2005/02/07]
Author: richardc Date: 2005-02-07 16:47:21 +0000 (Mon, 07 Feb 2005) New Revision: 1833 Added: trunk/Siesta-Plugin-GPGList/ trunk/Siesta-Plugin-GPGList/Build.PL trunk/Siesta-Plugin-GPGList/MANIFEST.SKIP trunk/Siesta-Plugin-GPGList/lib/ trunk/Siesta-Plugin-GPGList/lib/Siesta/ trunk/Siesta-Plugin-GPGList/lib/Siesta/Plugin/ trunk/Siesta-Plugin-GPGList/lib/Siesta/Plugin/GPGList.pm Log: skel Added: trunk/Siesta-Plugin-GPGList/Build.PL =================================================================== --- trunk/Siesta-Plugin-GPGList/Build.PL 2005-02-07 10:22:50 UTC (rev 1832) +++ trunk/Siesta-Plugin-GPGList/Build.PL 2005-02-07 16:47:21 UTC (rev 1833) @@ -0,0 +1,13 @@ +use strict; +use Module::Build; +Module::Build->new( + module_name => 'Siesta::Plugin::GPGList', + license => 'perl', + requires => { + 'perl' => 5.006, + }, + build_requires => { + 'Test::More' => 0, + }, + create_makefile_pl => 'traditional', + )->create_build_script; Added: trunk/Siesta-Plugin-GPGList/MANIFEST.SKIP =================================================================== --- trunk/Siesta-Plugin-GPGList/MANIFEST.SKIP 2005-02-07 10:22:50 UTC (rev 1832) +++ trunk/Siesta-Plugin-GPGList/MANIFEST.SKIP 2005-02-07 16:47:21 UTC (rev 1833) @@ -0,0 +1,20 @@ +CVS/.* +\.svn/.* +\.cvsignore$ +\.Inline/.* +_Inline/.* +\.bak$ +\.tar$ +\.tgz$ +\.tar\.gz$ +~$ +^mess/ +^tmp/ +^testdata/ +^blib/ +^Makefile$ +^Makefile\.[a-z]+$ +^Build$ +^pm_to_blib$ +^_build/.* +~$ \ No newline at end of file Added: trunk/Siesta-Plugin-GPGList/lib/Siesta/Plugin/GPGList.pm =================================================================== --- trunk/Siesta-Plugin-GPGList/lib/Siesta/Plugin/GPGList.pm 2005-02-07 10:22:50 UTC (rev 1832) +++ trunk/Siesta-Plugin-GPGList/lib/Siesta/Plugin/GPGList.pm 2005-02-07 16:47:21 UTC (rev 1833) @@ -0,0 +1,74 @@ + +=head1 NAME + +Siesta::Plugin::GPGList - try and do something 'clever' with gpg + +=head1 DESCRIPTION + +This plugin must be used as a personal plugin at the start of the post +queue. This makes it run twice, the first time it for the list and +runs gpg decodes the mail with the lists private key. The second time +it runs it's running in the per-user pipeline so it gpg encodes with +mail with the public key of the subscriber. + +Hey presto - a secure (well as secure as the memory of the mail +server) mailing list! + +=head1 SIGH + +Periodically someone will say "hey, Siesta should be able to do +$what_this_plugin_does" and I'll say "it can, just write a plugin +which works $how_this_plugin_does". Eventually I realised it'd just +be easier if I wrote the damn thing. + +=cut + +package Siesta::Plugin::GPGList; +use strict; +use warnings; +use Siesta::Plugin; +use base qw( Siesta::Plugin ); +our $VERSION = '0.02'; +use Log::Log4perl; +our $logger = Log::Log4perl->get_logger; + +sub description { "do gpg stuff" } + +sub process { + my $self = shift; + my $mail = shift; + + unless ($self->member) { + # okay, we're handling for the list + # gpg decode the body, or give up + + return 1; # give up + } + + unless ($self->pref("private_key")) { + $logger->log( $self->member->email, " hasn't set private key"); + return 1; + } + + return 1; +} + + + +1; +__END__ + +=head1 AUTHOR + +Richard Clamp <richardc@xxxxxxxxx.xxx> + +=head1 COPYRIGHT + +Copyright 2005 Richard Clamp. All Rights Reserved. + +This program is free software; you can redistribute it +and/or modify it under the same terms as Perl itself. + +=head1 SEE ALSO + +=cut
Generated at 18:00 on 07 Feb 2005 by mariachi 0.52