[Rt-commit] r8970 - rt/branches/3.7-EXPERIMENTAL/lib/RT/Crypt

ruz at bestpractical.com ruz at bestpractical.com
Fri Sep 7 21:17:22 EDT 2007


Author: ruz
Date: Fri Sep  7 21:17:21 2007
New Revision: 8970

Modified:
   rt/branches/3.7-EXPERIMENTAL/lib/RT/Crypt/GnuPG.pm

Log:
* oops, forgot to add major check for key's capabilities

Modified: rt/branches/3.7-EXPERIMENTAL/lib/RT/Crypt/GnuPG.pm
==============================================================================
--- rt/branches/3.7-EXPERIMENTAL/lib/RT/Crypt/GnuPG.pm	(original)
+++ rt/branches/3.7-EXPERIMENTAL/lib/RT/Crypt/GnuPG.pm	Fri Sep  7 21:17:21 2007
@@ -1565,6 +1565,8 @@
     foreach my $key ( @keys ) {
         # skip disabled keys
         next if $key->{'Capabilities'} =~ /D/;
+        # skip keys not suitable for encryption
+        next unless $key->{'Capabilities'} =~ /e/i;
         # skip disabled, expired, revoke and keys with no trust,
         # but leave keys with unknown trust level
         next if $key->{'TrustLevel'} < 0;


More information about the Rt-commit mailing list