[Rt-commit] rt branch, smime, updated. rt-3.8.7-185-g2018b46
Ruslan Zakirov
ruz at bestpractical.com
Tue Feb 23 21:33:55 EST 2010
The branch, smime has been updated
via 2018b46a68bee5316cf89057f235b27577eb403f (commit)
from bdd40381bc192e6f74b9504748e21bbb2fa3f32c (commit)
Summary of changes:
lib/RT/Crypt.pm | 60 ++++++++++++++++++++++++++++++++++++
lib/RT/Crypt/GnuPG.pm | 2 +-
lib/RT/Crypt/SMIME.pm | 81 +++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 142 insertions(+), 1 deletions(-)
- Log -----------------------------------------------------------------
commit 2018b46a68bee5316cf89057f235b27577eb403f
Author: Ruslan Zakirov <ruz at bestpractical.com>
Date: Wed Feb 24 05:33:09 2010 +0300
SMIME documentation
diff --git a/lib/RT/Crypt.pm b/lib/RT/Crypt.pm
index 48fbc07..170f23d 100644
--- a/lib/RT/Crypt.pm
+++ b/lib/RT/Crypt.pm
@@ -7,6 +7,66 @@ package RT::Crypt;
require RT::Crypt::GnuPG;
require RT::Crypt::SMIME;
+=head1 NAME
+
+RT::Crypt - encrypt/decrypt and sign/verify subsystem for RT
+
+=head1 DESCRIPTION
+
+This module provides support for encryption and signing of outgoing messages,
+as well as the decryption and verification of incoming emails using variouse
+encryption standards. At this moment L<GnuPG|RT::Crypt::GnuPG> and
+L<SMIME|RT::Crypt::SMIME> protocols are supported.
+
+=head1 CONFIGURATION
+
+You can control the configuration of this subsystem from RT's configuration file.
+Some options are available via the web interface, but to enable this functionality,
+you MUST start in the configuration file.
+
+For each protocol there is a hash with the same name in the configuration file.
+This hash controls RT specific options regarding the protocol. It allows you to
+enable/disable facility or change the format of messages, for example GnuPG use
+the following config:
+
+ Set( %GnuPG,
+ Enable => 1,
+ ... other options ...
+ );
+
+Enable the only key that generic for all protocols. A protocol may have
+additional options to tune behaviour.
+
+However, note that you B<must> add the
+L<Auth::Crypt|RT::Interface::Email::Auth::Crypt> email filter to enable
+the handling of incoming encrypted/signed messages.
+
+=head2 %Crypt
+
+Config option hash to choose protocols decrypted and verified
+in incoming messages, pick protocol for outgoing emails, behaviour on
+errors during decryptions and signatures.
+
+By default all these options are generated. Every enabled protocol
+is checked on incomming messages, but you can change that:
+
+ Set( %Crypt,
+ ...
+ Incoming => ['SMIME'],
+ ...
+ );
+
+Protocol for outgoing emails can be only one and by default it's
+first one value from above list.
+
+ Set( %Crypt,
+ ...
+ Outgoing => 'GnuPG',
+ ...
+ );
+
+=cut
+
our @PROTOCOLS = ('GnuPG', 'SMIME');
our %PROTOCOLS = map { lc $_ => $_ } @PROTOCOLS;
diff --git a/lib/RT/Crypt/GnuPG.pm b/lib/RT/Crypt/GnuPG.pm
index 0bdeb64..d431c8b 100644
--- a/lib/RT/Crypt/GnuPG.pm
+++ b/lib/RT/Crypt/GnuPG.pm
@@ -64,7 +64,7 @@ RT::Crypt::GnuPG - encrypt/decrypt and sign/verify email messages with the GNU P
=head1 DESCRIPTION
This module provides support for encryption and signing of outgoing messages,
-as well as the decryption and verification of incoming email.
+as well as the decryption and verification of incoming emails.
=head1 CONFIGURATION
diff --git a/lib/RT/Crypt/SMIME.pm b/lib/RT/Crypt/SMIME.pm
index 6e9607b..1aa48c0 100644
--- a/lib/RT/Crypt/SMIME.pm
+++ b/lib/RT/Crypt/SMIME.pm
@@ -1,3 +1,50 @@
+# BEGIN BPS TAGGED BLOCK {{{
+#
+# COPYRIGHT:
+#
+# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC
+# <jesse at bestpractical.com>
+#
+# (Except where explicitly superseded by other copyright notices)
+#
+#
+# LICENSE:
+#
+# This work is made available to you under the terms of Version 2 of
+# the GNU General Public License. A copy of that license should have
+# been provided with this software, but in any event can be snarfed
+# from www.gnu.org.
+#
+# This work is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+# 02110-1301 or visit their web page on the internet at
+# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html.
+#
+#
+# CONTRIBUTION SUBMISSION POLICY:
+#
+# (The following paragraph is not intended to limit the rights granted
+# to you to modify and distribute this software under the terms of
+# the GNU General Public License and is only of importance to you if
+# you choose to contribute your changes and enhancements to the
+# community by submitting them to Best Practical Solutions, LLC.)
+#
+# By intentionally submitting any modifications, corrections or
+# derivatives to this work, or any other work intended for use with
+# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+# you are the copyright holder for those contributions and you grant
+# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+# royalty-free, perpetual, license to use, copy, create derivative
+# works based on those contributions, and sublicense and distribute
+# those contributions and any derivatives thereof.
+#
+# END BPS TAGGED BLOCK }}}
use strict;
use warnings;
@@ -10,6 +57,40 @@ use IPC::Run3 0.036 'run3';
use String::ShellQuote 'shell_quote';
use RT::Util 'safe_run_child';
+=head1 NAME
+
+RT::Crypt::SMIME - encrypt/decrypt and sign/verify email messages with the SMIME
+
+=head1 CONFIGURATION
+
+You should start from reading L<RT::Crypt>.
+
+=head2 %SMIME
+
+ Set( %SMIME,
+ Enable => 1,
+ OpenSSL => '/opt/local/bin/openssl',
+ Keyring => '/opt/rt3/var/data/smime',
+ Passphrase => {
+ 'queue.address at exampl.com' => 'passphrase',
+ },
+ );
+
+=head3 OpenSSL
+
+Path to openssl executable.
+
+=head3 Keyring
+
+Path to directory with keys and certificates for queues. Key and certificates
+should be stored in a PEM file named F<email.address at example.com.pem>.
+
+=head3 Passphrase
+
+Hash with passphrases for keys in the keyring.
+
+=cut
+
{ my $cache = shift;
sub OpenSSLPath {
return $cache ||= RT->Config->Get('SMIME')->{'OpenSSL'};
-----------------------------------------------------------------------
More information about the Rt-commit
mailing list