[Rt-commit] rt branch, 4.4-trunk, updated. rt-4.4.4-505-g43acfb645b

? sunnavy sunnavy at bestpractical.com
Thu Jun 3 16:31:25 EDT 2021


The branch, 4.4-trunk has been updated
       via  43acfb645b556e1c3d2d57bc5d7c610517664be4 (commit)
      from  3effbaf7493cce28baf8c3df15b81581e53a7589 (commit)

Summary of changes:
 t/mail/crypt-gnupg.t | 10 ++++++++--
 t/web/crypt-gnupg.t  |  5 +++--
 2 files changed, 11 insertions(+), 4 deletions(-)

- Log -----------------------------------------------------------------
commit 43acfb645b556e1c3d2d57bc5d7c610517664be4
Author: Andrew Ruthven <puck at catalyst.net.nz>
Date:   Fri May 21 23:44:56 2021 +1200

    Disable using WKD on GnuPG tests that might attempt to use the network.
    
    If GnuPG isn't able to use the network (DNS and HTTPS) then the error
    message returned from a failed WKD lookup is different than one which
    fails due to the key not existing.
    
    Given it is a Debian policy requirement[0] to during build no remote
    network access is allowed, we'll disable WKD usage.
    
    [0] https://www.debian.org/doc/debian-policy/ch-source.html#main-building-script-debian-rules
    
    Debian-Bug: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=988905
    Patch-Name: rt_test_gnupg_disable_wkd.diff
    
    Fixes: I#37159

diff --git a/t/mail/crypt-gnupg.t b/t/mail/crypt-gnupg.t
index 36d2ff1b44..b731f95bb3 100644
--- a/t/mail/crypt-gnupg.t
+++ b/t/mail/crypt-gnupg.t
@@ -9,7 +9,13 @@ BEGIN {
         RT::Test::get_abs_relocatable_dir( File::Spec->updir(), qw/data gnupg keyrings/ ) );
 }
 
-use RT::Test::Crypt GnuPG => 1, tests => undef, gnupg_options => { homedir => $homedir, quiet => 1 };
+use RT::Test::Crypt GnuPG => 1,
+  tests => undef,
+  gnupg_options => {
+    homedir => $homedir,
+    quiet => 1,
+    'auto-key-locate' => 'local',
+  };
 use Test::Warn;
 
 my $gnupg_version = RT::Test::Crypt::gnupg_version;
@@ -171,7 +177,7 @@ diag 'encryption only, bad recipient';
             Entity => $entity,
             Sign   => 0,
         );
-    } qr/public key not found|error retrieving 'keyless\@example.com' via WKD: No data/;
+    } qr/No public key|public key not found/;
 
     ok( $res{'exit_code'}, 'no way to encrypt without keys of recipients');
     ok( $res{'logger'}, "errors are in logger" );
diff --git a/t/web/crypt-gnupg.t b/t/web/crypt-gnupg.t
index 550d52e11c..23cc7dfccf 100644
--- a/t/web/crypt-gnupg.t
+++ b/t/web/crypt-gnupg.t
@@ -7,6 +7,7 @@ use RT::Test::Crypt
   gnupg_options => {
     passphrase    => 'recipient',
     'trust-model' => 'always',
+    'auto-key-locate' => 'local',
 };
 use Test::Warn;
 use MIME::Head;
@@ -378,7 +379,7 @@ warning_like {
     $tick->Create(Subject => 'owner lacks pubkey', Queue => 'general',
                   Owner => $nokey);
 } [
-    qr/nokey\@example.com: skipped: public key not found|error retrieving 'nokey\@example.com' via WKD: No data/,
+    qr/nokey\@example.com: skipped: (?:No public key|public key not found)/,
     qr/Recipient 'nokey\@example.com' is unusable/,
 ];
 ok(my $id = $tick->id, 'created ticket for owner-without-pubkey');
@@ -400,7 +401,7 @@ my $status;
 warning_like {
     ($status, $id) = RT::Test->send_via_mailgate($mail);
 } [
-    qr/nokey\@example.com: skipped: public key not found|error retrieving 'nokey\@example.com' via WKD: No data/,
+    qr/nokey\@example.com: skipped: (?:No public key|public key not found)/,
     qr/Recipient 'nokey\@example.com' is unusable/,
 ];
 

-----------------------------------------------------------------------


More information about the rt-commit mailing list