From alon.barlev at gmail.com Mon Jul 3 20:23:31 2017 From: alon.barlev at gmail.com (Alon Bar-Lev) Date: Mon, 3 Jul 2017 21:23:31 +0300 Subject: gpgme master build sandbox violations Message-ID: Hi, While waiting ages for gpgme-1.9.1 release, I checked master and noticed the following sandbox violations. It tries to create /run/user/XXX while it should use either TMPDIR or the builddir. Thanks, Alon --- Making all in tests make[2]: Entering directory '/var/tmp/portage/app-crypt/gpgme-1.9.1/work/gpgme-1.9.1-beta43/tests' Making all in gpg make[3]: Entering directory '/var/tmp/portage/app-crypt/gpgme-1.9.1/work/gpgme-1.9.1-beta43/tests/gpg' echo no-force-v3-sigs > ./gpg.conf echo pinentry-program /var/tmp/portage/app-crypt/gpgme-1.9.1/work/gpgme-1.9.1-beta43/tests/gpg/pinentry > ./gpg-agent.conf gpgconf --kill all * ACCESS DENIED: mkdir: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 * ACCESS DENIED: mkdir: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 * ACCESS DENIED: mkdir: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 /bin/mkdir -p ./private-keys-v1.d for k in 13CD0F3BDF24BE53FE192D62F18737256FF6E4FD 76F7E2B35832976B50A27A282D9B87E44577EB66 A0747D5F9425E6664F4FFBEED20FBCA79FDED2BD 13CBE3758AFE42B5E5E2AE4CED27AFA455E3F87F 7A030357C0F253A5BBCD282FFC4E521B37558F5C; do \ cp ./$k private-keys-v1.d/$k.key; \ done echo x > ./private-keys-v1.d/gpg-sample.stamp gpg --batch --no-permission-warning \ --import ./pubdemo.asc gpg: keybox '/var/tmp/portage/app-crypt/gpgme-1.9.1/work/gpgme-1.9.1-beta43/tests/gpg/pubring.kbx' created gpg: /var/tmp/portage/app-crypt/gpgme-1.9.1/work/gpgme-1.9.1-beta43/tests/gpg/trustdb.gpg: trustdb created gpg: key 2D727CC768697734: public key "Alfa Test (demo key) < alfa at example.net>" imported * ACCESS DENIED: mkdir: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 * ACCESS DENIED: mkdir: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 gpg: key FE180B1DA9E3B0B2: public key "Bob (demo key)" imported gpg: key 9EEF34CD4B11B25F: public key "Yankee Test (demo key) < yankee at example.net>" imported gpg: key 6BC4778054ACD246: public key "Zulu Test (demo key) < zulu at example.net>" imported gpg: Total number processed: 26 gpg: imported: 26 gpg --batch --no-permission-warning \ --import ./secdemo.asc gpg: key 2D727CC768697734: "Alfa Test (demo key) " 1 new signature * ACCESS DENIED: mkdir: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 gpg: key 2D727CC768697734: secret key imported make[3]: Entering directory '/var/tmp/portage/app-crypt/gpgme-1.9.1/work/gpgme-1.9.1-beta43/tests/gpgsm' echo disable-crl-checks > ./gpgsm.conf echo faked-system-time 1008241200 >> ./gpgsm.conf echo 32100C27173EF6E9C4E9A25D3D69F86D37A4F939 > ./trustlist.txt echo >> ./trustlist.txt echo "# CN=test cert 1,OU=Aegypten Project,O=g10 Code GmbH,L=D?sseldorf,C=DE" >> ./trustlist.txt echo "3CF405464F66ED4A7DF45BBDD1E4282E33BDB76E S" >> ./trustlist.txt gpgconf --kill all * ACCESS DENIED: mkdir: /run/user/1000/gnupg/d.51ih5c4sxjgpci4ftrcx8c49 * ACCESS DENIED: mkdir: /run/user/1000/gnupg/d.51ih5c4sxjgpci4ftrcx8c49 * ACCESS DENIED: mkdir: /run/user/1000/gnupg/d.51ih5c4sxjgpci4ftrcx8c49 /bin/mkdir -p ./private-keys-v1.d cp ./32100C27173EF6E9C4E9A25D3D69F86D37A4F939 private-keys-v1.d/32100C27173EF6E9C4E9A25D3D69F86D37A4F939.key echo x > ./private-keys-v1.d/gpg-sample.stamp FORMAT: F - Function called FORMAT: S - Access Status FORMAT: P - Path as passed to function FORMAT: A - Absolute Path (not canonical) FORMAT: R - Canonical Path FORMAT: C - Command Line F: mkdir S: deny P: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 A: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 R: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 C: gpg-connect-agent --no-autostart KILLAGENT F: mkdir S: deny P: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 A: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 R: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 C: gpg-connect-agent -s --no-autostart GETINFO scd_running /if ${! $?} scd killscd /end F: mkdir S: deny P: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 A: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 R: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 C: gpg-connect-agent --no-autostart --dirmngr KILLDIRMNGR F: mkdir S: deny P: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 A: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 R: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 C: gpg --batch --no-permission-warning --import ./pubdemo.asc F: mkdir S: deny P: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 A: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 R: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 C: gpg-agent --homedir /var/tmp/portage/app-crypt/gpgme-1.9.1/work/gpgme-1.9.1-beta43/tests/gpg --use-standard-socket --daemon F: mkdir S: deny P: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 A: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 R: /run/user/1000/gnupg/d.dn67o4dwds88dto43wzt7y31 C: gpg --batch --no-permission-warning --import ./secdemo.asc F: mkdir S: deny P: /run/user/1000/gnupg/d.51ih5c4sxjgpci4ftrcx8c49 A: /run/user/1000/gnupg/d.51ih5c4sxjgpci4ftrcx8c49 R: /run/user/1000/gnupg/d.51ih5c4sxjgpci4ftrcx8c49 C: gpg-connect-agent --no-autostart KILLAGENT F: mkdir S: deny P: /run/user/1000/gnupg/d.51ih5c4sxjgpci4ftrcx8c49 A: /run/user/1000/gnupg/d.51ih5c4sxjgpci4ftrcx8c49 R: /run/user/1000/gnupg/d.51ih5c4sxjgpci4ftrcx8c49 C: gpg-connect-agent -s --no-autostart GETINFO scd_running /if ${! $?} scd killscd /end F: mkdir S: deny P: /run/user/1000/gnupg/d.51ih5c4sxjgpci4ftrcx8c49 A: /run/user/1000/gnupg/d.51ih5c4sxjgpci4ftrcx8c49 R: /run/user/1000/gnupg/d.51ih5c4sxjgpci4ftrcx8c49 C: gpg-connect-agent --no-autostart --dirmngr KILLDIRMNGR F: mkdir S: deny P: /run/user/1000/gnupg/d.sapwjz18zz5c65r7ujpk4nyu A: /run/user/1000/gnupg/d.sapwjz18zz5c65r7ujpk4nyu R: /run/user/1000/gnupg/d.sapwjz18zz5c65r7ujpk4nyu C: gpg-connect-agent --no-autostart KILLAGENT F: mkdir S: deny P: /run/user/1000/gnupg/d.sapwjz18zz5c65r7ujpk4nyu A: /run/user/1000/gnupg/d.sapwjz18zz5c65r7ujpk4nyu R: /run/user/1000/gnupg/d.sapwjz18zz5c65r7ujpk4nyu C: gpg-connect-agent -s --no-autostart GETINFO scd_running /if ${! $?} scd killscd /end F: mkdir S: deny P: /run/user/1000/gnupg/d.sapwjz18zz5c65r7ujpk4nyu A: /run/user/1000/gnupg/d.sapwjz18zz5c65r7ujpk4nyu R: /run/user/1000/gnupg/d.sapwjz18zz5c65r7ujpk4nyu C: gpg-connect-agent --no-autostart --dirmngr KILLDIRMNGR F: mkdir S: deny P: /run/user/1000/gnupg/d.sapwjz18zz5c65r7ujpk4nyu A: /run/user/1000/gnupg/d.sapwjz18zz5c65r7ujpk4nyu R: /run/user/1000/gnupg/d.sapwjz18zz5c65r7ujpk4nyu C: gpg --no-permission-warning --import ../../../tests/gpg/pubdemo.asc F: mkdir S: deny P: /run/user/1000/gnupg/d.sapwjz18zz5c65r7ujpk4nyu A: /run/user/1000/gnupg/d.sapwjz18zz5c65r7ujpk4nyu R: /run/user/1000/gnupg/d.sapwjz18zz5c65r7ujpk4nyu C: gpg-agent --homedir /var/tmp/portage/app-crypt/gpgme-1.9.1/work/gpgme-1.9.1-beta43/lang/qt/tests --use-standard-socket --daemon F: mkdir S: deny P: /run/user/1000/gnupg/d.sapwjz18zz5c65r7ujpk4nyu A: /run/user/1000/gnupg/d.sapwjz18zz5c65r7ujpk4nyu R: /run/user/1000/gnupg/d.sapwjz18zz5c65r7ujpk4nyu C: gpg --no-permission-warning --passphrase abc --import ../../../tests/gpg/secdemo.asc -------------- next part -------------- An HTML attachment was scrubbed... URL: From dgouttegattat at incenp.org Wed Jul 5 11:22:46 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Wed, 5 Jul 2017 11:22:46 +0200 Subject: [PATCH] pinentry-gtk: Always set the window as transient. Message-ID: <20170705092246.13785-1-dgouttegattat@incenp.org> * gtk+-2/pinentry-gtk-2.c (create_window): Setup the make_transient callback whether we ask for a passphrase or not. -- Making the window transient seems necessary for (at least some) tiling window managers to make sure the dialog is floating. GnuPG-bug-id: T3253 Signed-off-by: Damien Goutte-Gattat --- gtk+-2/pinentry-gtk-2.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/gtk+-2/pinentry-gtk-2.c b/gtk+-2/pinentry-gtk-2.c index dee0360..d467ec5 100644 --- a/gtk+-2/pinentry-gtk-2.c +++ b/gtk+-2/pinentry-gtk-2.c @@ -113,9 +113,9 @@ constrain_size (GtkWidget *win, GtkRequisition *req, gpointer data) } -/* Realize the window as transient if we grab the keyboard. This - makes the window a modal dialog to the root window, which helps the - window manager. See the following quote from: +/* Realize the window as transient. This makes the window a modal + dialog to the root window, which helps the window manager. + See the following quote from: https://standards.freedesktop.org/wm-spec/wm-spec-1.4.html#id2512420 Implementing enhanced support for application transient windows @@ -586,12 +586,12 @@ create_window (pinentry_t ctx) #endif g_signal_connect (G_OBJECT (win), "size-request", G_CALLBACK (constrain_size), NULL); + + g_signal_connect (G_OBJECT (win), + "realize", G_CALLBACK (make_transient), NULL); + if (!confirm_mode) { - if (pinentry->grab) - g_signal_connect (G_OBJECT (win), - "realize", G_CALLBACK (make_transient), NULL); - /* We need to grab the keyboard when its visible! not when its mapped (there is a difference) */ g_object_set (G_OBJECT(win), "events", -- 2.9.0 From wk at gnupg.org Wed Jul 5 15:17:32 2017 From: wk at gnupg.org (Werner Koch) Date: Wed, 05 Jul 2017 15:17:32 +0200 Subject: [PATCH] pinentry-gtk: Always set the window as transient. In-Reply-To: <20170705092246.13785-1-dgouttegattat@incenp.org> (Damien Goutte-Gattat's message of "Wed, 5 Jul 2017 11:22:46 +0200") References: <20170705092246.13785-1-dgouttegattat@incenp.org> Message-ID: <87inj7qaz7.fsf@wheatstone.g10code.de> Pushed. Thanks. Salam-Shalom, Werner p.s. > GnuPG-bug-id: T3253 Please don't prefix the numbger with the 'T" this is just an interal Phrabicator thing and would trouble us the next time we switch the BTS. -- Die Gedanken sind frei. Ausnahmen regelt ein Bundesgesetz. -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 227 bytes Desc: not available URL: From forenjunkie at chello.at Fri Jul 7 02:01:05 2017 From: forenjunkie at chello.at (forenjunkie) Date: Fri, 7 Jul 2017 02:01:05 +0200 Subject: gpgme python bindings for windows Message-ID: <3f46cfb9-b9ae-3b95-9f1a-e3984d6fe91f@chello.at> Hi, How to install the python bindings of gpgme on windows? I found the bindings in the gpgme git repo, but nothing on how to compile them on windows thanks lovetox From justus at g10code.com Fri Jul 7 11:33:37 2017 From: justus at g10code.com (Justus Winter) Date: Fri, 07 Jul 2017 11:33:37 +0200 Subject: gpgme python bindings for windows In-Reply-To: <3f46cfb9-b9ae-3b95-9f1a-e3984d6fe91f@chello.at> References: <3f46cfb9-b9ae-3b95-9f1a-e3984d6fe91f@chello.at> Message-ID: <87y3s0zj4e.fsf@europa.jade-hamburg.de> Hello, forenjunkie writes: > How to install the python bindings of gpgme on windows? > > I found the bindings in the gpgme git repo, but nothing on how to > compile them on windows This is an open problem. We cross-compile all our software for windows with MinGW, but we have not yet done that for the Python bindings. If you manage to do that, please do share your findings. Cheers, Justus -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 487 bytes Desc: not available URL: From dgouttegattat at incenp.org Sat Jul 8 15:43:18 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Sat, 8 Jul 2017 15:43:18 +0200 Subject: Scute release ahead Message-ID: Hi GnuPG folks, I plan to release version 1.5.0 of Scute, the PKCS#11 module for Scdaemon, very soon. I think this is long overdue since the last released version, 1.4.0, came out in 2010. If you are aware of any blocker that should delays the release, or if you are currently working on a patch that you think should be merged into version 1.5.0, please let me know. Otherwise, the release will probably occur sometimes next week. "If anyone here has any reason why this release should not be done, let him speak now or forever remain silent." Regards, Damien -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 488 bytes Desc: OpenPGP digital signature URL: From yurchor at ukr.net Sat Jul 8 17:07:30 2017 From: yurchor at ukr.net (Yuri Chornoivan) Date: Sat, 08 Jul 2017 18:07:30 +0300 Subject: [gpg/scute] Fix minor typos Message-ID: <9810782.sjqn37MnQy@localhost.localdomain> Hi, Just a fix for a few minor typos in comments and docs. Thanks for your time. Best regards, Yuri -------------- next part -------------- A non-text attachment was scrubbed... Name: 1.patch Type: text/x-patch Size: 2882 bytes Desc: not available URL: From dgouttegattat at incenp.org Sat Jul 8 21:42:21 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Sat, 8 Jul 2017 21:42:21 +0200 Subject: [gpg/scute] Fix minor typos In-Reply-To: <9810782.sjqn37MnQy@localhost.localdomain> References: <9810782.sjqn37MnQy@localhost.localdomain> Message-ID: <4c50db10-80bf-db41-19ba-ae825b95ef6e@incenp.org> On 07/08/2017 05:07 PM, Yuri Chornoivan wrote: > Just a fix for a few minor typos in comments and docs. Merged, thanks! (Note that it is generally not needed to patch doc/manual/texinfo.tex, as this file comes from the TeXinfo project and is copied automatically into our source tree by Automake. We update it occasionally from the upstream TeXinfo source.) Regards, Damien -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 488 bytes Desc: OpenPGP digital signature URL: From aheinlein at gmx.com Tue Jul 11 15:53:40 2017 From: aheinlein at gmx.com (Andreas Heinlein) Date: Tue, 11 Jul 2017 15:53:40 +0200 Subject: Certificate for dev.gnupg.org expired? Message-ID: <215b1607-02c3-1751-6b9b-1714cbc09d14@gmx.com> Hello, I noticed the certificate for https://dev.gnupg.org/ just expired a few minutes ago? Sorry, did not know whom to contact. Andreas From kai at gnupg.org Tue Jul 11 17:16:23 2017 From: kai at gnupg.org (Kai Michaelis) Date: Tue, 11 Jul 2017 17:16:23 +0200 Subject: Certificate for dev.gnupg.org expired? In-Reply-To: <215b1607-02c3-1751-6b9b-1714cbc09d14@gmx.com> References: <215b1607-02c3-1751-6b9b-1714cbc09d14@gmx.com> Message-ID: <6684fc57-cb2e-08fc-20c0-2c4b47620d7d@gnupg.org> Hello Andreas, sorry our cron job broke :(. It should work now. Regards Kai On 07/11/2017 03:53 PM, Andreas Heinlein wrote: > Hello, > > I noticed the certificate for https://dev.gnupg.org/ just expired a few > minutes ago? > > Sorry, did not know whom to contact. > > Andreas > > _______________________________________________ > Gnupg-devel mailing list > Gnupg-devel at gnupg.org > http://lists.gnupg.org/mailman/listinfo/gnupg-devel > -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 228 bytes Desc: OpenPGP digital signature URL: From albrecht.dress at arcor.de Wed Jul 12 21:23:23 2017 From: albrecht.dress at arcor.de (Albrecht =?iso-8859-1?b?RHJl3w==?=) Date: Wed, 12 Jul 2017 21:23:23 +0200 Subject: [GpgME] signing w/ protocol CMS -> 'Nich implementiert'? Message-ID: Hi all, I develop the crypto functions for a MUA (Balsa) using GpgME and ran into an issue when I try to sign a S/MIME (CMS) message: the function gpgme_op_sign() returns (in German locale) the error "Nich implementiert". The output of running the application with GPGME_DEBUG=6 is attached. Decryption and signature verification as well as listing the signer certificates for CMS using GpgME works just fine. GpgSM and the key are also fine, i.e. I can successfully run 'gpgsm --sign --local-user 0x6F1DDFCA some_file > signature' on the command line. My system is a 64-bit Ubuntu 16.04 LTS, with gpgme 1.6.0 and gpgsm 2.1.11. BTW, I implemented these functions years ago, and iirc, S/MIME signing worked fine using GpgME those days (I typically use gpg keys, so I cannot recall when...). Any insight would be highly appreciated! Thanks in advance, Albrecht. -------------- next part -------------- A non-text attachment was scrubbed... Name: gpgsm.log Type: text/x-log Size: 8853 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 473 bytes Desc: not available URL: From dgouttegattat at incenp.org Thu Jul 13 16:24:37 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Thu, 13 Jul 2017 16:24:37 +0200 Subject: [PATCH 0/2] agent: Use npth_clock_gettime for S2K calibration. Message-ID: <20170713142439.29482-1-dgouttegattat@incenp.org> Hi GnuPG folks, This is a follow-up to the discussion on dev.gnupg.org/T3276. The first of the following two patches proposes to replace the use of times(2) (which leads to an infinite loop when used under certain kernel configurations) by the npth_clock_gettime wrapper as provided by the nPth library. It is quite non-intrusive and is enough to fix the reported bug. The second patch (built upon the first) is a proposal for a more drastic change: it also replaces the Windows-specific code by the same wrapper. This does not fix anything, the rationale here is solely to somewhat simplify the code by abstracting system differences behind the nPth wrapper. (Note that I don't a have a Windows machine and therefore I cannot test that second patch. All I can say is that the code compiles under MingW.) Damien Goutte-Gattat (2): agent: Use npth_clock_gettime for S2K calibration. agent: Use npth_clock_gettime on all platforms. agent/Makefile.am | 6 ++--- agent/protect.c | 74 +++++++------------------------------------------------ 2 files changed, 12 insertions(+), 68 deletions(-) -- 2.9.0 From dgouttegattat at incenp.org Thu Jul 13 16:24:38 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Thu, 13 Jul 2017 16:24:38 +0200 Subject: [PATCH 1/2] agent: Use npth_clock_gettime for S2K calibration. In-Reply-To: <20170713142439.29482-1-dgouttegattat@incenp.org> References: <20170713142439.29482-1-dgouttegattat@incenp.org> Message-ID: <20170713142439.29482-2-dgouttegattat@incenp.org> * agent/protect.c (struct calibrate_time_s): Make that struct an alias for timespec on non-W32 systems. (calibrate_gettime): Use npth_clock_gettime instead of times. (calibrate_elapsed_time): Adapt computation of elapsed time accordingly. * agent/Makefile.am: Link gpg-protect-tool against nPth. -- It has been reported that the current method of measuring elapsed times could result in the agent being stuck in an infinite loop if the Linux kernel we are running on has been configured with VIRT_CPU_ACCOUNTING_GEN=y. Contrary to times(), clock_gettime() seems unaffected by whatever happens in the kernel under that configuration. We use the nPth wrapper for clock_gettime, which will provide a fallback implementation on systems without clock_gettime. GnuPG-bug-id: 3276 Signed-off-by: Damien Goutte-Gattat --- agent/Makefile.am | 6 +++--- agent/protect.c | 22 ++++++++++++---------- 2 files changed, 15 insertions(+), 13 deletions(-) diff --git a/agent/Makefile.am b/agent/Makefile.am index ce29462..ea6db2b 100644 --- a/agent/Makefile.am +++ b/agent/Makefile.am @@ -77,10 +77,10 @@ gpg_protect_tool_SOURCES = \ protect-tool.c \ protect.c cvt-openpgp.c -gpg_protect_tool_CFLAGS = $(AM_CFLAGS) $(LIBASSUAN_CFLAGS) \ +gpg_protect_tool_CFLAGS = $(AM_CFLAGS) $(LIBASSUAN_CFLAGS) $(NPTH_CFLAGS) \ $(INCICONV) gpg_protect_tool_LDADD = $(common_libs) $(LIBGCRYPT_LIBS) $(LIBASSUAN_LIBS) \ - $(GPG_ERROR_LIBS) $(LIBINTL) $(NETLIBS) $(LIBICONV) + $(NPTH_LIBS) $(GPG_ERROR_LIBS) $(LIBINTL) $(NETLIBS) $(LIBICONV) gpg_preset_passphrase_SOURCES = \ preset-passphrase.c @@ -103,7 +103,7 @@ $(PROGRAMS): $(common_libs) $(commonpth_libs) $(pwquery_libs) TESTS = t-protect t_common_ldadd = $(common_libs) $(LIBGCRYPT_LIBS) $(GPG_ERROR_LIBS) \ - $(LIBINTL) $(LIBICONV) $(NETLIBS) + $(LIBINTL) $(LIBICONV) $(NETLIBS) $(NPTH_LIBS) t_protect_SOURCES = t-protect.c protect.c t_protect_LDADD = $(t_common_ldadd) diff --git a/agent/protect.c b/agent/protect.c index 18b44f1..42fb479 100644 --- a/agent/protect.c +++ b/agent/protect.c @@ -33,7 +33,7 @@ # endif # include #else -# include +# include #endif #include "agent.h" @@ -71,14 +71,14 @@ static const struct { /* A helper object for time measurement. */ +#ifdef HAVE_W32_SYSTEM struct calibrate_time_s { -#ifdef HAVE_W32_SYSTEM FILETIME creation_time, exit_time, kernel_time, user_time; +}; #else - clock_t ticks; + #define calibrate_time_s timespec #endif -}; static int @@ -105,10 +105,7 @@ calibrate_get_time (struct calibrate_time_s *data) &data->kernel_time, &data->user_time); # endif #else - struct tms tmp; - - times (&tmp); - data->ticks = tmp.tms_utime; + npth_clock_gettime(data); #endif } @@ -134,8 +131,13 @@ calibrate_elapsed_time (struct calibrate_time_s *starttime) return (unsigned long)((t2 - t1)/10000); } #else - return (unsigned long)((((double) (stoptime.ticks - starttime->ticks)) - /CLOCKS_PER_SEC)*10000000); + { + struct calibrate_time_s difftime; + + npth_timersub(&stoptime, starttime, &difftime); + + return difftime.tv_sec * 1000 + difftime.tv_nsec / 1000000.0; + } #endif } -- 2.9.0 From dgouttegattat at incenp.org Thu Jul 13 16:24:39 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Thu, 13 Jul 2017 16:24:39 +0200 Subject: [PATCH 2/2] agent: Use npth_clock_gettime on all platforms. In-Reply-To: <20170713142439.29482-1-dgouttegattat@incenp.org> References: <20170713142439.29482-1-dgouttegattat@incenp.org> Message-ID: <20170713142439.29482-3-dgouttegattat@incenp.org> * agent/protect.c (struct calibrate_time_s): Removed. (calibrate_get_time): Removed. (calibrate_elapsed_time): Remove Windows-specific code. (calibrate_s2k_count_one): Use npth_clock_gettime directly. -- Since we are already using the npth_clock_gettime wrapper, we no longer need a Windows-specific code path. We can rely entirely on nPth to abstract away the underlying system. Signed-off-by: Damien Goutte-Gattat --- agent/protect.c | 74 +++++++-------------------------------------------------- 1 file changed, 8 insertions(+), 66 deletions(-) diff --git a/agent/protect.c b/agent/protect.c index 42fb479..08d5ca0 100644 --- a/agent/protect.c +++ b/agent/protect.c @@ -27,14 +27,7 @@ #include #include #include -#ifdef HAVE_W32_SYSTEM -# ifdef HAVE_WINSOCK2_H -# include -# endif -# include -#else -# include -#endif +#include #include "agent.h" @@ -70,17 +63,6 @@ static const struct { }; -/* A helper object for time measurement. */ -#ifdef HAVE_W32_SYSTEM -struct calibrate_time_s -{ - FILETIME creation_time, exit_time, kernel_time, user_time; -}; -#else - #define calibrate_time_s timespec -#endif - - static int hash_passphrase (const char *passphrase, int hashalgo, int s2kmode, @@ -90,55 +72,15 @@ hash_passphrase (const char *passphrase, int hashalgo, -/* Get the process time and store it in DATA. */ -static void -calibrate_get_time (struct calibrate_time_s *data) -{ -#ifdef HAVE_W32_SYSTEM -# ifdef HAVE_W32CE_SYSTEM - GetThreadTimes (GetCurrentThread (), - &data->creation_time, &data->exit_time, - &data->kernel_time, &data->user_time); -# else - GetProcessTimes (GetCurrentProcess (), - &data->creation_time, &data->exit_time, - &data->kernel_time, &data->user_time); -# endif -#else - npth_clock_gettime(data); -#endif -} - - static unsigned long -calibrate_elapsed_time (struct calibrate_time_s *starttime) +calibrate_elapsed_time (struct timespec *starttime) { - struct calibrate_time_s stoptime; - - calibrate_get_time (&stoptime); -#ifdef HAVE_W32_SYSTEM - { - unsigned long long t1, t2; - - t1 = (((unsigned long long)starttime->kernel_time.dwHighDateTime << 32) - + starttime->kernel_time.dwLowDateTime); - t1 += (((unsigned long long)starttime->user_time.dwHighDateTime << 32) - + starttime->user_time.dwLowDateTime); - t2 = (((unsigned long long)stoptime.kernel_time.dwHighDateTime << 32) - + stoptime.kernel_time.dwLowDateTime); - t2 += (((unsigned long long)stoptime.user_time.dwHighDateTime << 32) - + stoptime.user_time.dwLowDateTime); - return (unsigned long)((t2 - t1)/10000); - } -#else - { - struct calibrate_time_s difftime; + struct timespec stoptime, difftime; - npth_timersub(&stoptime, starttime, &difftime); + npth_clock_gettime (&stoptime); + npth_timersub(&stoptime, starttime, &difftime); - return difftime.tv_sec * 1000 + difftime.tv_nsec / 1000000.0; - } -#endif + return difftime.tv_sec * 1000 + difftime.tv_nsec / 1000000.0; } @@ -149,9 +91,9 @@ calibrate_s2k_count_one (unsigned long count) { int rc; char keybuf[PROT_CIPHER_KEYLEN]; - struct calibrate_time_s starttime; + struct timespec starttime; - calibrate_get_time (&starttime); + npth_clock_gettime (&starttime); rc = hash_passphrase ("123456789abcdef0", GCRY_MD_SHA1, 3, "saltsalt", count, keybuf, sizeof keybuf); if (rc) -- 2.9.0 From albrecht.dress at arcor.de Thu Jul 13 17:51:58 2017 From: albrecht.dress at arcor.de (Albrecht =?iso-8859-1?b?RHJl3w==?=) Date: Thu, 13 Jul 2017 17:51:58 +0200 Subject: [GpgME] signing w/ protocol CMS -> 'Nich implementiert'? In-Reply-To: <87vamwix51.fsf@wheatstone.g10code.de> (from wk@gnupg.org on Thu Jul 13 10:00:58 2017) Message-ID: Hi Werner: Am 13.07.17 10:00 schrieb(en) Werner Koch: > > GPGME 2017-07-12 21:04:33 <0x7f17ad8f5a80> gpgme_op_sign:476: error: Nich implementiert > > Did you set a passphrase callback? This is not available for gpgsm. Yes. And setting it to NULL for GPGME_PROTOCOL_CMS immediately solves the issue. Maybe I'm too dumb, but I didn't find this behavior being mentioned in the manual. And, to be honest, I don't understand why the sign operation should throw an error if a callback has been defined. Wouldn't it be sufficient to just ignore it, as with gpg if pinentry is available? Thanks a lot for your help, best, Albrecht. -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 473 bytes Desc: not available URL: From dgouttegattat at incenp.org Fri Jul 14 17:10:06 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Fri, 14 Jul 2017 17:10:06 +0200 Subject: [Announce] Scute 1.5.0 released Message-ID: <4205b88b-7cc0-9df4-d1f4-ac7d9d976e91@incenp.org> Hi, The GnuPG Project is pleased to announce the availability of Scute 1.5.0. Scute is a PKCS#11 module built around the GnuPG Agent and the GnuPG Smart Card Daemon. It allows you to use your OpenPGP smart card for TLS client authentication and S/MIME mail and document signing. Noteworthy changes in version 1.5.0 (2017-07-14) =================================== * Support for TLS 1.2. * Support for S/MIME signing. This has been tested with Thunderbird (to sign e-mails) and with LibreOffice (to sign OpenDocument and PDF files). * Support for 4096 bit RSA keys. * Better support for GnuPG 2.1: - A communication bug between GnuPG Agent and Scute, leading to failed signatures, has been fixed. - Scute now relies on gpg-connect-agent to be able to always find the socket for GnuPG Agent, no matter where that socket is actually located. * C_GenerateRandom function is implemented. This allows Firefox to seed its entropy pool using the OpenPGP smart card's random number generator. Download ======== Source code is hosted at the GnuPG FTP server and its mirrors as listed as . On the primary server the source tarball and its digital signature are: ftp://ftp.gnupg.org/gcrypt/scute/scute-1.5.0.tar.bz2 (968k) ftp://ftp.gnupg.org/gcrypt/scute/scute-1.5.0.tar.bz2.sig The same files are also available via HTTP: https://gnupg.org/ftp/gcrypt/scute/scute-1.5.0.tar.bz2 https://gnupg.org/ftp/gcrypt/scute/scute-1.5.0.tar.bz2.sig Copying ======= Scute is copyrighted by g10 Code GmbH ans licensed under the GNU General Public License version 2 or later (GPLv2+) with the following exception: In addition, as a special exception, g10 Code GmbH gives permission to link this library: with the Mozilla Foundation's code for Mozilla (or with modified versions of it that use the same license as the "Mozilla" code), and distribute the linked executables. You must obey the GNU General Public License in all respects for all of the code used other than "Mozilla". If you modify the software, you may extend this exception to your version of the software, but you are not obligated to do so. If you do not wish to do so, delete this exception statement from your version and from all source files. Support ======= The Scute manual is included in the source distribution and is also available online at . For community support, you may ask on the gnupg-users mailing list . If you need commercial support, check out . Maintenance and development of Scute and of GnuPG as a whole is mostly financed by donations. Please consider donating via . -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 488 bytes Desc: OpenPGP digital signature URL: -------------- next part -------------- _______________________________________________ Gnupg-announce mailing list Gnupg-announce at gnupg.org http://lists.gnupg.org/mailman/listinfo/gnupg-announce From wk at gnupg.org Tue Jul 18 22:43:19 2017 From: wk at gnupg.org (Werner Koch) Date: Tue, 18 Jul 2017 22:43:19 +0200 Subject: [Announce] Libgcrypt 1.8.0 released Message-ID: <87bmoheas8.fsf@wheatstone.g10code.de> Hello! The GnuPG Project is pleased to announce the availability of Libgcrypt version 1.8.0. This is a new stable version of Libgcrypt with full API and ABI compatibility to the 1.7 series. Its main features are support Blake-2, XTS mode, an improved RNG, and performance improvements for the ARM architecture. Libgcrypt is a general purpose library of cryptographic building blocks. It is originally based on code used by GnuPG. It does not provide any implementation of OpenPGP or other protocols. Thorough understanding of applied cryptography is required to use Libgcrypt. Noteworthy changes between version 1.7.0 and 1.8.0: =================================================== * New interfaces: - New cipher mode XTS - New hash function Blake-2 - New function gcry_mpi_point_copy. - New function gcry_get_config. - GCRYCTL_REINIT_SYSCALL_CLAMP allows to init nPth after Libgcrypt. - New gobal configuration file /etc/gcrypt/random.conf. * Extended interfaces: - GCRYCTL_PRINT_CONFIG does now also print build information for libgpg-error and the used compiler version. - GCRY_CIPHER_MODE_CFB8 is now supported. - Add Stribog OIDs. [also in 1.7.4] * Performance: - A jitter based entropy collector is now used in addition to the other entropy collectors. - Optimized gcry_md_hash_buffers for SHA-256 and SHA-512. - More ARMv8/AArch32 improvements for AES, GCM, SHA-256, and SHA-1. [also in 1.7.4] - Add ARMv8/AArch32 assembly implementation for Twofish and Camellia. [also in 1.7.4] - Add bulk processing implementation for ARMv8/AArch32. [also in 1.7.4] - Improve the DRBG performance and sync the code with the Linux version. [also in 1.7.4] * Internal changes: - Libgpg-error 1.25 is now required. This avoids stalling of nPth threads due to contention on internal Libgcrypt locks (e.g. the random pool lock). - The system call clamp of libgpg-error is now used to wrap the blocking read of /dev/random. This allows other nPth threads to run while Libgcrypt is gathering entropy. - When secure memory is requested by the MPI functions or by gcry_xmalloc_secure, they do not anymore lead to a fatal error if the secure memory pool is used up. Instead new pools are allocated as needed. These new pools are not protected against being swapped out (mlock can't be used). However, these days this is considered a minor issue and can easily be mitigated by using encrypted swap space. [also in 1.7.4] * Bug fixes: - Fix AES CTR self-check detected failure in the SSSE3 based implementation. [also in 1.7.6] - Remove gratuitous select before the getrandom syscall. [also in 1.7.6] - Fix regression in mlock detection. [bug#2870] [also in 1.7.5] - Fix GOST 28147 CryptoPro-B S-box. [also in 1.7.4] - Fix error code handling of mlock calls. [also in 1.7.4] - Fix possible timing attack on EdDSA session key. [also in 1.7.7] - Fix long standing bug in secure memory implementation which could lead to a segv on free. [bug#3027] [also in 1.7.7] - Mitigate a flush+reload side-channel attack on RSA secret keys dubbed "Sliding right into disaster". For details see . [CVE-2017-7526] [also in 1.7.8] For a list of interface changes relative to the 1.7.0 release see [4]. Download ======== Source code is hosted at the GnuPG FTP server and its mirrors as listed at . On the primary server the source tarball and its digital signature are: ftp://ftp.gnupg.org/gcrypt/libgcrypt/libgcrypt-1.8.0.tar.bz2 ftp://ftp.gnupg.org/gcrypt/libgcrypt/libgcrypt-1.8.0.tar.bz2.sig That file is bzip2 compressed. A gzip compressed version is here: ftp://ftp.gnupg.org/gcrypt/libgcrypt/libgcrypt-1.8.0.tar.gz ftp://ftp.gnupg.org/gcrypt/libgcrypt/libgcrypt-1.8.0.tar.gz.sig The same files are also available via HTTP: https://gnupg.org/ftp/gcrypt/libgcrypt/libgcrypt-1.8.0.tar.bz2 https://gnupg.org/ftp/gcrypt/libgcrypt/libgcrypt-1.8.0tar.bz2.sig https://gnupg.org/ftp/gcrypt/libgcrypt/libgcrypt-1.8.0.tar.gz https://gnupg.org/ftp/gcrypt/libgcrypt/libgcrypt-1.8.0.tar.gz.sig In order to check that the version of Libgcrypt you downloaded is an original and unmodified file please follow the instructions found at . In short, you may use one of the following methods: - Check the supplied OpenPGP signature. For example to check the signature of the file libgcrypt-1.8.0.tar.bz2 you would use this command: gpg --verify libgcrypt-1.8.0.tar.bz2.sig libgcrypt-1.8.0.tar.bz2 This checks whether the signature file matches the source file. You should see a message indicating that the signature is good and made by one or more of the release signing keys. Make sure that this is a valid key, either by matching the shown fingerprint against a trustworthy list of valid release signing keys or by checking that the key has been signed by trustworthy other keys. See the end of this mail for information on the signing keys. - If you are not able to use an existing version of GnuPG, you have to verify the SHA-1 checksum. On Unix systems the command to do this is either "sha1sum" or "shasum". Assuming you downloaded the file libgcrypt-1.8.0.tar.bz2, you run the command like this: sha1sum libgcrypt-1.8.0.tar.bz2 and check that the output matches the first line from the this list: b4ffb20369f2ab8249d5cc0fb8b3b31371f6b112 libgcrypt-1.8.0.tar.bz2 1c5f57008e9d0944a3d0ecec894205dd1a272752 libgcrypt-1.8.0.tar.gz You should also verify that the checksums above are authentic by matching them with copies of this announcement. Those copies can be found at other mailing lists, web sites, and search engines. Copying ======= Libgcrypt is distributed under the terms of the GNU Lesser General Public License (LGPLv2.1+). The helper programs as well as the documentation are distributed under the terms of the GNU General Public License (GPLv2+). The file LICENSES has notices about contributions that require that these additional notices are distributed. Support ======= For help on developing with Libgcrypt you should read the included manual and optional ask on the gcrypt-devel mailing list [1]. A listing with commercial support offers for Libgcrypt and related software is available at the GnuPG web site [2]. If you are a developer and you may need a certain feature for your project, please do not hesitate to bring it to the gcrypt-devel mailing list for discussion. Maintenance and development of Libgcrypt is mostly financed by donations; see . We currently employ 4 full-time developers, one part-timer, and one contractor to work on GnuPG and closely related software like Libgcrypt. Thanks ====== We like to thank all the people who helped with this release, be it testing, coding, translating, suggesting, auditing, administering the servers, spreading the word, and answering questions on the mailing lists. Also many thanks to all our donors [3]. Special thanks to Stephan M?ller for his entropy generator based on timing jitter. Happy hacking, The GnuPG Team [1] https://lists.gnupg.org/mailman/listinfo/gcrypt-devel [2] https://www.gnupg.org/service.html [3] https://gnupg.org/donate/kudos.html [4] Interface changes relative to the 1.7.0 release: ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ gcry_get_config NEW function. gcry_mpi_point_copy NEW function. GCRYCTL_REINIT_SYSCALL_CLAMP NEW macro. GCRY_MD_BLAKE2B_512 NEW constant. GCRY_MD_BLAKE2B_384 NEW constant. GCRY_MD_BLAKE2B_256 NEW constant. GCRY_MD_BLAKE2B_160 NEW constant. GCRY_MD_BLAKE2S_256 NEW constant. GCRY_MD_BLAKE2S_224 NEW constant. GCRY_MD_BLAKE2S_160 NEW constant. GCRY_MD_BLAKE2S_128 NEW constant. GCRY_CIPHER_MODE_XTS NEW constant. gcry_md_info DEPRECATED. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ p.s. This is an announcement only mailing list. Please send replies only to the gcrypt-devel 'at' gnupg.org mailing list. p.p.s List of Release Signing Keys: To guarantee that a downloaded GnuPG version has not been tampered by malicious entities we provide signature files for all tarballs and binary versions. The keys are also signed by the long term keys of their respective owners. Current releases are signed by one or more of these five keys: 2048R/4F25E3B6 2011-01-12 [expires: 2019-12-31] Key fingerprint = D869 2123 C406 5DEA 5E0F 3AB5 249B 39D2 4F25 E3B6 Werner Koch (dist sig) rsa2048/E0856959 2014-10-29 [expires: 2019-12-31] Key fingerprint = 46CC 7308 65BB 5C78 EBAB ADCF 0437 6F3E E085 6959 David Shaw (GnuPG Release Signing Key) rsa2048/33BD3F06 2014-10-29 [expires: 2016-10-28] Key fingerprint = 031E C253 6E58 0D8E A286 A9F2 2071 B08A 33BD 3F06 NIIBE Yutaka (GnuPG Release Key) rsa2048/7EFD60D9 2014-10-19 [expires: 2020-12-31] Key fingerprint = D238 EA65 D64C 67ED 4C30 73F2 8A86 1B1C 7EFD 60D9 Werner Koch (Release Signing Key) rsa3072/4B092E28 2017-03-17 [expires: 2027-03-15] Key fingerprint = 5B80 C575 4298 F0CB 55D8 ED6A BCEF 7E29 4B09 2E28 Andre Heinecke (Release Signing Key) You may retrieve these keys from a keyserver using this command gpg --keyserver hkp://keys.gnupg.net --recv-keys \ 249B39D24F25E3B6 04376F3EE0856959 \ 2071B08A33BD3F06 8A861B1C7EFD60D9 BCEF7E294B092E28 The keys are also available at https://gnupg.org/signature_key.html and in any recently released GnuPG tarball in the file g10/distsigkey.gpg . Note that this mail has been signed by a different key. -- Die Gedanken sind frei. Ausnahmen regelt ein Bundesgesetz. -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 194 bytes Desc: not available URL: -------------- next part -------------- _______________________________________________ Gnupg-announce mailing list Gnupg-announce at gnupg.org http://lists.gnupg.org/mailman/listinfo/gnupg-announce From dgouttegattat at incenp.org Wed Jul 19 11:33:00 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Wed, 19 Jul 2017 11:33:00 +0200 Subject: [PATCH 1/5] gpgconf: Make WoT settings configurable by gpgconf. In-Reply-To: <20170719093304.30138-1-dgouttegattat@incenp.org> References: <20170719093304.30138-1-dgouttegattat@incenp.org> Message-ID: <20170719093304.30138-2-dgouttegattat@incenp.org> * tools/gpgconf-comp.c (gc_options_gpg): Add max-cert-depth, completes-needed, and marginals-needed options. * g10/gpg.c (gpgconf_list): Likewise. -- Some tests to come for the PGP trust model will need to manipulate these parameters. Signed-off-by: Damien Goutte-Gattat --- g10/gpg.c | 3 +++ tools/gpgconf-comp.c | 12 ++++++++++++ 2 files changed, 15 insertions(+) diff --git a/g10/gpg.c b/g10/gpg.c index 5c60e1d..4dccf72 100644 --- a/g10/gpg.c +++ b/g10/gpg.c @@ -1855,6 +1855,9 @@ gpgconf_list (const char *configfile) es_printf ("compliance:%lu:\"%s:\n", GC_OPT_FLAG_DEFAULT, "gnupg"); es_printf ("default-new-key-algo:%lu:\n", GC_OPT_FLAG_NONE); es_printf ("trust-model:%lu:\n", GC_OPT_FLAG_NONE); + es_printf ("max-cert-depth:%lu:\n", GC_OPT_FLAG_NONE); + es_printf ("completes-needed:%lu:\n", GC_OPT_FLAG_NONE); + es_printf ("marginals-needed:%lu:\n", GC_OPT_FLAG_NONE); /* The next one is an info only item and should match the macros at the top of keygen.c */ diff --git a/tools/gpgconf-comp.c b/tools/gpgconf-comp.c index a8ecb07..ba7abe0 100644 --- a/tools/gpgconf-comp.c +++ b/tools/gpgconf-comp.c @@ -724,6 +724,18 @@ static gc_option_t gc_options_gpg[] = GC_OPT_FLAG_NONE, GC_LEVEL_INVISIBLE, NULL, NULL, GC_ARG_TYPE_STRING, GC_BACKEND_GPG }, + { "max-cert-depth", + GC_OPT_FLAG_NONE, GC_LEVEL_INVISIBLE, + NULL, NULL, + GC_ARG_TYPE_UINT32, GC_BACKEND_GPG }, + { "completes-needed", + GC_OPT_FLAG_NONE, GC_LEVEL_INVISIBLE, + NULL, NULL, + GC_ARG_TYPE_UINT32, GC_BACKEND_GPG }, + { "marginals-needed", + GC_OPT_FLAG_NONE, GC_LEVEL_INVISIBLE, + NULL, NULL, + GC_ARG_TYPE_UINT32, GC_BACKEND_GPG }, { "Debug", -- 2.9.0 From dgouttegattat at incenp.org Wed Jul 19 11:32:59 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Wed, 19 Jul 2017 11:32:59 +0200 Subject: [PATCH 0/5] Tests for the PGP trust model Message-ID: <20170719093304.30138-1-dgouttegattat@incenp.org> Hi GnuPG folks, As Justus pointed out in the discussion around issue 2923 [1], there are currently no tests covering the PGP trust model. The following patch set proposes such tests. They use four distinct scenarios (a "scenario" here is a set of public keys with associated signatures) to test several conditions. There is no hope of covering all the possible cases, but hopefully those tests could serve as a base to elaborate more precise tests if we ever find a bug occuring in very special conditions. Those tests include a test for domain restrictions associated with trust signatures, whose verification is currently broken in GnuPG due to issue 2923. The last patch of the set is a fix for issue 2923, allowing all the tests to pass successfully. [1] https://dev.gnupg.org/T2923#100545 Damien Goutte-Gattat (5): gpgconf: Make WoT settings configurable by gpgconf. gpg,tests: Move some functions into a common module. gpg,tests: Add tests for the PGP trust model. gpg,tests: Add private keys for PGP tests. gpg: Fix regexp sanitization. g10/gpg.c | 3 + g10/trustdb.c | 2 +- tests/openpgp/Makefile.am | 14 ++- tests/openpgp/defs.scm | 24 +++++ tests/openpgp/tofu.scm | 24 ----- tests/openpgp/trust-pgp.scm | 190 ++++++++++++++++++++++++++++++++++ tests/openpgp/trust-pgp/alice.sec.asc | 11 ++ tests/openpgp/trust-pgp/bobby.sec.asc | 11 ++ tests/openpgp/trust-pgp/carol.sec.asc | 11 ++ tests/openpgp/trust-pgp/david.sec.asc | 11 ++ tests/openpgp/trust-pgp/frank.sec.asc | 11 ++ tests/openpgp/trust-pgp/grace.sec.asc | 11 ++ tests/openpgp/trust-pgp/heidi.sec.asc | 11 ++ tests/openpgp/trust-pgp/scenario1.asc | 75 ++++++++++++++ tests/openpgp/trust-pgp/scenario2.asc | 70 +++++++++++++ tests/openpgp/trust-pgp/scenario3.asc | 58 +++++++++++ tests/openpgp/trust-pgp/scenario4.asc | 84 +++++++++++++++ tools/gpgconf-comp.c | 12 +++ 18 files changed, 607 insertions(+), 26 deletions(-) create mode 100644 tests/openpgp/trust-pgp.scm create mode 100644 tests/openpgp/trust-pgp/alice.sec.asc create mode 100644 tests/openpgp/trust-pgp/bobby.sec.asc create mode 100644 tests/openpgp/trust-pgp/carol.sec.asc create mode 100644 tests/openpgp/trust-pgp/david.sec.asc create mode 100644 tests/openpgp/trust-pgp/frank.sec.asc create mode 100644 tests/openpgp/trust-pgp/grace.sec.asc create mode 100644 tests/openpgp/trust-pgp/heidi.sec.asc create mode 100644 tests/openpgp/trust-pgp/scenario1.asc create mode 100644 tests/openpgp/trust-pgp/scenario2.asc create mode 100644 tests/openpgp/trust-pgp/scenario3.asc create mode 100644 tests/openpgp/trust-pgp/scenario4.asc -- 2.9.0 From dgouttegattat at incenp.org Wed Jul 19 11:33:04 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Wed, 19 Jul 2017 11:33:04 +0200 Subject: [PATCH 5/5] gpg: Fix regexp sanitization. In-Reply-To: <20170719093304.30138-1-dgouttegattat@incenp.org> References: <20170719093304.30138-1-dgouttegattat@incenp.org> Message-ID: <20170719093304.30138-6-dgouttegattat@incenp.org> * g10/trustdb.c (sanitize_regexp): Do not escape normal characters. -- The current sanitization code escapes ALL characters in the regular expression, including characters that do not have any special meaning and only match themselves. Only the dot (.) is not escaped. This leads to, e.g., 'example.com' being sanitized into '\e\x\a\m\p\l\e.\c\o\m', which will then fail to match against 'alice at example.com'. This patch updates the function to escape only the meaningful characters (minus the dot). GnuPG-bug-id: 2923 Signed-off-by: Damien Goutte-Gattat --- g10/trustdb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/g10/trustdb.c b/g10/trustdb.c index e2c3bda..080f2f3 100644 --- a/g10/trustdb.c +++ b/g10/trustdb.c @@ -1541,7 +1541,7 @@ sanitize_regexp(const char *old) { if(!escaped && old[start]=='\\') escaped=1; - else if(!escaped && old[start]!='.') + else if(!escaped && strchr("[]$^()|*+?{}", old[start])) new[idx++]='\\'; else escaped=0; -- 2.9.0 From dgouttegattat at incenp.org Wed Jul 19 11:33:01 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Wed, 19 Jul 2017 11:33:01 +0200 Subject: [PATCH 2/5] gpg,tests: Move some functions into a common module. In-Reply-To: <20170719093304.30138-1-dgouttegattat@incenp.org> References: <20170719093304.30138-1-dgouttegattat@incenp.org> Message-ID: <20170719093304.30138-3-dgouttegattat@incenp.org> * tests/openpgp/tofu.scm (gettrust): Moved to the common defs.scm module. (checktrust): Likewise. * tests/openpgp/defs.scm (gettrust): New function. (checktrust): Likewise. -- These functions will be re-used by the tests for the PGP trust model. Signed-off-by: Damien Goutte-Gattat --- tests/openpgp/defs.scm | 24 ++++++++++++++++++++++++ tests/openpgp/tofu.scm | 24 ------------------------ 2 files changed, 24 insertions(+), 24 deletions(-) diff --git a/tests/openpgp/defs.scm b/tests/openpgp/defs.scm index b5e3078..815200e 100644 --- a/tests/openpgp/defs.scm +++ b/tests/openpgp/defs.scm @@ -464,5 +464,29 @@ (catch (log "Warning: Removing socket directory failed.") (gpg-conf '--remove-socketdir))) +;; Get the trust level for KEYID. Any remaining arguments are simply +;; passed to GPG. +;; +;; This function only supports keys with a single user id. +(define (gettrust keyid . args) + (let ((trust + (list-ref (assoc "pub" (gpg-with-colons + `(, at args + --list-keys ,keyid))) 1))) + (unless (and (= 1 (string-length trust)) + (member (string-ref trust 0) (string->list "oidreqnmfuws-"))) + (fail "Bad trust value:" trust)) + trust)) + +;; Check that KEYID's trust level matches EXPECTED-TRUST. Any +;; remaining arguments are simply passed to GPG. +;; +;; This function only supports keys with a single user id. +(define (checktrust keyid expected-trust . args) + (let ((trust (apply gettrust `(,keyid , at args)))) + (unless (string=? trust expected-trust) + (fail keyid ": Expected trust to be" expected-trust + "but got" trust)))) + ;; end diff --git a/tests/openpgp/tofu.scm b/tests/openpgp/tofu.scm index 58b2a03..cd4b4c7 100755 --- a/tests/openpgp/tofu.scm +++ b/tests/openpgp/tofu.scm @@ -71,30 +71,6 @@ (fail keyid ": Expected policy to be" expected-policy "but got" policy)))) -;; Get the trust level for KEYID. Any remaining arguments are simply -;; passed to GPG. -;; -;; This function only supports keys with a single user id. -(define (gettrust keyid . args) - (let ((trust - (list-ref (assoc "pub" (gpg-with-colons - `(, at args - --list-keys ,keyid))) 1))) - (unless (and (= 1 (string-length trust)) - (member (string-ref trust 0) (string->list "oidreqnmfuws-"))) - (fail "Bad trust value:" trust)) - trust)) - -;; Check that KEYID's trust level matches EXPECTED-TRUST. Any -;; remaining arguments are simply passed to GPG. -;; -;; This function only supports keys with a single user id. -(define (checktrust keyid expected-trust . args) - (let ((trust (apply gettrust `(,keyid , at args)))) - (unless (string=? trust expected-trust) - (fail keyid ": Expected trust to be" expected-trust - "but got" trust)))) - ;; Set key KEYID's policy to POLICY. Any remaining arguments are ;; passed as options to gpg. (define (setpolicy keyid policy . args) -- 2.9.0 From dgouttegattat at incenp.org Wed Jul 19 11:33:02 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Wed, 19 Jul 2017 11:33:02 +0200 Subject: [PATCH 3/5] gpg,tests: Add tests for the PGP trust model. In-Reply-To: <20170719093304.30138-1-dgouttegattat@incenp.org> References: <20170719093304.30138-1-dgouttegattat@incenp.org> Message-ID: <20170719093304.30138-4-dgouttegattat@incenp.org> * tests/openpgp/Makefile.am (XTESTS): Add trust-pgp.scm. (TEST_FILES): Add scenario files. * tests/openpgp/trust-pgp.scm: New file. * tests/openpgp/trust-pgp/scenario1.asc: New file. * tests/openpgp/trust-pgp/scenario2.asc: New file. * tests/openpgp/trust-pgp/scenario3.asc: New file. * tests/openpgp/trust-pgp/scenario4.asc: New file. Signed-off-by: Damien Goutte-Gattat --- tests/openpgp/Makefile.am | 7 +- tests/openpgp/trust-pgp.scm | 190 ++++++++++++++++++++++++++++++++++ tests/openpgp/trust-pgp/scenario1.asc | 75 ++++++++++++++ tests/openpgp/trust-pgp/scenario2.asc | 70 +++++++++++++ tests/openpgp/trust-pgp/scenario3.asc | 58 +++++++++++ tests/openpgp/trust-pgp/scenario4.asc | 84 +++++++++++++++ 6 files changed, 483 insertions(+), 1 deletion(-) create mode 100644 tests/openpgp/trust-pgp.scm create mode 100644 tests/openpgp/trust-pgp/scenario1.asc create mode 100644 tests/openpgp/trust-pgp/scenario2.asc create mode 100644 tests/openpgp/trust-pgp/scenario3.asc create mode 100644 tests/openpgp/trust-pgp/scenario4.asc diff --git a/tests/openpgp/Makefile.am b/tests/openpgp/Makefile.am index 506bce5..c615c2a 100644 --- a/tests/openpgp/Makefile.am +++ b/tests/openpgp/Makefile.am @@ -82,6 +82,7 @@ XTESTS = \ ecc.scm \ 4gb-packet.scm \ tofu.scm \ + trust-pgp.scm \ gpgtar.scm \ use-exact-key.scm \ default-key.scm \ @@ -158,7 +159,11 @@ TEST_FILES = pubring.asc secring.asc plain-1o.asc plain-2o.asc plain-3o.asc \ key-selection/1.asc \ key-selection/2.asc \ key-selection/3.asc \ - key-selection/4.asc + key-selection/4.asc \ + trust-pgp/scenario1.asc \ + trust-pgp/scenario2.asc \ + trust-pgp/scenario3.asc \ + trust-pgp/scenario4.asc data_files = data-500 data-9000 data-32000 data-80000 plain-large diff --git a/tests/openpgp/trust-pgp.scm b/tests/openpgp/trust-pgp.scm new file mode 100644 index 0000000..d83361b --- /dev/null +++ b/tests/openpgp/trust-pgp.scm @@ -0,0 +1,190 @@ +#!/usr/bin/env gpgscm + +;; Copyright (C) 2017 g10 Code GmbH +;; +;; This file is part of GnuPG. +;; +;; +;; GnuPG is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 3 of the License, or +;; (at your option) any later version. +;; +;; GnuPG 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, see . + +(load (in-srcdir "tests" "openpgp" "defs.scm")) +(setup-environment) + +;; Redefine GPG without --always-trust. +(define GPG `(,(tool 'gpg))) + +;; Helper constants for setownertrust. +(define MARGINALTRUST "4") +(define FULLTRUST "5") +(define ULTIMATETRUST "6") + +;; Assign OWNERTRUST to the key identified by the provided +;; fingerprint KEYFPR. +(define (setownertrust keyfpr ownertrust) + (pipe:do + (pipe:echo (string-append keyfpr ":" ownertrust ":\n")) + (pipe:gpg `(--import-ownertrust)))) + +;; Force a trustdb update. +(define (updatetrustdb) + (call-check `(, at GPG --check-trustdb --yes))) + +;; Reset the test environment. We do that kind of brutally, +;; by removing the pubring and trustdb files. +(define (reset-environment) + (catch '() (unlink (path-join GNUPGHOME "pubring.kbx"))) + (catch '() (unlink (path-join GNUPGHOME "pubring.gpg"))) + (unlink (path-join GNUPGHOME "trustdb.gpg"))) + +;; IDs of all the keys involved in those tests. +(define ALICE "FD9B20DD3C98123EEEAF8CC51BA41538D2E656B5") +(define BOBBY "4D3F59F4D8030FD2D844AFEBA5BAC3ED125CCAE5") +(define CAROL "6C62735E454CCDD79FA6CA601079113AEC1282FD") +(define DAVID "A0607635198CABA2C467FAA64CE5BB42E3984000") +(define FRANK "CE1A0E07CF8A20CBF8DC47D6DB9017DBAE6CD0EF") +(define GRACE "B935F4B8DA009AFBCCDD41386653A183007F8345") +(define HEIDI "0389C0B7990E10520B334F23756F1571EDA9184B") + +;; PGP is the default trust model for now, but that +;; could change for TOFU in the future, so let's make +;; sure we are using PGP. +;; For now, we play with the "classic" trust model. +(let ((trust-model (gpg-config 'gpg "trust-model"))) + (trust-model::update "pgp")) + + +;; First scenario (basic checks with normal signatures only). +(display "Checking basic WoT (classic trust model)...\n") +(call-check `(, at GPG --import + ,(in-srcdir "tests" "openpgp" "trust-pgp" "scenario1.asc"))) + +;; Use Alice's key as the root of all trust evaluations. +(setownertrust ALICE ULTIMATETRUST) +(updatetrustdb) + +;; Check initial state. +(checktrust BOBBY "f") ;; Directly signed by Alice's key. +(checktrust CAROL "q") ;; Signed by Bobby, whose key has + ;; no explicit ownertrust. +(checktrust DAVID "q") ;; Likewise. +(checktrust FRANK "q") ;; Likewise. +(checktrust GRACE "-") ;; Signed by the previous three keys; + ;; not evaluated since they are not valid. + +;; Let's trust Bobby. +;; This should make Carol's, David's, and Frank's keys valid. +(setownertrust BOBBY FULLTRUST) +(updatetrustdb) +(checktrust CAROL "f") +(checktrust DAVID "f") +(checktrust FRANK "f") +(checktrust GRACE "q") ;; Now evaluated, but validity still unknown. + +;; Let's trust (marginally) Carol and David. +;; This should not be enough to make Grace's key fully valid +;; since marginals-needed defaults to 3. +(setownertrust CAROL MARGINALTRUST) +(setownertrust DAVID MARGINALTRUST) +(updatetrustdb) +(checktrust GRACE "m") + +;; Add marginal ownertrust to Frank's key. +;; This should make Grace's key fully valid. +(setownertrust FRANK MARGINALTRUST) +(updatetrustdb) +(checktrust GRACE "f") + +;; Now let's play with the length of certification chains. +;; Setting max-cert-length to 2 should put Grace's key +;; one step too far from Alice's key. +(let ((max-cert-depth (gpg-config 'gpg "max-cert-depth"))) + (max-cert-depth::update 2)) +(updatetrustdb) +(checktrust GRACE "-") + +;; Raise the bar for assigning full validity. +;; Bobby's key should be the only one retaining full validity. +(let ((completes-needed (gpg-config 'gpg "completes-needed"))) + (completes-needed::update 2)) +(updatetrustdb) +(checktrust BOBBY "f") +(checktrust CAROL "m") +(checktrust DAVID "m") +(checktrust FRANK "m") +(checktrust GRACE "-") + + +;; Second scenario (basic trust signature checks). +(display "Checking WoT with trust signatures (PGP trust model)...\n") +(let ((max-cert-depth (gpg-config 'gpg "max-cert-depth"))) + (max-cert-depth::clear)) +(let ((completes-needed (gpg-config 'gpg "completes-needed"))) + (completes-needed::clear)) +(reset-environment) + +(call-check `(, at GPG --import + ,(in-srcdir "tests" "openpgp" "trust-pgp" "scenario2.asc"))) +(setownertrust ALICE ULTIMATETRUST) +(updatetrustdb) + +(checktrust BOBBY "f") ;; Tsigned by Alice with trust=120. +(checktrust CAROL "f") ;; Signed by Bobby, whose key should have full + ;; ownertrust due to the tsig. +(checktrust DAVID "f") ;; Signed by Alice. +(checktrust FRANK "q") ;; Tsigned by David, whose key has no ownertrust. +(checktrust GRACE "-") ;; Signed by Frank. + +(setownertrust DAVID FULLTRUST) +(updatetrustdb) +(checktrust FRANK "f") ;; David's key has now full ownertrust. +(checktrust GRACE "q") ;; David is not authorized to emit tsigs, + ;; so his tsig on Frank's key should be treated + ;; like a normal sig (confering no ownertrust). + + +;; Third scenario (sig chain depth). +(display "Checking max depth of trust signature chains...\n") +(reset-environment) +(call-check `(, at GPG --import + ,(in-srcdir "tests" "openpgp" "trust-pgp" "scenario3.asc"))) +(setownertrust ALICE ULTIMATETRUST) +(updatetrustdb) + +(checktrust BOBBY "f") ;; Tsigned by Alice (level=2, trust=120). +(checktrust CAROL "f") ;; Tsigned by Bobby (level=2, trust=120). +(checktrust DAVID "f") ;; Tsigned by Carol (level=2, trust=120). +(checktrust FRANK "q") ;; The tsig from Carol does not confer + ;; ownertrust to David's key (too deep). + + +;; Fourth scenario (trust domain restrictions). +(display "Checking trust signature with domain restrictions...\n") +(reset-environment) +(call-check `(, at GPG --import + ,(in-srcdir "tests" "openpgp" "trust-pgp" "scenario4.asc"))) +(setownertrust ALICE ULTIMATETRUST) +(updatetrustdb) + +(checktrust BOBBY "f") ;; Tsigned by Alice, allowed to sign for example.com. +(checktrust CAROL "-") ;; Signed by Bobby, but the signature should be + ;; ignored since Carol has an address in example.net. + +(checktrust DAVID "f") ;; Tsigned by Alice, allowed to sign for example.net. +(checktrust FRANK "-") ;; Tsignature from David should be ignored because + ;; Frank has an address in example.com. + +;; The following two tests fail due to issue 2923. +(checktrust HEIDI "f") ;; Tsigned by David, should be valid since Heidi + ;; has an address in example.org. +(checktrust GRACE "f") ;; Signed by Heidi. diff --git a/tests/openpgp/trust-pgp/scenario1.asc b/tests/openpgp/trust-pgp/scenario1.asc new file mode 100644 index 0000000..82fee76 --- /dev/null +++ b/tests/openpgp/trust-pgp/scenario1.asc @@ -0,0 +1,75 @@ +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW2+WxMIKoZIzj0DAQcCAwQnUnqiwvOPU7gGepFTew8Fk5kmVexr+PvaqXgv +9wKxNzZrs4GvamULk9pl2euwJGKPBRJRz8RSNpW6HIIzAPoOtBlBbGljZSA8YWxp +Y2VAZXhhbXBsZS5vcmc+iJAEExMIADgWIQT9myDdPJgSPu6vjMUbpBU40uZWtQUC +WW2+WwIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRAbpBU40uZWtTs8AQC8 +6p4hEyInw17S3P4rVpHP+en+6YJDE7x12b2aevgzsQD/XPhh0PTrAlenhFdQjQbZ +A4dNj5BcxKEIWunJICtZCo0= +=rf4w +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3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VS +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3WzRMIKoZIzj0DAQcCAwQrTeILyHVpkkDsAyAlY7wz0PYjG48ShCYeTX2z +5f2bLxZGeepQeMiOXznPvCwRNMNpr63048+LGqu34Q9di5tvtBlEYXZpZCA8ZGF2 +aWRAZXhhbXBsZS5vcmc+iJAEExMIADgWIQSgYHY1GYyrosRn+qZM5btC45hAAAUC +WW3WzQIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRBM5btC45hAAAm0AP4n +GINm20BvnUWMHmgnUGSybMiuAvqi6itsstGNXKTuuQD/QmrIuGHUre+fitgNu4q2 +9ABx9BsKd3PAX1e4ZD/uBtKIdQQQEwgAHRYhBE0/WfTYAw/S2ESv66W6w+0SXMrl +BQJZbhB0AAoJEKW6w+0SXMrlARwA/RiqKRh4rYtW5gP20PoQNYfS1qh+lDRTlhfp +SSF5aKKFAP90s5/fp6n382IjbOhmQiEB9N4gv4pZT3YP13NQwAABbg== +=bLxR +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3W3RMIKoZIzj0DAQcCAwQs0QS2PEUXhpmsPlaTFOsXd8AoYqpa6xcc0+AE +Mck1EzlqRlxeibvYeh/+yxjl18Ouww/BERB+PcoABXp00zXztBlGcmFuayA8ZnJh +bmtAZXhhbXBsZS5jb20+iJAEExMIADgWIQTOGg4Hz4ogy/jcR9bbkBfbrmzQ7wUC +WW3W3QIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRDbkBfbrmzQ76cNAP9G +mUKYA9CAx6OGzb9iY6pat6TJ3ghY2P3PIjafbbxZdgEAnX9Z/W8G+I4SrOzu34LS +IETHEldWI+UbSc1n1qiJfUaIdQQQEwgAHRYhBE0/WfTYAw/S2ESv66W6w+0SXMrl +BQJZbhCEAAoJEKW6w+0SXMrlepAA/3+AAaRQVfsU+zQtGg43VxAcfW+ezuUVCYUY +IW2Lv+GkAP0WF7Nh5N4nDo/gC3WBW2zdWArlRaWa5NxcCquEUaE7Tg== +=SWmz +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3W8RMIKoZIzj0DAQcCAwRTGb7wRrdPa+mXxUNJoYgWbKfMDQH9M1H366PQ +ga8L32TYccFzyCD8DuRYOQxzhnCtSHtdzK4QAwwGLaJV6GRjtBlHcmFjZSA8Z3Jh +Y2VAZXhhbXBsZS5uZXQ+iJAEExMIADgWIQS5NfS42gCa+8zdQThmU6GDAH+DRQUC +WW3W8QIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRBmU6GDAH+DRbYAAP4q +ZbYNAAtZOexWcv9Ap0nUnwOxpHWX7LaHsVRi4W21CwEAtliza9TA5UGcBjKpseiC +qBs9LEpFd4DE2qh6nHpyy/6IdQQQEwgAHRYhBGxic15FTM3Xn6bKYBB5ETrsEoL9 +BQJZbhCyAAoJEBB5ETrsEoL9pVoBAPGc50vXiWmSAx8U573pqAyBsVPPMUlfrrgc +tVZZQ9DyAP9LCpG1kJOnB1Fia1M6M/37FAwVjUerWTrp6XoG1888PYh1BBATCAAd +FiEEoGB2NRmMq6LEZ/qmTOW7QuOYQAAFAlluEM4ACgkQTOW7QuOYQAB3HgD+Kw+R +WbH8RcSlNbwlGWCWYwKvik7ukIMcTXXYD5azTYoBANF5Ym2n5RExmEd8nTrWu9MR +TUlOgAXfzm/iH4+TNj2yiHUEEBMIAB0WIQTOGg4Hz4ogy/jcR9bbkBfbrmzQ7wUC +WW4Q7AAKCRDbkBfbrmzQ7weXAP9OyFxzdpbq1R+V6T5WEckR5OtE6Va/7CHRPRW+ +kMNVjwD/YQZVbOCRxKybVbvPuF+29w7sWp4iAmmrmCFnKfgxZsQ= +=r9Ly +-----END PGP PUBLIC KEY BLOCK----- diff --git a/tests/openpgp/trust-pgp/scenario2.asc b/tests/openpgp/trust-pgp/scenario2.asc new file mode 100644 index 0000000..3a98621 --- /dev/null +++ b/tests/openpgp/trust-pgp/scenario2.asc @@ -0,0 +1,70 @@ +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW2+WxMIKoZIzj0DAQcCAwQnUnqiwvOPU7gGepFTew8Fk5kmVexr+PvaqXgv +9wKxNzZrs4GvamULk9pl2euwJGKPBRJRz8RSNpW6HIIzAPoOtBlBbGljZSA8YWxp +Y2VAZXhhbXBsZS5vcmc+iJAEExMIADgWIQT9myDdPJgSPu6vjMUbpBU40uZWtQUC +WW2+WwIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRAbpBU40uZWtTs8AQC8 +6p4hEyInw17S3P4rVpHP+en+6YJDE7x12b2aevgzsQD/XPhh0PTrAlenhFdQjQbZ +A4dNj5BcxKEIWunJICtZCo0= +=rf4w +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3WihMIKoZIzj0DAQcCAwTtUYI84wfNPCwa/r2ke7tXz0uv/En9LQZbW0QE +nzHigEvMXLfyjfjCf5tQ2eVbKLbABxtKwDtC2bv8dMcmgqd/tBlCb2JieSA8Ym9i +YnlAZXhhbXBsZS5jb20+iJAEExMIADgWIQRNP1n02AMP0thEr+ulusPtElzK5QUC +WW3WigIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRClusPtElzK5ZSOAQD1 +St647GAPOFIIYBDka3EGJeSan8i4f+u80jyplpWeggEA+z9VSDLd7JKMXqD3B/9T +O+rBR22hpi+TILZrbk7svFyIeQQQEwgAIRYhBP2bIN08mBI+7q+MxRukFTjS5la1 +BQJZbjsoAwUBeAAKCRAbpBU40uZWtVGlAQCgHkwmJSATJbrqV7+h/1ByLDi4+thQ +ApW8nRinGuwkxQD+NgjOVmkPGZtpvaBzLXJS/IdPAYBWAriAzDZEV2GchWM= +=4Xcm +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY B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Dv +BQJZbkVQAAoJENuQF9uubNDvyrkBAICiFq2dTFzLrXNsItwpPrB20trzEPM/JAxa +lzSyknJMAQDBCj8nyEtlpkYh9t9ovy/x75D1OUBFFYHOQXCMy0QyRA== +=yoqI +-----END PGP PUBLIC KEY BLOCK----- diff --git a/tests/openpgp/trust-pgp/scenario3.asc b/tests/openpgp/trust-pgp/scenario3.asc new file mode 100644 index 0000000..240afd5 --- /dev/null +++ b/tests/openpgp/trust-pgp/scenario3.asc @@ -0,0 +1,58 @@ +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW2+WxMIKoZIzj0DAQcCAwQnUnqiwvOPU7gGepFTew8Fk5kmVexr+PvaqXgv +9wKxNzZrs4GvamULk9pl2euwJGKPBRJRz8RSNpW6HIIzAPoOtBlBbGljZSA8YWxp +Y2VAZXhhbXBsZS5vcmc+iJAEExMIADgWIQT9myDdPJgSPu6vjMUbpBU40uZWtQUC +WW2+WwIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRAbpBU40uZWtTs8AQC8 +6p4hEyInw17S3P4rVpHP+en+6YJDE7x12b2aevgzsQD/XPhh0PTrAlenhFdQjQbZ +A4dNj5BcxKEIWunJICtZCo0= +=rf4w +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3WihMIKoZIzj0DAQcCAwTtUYI84wfNPCwa/r2ke7tXz0uv/En9LQZbW0QE +nzHigEvMXLfyjfjCf5tQ2eVbKLbABxtKwDtC2bv8dMcmgqd/tBlCb2JieSA8Ym9i +YnlAZXhhbXBsZS5jb20+iJAEExMIADgWIQRNP1n02AMP0thEr+ulusPtElzK5QUC +WW3WigIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRClusPtElzK5ZSOAQD1 +St647GAPOFIIYBDka3EGJeSan8i4f+u80jyplpWeggEA+z9VSDLd7JKMXqD3B/9T +O+rBR22hpi+TILZrbk7svFyIeQQQEwgAIRYhBP2b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UGSybMiuAvqi6itsstGNXKTuuQD/QmrIuGHUre+fitgNu4q2 +9ABx9BsKd3PAX1e4ZD/uBtKIeQQQEwgAIRYhBGxic15FTM3Xn6bKYBB5ETrsEoL9 +BQJZbmZ0AwUCeAAKCRAQeRE67BKC/eFYAQDaKoyQZYnNH/62hydWITZ1nOYM/h6i +6L/b+XqB9DD0ewD9FAbO1wzassj6FmZMZDaraqdljTX+94JY5E3GJ8EQXo4= +=kaec +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3W3RMIKoZIzj0DAQcCAwQs0QS2PEUXhpmsPlaTFOsXd8AoYqpa6xcc0+AE +Mck1EzlqRlxeibvYeh/+yxjl18Ouww/BERB+PcoABXp00zXztBlGcmFuayA8ZnJh +bmtAZXhhbXBsZS5jb20+iJAEExMIADgWIQTOGg4Hz4ogy/jcR9bbkBfbrmzQ7wUC +WW3W3QIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRDbkBfbrmzQ76cNAP9G +mUKYA9CAx6OGzb9iY6pat6TJ3ghY2P3PIjafbbxZdgEAnX9Z/W8G+I4SrOzu34LS +IETHEldWI+UbSc1n1qiJfUaIeQQQEwgAIRYhBKBgdjUZjKuixGf6pkzlu0LjmEAA +BQJZbmaiAwUCeAAKCRBM5btC45hAAMcRAP9dcKO3ETB52AsFdBp2iJVjqJ5JiftN +B/2FZBxPtSjXpAD/YdDzs+zNaAUlFIFmXzP9EmIqmXhC6XSiASrNd5EW33A= +=DXNa +-----END PGP PUBLIC KEY BLOCK----- diff --git a/tests/openpgp/trust-pgp/scenario4.asc b/tests/openpgp/trust-pgp/scenario4.asc new file mode 100644 index 0000000..7860c95 --- /dev/null +++ b/tests/openpgp/trust-pgp/scenario4.asc @@ -0,0 +1,84 @@ +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW2+WxMIKoZIzj0DAQcCAwQnUnqiwvOPU7gGepFTew8Fk5kmVexr+PvaqXgv +9wKxNzZrs4GvamULk9pl2euwJGKPBRJRz8RSNpW6HIIzAPoOtBlBbGljZSA8YWxp +Y2VAZXhhbXBsZS5vcmc+iJAEExMIADgWIQT9myDdPJgSPu6vjMUbpBU40uZWtQUC +WW2+WwIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRAbpBU40uZWtTs8AQC8 +6p4hEyInw17S3P4rVpHP+en+6YJDE7x12b2aevgzsQD/XPhh0PTrAlenhFdQjQbZ +A4dNj5BcxKEIWunJICtZCo0= +=rf4w +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3WihMIKoZIzj0DAQcCAwTtUYI84wfNPCwa/r2ke7tXz0uv/En9LQZbW0QE +nzHigEvMXLfyjfjCf5tQ2eVbKLbABxtKwDtC2bv8dMcmgqd/tBlCb2JieSA8Ym9i +YnlAZXhhbXBsZS5jb20+iJAEExMIADgWIQRNP1n02AMP0thEr+ulusPtElzK5QUC +WW3WigIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRClusPtElzK5ZSOAQD1 +St647GAPOFIIYBDka3EGJeSan8i4f+u80jyplpWeggEA+z9VSDLd7JKMXqD3B/9T +O+rBR22hpi+TILZrbk7svFyIlAQQEwgAPBYhBP2bIN08mBI+7q+MxRukFTjS5la1 +BQJZbm5IAwUCeBqGPFtePl0rW0AuXWV4YW1wbGVcLmNvbT4kAAAKCRAbpBU40uZW +tb+2APsFKgWxiLtSbpcekarOlPrw014LVinLGah3VE1Izay+tAEA+0INHdcNoz64 +kRE/2siUnx1ksrWcWvJbvNMteknXhzY= +=UQni +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3WrxMIKoZIzj0DAQcCAwS4HzEJ0YwXZ1SWciHOmWdfnESTvwC3Zb/sWRu8 +zdIeZzxAwu8lYQaDq/eOgKeXQVW5gxkQG5rCWUazbG+gCBEItBlDYXJvbCA8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264dBv8ojBr0/1uFWOvci/w== +=q1yC +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3XBxMIKoZIzj0DAQcCAwSINFpTZUYnxDDj3k16ljZIt58rh3cuUNIvUcqR +zR9kdlmudQTaf1zUsW6F3r+t91t88kaA2Fcci3wkU0CAob0WtBlIZWlkaSA8aGVp +ZGlAZXhhbXBsZS5vcmc+iJAEExMIADgWIQQDicC3mQ4QUgszTyN1bxVx7akYSwUC +WW3XBwIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRB1bxVx7akYS3BcAP9J +XIhGIadg+SoFWoZ8jYyVOA3z66Ku6vYl2Rw+jKUIQwD+Pc54tFFPV2hycSe9JPWy +uaVfFlNs1RyWcCVrY5l3swSIeQQQEwgAIRYhBKBgdjUZjKuixGf6pkzlu0LjmEAA +BQJZbm8aAwUCeAAKCRBM5btC45hAAPABAPwLtRtV1gnk6qbyb9DvvHbG1kd2sqQ5 +mBM7cw6rPmf2EgEA3V3J9D7/4hbF/tulACVEpW9yvZq3wnEj0GSMpF6qQDE= +=7uOj +-----END PGP PUBLIC KEY BLOCK----- -- 2.9.0 From dgouttegattat at incenp.org Wed Jul 19 11:33:03 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Wed, 19 Jul 2017 11:33:03 +0200 Subject: [PATCH 4/5] gpg,tests: Add private keys for PGP tests. In-Reply-To: <20170719093304.30138-1-dgouttegattat@incenp.org> References: <20170719093304.30138-1-dgouttegattat@incenp.org> Message-ID: <20170719093304.30138-5-dgouttegattat@incenp.org> * tests/openpgp/trust-pgp/alice.sec.asc: New file. * tests/openpgp/trust-pgp/bobby.sec.asc: New file. * tests/openpgp/trust-pgp/carol.sec.asc: New file. * tests/openpgp/trust-pgp/david.sec.asc: New file. * tests/openpgp/trust-pgp/frank.sec.asc: New file. * tests/openpgp/trust-pgp/grace.sec.asc: New file. * tests/openpgp/trust-pgp/heidi.sec.asc: New file. * tests/openpgp/Makefile.am (TEST_FILES): Add new files. -- Those are the private keys used to generate the "scenarios" tested in trust-pgp.scm. They are not needed to run the tests, but they may serve to elaborate other scenarios to test in the future. Signed-off-by: Damien Goutte-Gattat --- tests/openpgp/Makefile.am | 9 ++++++++- tests/openpgp/trust-pgp/alice.sec.asc | 11 +++++++++++ tests/openpgp/trust-pgp/bobby.sec.asc | 11 +++++++++++ tests/openpgp/trust-pgp/carol.sec.asc | 11 +++++++++++ tests/openpgp/trust-pgp/david.sec.asc | 11 +++++++++++ tests/openpgp/trust-pgp/frank.sec.asc | 11 +++++++++++ tests/openpgp/trust-pgp/grace.sec.asc | 11 +++++++++++ tests/openpgp/trust-pgp/heidi.sec.asc | 11 +++++++++++ 8 files changed, 85 insertions(+), 1 deletion(-) create mode 100644 tests/openpgp/trust-pgp/alice.sec.asc create mode 100644 tests/openpgp/trust-pgp/bobby.sec.asc create mode 100644 tests/openpgp/trust-pgp/carol.sec.asc create mode 100644 tests/openpgp/trust-pgp/david.sec.asc create mode 100644 tests/openpgp/trust-pgp/frank.sec.asc create mode 100644 tests/openpgp/trust-pgp/grace.sec.asc create mode 100644 tests/openpgp/trust-pgp/heidi.sec.asc diff --git a/tests/openpgp/Makefile.am b/tests/openpgp/Makefile.am index c615c2a..b3f6e2e 100644 --- a/tests/openpgp/Makefile.am +++ b/tests/openpgp/Makefile.am @@ -163,7 +163,14 @@ TEST_FILES = pubring.asc secring.asc plain-1o.asc plain-2o.asc plain-3o.asc \ trust-pgp/scenario1.asc \ trust-pgp/scenario2.asc \ trust-pgp/scenario3.asc \ - trust-pgp/scenario4.asc + trust-pgp/scenario4.asc \ + trust-pgp/alice.sec.asc \ + trust-pgp/bobby.sec.asc \ + trust-pgp/carol.sec.asc \ + trust-pgp/david.sec.asc \ + trust-pgp/frank.sec.asc \ + trust-pgp/grace.sec.asc \ + trust-pgp/heidi.sec.asc data_files = data-500 data-9000 data-32000 data-80000 plain-large diff --git a/tests/openpgp/trust-pgp/alice.sec.asc b/tests/openpgp/trust-pgp/alice.sec.asc new file mode 100644 index 0000000..1cdde46 --- /dev/null +++ b/tests/openpgp/trust-pgp/alice.sec.asc @@ -0,0 +1,11 @@ +-----BEGIN PGP PRIVATE KEY BLOCK----- + +lHcEWW2+WxMIKoZIzj0DAQcCAwQnUnqiwvOPU7gGepFTew8Fk5kmVexr+PvaqXgv +9wKxNzZrs4GvamULk9pl2euwJGKPBRJRz8RSNpW6HIIzAPoOAAEAgOZk+WDjrmum +0OygJdb6qJp27qsyXvMVZ8AGlsdYtUgS37QZQWxpY2UgPGFsaWNlQGV4YW1wbGUu +b3JnPoiQBBMTCAA4FiEE/Zsg3TyYEj7ur4zFG6QVONLmVrUFAlltvlsCGwMFCwkI +BwIGFQgJCgsCBBYCAwECHgECF4AACgkQG6QVONLmVrU7PAEAvOqeIRMiJ8Ne0tz+ +K1aRz/np/umCQxO8ddm9mnr4M7EA/1z4YdD06wJXp4RXUI0G2QOHTY+QXMShCFrp +ySArWQqN +=3+Iz +-----END PGP PRIVATE KEY BLOCK----- diff --git a/tests/openpgp/trust-pgp/bobby.sec.asc b/tests/openpgp/trust-pgp/bobby.sec.asc new file mode 100644 index 0000000..2164b5d --- /dev/null +++ b/tests/openpgp/trust-pgp/bobby.sec.asc @@ -0,0 +1,11 @@ +-----BEGIN PGP PRIVATE KEY BLOCK----- + +lHcEWW3WihMIKoZIzj0DAQcCAwTtUYI84wfNPCwa/r2ke7tXz0uv/En9LQZbW0QE +nzHigEvMXLfyjfjCf5tQ2eVbKLbABxtKwDtC2bv8dMcmgqd/AAEA6EzyQYtLOL9v +4SErBRic7MmQfxFbEJIQSu2vtbWos/0QFLQZQm9iYnkgPGJvYmJ5QGV4YW1wbGUu +Y29tPoiQBBMTCAA4FiEETT9Z9NgDD9LYRK/rpbrD7RJcyuUFAllt1ooCGwMFCwkI +BwIGFQgJCgsCBBYCAwECHgECF4AACgkQpbrD7RJcyuWUjgEA9UreuOxgDzhSCGAQ +5GtxBiXkmp/IuH/rvNI8qZaVnoIBAPs/VUgy3eySjF6g9wf/UzvqwUdtoaYvkyC2 +a25O7Lxc +=76RO +-----END PGP PRIVATE KEY BLOCK----- diff --git a/tests/openpgp/trust-pgp/carol.sec.asc b/tests/openpgp/trust-pgp/carol.sec.asc new file mode 100644 index 0000000..d366f3f --- /dev/null +++ b/tests/openpgp/trust-pgp/carol.sec.asc @@ -0,0 +1,11 @@ +-----BEGIN PGP PRIVATE KEY BLOCK----- + +lHcEWW3WrxMIKoZIzj0DAQcCAwS4HzEJ0YwXZ1SWciHOmWdfnESTvwC3Zb/sWRu8 +zdIeZzxAwu8lYQaDq/eOgKeXQVW5gxkQG5rCWUazbG+gCBEIAAEA2QzHlkxFJkTg +QvZuimqU0AySYsleRUaO9B9UARiUbOYOwrQZQ2Fyb2wgPGNhcm9sQGV4YW1wbGUu +bmV0PoiQBBMTCAA4FiEEbGJzXkVMzdefpspgEHkROuwSgv0FAllt1q8CGwMFCwkI +BwIGFQgJCgsCBBYCAwECHgECF4AACgkQEHkROuwSgv3MygD+KdusoDvz7WZbsjjB +WI/HLhWfWfXsoAR9mN/5rZ94HDgA/1VqbvUcM+vPU62g7/0qoGqWCda3SURB6263 +Kirbk6hY +=wkQ4 +-----END PGP PRIVATE KEY BLOCK----- diff --git a/tests/openpgp/trust-pgp/david.sec.asc b/tests/openpgp/trust-pgp/david.sec.asc new file mode 100644 index 0000000..06c4e83 --- /dev/null +++ b/tests/openpgp/trust-pgp/david.sec.asc @@ -0,0 +1,11 @@ +-----BEGIN PGP PRIVATE KEY BLOCK----- + +lHcEWW3WzRMIKoZIzj0DAQcCAwQrTeILyHVpkkDsAyAlY7wz0PYjG48ShCYeTX2z +5f2bLxZGeepQeMiOXznPvCwRNMNpr63048+LGqu34Q9di5tvAAD9HITG0iG5SzeW +cGMfhzGuXEn2P+9arb0OttTUcj+eGBIP8bQZRGF2aWQgPGRhdmlkQGV4YW1wbGUu +b3JnPoiQBBMTCAA4FiEEoGB2NRmMq6LEZ/qmTOW7QuOYQAAFAllt1s0CGwMFCwkI +BwIGFQgJCgsCBBYCAwECHgECF4AACgkQTOW7QuOYQAAJtAD+JxiDZttAb51FjB5o +J1BksmzIrgL6ouorbLLRjVyk7rkA/0JqyLhh1K3vn4rYDbuKtvQAcfQbCndzwF9X +uGQ/7gbS +=EC4L +-----END PGP PRIVATE KEY BLOCK----- diff --git a/tests/openpgp/trust-pgp/frank.sec.asc b/tests/openpgp/trust-pgp/frank.sec.asc new file mode 100644 index 0000000..50235de --- /dev/null +++ b/tests/openpgp/trust-pgp/frank.sec.asc @@ -0,0 +1,11 @@ +-----BEGIN PGP PRIVATE KEY BLOCK----- + +lHcEWW3W3RMIKoZIzj0DAQcCAwQs0QS2PEUXhpmsPlaTFOsXd8AoYqpa6xcc0+AE +Mck1EzlqRlxeibvYeh/+yxjl18Ouww/BERB+PcoABXp00zXzAAD+Oybk8/6x5nc8 +ZNHkRIbfHW8oKh7jxbpob9X7QIfBpf8TcbQZRnJhbmsgPGZyYW5rQGV4YW1wbGUu +Y29tPoiQBBMTCAA4FiEEzhoOB8+KIMv43EfW25AX265s0O8FAllt1t0CGwMFCwkI +BwIGFQgJCgsCBBYCAwECHgECF4AACgkQ25AX265s0O+nDQD/RplCmAPQgMejhs2/ +YmOqWrekyd4IWNj9zyI2n228WXYBAJ1/Wf1vBviOEqzs7t+C0iBExxJXViPlG0nN +Z9aoiX1G +=vnHF +-----END PGP PRIVATE KEY BLOCK----- diff --git a/tests/openpgp/trust-pgp/grace.sec.asc b/tests/openpgp/trust-pgp/grace.sec.asc new file mode 100644 index 0000000..23ebd71 --- /dev/null +++ b/tests/openpgp/trust-pgp/grace.sec.asc @@ -0,0 +1,11 @@ +-----BEGIN PGP PRIVATE KEY BLOCK----- + +lHcEWW3W8RMIKoZIzj0DAQcCAwRTGb7wRrdPa+mXxUNJoYgWbKfMDQH9M1H366PQ +ga8L32TYccFzyCD8DuRYOQxzhnCtSHtdzK4QAwwGLaJV6GRjAAEAzBLT+dB5ga7S +Lh7PepOB9yObDHrHAvXGXg9AUvEm3ZkQ6bQZR3JhY2UgPGdyYWNlQGV4YW1wbGUu +bmV0PoiQBBMTCAA4FiEEuTX0uNoAmvvM3UE4ZlOhgwB/g0UFAllt1vECGwMFCwkI +BwIGFQgJCgsCBBYCAwECHgECF4AACgkQZlOhgwB/g0W2AAD+KmW2DQALWTnsVnL/ +QKdJ1J8DsaR1l+y2h7FUYuFttQsBALZYs2vUwOVBnAYyqbHogqgbPSxKRXeAxNqo +epx6csv+ +=05c1 +-----END PGP PRIVATE KEY BLOCK----- diff --git a/tests/openpgp/trust-pgp/heidi.sec.asc b/tests/openpgp/trust-pgp/heidi.sec.asc new file mode 100644 index 0000000..f650d1a --- /dev/null +++ b/tests/openpgp/trust-pgp/heidi.sec.asc @@ -0,0 +1,11 @@ +-----BEGIN PGP PRIVATE KEY BLOCK----- + +lHcEWW3XBxMIKoZIzj0DAQcCAwSINFpTZUYnxDDj3k16ljZIt58rh3cuUNIvUcqR +zR9kdlmudQTaf1zUsW6F3r+t91t88kaA2Fcci3wkU0CAob0WAAD/eTlMM3JTEF6K +yh8gxk1+mXRVUAmcGwr+1PzC3nzJAkgPALQZSGVpZGkgPGhlaWRpQGV4YW1wbGUu +b3JnPoiQBBMTCAA4FiEEA4nAt5kOEFILM08jdW8Vce2pGEsFAllt1wcCGwMFCwkI +BwIGFQgJCgsCBBYCAwECHgECF4AACgkQdW8Vce2pGEtwXAD/SVyIRiGnYPkqBVqG +fI2MlTgN8+uirur2JdkcPoylCEMA/j3OeLRRT1docnEnvST1srmlXxZTbNUclnAl +a2OZd7ME +=1goe +-----END PGP PRIVATE KEY BLOCK----- -- 2.9.0 From justus at g10code.com Wed Jul 19 12:52:41 2017 From: justus at g10code.com (Justus Winter) Date: Wed, 19 Jul 2017 12:52:41 +0200 Subject: [PATCH 3/5] gpg,tests: Add tests for the PGP trust model. In-Reply-To: <20170719093304.30138-4-dgouttegattat@incenp.org> References: <20170719093304.30138-1-dgouttegattat@incenp.org> <20170719093304.30138-4-dgouttegattat@incenp.org> Message-ID: <87a840aebq.fsf@europa.jade-hamburg.de> Hi Damien :) Let me be the first to say: Very cool :D Damien Goutte-Gattat writes: > diff --git a/tests/openpgp/trust-pgp.scm b/tests/openpgp/trust-pgp.scm > new file mode 100644 > index 0000000..d83361b > --- /dev/null > +++ b/tests/openpgp/trust-pgp.scm > @@ -0,0 +1,190 @@ > +#!/usr/bin/env gpgscm > + > +;; Copyright (C) 2017 g10 Code GmbH That should be (c) by you. > +(load (in-srcdir "tests" "openpgp" "defs.scm")) > +(setup-environment) > + > +;; Redefine GPG without --always-trust. > +(define GPG `(,(tool 'gpg))) We should explicitly select the trust model here, because we may want to change the default trust model in the future. > +;; Reset the test environment. We do that kind of brutally, > +;; by removing the pubring and trustdb files. > +(define (reset-environment) > + (catch '() (unlink (path-join GNUPGHOME "pubring.kbx"))) > + (catch '() (unlink (path-join GNUPGHOME "pubring.gpg"))) > + (unlink (path-join GNUPGHOME "trustdb.gpg"))) Hehe >,< brutally, yes. It also hard-codes a lot of knowledge about the internal state of GnuPG. Why not move the common definitions to a separate file, and split this test into four? Thanks, Justus -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 487 bytes Desc: not available URL: From justus at g10code.com Wed Jul 19 12:53:51 2017 From: justus at g10code.com (Justus Winter) Date: Wed, 19 Jul 2017 12:53:51 +0200 Subject: [PATCH 4/5] gpg,tests: Add private keys for PGP tests. In-Reply-To: <20170719093304.30138-5-dgouttegattat@incenp.org> References: <20170719093304.30138-1-dgouttegattat@incenp.org> <20170719093304.30138-5-dgouttegattat@incenp.org> Message-ID: <877ez4ae9s.fsf@europa.jade-hamburg.de> Damien Goutte-Gattat writes: > * tests/openpgp/trust-pgp/alice.sec.asc: New file. > * tests/openpgp/trust-pgp/bobby.sec.asc: New file. > * tests/openpgp/trust-pgp/carol.sec.asc: New file. > * tests/openpgp/trust-pgp/david.sec.asc: New file. > * tests/openpgp/trust-pgp/frank.sec.asc: New file. > * tests/openpgp/trust-pgp/grace.sec.asc: New file. > * tests/openpgp/trust-pgp/heidi.sec.asc: New file. > * tests/openpgp/Makefile.am (TEST_FILES): Add new files. > -- > > Those are the private keys used to generate the "scenarios" tested > in trust-pgp.scm. They are not needed to run the tests, but they > may serve to elaborate other scenarios to test in the future. Why not just add them at the same time as the public counterparts, I always do that. Justus -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 487 bytes Desc: not available URL: From justus at g10code.com Wed Jul 19 13:22:29 2017 From: justus at g10code.com (Justus Winter) Date: Wed, 19 Jul 2017 13:22:29 +0200 Subject: [PATCH 5/5] gpg: Fix regexp sanitization. In-Reply-To: <20170719093304.30138-6-dgouttegattat@incenp.org> References: <20170719093304.30138-1-dgouttegattat@incenp.org> <20170719093304.30138-6-dgouttegattat@incenp.org> Message-ID: <87379sacy2.fsf@europa.jade-hamburg.de> Damien Goutte-Gattat writes: > * g10/trustdb.c (sanitize_regexp): Do not escape normal characters. > -- > > The current sanitization code escapes ALL characters in the > regular expression, including characters that do not have any > special meaning and only match themselves. Only the dot (.) > is not escaped. That is odd indeed. > This leads to, e.g., 'example.com' being sanitized into > '\e\x\a\m\p\l\e.\c\o\m', which will then fail to match against > 'alice at example.com'. And rightfully so, because POSIX says: > The interpretation of an ordinary character preceded by a backslash ( > '\' ) is undefined. http://pubs.opengroup.org/onlinepubs/009695399/basedefs/xbd_chap09.html#tag_09_04_02 > This patch updates the function to escape only the meaningful > characters (minus the dot). I'm not convinced that this patch is correct. I'm not convinced that we should attempt any kind of sanitization at all. This happens right before the expression is fed to the regex engine. I could somehow understand that we do sanitization or try to suggest improvements when users enter an expression, but not when interpreting expressions found in keys. Imagine I have for some reason the expression 'foo.*\.org' in a trust signature, because I only want to match organisations starting with foo. RFC4880 seems to allow that aiui. Your patch breaks that, but so does sanitize_regexp as it is now. I don't see how and why we should do any sane sanitization at all. Discuss! Cheers, Justus -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 487 bytes Desc: not available URL: From dgouttegattat at incenp.org Wed Jul 19 15:07:22 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Wed, 19 Jul 2017 15:07:22 +0200 Subject: [PATCH 5/5] gpg: Fix regexp sanitization. In-Reply-To: <87379sacy2.fsf@europa.jade-hamburg.de> References: <20170719093304.30138-1-dgouttegattat@incenp.org> <20170719093304.30138-6-dgouttegattat@incenp.org> <87379sacy2.fsf@europa.jade-hamburg.de> Message-ID: On 07/19/2017 01:22 PM, Justus Winter wrote:> Imagine I have for some reason the expression 'foo.*\.org' in a > trust signature, because I only want to match organisations starting > with foo. RFC4880 seems to allow that aiui. Your patch breaks that, > but so does sanitize_regexp as it is now. Yes. It seems GnuPG wants to use the regex associated with trust signatures in a more restricted way than is permitted by RFC4880. I think it was designed that way probably to be compatible with PGP. I never actually used PGP, but judging from a quick look at the manuals for several versions, it seems that in PGP too this feature was limited to simple domain matching. See for example this sentence from the manual for PGP 10.2 [1]: "If you want to limit the trusted introducer's key validation capabilities to a single domain, type the domain name in the Domain Restriction text box." I guess that when they allowed the use of regular expressions in trust signature, the authors of RFC4880 went beyond what the implementations of the time supported. > I don't see how and why we should do any sane sanitization at all. For what is worth, I tend to agree. But I won't pretend I have seriously considered all the implications. > Discuss! Well, I am not sure whether we *should* sanitize, but if we do, we should do it correctly. As of now, our sanitization code is broken, so I would suggest to fix it so that it at least works as intended (that is, it allows simple domain matching). After that we may decide what to do with it. A possible compromise would be to make the behavior dependent on the --rfc4880 compliance flag: if the flag is set, we allow full-fledged regex matching as per RFC4880, otherwise (and by default) we sanitize the regex to only allow simple domain matching. Damien [1] https://symwisedownload.symantec.com/resources/sites/SYMWISE/content/live/DOCUMENTATION/3000/DOC3586/en_US/pgpDesktopWin1011_usersguide_en.pdf?__gda__=1500611307_8d91680315b12345b9773774e1cd28b1 -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 488 bytes Desc: OpenPGP digital signature URL: From dgouttegattat at incenp.org Wed Jul 19 15:16:19 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Wed, 19 Jul 2017 15:16:19 +0200 Subject: [PATCH 3/5] gpg,tests: Add tests for the PGP trust model. In-Reply-To: <87a840aebq.fsf@europa.jade-hamburg.de> References: <20170719093304.30138-1-dgouttegattat@incenp.org> <20170719093304.30138-4-dgouttegattat@incenp.org> <87a840aebq.fsf@europa.jade-hamburg.de> Message-ID: <003d5212-8827-4c73-8612-5b07ace9033c@incenp.org> On 07/19/2017 12:52 PM, Justus Winter wrote: > Let me be the first to say: Very cool :D Thanks. :) >> +;; Redefine GPG without --always-trust. >> +(define GPG `(,(tool 'gpg))) > > We should explicitly select the trust model here, because we may want to > change the default trust model in the future. That is done a little bit later by calling gpgconf to set the trust-model option: (let ((trust-model (gpg-config 'gpg "trust-model"))) (trust-model::update "pgp")) > Hehe >,< brutally, yes. It also hard-codes a lot of knowledge about the > internal state of GnuPG. Why not move the common definitions to a > separate file, and split this test into four? That would probably be cleaner and more robust, indeed. OK, I will do that and re-submit the patchset. Thanks for the comments. -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 488 bytes Desc: OpenPGP digital signature URL: From john.fr.omeara at gmail.com Wed Jul 19 14:55:34 2017 From: john.fr.omeara at gmail.com (John O'Meara) Date: Wed, 19 Jul 2017 08:55:34 -0400 Subject: [PATCH 5/5] gpg: Fix regexp sanitization. In-Reply-To: <87379sacy2.fsf@europa.jade-hamburg.de> References: <20170719093304.30138-1-dgouttegattat@incenp.org> <20170719093304.30138-6-dgouttegattat@incenp.org> <87379sacy2.fsf@europa.jade-hamburg.de> Message-ID: <150046893440.3915.7643307196959228753.mailnex@john-laptop-bonb.linsam.homelinux.com> Quoth Justus Winter on Wed, 19 Jul 2017 13:22:29 +0200: > Damien Goutte-Gattat writes: > >> This patch updates the function to escape only the meaningful >> characters (minus the dot). > > I'm not convinced that this patch is correct. I'm not convinced that we > should attempt any kind of sanitization at all. This happens right > before the expression is fed to the regex engine. I could somehow > understand that we do sanitization or try to suggest improvements when > users enter an expression, but not when interpreting expressions found > in keys. > > Imagine I have for some reason the expression 'foo.*\.org' in a trust > signature, because I only want to match organisations starting with foo. > RFC4880 seems to allow that aiui. Your patch breaks that, but so does > sanitize_regexp as it is now. > > > I don't see how and why we should do any sane sanitization at all. > > Discuss! As I see it, the problem is that the OpenPGP regex dialect (from RFC4880) is different than the one that POSIX uses. I can see 3 options for dealing with the difference: 1: Implement the RFC4880 dialect ourselves. This seems error prone and a 'reinvention of the wheel'. 2: Utilize the regex implementation specified in RFC4880. I presume this wasn't done due to license incompatibility (but I don't actually know). 3: Convert from RFC4880 regex dialect to POSIX dialect and then feed the result to the POSIX engine. The latter is what I attempted in my January patch, and for the purpose of covering cases like the 'foo.*\.org' case you mention. For my own purposes, I needed to select 2 domains, so I needed something like '(domA|domB)\.com', which my patch also covered. (However, I didn't have any coded tests for it) I think option 2 would be the best, if possible, because then there shouldn't be any weird corner cases to worry about. I am happy in the short term for Damien's patches, since they provide the testing foundation and the sanitation update at least allows simple trust signatures to work now. -- John O'Meara From neal at walfield.org Wed Jul 19 15:45:35 2017 From: neal at walfield.org (Neal H. Walfield) Date: Wed, 19 Jul 2017 15:45:35 +0200 Subject: [PATCH 5/5] gpg: Fix regexp sanitization. In-Reply-To: References: <20170719093304.30138-1-dgouttegattat@incenp.org> <20170719093304.30138-6-dgouttegattat@incenp.org> <87379sacy2.fsf@europa.jade-hamburg.de> Message-ID: <871spcv8u8.wl-neal@walfield.org> At Wed, 19 Jul 2017 15:07:22 +0200, Damien Goutte-Gattat wrote: > > I don't see how and why we should do any sane sanitization at all. > > For what is worth, I tend to agree. But I won't pretend I have > seriously considered all the implications. I think trust signatures are very useful from an organizational perspective, but are completely under used. I think it is worth exploring what the implications of any change in behavior are. A good start would be finding all trust sigs with a non-empty regex in a key server dump so that we can see how people are actually using them in practice. (I suspect there aren't that many.) Thanks, :) Neal From dgouttegattat at incenp.org Wed Jul 19 22:17:26 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Wed, 19 Jul 2017 22:17:26 +0200 Subject: [PATCH v2 0/4] Add tests for the PGP trust model In-Reply-To: <87a840aebq.fsf@europa.jade-hamburg.de> References: <87a840aebq.fsf@europa.jade-hamburg.de> Message-ID: <20170719201730.4339-1-dgouttegattat@incenp.org> On 07/19/2017 12:52 PM, Justus Winter wrote: > Why not move the common definitions to a separate file, and > split this test into four. OK, I have done just that. Thanks for the suggestion, I believe it is indeed much cleaner this way. For convenience, here is the whole patchset again. Note that I have again included the patch about regexp sanitization, even though we have yet to decide about the best way to fix this issue. If you prefer not to apply that patch yet, we would have to either 1) disable the corresponding test trust-pgp-4.scm, or 2) mark it as a test that should fail, or 3) accept that 'make check' fails until issue 2923 is fixed one way or another. :) Damien Goutte-Gattat (4): gpgconf: Make WoT settings configurable by gpgconf. gpg,tests: Move some functions into a common module. gpg,tests: Add tests for the PGP trust model. gpg: Fix regexp sanitization. g10/gpg.c | 3 ++ g10/trustdb.c | 2 +- tests/openpgp/Makefile.am | 19 +++++++- tests/openpgp/defs.scm | 24 ++++++++++ tests/openpgp/tofu.scm | 24 ---------- tests/openpgp/trust-pgp-1.scm | 76 +++++++++++++++++++++++++++++++ tests/openpgp/trust-pgp-2.scm | 39 ++++++++++++++++ tests/openpgp/trust-pgp-3.scm | 31 +++++++++++++ tests/openpgp/trust-pgp-4.scm | 37 +++++++++++++++ tests/openpgp/trust-pgp/alice.sec.asc | 11 +++++ tests/openpgp/trust-pgp/bobby.sec.asc | 11 +++++ tests/openpgp/trust-pgp/carol.sec.asc | 11 +++++ tests/openpgp/trust-pgp/common.scm | 66 +++++++++++++++++++++++++++ tests/openpgp/trust-pgp/david.sec.asc | 11 +++++ tests/openpgp/trust-pgp/frank.sec.asc | 11 +++++ tests/openpgp/trust-pgp/grace.sec.asc | 11 +++++ tests/openpgp/trust-pgp/heidi.sec.asc | 11 +++++ tests/openpgp/trust-pgp/scenario1.asc | 75 +++++++++++++++++++++++++++++++ tests/openpgp/trust-pgp/scenario2.asc | 70 +++++++++++++++++++++++++++++ tests/openpgp/trust-pgp/scenario3.asc | 58 ++++++++++++++++++++++++ tests/openpgp/trust-pgp/scenario4.asc | 84 +++++++++++++++++++++++++++++++++++ tools/gpgconf-comp.c | 12 +++++ 22 files changed, 670 insertions(+), 27 deletions(-) create mode 100755 tests/openpgp/trust-pgp-1.scm create mode 100755 tests/openpgp/trust-pgp-2.scm create mode 100755 tests/openpgp/trust-pgp-3.scm create mode 100755 tests/openpgp/trust-pgp-4.scm create mode 100644 tests/openpgp/trust-pgp/alice.sec.asc create mode 100644 tests/openpgp/trust-pgp/bobby.sec.asc create mode 100644 tests/openpgp/trust-pgp/carol.sec.asc create mode 100644 tests/openpgp/trust-pgp/common.scm create mode 100644 tests/openpgp/trust-pgp/david.sec.asc create mode 100644 tests/openpgp/trust-pgp/frank.sec.asc create mode 100644 tests/openpgp/trust-pgp/grace.sec.asc create mode 100644 tests/openpgp/trust-pgp/heidi.sec.asc create mode 100644 tests/openpgp/trust-pgp/scenario1.asc create mode 100644 tests/openpgp/trust-pgp/scenario2.asc create mode 100644 tests/openpgp/trust-pgp/scenario3.asc create mode 100644 tests/openpgp/trust-pgp/scenario4.asc -- 2.9.0 From dgouttegattat at incenp.org Wed Jul 19 22:17:27 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Wed, 19 Jul 2017 22:17:27 +0200 Subject: [PATCH v2 1/4] gpgconf: Make WoT settings configurable by gpgconf. In-Reply-To: <20170719201730.4339-1-dgouttegattat@incenp.org> References: <20170719201730.4339-1-dgouttegattat@incenp.org> Message-ID: <20170719201730.4339-2-dgouttegattat@incenp.org> * tools/gpgconf-comp.c (gc_options_gpg): Add max-cert-depth, completes-needed, and marginals-needed options. * g10/gpg.c (gpgconf_list): Likewise. -- Some tests to come for the PGP trust model will need to manipulate these parameters. Signed-off-by: Damien Goutte-Gattat --- g10/gpg.c | 3 +++ tools/gpgconf-comp.c | 12 ++++++++++++ 2 files changed, 15 insertions(+) diff --git a/g10/gpg.c b/g10/gpg.c index 5c60e1d..4dccf72 100644 --- a/g10/gpg.c +++ b/g10/gpg.c @@ -1855,6 +1855,9 @@ gpgconf_list (const char *configfile) es_printf ("compliance:%lu:\"%s:\n", GC_OPT_FLAG_DEFAULT, "gnupg"); es_printf ("default-new-key-algo:%lu:\n", GC_OPT_FLAG_NONE); es_printf ("trust-model:%lu:\n", GC_OPT_FLAG_NONE); + es_printf ("max-cert-depth:%lu:\n", GC_OPT_FLAG_NONE); + es_printf ("completes-needed:%lu:\n", GC_OPT_FLAG_NONE); + es_printf ("marginals-needed:%lu:\n", GC_OPT_FLAG_NONE); /* The next one is an info only item and should match the macros at the top of keygen.c */ diff --git a/tools/gpgconf-comp.c b/tools/gpgconf-comp.c index a8ecb07..ba7abe0 100644 --- a/tools/gpgconf-comp.c +++ b/tools/gpgconf-comp.c @@ -724,6 +724,18 @@ static gc_option_t gc_options_gpg[] = GC_OPT_FLAG_NONE, GC_LEVEL_INVISIBLE, NULL, NULL, GC_ARG_TYPE_STRING, GC_BACKEND_GPG }, + { "max-cert-depth", + GC_OPT_FLAG_NONE, GC_LEVEL_INVISIBLE, + NULL, NULL, + GC_ARG_TYPE_UINT32, GC_BACKEND_GPG }, + { "completes-needed", + GC_OPT_FLAG_NONE, GC_LEVEL_INVISIBLE, + NULL, NULL, + GC_ARG_TYPE_UINT32, GC_BACKEND_GPG }, + { "marginals-needed", + GC_OPT_FLAG_NONE, GC_LEVEL_INVISIBLE, + NULL, NULL, + GC_ARG_TYPE_UINT32, GC_BACKEND_GPG }, { "Debug", -- 2.9.0 From dgouttegattat at incenp.org Wed Jul 19 22:17:28 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Wed, 19 Jul 2017 22:17:28 +0200 Subject: [PATCH v2 2/4] gpg,tests: Move some functions into a common module. In-Reply-To: <20170719201730.4339-1-dgouttegattat@incenp.org> References: <20170719201730.4339-1-dgouttegattat@incenp.org> Message-ID: <20170719201730.4339-3-dgouttegattat@incenp.org> * tests/openpgp/tofu.scm (gettrust): Moved to the common defs.scm module. (checktrust): Likewise. * tests/openpgp/defs.scm (gettrust): New function. (checktrust): Likewise. -- These functions will be re-used by the tests for the PGP trust model. Signed-off-by: Damien Goutte-Gattat --- tests/openpgp/defs.scm | 24 ++++++++++++++++++++++++ tests/openpgp/tofu.scm | 24 ------------------------ 2 files changed, 24 insertions(+), 24 deletions(-) diff --git a/tests/openpgp/defs.scm b/tests/openpgp/defs.scm index b5e3078..815200e 100644 --- a/tests/openpgp/defs.scm +++ b/tests/openpgp/defs.scm @@ -464,5 +464,29 @@ (catch (log "Warning: Removing socket directory failed.") (gpg-conf '--remove-socketdir))) +;; Get the trust level for KEYID. Any remaining arguments are simply +;; passed to GPG. +;; +;; This function only supports keys with a single user id. +(define (gettrust keyid . args) + (let ((trust + (list-ref (assoc "pub" (gpg-with-colons + `(, at args + --list-keys ,keyid))) 1))) + (unless (and (= 1 (string-length trust)) + (member (string-ref trust 0) (string->list "oidreqnmfuws-"))) + (fail "Bad trust value:" trust)) + trust)) + +;; Check that KEYID's trust level matches EXPECTED-TRUST. Any +;; remaining arguments are simply passed to GPG. +;; +;; This function only supports keys with a single user id. +(define (checktrust keyid expected-trust . args) + (let ((trust (apply gettrust `(,keyid , at args)))) + (unless (string=? trust expected-trust) + (fail keyid ": Expected trust to be" expected-trust + "but got" trust)))) + ;; end diff --git a/tests/openpgp/tofu.scm b/tests/openpgp/tofu.scm index 58b2a03..cd4b4c7 100755 --- a/tests/openpgp/tofu.scm +++ b/tests/openpgp/tofu.scm @@ -71,30 +71,6 @@ (fail keyid ": Expected policy to be" expected-policy "but got" policy)))) -;; Get the trust level for KEYID. Any remaining arguments are simply -;; passed to GPG. -;; -;; This function only supports keys with a single user id. -(define (gettrust keyid . args) - (let ((trust - (list-ref (assoc "pub" (gpg-with-colons - `(, at args - --list-keys ,keyid))) 1))) - (unless (and (= 1 (string-length trust)) - (member (string-ref trust 0) (string->list "oidreqnmfuws-"))) - (fail "Bad trust value:" trust)) - trust)) - -;; Check that KEYID's trust level matches EXPECTED-TRUST. Any -;; remaining arguments are simply passed to GPG. -;; -;; This function only supports keys with a single user id. -(define (checktrust keyid expected-trust . args) - (let ((trust (apply gettrust `(,keyid , at args)))) - (unless (string=? trust expected-trust) - (fail keyid ": Expected trust to be" expected-trust - "but got" trust)))) - ;; Set key KEYID's policy to POLICY. Any remaining arguments are ;; passed as options to gpg. (define (setpolicy keyid policy . args) -- 2.9.0 From dgouttegattat at incenp.org Wed Jul 19 22:17:30 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Wed, 19 Jul 2017 22:17:30 +0200 Subject: [PATCH v2 4/4] gpg: Fix regexp sanitization. In-Reply-To: <20170719201730.4339-1-dgouttegattat@incenp.org> References: <20170719201730.4339-1-dgouttegattat@incenp.org> Message-ID: <20170719201730.4339-5-dgouttegattat@incenp.org> * g10/trustdb.c (sanitize_regexp): Do not escape normal characters. -- The current sanitization code escapes ALL characters in the regular expression, including characters that do not have any special meaning and only match themselves. Only the dot (.) is not escaped. This leads to, e.g., 'example.com' being sanitized into '\e\x\a\m\p\l\e.\c\o\m', which will then fail to match against 'alice at example.com'. This patch updates the function to escape only the meaningful characters (minus the dot). GnuPG-bug-id: 2923 Signed-off-by: Damien Goutte-Gattat --- g10/trustdb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/g10/trustdb.c b/g10/trustdb.c index e2c3bda..080f2f3 100644 --- a/g10/trustdb.c +++ b/g10/trustdb.c @@ -1541,7 +1541,7 @@ sanitize_regexp(const char *old) { if(!escaped && old[start]=='\\') escaped=1; - else if(!escaped && old[start]!='.') + else if(!escaped && strchr("[]$^()|*+?{}", old[start])) new[idx++]='\\'; else escaped=0; -- 2.9.0 From dgouttegattat at incenp.org Wed Jul 19 22:17:29 2017 From: dgouttegattat at incenp.org (Damien Goutte-Gattat) Date: Wed, 19 Jul 2017 22:17:29 +0200 Subject: [PATCH v2 3/4] gpg,tests: Add tests for the PGP trust model. In-Reply-To: <20170719201730.4339-1-dgouttegattat@incenp.org> References: <20170719201730.4339-1-dgouttegattat@incenp.org> Message-ID: <20170719201730.4339-4-dgouttegattat@incenp.org> * tests/openpgp/trust-pgp-1.scm: New file. * tests/openpgp/trust-pgp-2.scm: New file. * tests/openpgp/trust-pgp-3.scm: New file. * tests/openpgp/trust-pgp-4.scm: New file. * tests/openpgp/trust-pgp/common.scm: New file. * tests/openpgp/trust-pgp/scenario1.asc: New file. * tests/openpgp/trust-pgp/scenario2.asc: New file. * tests/openpgp/trust-pgp/scenario3.asc: New file. * tests/openpgp/trust-pgp/scenario4.asc: New file. * tests/openpgp/trust-pgp/alice.sec.asc: New file. * tests/openpgp/trust-pgp/bobby.sec.asc: New file. * tests/openpgp/trust-pgp/carol.sec.asc: New file. * tests/openpgp/trust-pgp/david.sec.asc: New file. * tests/openpgp/trust-pgp/frank.sec.asc: New file. * tests/openpgp/trust-pgp/grace.sec.asc: New file. * tests/openpgp/trust-pgp/heidi.sec.asc: New file. * tests/openpgp/Makefile.am (XTESTS): Add new tests. (TEST_FILES): Add new files. (EXTRA_DIST): Add new common file. Signed-off-by: Damien Goutte-Gattat --- tests/openpgp/Makefile.am | 19 +++++++- tests/openpgp/trust-pgp-1.scm | 76 +++++++++++++++++++++++++++++++ tests/openpgp/trust-pgp-2.scm | 39 ++++++++++++++++ tests/openpgp/trust-pgp-3.scm | 31 +++++++++++++ tests/openpgp/trust-pgp-4.scm | 37 +++++++++++++++ tests/openpgp/trust-pgp/alice.sec.asc | 11 +++++ tests/openpgp/trust-pgp/bobby.sec.asc | 11 +++++ tests/openpgp/trust-pgp/carol.sec.asc | 11 +++++ tests/openpgp/trust-pgp/common.scm | 66 +++++++++++++++++++++++++++ tests/openpgp/trust-pgp/david.sec.asc | 11 +++++ tests/openpgp/trust-pgp/frank.sec.asc | 11 +++++ tests/openpgp/trust-pgp/grace.sec.asc | 11 +++++ tests/openpgp/trust-pgp/heidi.sec.asc | 11 +++++ tests/openpgp/trust-pgp/scenario1.asc | 75 +++++++++++++++++++++++++++++++ tests/openpgp/trust-pgp/scenario2.asc | 70 +++++++++++++++++++++++++++++ tests/openpgp/trust-pgp/scenario3.asc | 58 ++++++++++++++++++++++++ tests/openpgp/trust-pgp/scenario4.asc | 84 +++++++++++++++++++++++++++++++++++ 17 files changed, 630 insertions(+), 2 deletions(-) create mode 100755 tests/openpgp/trust-pgp-1.scm create mode 100755 tests/openpgp/trust-pgp-2.scm create mode 100755 tests/openpgp/trust-pgp-3.scm create mode 100755 tests/openpgp/trust-pgp-4.scm create mode 100644 tests/openpgp/trust-pgp/alice.sec.asc create mode 100644 tests/openpgp/trust-pgp/bobby.sec.asc create mode 100644 tests/openpgp/trust-pgp/carol.sec.asc create mode 100644 tests/openpgp/trust-pgp/common.scm create mode 100644 tests/openpgp/trust-pgp/david.sec.asc create mode 100644 tests/openpgp/trust-pgp/frank.sec.asc create mode 100644 tests/openpgp/trust-pgp/grace.sec.asc create mode 100644 tests/openpgp/trust-pgp/heidi.sec.asc create mode 100644 tests/openpgp/trust-pgp/scenario1.asc create mode 100644 tests/openpgp/trust-pgp/scenario2.asc create mode 100644 tests/openpgp/trust-pgp/scenario3.asc create mode 100644 tests/openpgp/trust-pgp/scenario4.asc diff --git a/tests/openpgp/Makefile.am b/tests/openpgp/Makefile.am index 506bce5..190e2b5 100644 --- a/tests/openpgp/Makefile.am +++ b/tests/openpgp/Makefile.am @@ -82,6 +82,10 @@ XTESTS = \ ecc.scm \ 4gb-packet.scm \ tofu.scm \ + trust-pgp-1.scm \ + trust-pgp-2.scm \ + trust-pgp-3.scm \ + trust-pgp-4.scm \ gpgtar.scm \ use-exact-key.scm \ default-key.scm \ @@ -158,7 +162,18 @@ TEST_FILES = pubring.asc secring.asc plain-1o.asc plain-2o.asc plain-3o.asc \ key-selection/1.asc \ key-selection/2.asc \ key-selection/3.asc \ - key-selection/4.asc + key-selection/4.asc \ + trust-pgp/scenario1.asc \ + trust-pgp/scenario2.asc \ + trust-pgp/scenario3.asc \ + trust-pgp/scenario4.asc \ + trust-pgp/alice.sec.asc \ + trust-pgp/bobby.sec.asc \ + trust-pgp/carol.sec.asc \ + trust-pgp/david.sec.asc \ + trust-pgp/frank.sec.asc \ + trust-pgp/grace.sec.asc \ + trust-pgp/heidi.sec.asc data_files = data-500 data-9000 data-32000 data-80000 plain-large @@ -248,7 +263,7 @@ sample_msgs = samplemsgs/clearsig-1-key-1.asc \ samplemsgs/signed-2-keys-1.asc \ samplemsgs/signed-2-keys-2.asc -EXTRA_DIST = defs.scm $(XTESTS) $(TEST_FILES) \ +EXTRA_DIST = defs.scm trust-pgp/common.scm $(XTESTS) $(TEST_FILES) \ mkdemodirs signdemokey $(priv_keys) $(sample_keys) \ $(sample_msgs) ChangeLog-2011 run-tests.scm \ setup.scm shell.scm all-tests.scm signed-messages.scm diff --git a/tests/openpgp/trust-pgp-1.scm b/tests/openpgp/trust-pgp-1.scm new file mode 100755 index 0000000..235cb55 --- /dev/null +++ b/tests/openpgp/trust-pgp-1.scm @@ -0,0 +1,76 @@ +#!/usr/bin/env gpgscm + +;; Copyright (C) 2017 Damien Goutte-Gattat +;; +;; This file is part of GnuPG. +;; +;; +;; GnuPG is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 3 of the License, or +;; (at your option) any later version. +;; +;; GnuPG 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, see . + +(load (in-srcdir "tests" "openpgp" "trust-pgp" "common.scm")) + +(display "Checking basic WoT (classic trust model)...\n") + +(initscenario "scenario1") + +;; Check initial state. +(checktrust BOBBY "f") ;; Directly signed by Alice's key. +(checktrust CAROL "q") ;; Signed by Bobby, whose key has + ;; no explicit ownertrust. +(checktrust DAVID "q") ;; Likewise. +(checktrust FRANK "q") ;; Likewise. +(checktrust GRACE "-") ;; Signed by the previous three keys; + ;; not evaluated since they are not valid. + +;; Let's trust Bobby. +;; This should make Carol's, David's, and Frank's keys valid. +(setownertrust BOBBY FULLTRUST) +(updatetrustdb) +(checktrust CAROL "f") +(checktrust DAVID "f") +(checktrust FRANK "f") +(checktrust GRACE "q") ;; Now evaluated, but validity still unknown. + +;; Let's trust (marginally) Carol and David. +;; This should not be enough to make Grace's key fully valid +;; since marginals-needed defaults to 3. +(setownertrust CAROL MARGINALTRUST) +(setownertrust DAVID MARGINALTRUST) +(updatetrustdb) +(checktrust GRACE "m") + +;; Add marginal ownertrust to Frank's key. +;; This should make Grace's key fully valid. +(setownertrust FRANK MARGINALTRUST) +(updatetrustdb) +(checktrust GRACE "f") + +;; Now let's play with the length of certification chains. +;; Setting max-cert-length to 2 should put Grace's key +;; one step too far from Alice's key. +(let ((max-cert-depth (gpg-config 'gpg "max-cert-depth"))) + (max-cert-depth::update 2)) +(updatetrustdb) +(checktrust GRACE "-") + +;; Raise the bar for assigning full validity. +;; Bobby's key should be the only one retaining full validity. +(let ((completes-needed (gpg-config 'gpg "completes-needed"))) + (completes-needed::update 2)) +(updatetrustdb) +(checktrust BOBBY "f") +(checktrust CAROL "m") +(checktrust DAVID "m") +(checktrust FRANK "m") +(checktrust GRACE "-") diff --git a/tests/openpgp/trust-pgp-2.scm b/tests/openpgp/trust-pgp-2.scm new file mode 100755 index 0000000..a56d0a9 --- /dev/null +++ b/tests/openpgp/trust-pgp-2.scm @@ -0,0 +1,39 @@ +#!/usr/bin/env gpgscm + +;; Copyright (C) 2017 Damien Goutte-Gattat +;; +;; This file is part of GnuPG. +;; +;; +;; GnuPG is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 3 of the License, or +;; (at your option) any later version. +;; +;; GnuPG 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, see . + +(load (in-srcdir "tests" "openpgp" "trust-pgp" "common.scm")) + +(display "Checking WoT with trust signatures (PGP trust model)...\n") + +(initscenario "scenario2") + +(checktrust BOBBY "f") ;; Tsigned by Alice with trust=120. +(checktrust CAROL "f") ;; Signed by Bobby, whose key should have full + ;; ownertrust due to the tsig. +(checktrust DAVID "f") ;; Signed by Alice. +(checktrust FRANK "q") ;; Tsigned by David, whose key has no ownertrust. +(checktrust GRACE "-") ;; Signed by Frank. + +(setownertrust DAVID FULLTRUST) +(updatetrustdb) +(checktrust FRANK "f") ;; David's key has now full ownertrust. +(checktrust GRACE "q") ;; David is not authorized to emit tsigs, + ;; so his tsig on Frank's key should be treated + ;; like a normal sig (confering no ownertrust). diff --git a/tests/openpgp/trust-pgp-3.scm b/tests/openpgp/trust-pgp-3.scm new file mode 100755 index 0000000..33832db --- /dev/null +++ b/tests/openpgp/trust-pgp-3.scm @@ -0,0 +1,31 @@ +#!/usr/bin/env gpgscm + +;; Copyright (C) 2017 Damien Goutte-Gattat +;; +;; This file is part of GnuPG. +;; +;; +;; GnuPG is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 3 of the License, or +;; (at your option) any later version. +;; +;; GnuPG 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, see . + +(load (in-srcdir "tests" "openpgp" "trust-pgp" "common.scm")) + +(display "Checking max depth of trust signature chains...\n") + +(initscenario "scenario3") + +(checktrust BOBBY "f") ;; Tsigned by Alice (level=2, trust=120). +(checktrust CAROL "f") ;; Tsigned by Bobby (level=2, trust=120). +(checktrust DAVID "f") ;; Tsigned by Carol (level=2, trust=120). +(checktrust FRANK "q") ;; The tsig from Carol does not confer + ;; ownertrust to David's key (too deep). diff --git a/tests/openpgp/trust-pgp-4.scm b/tests/openpgp/trust-pgp-4.scm new file mode 100755 index 0000000..17746a5 --- /dev/null +++ b/tests/openpgp/trust-pgp-4.scm @@ -0,0 +1,37 @@ +#!/usr/bin/env gpgscm + +;; Copyright (C) 2017 Damien Goutte-Gattat +;; +;; This file is part of GnuPG. +;; +;; +;; GnuPG is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 3 of the License, or +;; (at your option) any later version. +;; +;; GnuPG 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, see . + +(load (in-srcdir "tests" "openpgp" "trust-pgp" "common.scm")) + +(display "Checking trust signature with domain restrictions...\n") + +(initscenario "scenario4") + +(checktrust BOBBY "f") ;; Tsigned by Alice, allowed to sign for example.com. +(checktrust CAROL "-") ;; Signed by Bobby, but the signature should be + ;; ignored since Carol has an address in example.net. + +(checktrust DAVID "f") ;; Tsigned by Alice, allowed to sign for example.net. +(checktrust FRANK "-") ;; Tsignature from David should be ignored because + ;; Frank has an address in example.com. + +(checktrust HEIDI "f") ;; Tsigned by David, should be valid since Heidi + ;; has an address in example.org. +(checktrust GRACE "f") ;; Signed by Heidi. diff --git a/tests/openpgp/trust-pgp/alice.sec.asc b/tests/openpgp/trust-pgp/alice.sec.asc new file mode 100644 index 0000000..1cdde46 --- /dev/null +++ b/tests/openpgp/trust-pgp/alice.sec.asc @@ -0,0 +1,11 @@ +-----BEGIN PGP PRIVATE KEY BLOCK----- + +lHcEWW2+WxMIKoZIzj0DAQcCAwQnUnqiwvOPU7gGepFTew8Fk5kmVexr+PvaqXgv +9wKxNzZrs4GvamULk9pl2euwJGKPBRJRz8RSNpW6HIIzAPoOAAEAgOZk+WDjrmum +0OygJdb6qJp27qsyXvMVZ8AGlsdYtUgS37QZQWxpY2UgPGFsaWNlQGV4YW1wbGUu +b3JnPoiQBBMTCAA4FiEE/Zsg3TyYEj7ur4zFG6QVONLmVrUFAlltvlsCGwMFCwkI +BwIGFQgJCgsCBBYCAwECHgECF4AACgkQG6QVONLmVrU7PAEAvOqeIRMiJ8Ne0tz+ +K1aRz/np/umCQxO8ddm9mnr4M7EA/1z4YdD06wJXp4RXUI0G2QOHTY+QXMShCFrp +ySArWQqN +=3+Iz +-----END PGP PRIVATE KEY BLOCK----- diff --git a/tests/openpgp/trust-pgp/bobby.sec.asc b/tests/openpgp/trust-pgp/bobby.sec.asc new file mode 100644 index 0000000..2164b5d --- /dev/null +++ b/tests/openpgp/trust-pgp/bobby.sec.asc @@ -0,0 +1,11 @@ +-----BEGIN PGP PRIVATE KEY BLOCK----- + +lHcEWW3WihMIKoZIzj0DAQcCAwTtUYI84wfNPCwa/r2ke7tXz0uv/En9LQZbW0QE +nzHigEvMXLfyjfjCf5tQ2eVbKLbABxtKwDtC2bv8dMcmgqd/AAEA6EzyQYtLOL9v +4SErBRic7MmQfxFbEJIQSu2vtbWos/0QFLQZQm9iYnkgPGJvYmJ5QGV4YW1wbGUu +Y29tPoiQBBMTCAA4FiEETT9Z9NgDD9LYRK/rpbrD7RJcyuUFAllt1ooCGwMFCwkI +BwIGFQgJCgsCBBYCAwECHgECF4AACgkQpbrD7RJcyuWUjgEA9UreuOxgDzhSCGAQ +5GtxBiXkmp/IuH/rvNI8qZaVnoIBAPs/VUgy3eySjF6g9wf/UzvqwUdtoaYvkyC2 +a25O7Lxc +=76RO +-----END PGP PRIVATE KEY BLOCK----- diff --git a/tests/openpgp/trust-pgp/carol.sec.asc b/tests/openpgp/trust-pgp/carol.sec.asc new file mode 100644 index 0000000..d366f3f --- /dev/null +++ b/tests/openpgp/trust-pgp/carol.sec.asc @@ -0,0 +1,11 @@ +-----BEGIN PGP PRIVATE KEY BLOCK----- + +lHcEWW3WrxMIKoZIzj0DAQcCAwS4HzEJ0YwXZ1SWciHOmWdfnESTvwC3Zb/sWRu8 +zdIeZzxAwu8lYQaDq/eOgKeXQVW5gxkQG5rCWUazbG+gCBEIAAEA2QzHlkxFJkTg +QvZuimqU0AySYsleRUaO9B9UARiUbOYOwrQZQ2Fyb2wgPGNhcm9sQGV4YW1wbGUu +bmV0PoiQBBMTCAA4FiEEbGJzXkVMzdefpspgEHkROuwSgv0FAllt1q8CGwMFCwkI +BwIGFQgJCgsCBBYCAwECHgECF4AACgkQEHkROuwSgv3MygD+KdusoDvz7WZbsjjB +WI/HLhWfWfXsoAR9mN/5rZ94HDgA/1VqbvUcM+vPU62g7/0qoGqWCda3SURB6263 +Kirbk6hY +=wkQ4 +-----END PGP PRIVATE KEY BLOCK----- diff --git a/tests/openpgp/trust-pgp/common.scm b/tests/openpgp/trust-pgp/common.scm new file mode 100644 index 0000000..2a545e8 --- /dev/null +++ b/tests/openpgp/trust-pgp/common.scm @@ -0,0 +1,66 @@ +#!/usr/bin/env gpgscm + +;; Copyright (C) 2017 Damien Goutte-Gattat +;; +;; This file is part of GnuPG. +;; +;; +;; GnuPG is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 3 of the License, or +;; (at your option) any later version. +;; +;; GnuPG 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, see . + +(load (in-srcdir "tests" "openpgp" "defs.scm")) + +;; Redefine GPG without --always-trust. +(define GPG `(,(tool 'gpg))) + +;; Helper constants for setownertrust. +(define MARGINALTRUST "4") +(define FULLTRUST "5") +(define ULTIMATETRUST "6") + +;; Assign OWNERTRUST to the key identified by the provided +;; fingerprint KEYFPR. +(define (setownertrust keyfpr ownertrust) + (pipe:do + (pipe:echo (string-append keyfpr ":" ownertrust ":\n")) + (pipe:gpg `(--import-ownertrust)))) + +;; Force a trustdb update. +(define (updatetrustdb) + (call-check `(, at GPG --check-trustdb --yes))) + +;; IDs of all the keys involved in those tests. +(define ALICE "FD9B20DD3C98123EEEAF8CC51BA41538D2E656B5") +(define BOBBY "4D3F59F4D8030FD2D844AFEBA5BAC3ED125CCAE5") +(define CAROL "6C62735E454CCDD79FA6CA601079113AEC1282FD") +(define DAVID "A0607635198CABA2C467FAA64CE5BB42E3984000") +(define FRANK "CE1A0E07CF8A20CBF8DC47D6DB9017DBAE6CD0EF") +(define GRACE "B935F4B8DA009AFBCCDD41386653A183007F8345") +(define HEIDI "0389C0B7990E10520B334F23756F1571EDA9184B") + +;; Initialize a given scenario. +;; NAME should be the basename of the scenario file +;; in this directory. +(define (initscenario name) + (setup-environment) + ;; Make sure we are using the PGP trust model. This may no + ;; be the default model in the future. + (let ((trust-model (gpg-config 'gpg "trust-model"))) + (trust-model::update "pgp")) + ;; Load the scenario's public keys. + (call-check `(, at GPG --import + ,(in-srcdir "tests" "openpgp" "trust-pgp" + (string-append name ".asc")))) + ;; Use Alice's key as root for all trust evaluations. + (setownertrust ALICE ULTIMATETRUST) + (updatetrustdb)) diff --git a/tests/openpgp/trust-pgp/david.sec.asc b/tests/openpgp/trust-pgp/david.sec.asc new file mode 100644 index 0000000..06c4e83 --- /dev/null +++ b/tests/openpgp/trust-pgp/david.sec.asc @@ -0,0 +1,11 @@ +-----BEGIN PGP PRIVATE KEY BLOCK----- + +lHcEWW3WzRMIKoZIzj0DAQcCAwQrTeILyHVpkkDsAyAlY7wz0PYjG48ShCYeTX2z +5f2bLxZGeepQeMiOXznPvCwRNMNpr63048+LGqu34Q9di5tvAAD9HITG0iG5SzeW +cGMfhzGuXEn2P+9arb0OttTUcj+eGBIP8bQZRGF2aWQgPGRhdmlkQGV4YW1wbGUu +b3JnPoiQBBMTCAA4FiEEoGB2NRmMq6LEZ/qmTOW7QuOYQAAFAllt1s0CGwMFCwkI +BwIGFQgJCgsCBBYCAwECHgECF4AACgkQTOW7QuOYQAAJtAD+JxiDZttAb51FjB5o +J1BksmzIrgL6ouorbLLRjVyk7rkA/0JqyLhh1K3vn4rYDbuKtvQAcfQbCndzwF9X +uGQ/7gbS +=EC4L +-----END PGP PRIVATE KEY BLOCK----- diff --git a/tests/openpgp/trust-pgp/frank.sec.asc b/tests/openpgp/trust-pgp/frank.sec.asc new file mode 100644 index 0000000..50235de --- /dev/null +++ b/tests/openpgp/trust-pgp/frank.sec.asc @@ -0,0 +1,11 @@ +-----BEGIN PGP PRIVATE KEY BLOCK----- + +lHcEWW3W3RMIKoZIzj0DAQcCAwQs0QS2PEUXhpmsPlaTFOsXd8AoYqpa6xcc0+AE +Mck1EzlqRlxeibvYeh/+yxjl18Ouww/BERB+PcoABXp00zXzAAD+Oybk8/6x5nc8 +ZNHkRIbfHW8oKh7jxbpob9X7QIfBpf8TcbQZRnJhbmsgPGZyYW5rQGV4YW1wbGUu +Y29tPoiQBBMTCAA4FiEEzhoOB8+KIMv43EfW25AX265s0O8FAllt1t0CGwMFCwkI +BwIGFQgJCgsCBBYCAwECHgECF4AACgkQ25AX265s0O+nDQD/RplCmAPQgMejhs2/ +YmOqWrekyd4IWNj9zyI2n228WXYBAJ1/Wf1vBviOEqzs7t+C0iBExxJXViPlG0nN +Z9aoiX1G +=vnHF +-----END PGP PRIVATE KEY BLOCK----- diff --git a/tests/openpgp/trust-pgp/grace.sec.asc b/tests/openpgp/trust-pgp/grace.sec.asc new file mode 100644 index 0000000..23ebd71 --- /dev/null +++ b/tests/openpgp/trust-pgp/grace.sec.asc @@ -0,0 +1,11 @@ +-----BEGIN PGP PRIVATE KEY BLOCK----- + +lHcEWW3W8RMIKoZIzj0DAQcCAwRTGb7wRrdPa+mXxUNJoYgWbKfMDQH9M1H366PQ +ga8L32TYccFzyCD8DuRYOQxzhnCtSHtdzK4QAwwGLaJV6GRjAAEAzBLT+dB5ga7S +Lh7PepOB9yObDHrHAvXGXg9AUvEm3ZkQ6bQZR3JhY2UgPGdyYWNlQGV4YW1wbGUu +bmV0PoiQBBMTCAA4FiEEuTX0uNoAmvvM3UE4ZlOhgwB/g0UFAllt1vECGwMFCwkI +BwIGFQgJCgsCBBYCAwECHgECF4AACgkQZlOhgwB/g0W2AAD+KmW2DQALWTnsVnL/ +QKdJ1J8DsaR1l+y2h7FUYuFttQsBALZYs2vUwOVBnAYyqbHogqgbPSxKRXeAxNqo +epx6csv+ +=05c1 +-----END PGP PRIVATE KEY BLOCK----- diff --git a/tests/openpgp/trust-pgp/heidi.sec.asc b/tests/openpgp/trust-pgp/heidi.sec.asc new file mode 100644 index 0000000..f650d1a --- /dev/null +++ b/tests/openpgp/trust-pgp/heidi.sec.asc @@ -0,0 +1,11 @@ +-----BEGIN PGP PRIVATE KEY BLOCK----- + +lHcEWW3XBxMIKoZIzj0DAQcCAwSINFpTZUYnxDDj3k16ljZIt58rh3cuUNIvUcqR +zR9kdlmudQTaf1zUsW6F3r+t91t88kaA2Fcci3wkU0CAob0WAAD/eTlMM3JTEF6K +yh8gxk1+mXRVUAmcGwr+1PzC3nzJAkgPALQZSGVpZGkgPGhlaWRpQGV4YW1wbGUu +b3JnPoiQBBMTCAA4FiEEA4nAt5kOEFILM08jdW8Vce2pGEsFAllt1wcCGwMFCwkI +BwIGFQgJCgsCBBYCAwECHgECF4AACgkQdW8Vce2pGEtwXAD/SVyIRiGnYPkqBVqG +fI2MlTgN8+uirur2JdkcPoylCEMA/j3OeLRRT1docnEnvST1srmlXxZTbNUclnAl +a2OZd7ME +=1goe +-----END PGP PRIVATE KEY BLOCK----- diff --git a/tests/openpgp/trust-pgp/scenario1.asc b/tests/openpgp/trust-pgp/scenario1.asc new file mode 100644 index 0000000..82fee76 --- /dev/null +++ b/tests/openpgp/trust-pgp/scenario1.asc @@ -0,0 +1,75 @@ +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW2+WxMIKoZIzj0DAQcCAwQnUnqiwvOPU7gGepFTew8Fk5kmVexr+PvaqXgv +9wKxNzZrs4GvamULk9pl2euwJGKPBRJRz8RSNpW6HIIzAPoOtBlBbGljZSA8YWxp +Y2VAZXhhbXBsZS5vcmc+iJAEExMIADgWIQT9myDdPJgSPu6vjMUbpBU40uZWtQUC +WW2+WwIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRAbpBU40uZWtTs8AQC8 +6p4hEyInw17S3P4rVpHP+en+6YJDE7x12b2aevgzsQD/XPhh0PTrAlenhFdQjQbZ +A4dNj5BcxKEIWunJICtZCo0= +=rf4w +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3WihMIKoZIzj0DAQcCAwTtUYI84wfNPCwa/r2ke7tXz0uv/En9LQZbW0QE +nzHigEvMXLfyjfjCf5tQ2eVbKLbABxtKwDtC2bv8dMcmgqd/tBlCb2JieSA8Ym9i +YnlAZXhhbXBsZS5jb20+iJAEExMIADgWIQRNP1n02AMP0thEr+ulusPtElzK5QUC +WW3WigIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRClusPtElzK5ZSOAQD1 +St647GAPOFIIYBDka3EGJeSan8i4f+u80jyplpWeggEA+z9VSDLd7JKMXqD3B/9T +O+rBR22hpi+TILZrbk7svFyIdQQQEwgAHRYhBP2bIN08mBI+7q+MxRukFTjS5la1 +BQJZbhAyAAoJEBukFTjS5la10+gA/2wr/lG67+xA1n3+2tQkIf1254lnwr8NXhwg +w4UAAbajAP9hOXzltmmHV4BaBm35GEv/A2iAABV6lzgvApmM9c445A== +=i2Va +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3WrxMIKoZIzj0DAQcCAwS4HzEJ0YwXZ1SWciHOmWdfnESTvwC3Zb/sWRu8 +zdIeZzxAwu8lYQaDq/eOgKeXQVW5gxkQG5rCWUazbG+gCBEItBlDYXJvbCA8Y2Fy +b2xAZXhhbXBsZS5uZXQ+iJAEExMIADgWIQRsYnNeRUzN15+mymAQeRE67BKC/QUC +WW3WrwIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRAQeRE67BKC/czKAP4p +26ygO/PtZluyOMFYj8cuFZ9Z9eygBH2Y3/mtn3gcOAD/VWpu9Rwz689TraDv/Sqg +apYJ1rdJREHrbrcqKtuTqFiIdQQQEwgAHRYhBE0/WfTYAw/S2ESv66W6w+0SXMrl +BQJZbhBhAAoJEKW6w+0SXMrlPYgA/21rYq9iItnLASDCdt4ZX6gPKEZVBFDk6850 +Gyvg3TrEAP9/9bjKEFCSbo6vFKONOEpKqA/9B85Ff+2jq1lvfafV4Q== +=mwVS +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3WzRMIKoZIzj0DAQcCAwQrTeILyHVpkkDsAyAlY7wz0PYjG48ShCYeTX2z +5f2bLxZGeepQeMiOXznPvCwRNMNpr63048+LGqu34Q9di5tvtBlEYXZpZCA8ZGF2 +aWRAZXhhbXBsZS5vcmc+iJAEExMIADgWIQSgYHY1GYyrosRn+qZM5btC45hAAAUC +WW3WzQIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRBM5btC45hAAAm0AP4n +GINm20BvnUWMHmgnUGSybMiuAvqi6itsstGNXKTuuQD/QmrIuGHUre+fitgNu4q2 +9ABx9BsKd3PAX1e4ZD/uBtKIdQQQEwgAHRYhBE0/WfTYAw/S2ESv66W6w+0SXMrl +BQJZbhB0AAoJEKW6w+0SXMrlARwA/RiqKRh4rYtW5gP20PoQNYfS1qh+lDRTlhfp +SSF5aKKFAP90s5/fp6n382IjbOhmQiEB9N4gv4pZT3YP13NQwAABbg== +=bLxR +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3W3RM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VjUerWTrp6XoG1888PYh1BBATCAAd +FiEEoGB2NRmMq6LEZ/qmTOW7QuOYQAAFAlluEM4ACgkQTOW7QuOYQAB3HgD+Kw+R +WbH8RcSlNbwlGWCWYwKvik7ukIMcTXXYD5azTYoBANF5Ym2n5RExmEd8nTrWu9MR +TUlOgAXfzm/iH4+TNj2yiHUEEBMIAB0WIQTOGg4Hz4ogy/jcR9bbkBfbrmzQ7wUC +WW4Q7AAKCRDbkBfbrmzQ7weXAP9OyFxzdpbq1R+V6T5WEckR5OtE6Va/7CHRPRW+ +kMNVjwD/YQZVbOCRxKybVbvPuF+29w7sWp4iAmmrmCFnKfgxZsQ= +=r9Ly +-----END PGP PUBLIC KEY BLOCK----- diff --git a/tests/openpgp/trust-pgp/scenario2.asc b/tests/openpgp/trust-pgp/scenario2.asc new file mode 100644 index 0000000..3a98621 --- /dev/null +++ b/tests/openpgp/trust-pgp/scenario2.asc @@ -0,0 +1,70 @@ +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW2+WxMIKoZIzj0DAQcCAwQnUnqiwvOPU7gGepFTew8Fk5kmVexr+PvaqXgv +9wKxNzZrs4GvamULk9pl2euwJGKPBRJRz8RSNpW6HIIzAPoOtBlBbGljZSA8YWxp +Y2VAZXhhbXBsZS5vcmc+iJAEExMIADgWIQT9myDdPJgSPu6vjMUbpBU40uZWtQUC +WW2+WwIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRAbpBU40uZWtTs8AQC8 +6p4hEyInw17S3P4rVpHP+en+6YJDE7x12b2aevgzsQD/XPhh0PTrAlenhFdQjQbZ +A4dNj5BcxKEIWunJICtZCo0= +=rf4w +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3WihMIKoZIzj0DAQcCAwTtUYI84wfNPCwa/r2ke7tXz0uv/En9LQZbW0QE +nzHigEvMXLfyjfjCf5tQ2eVbKLbABxtKwDtC2bv8dMcmgqd/tBlCb2JieSA8Ym9i +YnlAZXhhbXBsZS5jb20+iJAEExMIADgWIQRNP1n02AMP0thEr+ulusPtElzK5QUC +WW3WigIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRClusPtElzK5ZSOAQD1 +St647GAPOFIIYBDka3EGJeSan8i4f+u80jyplpWeggEA+z9VSDLd7JKMXqD3B/9T +O+rBR22hpi+TILZrbk7svFyIeQQQEwgAIRYhBP2bIN08mBI+7q+MxRukFTjS5la1 +BQJZbjsoAwUBeAAKCRAbpBU40uZWtVGlAQCgHkwmJSATJbrqV7+h/1ByLDi4+thQ +ApW8nRinGuwkxQD+NgjOVmkPGZtpvaBzLXJS/IdPAYBWAriAzDZEV2GchWM= +=4Xcm +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3WrxMIKoZIzj0DAQcCAwS4HzEJ0YwXZ1SWciHOmWdfnESTvwC3Zb/sWRu8 +zdIeZzxAwu8lYQaDq/eOgKeXQVW5gxkQG5rCWUazbG+gCBEItBlDYXJvbCA8Y2Fy +b2xAZXhhbXBsZS5uZXQ+iJAEExMIADgWIQRsYnNeRUzN15+mymAQeRE67BKC/QUC +WW3WrwIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRAQeRE67BKC/czKAP4p +26ygO/PtZluyOMFYj8cuFZ9Z9eygBH2Y3/mtn3gcOAD/VWpu9Rwz689TraDv/Sqg +apYJ1rdJREHrbrcqKtuTqFiIdQQQEwgAHRYhBE0/WfTYAw/S2ESv66W6w+0SXMrl +BQJZbjteAAoJEKW6w+0SXMrlkJQBAO19erLoHXOqUI01Wl0tcaKIwEB5HkIHLh0w +cCTOG4bDAQCCG8a8D1mg9jVPukBzTBUZGpDZmg/U3JGW3XE6rKlKXQ== +=Df0N +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3WzRMIKoZIzj0DAQcCAwQrTeILyHVpkkDsAy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KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3W8RMIKoZIzj0DAQcCAwRTGb7wRrdPa+mXxUNJoYgWbKfMDQH9M1H366PQ +ga8L32TYccFzyCD8DuRYOQxzhnCtSHtdzK4QAwwGLaJV6GRjtBlHcmFjZSA8Z3Jh +Y2VAZXhhbXBsZS5uZXQ+iJAEExMIADgWIQS5NfS42gCa+8zdQThmU6GDAH+DRQUC +WW3W8QIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRBmU6GDAH+DRbYAAP4q +ZbYNAAtZOexWcv9Ap0nUnwOxpHWX7LaHsVRi4W21CwEAtliza9TA5UGcBjKpseiC +qBs9LEpFd4DE2qh6nHpyy/6IdQQQEwgAHRYhBM4aDgfPiiDL+NxH1tuQF9uubNDv +BQJZbkVQAAoJENuQF9uubNDvyrkBAICiFq2dTFzLrXNsItwpPrB20trzEPM/JAxa +lzSyknJMAQDBCj8nyEtlpkYh9t9ovy/x75D1OUBFFYHOQXCMy0QyRA== +=yoqI +-----END PGP PUBLIC KEY BLOCK----- diff --git a/tests/openpgp/trust-pgp/scenario3.asc b/tests/openpgp/trust-pgp/scenario3.asc new file mode 100644 index 0000000..240afd5 --- /dev/null +++ b/tests/openpgp/trust-pgp/scenario3.asc @@ -0,0 +1,58 @@ +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW2+WxMIKoZIzj0DAQcCAwQnUnqiwvOPU7gGepFTew8Fk5kmVexr+PvaqXgv +9wKxNzZrs4GvamULk9pl2euwJGKPBRJRz8RSNpW6HIIzAPoOtBlBbGljZSA8YWxp +Y2VAZXhhbXBsZS5vcmc+iJAEExMIADgWIQT9myDdPJgSPu6vjMUbpBU40uZWtQUC +WW2+WwIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRAbpBU40uZWtTs8AQC8 +6p4hEyInw17S3P4rVpHP+en+6YJDE7x12b2aevgzsQD/XPhh0PTrAlenhFdQjQbZ +A4dNj5BcxKEIWunJICtZCo0= +=rf4w +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3WihMIKoZIzj0DAQcCAwTtUYI84wfNPCwa/r2ke7tXz0uv/En9LQZbW0QE +nzHigEvMXLfyjfjCf5tQ2eVbKLbABxtKwDtC2bv8dMcmgqd/tBlCb2JieSA8Ym9i +YnlAZXhhbXBsZS5jb20+iJAEExMIADgWIQRNP1n02AMP0thEr+ulusPtElzK5QUC +WW3WigIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRClusPtElzK5ZSOAQD1 +St647GAPOFIIYBDka3EGJeSan8i4f+u80jyplpWeggEA+z9VSDLd7JKMXqD3B/9T +O+rBR22hpi+TILZrbk7svFyIeQQQEwgAIRYhBP2bIN08mBI+7q+MxRukFTjS5la1 +BQJZbmYmAwUCeAAKCRAbpBU40uZWtSQhAQD2HLi7PUipgcO9N+KEJLKl2T9ralzj +O1PMy8IbxnG86AD/Ya541TcH9oxZUWm5dsHd/eoBnSu2WwWkLPNHirRkzwE= +=R1uZ +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3WrxMIKoZIzj0DAQcCAwS4HzEJ0YwXZ1SWciHOmWdfnESTvwC3Zb/sWRu8 +zdIeZzxAwu8lYQaDq/eOgKeXQVW5gxkQG5rCWUazbG+gCBEItBlDYXJvbCA8Y2Fy +b2xAZXhhbXBsZS5uZXQ+iJAEExMIADgWIQRsYnNeRUzN15+mymAQeRE67BKC/QUC +WW3WrwIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRAQeRE67BKC/czKAP4p +26ygO/PtZluyOMFYj8cuFZ9Z9eygBH2Y3/mtn3gcOAD/VWpu9Rwz689TraDv/Sqg +apYJ1rdJREHrbrcqKtuTqFiIeQQQEwgAIRYhBE0/WfTYAw/S2ESv66W6w+0SXMrl +BQJZbmZIAwUCeAAKCRClusPtEl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EldWI+UbSc1n1qiJfUaIeQQQEwgAIRYhBKBgdjUZjKuixGf6pkzlu0LjmEAA +BQJZbmaiAwUCeAAKCRBM5btC45hAAMcRAP9dcKO3ETB52AsFdBp2iJVjqJ5JiftN +B/2FZBxPtSjXpAD/YdDzs+zNaAUlFIFmXzP9EmIqmXhC6XSiASrNd5EW33A= +=DXNa +-----END PGP PUBLIC KEY BLOCK----- diff --git a/tests/openpgp/trust-pgp/scenario4.asc b/tests/openpgp/trust-pgp/scenario4.asc new file mode 100644 index 0000000..7860c95 --- /dev/null +++ b/tests/openpgp/trust-pgp/scenario4.asc @@ -0,0 +1,84 @@ +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW2+WxMIKoZIzj0DAQcCAwQnUnqiwvOPU7gGepFTew8Fk5kmVexr+PvaqXgv +9wKxNzZrs4GvamULk9pl2euwJGKPBRJRz8RSNpW6HIIzAPoOtBlBbGljZSA8YWxp +Y2VAZXhhbXBsZS5vcmc+iJAEExMIADgWIQT9myDdPJgSPu6vjMUbpBU40uZWtQUC +WW2+WwIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRAbpBU40uZWtTs8AQC8 +6p4hEyInw17S3P4rVpHP+en+6YJDE7x12b2aevgzsQD/XPhh0PTrAlenhFdQjQbZ +A4dNj5BcxKEIWunJICtZCo0= +=rf4w +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3WihMIKoZIzj0DAQcCAwTtUYI84wfNPCwa/r2ke7tXz0uv/En9LQZbW0QE +nzHigEvMXLfyjfjCf5tQ2eVbKLbABxtKwDtC2bv8dMcmgqd/tBlCb2JieSA8Ym9i +YnlAZXhhbXBsZS5jb20+iJAEExMIADgWIQRNP1n02AMP0thEr+ulusPtElzK5QUC +WW3WigIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRClusPtElzK5ZSOAQD1 +St647GAPOFIIYBDka3EGJeSan8i4f+u80jyplpWeggEA+z9VSDLd7JKMXqD3B/9T +O+rBR22hpi+TILZrbk7svFyIlAQQEwgAPBYhBP2bIN08mBI+7q+MxRukFTjS5la1 +BQJZbm5IAwUCeBqGPFtePl0rW0AuXWV4YW1wbGVcLmNvbT4kAAAKCRAbpBU40uZW +tb+2APsFKgWxiLtSbpcekarOlPrw014LVinLGah3VE1Izay+tAEA+0INHdcNoz64 +kRE/2siUnx1ksrWcWvJbvNMteknXhzY= +=UQni +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3WrxMIKoZIzj0DAQcCAwS4HzEJ0YwXZ1SWciHOmWdfnESTvwC3Zb/sWRu8 +zdIeZzxAwu8lYQaDq/eOgKeXQVW5gxkQG5rCWUazbG+gCBEItBlDYXJvbCA8Y2Fy +b2xAZXhhbXBsZS5uZXQ+iJAEExMIADgWIQRsYnNeRUzN15+mymAQeRE67BKC/QUC +WW3WrwIbAwULCQgHAgYVCAkKCwIEFgIDAQIeAQIXgAAKCRAQeRE67BKC/czKAP4p +26ygO/PtZluyOMFYj8cuFZ9Z9eygBH2Y3/mtn3gcOAD/VWpu9Rwz689TraDv/Sqg +apYJ1rdJREHrbrcqKtuTqFiIdQQQEwgAHRYhBE0/WfTYAw/S2ESv66W6w+0SXMrl +BQJZbm6PAAoJEKW6w+0SXMrlWj8A/2UdgyhbV+tLjyFb87iBiaWxSIVfiVyjhLZN +htPTrKb2AP4yIRxJ3x0LmRSDLkZ/QIQmgahlAXRmKCXSRAB8x2KRsQ== +=Zbpr +-----END PGP PUBLIC KEY BLOCK----- +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mFIEWW3WzRMIKoZIzj0DAQcCAwQrTeILyHVpkkDsAyAlY7wz0PYjG48ShCYeTX2z +5f2bLxZGeepQeMiOXznPvCwRNMNpr63048+LGqu34Q9di5tvtBlEYXZpZCA8ZGF2 +aWRAZXhhbXBsZS5vcmc+iJAEExMIADgWIQSgYHY1GYyrosRn+q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-- 2.9.0 From lukele at gpgtools.org Thu Jul 20 11:57:12 2017 From: lukele at gpgtools.org (Lukas Pitschl | GPGTools) Date: Thu, 20 Jul 2017 11:57:12 +0200 Subject: Migration gnupg 2.0.x to gnupg 2.1.x Message-ID: <93CC6C69-745C-4060-980D-F2328B70B18C@gpgtools.org> Hi, we?re currently in the process of preparing the migration from gnupg 2.0.x to gnupg 2.1.x as default in GPG Suite for the near future. During the process of testing the migration, the following questions came up. It would be great if you could share your experience and knowledge with us in that regard: - Is there a document listing all the options which are no longer available? -> we?ll have to comment these out upon installation - Is there a document listing all the options which replace older options (but work the same)? -> we would like to automatically migrate these - Smart card stubs are not available after migration. Is this by design? Why? Is there any better method to have them in the migrated keyring as well, without running `gpg ?card-status`? - Are there any keys which are no longer supported and the user will lose access to after migration? - How do you handle the migration in gpg4win? Thank you very much in advance for your input and help. Best, Lukas GPGTools From dkg at fifthhorseman.net Fri Jul 21 20:51:27 2017 From: dkg at fifthhorseman.net (Daniel Kahn Gillmor) Date: Fri, 21 Jul 2017 14:51:27 -0400 Subject: [PATCH 5/5] gpg: Fix regexp sanitization. In-Reply-To: <871spcv8u8.wl-neal@walfield.org> References: <20170719093304.30138-1-dgouttegattat@incenp.org> <20170719093304.30138-6-dgouttegattat@incenp.org> <87379sacy2.fsf@europa.jade-hamburg.de> <871spcv8u8.wl-neal@walfield.org> Message-ID: <87d18ttyhc.fsf@fifthhorseman.net> On Wed 2017-07-19 15:45:35 +0200, Neal H. Walfield wrote: > I think it is worth exploring what the implications of any change in > behavior are. A good start would be finding all trust sigs with a > non-empty regex in a key server dump so that we can see how people are > actually using them in practice. (I suspect there aren't that many.) trust sigs are likely to be non-exportable, or simply made on systems that don't publish their tsigs anywhere anyway. There are very few good arguments for publicly exposing tsig information, as that is significantly more sensitive than normal WoT identity assertions. That suggests that just looking at tsigs on the keyserver network will be an undercount, and potentially a significant undercount at that :/ unfortunately, i don't have any specific recommendation to improve scanning or detection :( --dkg -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 832 bytes Desc: not available URL: From aheinecke at intevation.de Mon Jul 24 09:34:07 2017 From: aheinecke at intevation.de (Andre Heinecke) Date: Mon, 24 Jul 2017 09:34:07 +0200 Subject: Migration gnupg 2.0.x to gnupg 2.1.x In-Reply-To: <93CC6C69-745C-4060-980D-F2328B70B18C@gpgtools.org> References: <93CC6C69-745C-4060-980D-F2328B70B18C@gpgtools.org> Message-ID: <4159276.zMA6aNdKXi@esus> Hi, On Thursday, July 20, 2017 11:57:12 AM CEST Lukas Pitschl | GPGTools wrote: > we?re currently in the process of preparing the migration from gnupg 2.0.x to gnupg 2.1.x as default in GPG Suite for the near future. > During the process of testing the migration, the following questions came up. It would be great if you could share your experience and knowledge with us in that regard: > > - Is there a document listing all the options which are no longer available? > -> we?ll have to comment these out upon installation I don't think there are any, do you have an example? The main "feature loss" was the removed support for PGP 2 keys. And some changes regarding pinentry / gpg-agent. You always need gpg-agent (which is now autostarted) and to make the passphrase options work you need to set pinentry-mode loopback. > - Is there a document listing all the options which replace older options (but work the same)? Not directly but: https://git.gnupg.org/cgi-bin/gitweb.cgi?p=gnupg.git;a=blob;f=doc/whats-new-in-2.1.txt Is a good read. > -> we would like to automatically migrate these Probably the pinentry-mode loopback may be an issue for you. > - Smart card stubs are not available after migration. Is this by design? Why? Is there any better method to have them in the migrated keyring as well, without running `gpg ?card-status`? No idea from me. > - Are there any keys which are no longer supported and the user will lose access to after migration? Yes old PGP-2 Keys will no longer work. > - How do you handle the migration in gpg4win? As we use GPGME we don't have much worry. We don't warn about PGP-2 Keys because they are not really an issue for us as far as we see it. We mention it in the news. For us the main user facing change is that gpg2 is now called gpg. I still have it on my TODO to write a small "Migration guide for administrators" that use Batch scripts utilising gpg4win. But there won't be much. Mainly the name change, pinentry mode loopback, and a word about the fact that globbing on the command line no longer works. But for most of our users that only use the GUI we don't expect much trouble. And so far have not got any "showstopper" issues with our current Betas. Regards, Andre -- Andre Heinecke | ++49-541-335083-262 | http://www.intevation.de/ Intevation GmbH, Neuer Graben 17, 49074 Osnabr?ck | AG Osnabr?ck, HR B 18998 Gesch?ftsf?hrer: Frank Koormann, Bernhard Reiter, Dr. Jan-Oliver Wagner -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 228 bytes Desc: This is a digitally signed message part. URL: From wk at gnupg.org Mon Jul 24 12:33:47 2017 From: wk at gnupg.org (Werner Koch) Date: Mon, 24 Jul 2017 12:33:47 +0200 Subject: Migration gnupg 2.0.x to gnupg 2.1.x In-Reply-To: <4159276.zMA6aNdKXi@esus> (Andre Heinecke's message of "Mon, 24 Jul 2017 09:34:07 +0200") References: <93CC6C69-745C-4060-980D-F2328B70B18C@gpgtools.org> <4159276.zMA6aNdKXi@esus> Message-ID: <87r2x66s50.fsf@wheatstone.g10code.de> On Mon, 24 Jul 2017 09:34, aheinecke at intevation.de said: > https://git.gnupg.org/cgi-bin/gitweb.cgi?p=gnupg.git;a=blob;f=doc/whats-new-in-2.1.txt And rendered as HTML: https://gnupg.org/faq/whats-new-in-2.1.html ;-) Salam-Shalom, Werner -- Die Gedanken sind frei. Ausnahmen regelt ein Bundesgesetz. -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 227 bytes Desc: not available URL: From lukele at gpgtools.org Mon Jul 24 19:45:05 2017 From: lukele at gpgtools.org (Lukas Pitschl | GPGTools) Date: Mon, 24 Jul 2017 19:45:05 +0200 Subject: Migration gnupg 2.0.x to gnupg 2.1.x In-Reply-To: <4159276.zMA6aNdKXi@esus> References: <93CC6C69-745C-4060-980D-F2328B70B18C@gpgtools.org> <4159276.zMA6aNdKXi@esus> Message-ID: <1C15BD75-4012-465E-B64B-BB469C7E4907@gpgtools.org> Hi, > Not directly but: > https://git.gnupg.org/cgi-bin/gitweb.cgi?p=gnupg.git;a=blob;f=doc/whats-new-in-2.1.txt > > Is a good read. > Thanks, I?ve read through this guide before writing to the mailing list, since some information was not included. We?ve seen some users which couldn?t use gpg after a migration test, because it complained about unknown options, which is the reason, why I wanted to ask if the removed options are documented somewhere. > >> - Smart card stubs are not available after migration. Is this by design? > Why? Is there any better method to have them in the migrated keyring as well, > without running `gpg ?card-status`? @Werner: It would be great if you could add some details here. >> - Are there any keys which are no longer supported and the user will lose > access to after migration? > > Yes old PGP-2 Keys will no longer work. Thanks, that shouldn?t affect too many of our users. >> - How do you handle the migration in gpg4win? > > As we use GPGME we don't have much worry. We don't warn about PGP-2 Keys > because they are not really an issue for us as far as we see it. We mention it > in the news. > > For us the main user facing change is that gpg2 is now called gpg. I still > have it on my TODO to write a small "Migration guide for administrators" that > use Batch scripts utilising gpg4win. But there won't be much. Mainly the name > change, pinentry mode loopback, and a word about the fact that globbing on the > command line no longer works. > > But for most of our users that only use the GUI we don't expect much trouble. > And so far have not got any "showstopper" issues with our current Betas. > Thanks for this information. It?s great to hear, you didn?t have any big issues with the migration. We?re really looking forward to finally roll this out. Best, Lukas GPGTools From prestonkmoore at gmail.com Wed Jul 26 22:04:41 2017 From: prestonkmoore at gmail.com (Preston Moore) Date: Wed, 26 Jul 2017 16:04:41 -0400 Subject: =?utf-8?Q?Two_Application_Hangs_in_=E2=80=98gnupg=E2=80=99_Result?= =?utf-8?Q?ing_from_Failure_to_Check_File_Type?= References: <9D4F9F97-2CB4-455C-8A71-F6E52EC57CA3@gmail.com> Message-ID: *** I?m re-sending this as I never saw it appear on the list and it doesn?t appear in the archive. I guess my registration wasn?t active at the time. Apologies if this is a duplicate. *** Hey everyone, There are two situations where gnupg can be made to hang during execution. In the first case, a denial of service situation can occur when pubring.gpg or secring.gpg are replaced with a FIFO as the application ends up blocking forever waiting for data. In the second case, because the type of file containing a key to be imported with is not checked, gnupg can be made to spin forever attempting to process what amounts to an infinitely large file. Both of these situations can be particularly damaging when if gnupg is being run as part of an unattended process, such as a cron job, where the hang may go unnoticed. An unnoticed hang caused by the second situation can affect system performance as gnupg spins consuming as much processing capacity as it can. These problems were found as part of an effort to detect and deal with ?environmental? bugs in popular applications (for more information, check out https://works-everywhere.org). They were found using a tool that detects situations where an application fails to correctly handle unusual environmental conditions such as files having an unexpected file type. The following patch confirms that the file containing a key resource is regular file before processing its contents: --- g10/keydb.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/g10/keydb.c b/g10/keydb.c index 0f28bc3..1b5e095 100644 --- a/g10/keydb.c +++ b/g10/keydb.c @@ -650,6 +650,7 @@ keydb_add_resource (const char *url, unsigned int flags) gpg_error_t err = 0; KeydbResourceType rt = KEYDB_RESOURCE_TYPE_NONE; void *token; + struct stat sb; /* Create the resource if it is the first registered one. */ create = (!read_only && !any_registered); @@ -692,6 +693,13 @@ keydb_add_resource (const char *url, unsigned int flags) else filename = xstrdup (resname); + if(stat(filename, &sb) == -1 || !S_ISREG(sb.st_mode)) + { + log_error ("key resource is not a regular file"); + err = gpg_error (GPG_ERR_INV_KEYRING); + goto leave; + } + /* See whether we can determine the filetype. */ if (rt == KEYDB_RESOURCE_TYPE_NONE) { -- 2.7.4 The below patch to checks the file type of the file containing a key being imported and rejects it if the file is not a regular file: --- g10/import.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/g10/import.c b/g10/import.c index d9d658b..1c9a861 100644 --- a/g10/import.c +++ b/g10/import.c @@ -23,6 +23,7 @@ #include #include #include +#include #include "gpg.h" #include "options.h" @@ -431,6 +432,7 @@ import_keys_internal (ctrl_t ctrl, iobuf_t inp, char **fnames, int nnames, int i; int rc = 0; struct import_stats_s *stats = stats_handle; + struct stat sb; if (!stats) stats = import_new_stats_handle (); @@ -448,6 +450,12 @@ import_keys_internal (ctrl_t ctrl, iobuf_t inp, char **fnames, int nnames, for (i=0; i < nnames; i++) { const char *fname = fnames? fnames[i] : NULL; + if(!(stat(fname, &sb) == 0) || !S_ISREG(sb.st_mode)) + { + gpg_err_set_errno(EINVAL); + log_error ("%s is an invalid file type\n", fname); + break; + } IOBUF inp2 = iobuf_open(fname); if (!fname) -- 2.7.4 Thanks, Preston Moore From dkg at fifthhorseman.net Thu Jul 27 23:43:46 2017 From: dkg at fifthhorseman.net (Daniel Kahn Gillmor) Date: Thu, 27 Jul 2017 17:43:46 -0400 Subject: [pkg-gnupg-maint] Bug#869609: libgpg-error is unecessarily hard to bootstrap for new architectures/ABIs In-Reply-To: References: <20170724182129.15828.66418.reportbug@cheddar.halon.org.uk> Message-ID: <87y3r9blnx.fsf@fifthhorseman.net> Hi all-- over on https://bugs.debian.org/869609, Wookey and Steven Capper kicked off this discussion about making libgpg-error less painful to bootstrap for a new architecture (Steven's contribution is included below). I note that there is additional discussion about cross-compilation of things *based* on gpg-error over at https://bugs.debian.org/643341 -- i think that's a different issue, though it seems related: we haven't made ease of cross-compilation or bootstrapping a specific goal of the library, afaict. On Mon 2017-07-24 22:07:49 +0100, Steven Capper wrote: > So going through this my understanding is that for Linux this library > creates weak references to the pthread_mutex_ functions as well as > simulates the size of the pthread_mutex_t type. IIUC this obviates the > need to cross-compile against pthreads. When one loads the library, > the weak references will be overridden by the C library and, providing > the data type is the same as simulated, should operate as one is using > pthreads. > > If the simulated data type does not match the system implementation, I > am not sure what behaviour will manifest. > > I don't understand why one cannot cross-compile a library that makes > use of pthreads directly though? Was this weak function/type > simulation workaround needed for a bug in the past that has since been > fixed? > > Have we missed something obvious? I don't know the history of this part of libgpg-error, though i know that cross-platform portability (as well as support on historic architectures) has generally been a goal of the GnuPG project. It might be an irony of this focus that it's actually *harder* to do more common modern cross-compilation/bootstrapping as a result. But maybe Werner or some other GnuPG upstream folks with more knowledge can weigh in on the backstory here? fwiw, i generally agree that it'd be great to be able to make gpg-error more closely conform to modern cross-compilation and bootstrapping processes, since it tends to be in the core of a tight group of dependencies on many systems. Regards, --dkg -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 832 bytes Desc: not available URL: From wk at gnupg.org Fri Jul 28 21:03:02 2017 From: wk at gnupg.org (Werner Koch) Date: Fri, 28 Jul 2017 21:03:02 +0200 Subject: [Announce] GnuPG 2.1.22 released Message-ID: <87a83o4c61.fsf@wheatstone.g10code.de> Hello! The GnuPG team is pleased to announce the availability of a new release of GnuPG: version 2.1.22. See below for a list of new features and bug fixes. About GnuPG ============= The GNU Privacy Guard (GnuPG) is a complete and free implementation of the OpenPGP standard which is commonly abbreviated as PGP. GnuPG allows to encrypt and sign data and communication, features a versatile key management system as well as access modules for public key directories. GnuPG itself is a command line tool with features for easy integration with other applications. A wealth of frontend applications and libraries making use of GnuPG are available. As an Universal Crypto Engine GnuPG provides support for S/MIME and Secure Shell in addition to OpenPGP. GnuPG is Free Software (meaning that it respects your freedom). It can be freely used, modified and distributed under the terms of the GNU General Public License. Noteworthy changes in version 2.1.22 ==================================== * gpg: Extend command --quick-set-expire to allow for setting the expiration time of subkeys. * gpg: By default try to repair keys during import. New sub-option no-repair-keys for --import-options. * gpg,gpgsm: Improved checking and reporting of DE-VS compliance. * gpg: New options --key-origin and --with-key-origin. Store the time of the last key update from keyservers, WKD, or DANE. * agent: New option --ssh-fingerprint-digest. * dimngr: Lower timeouts on keyserver connection attempts and made it configurable. * dirmngr: Tor will now automatically be detected and used. The option --no-use-tor disables Tor detection. * dirmngr: Now detects a changed /etc/resolv.conf. * agent,dirmngr: Initiate shutdown on removal of the GnuPG home directory. * gpg: Avoid caching passphrase for failed symmetric encryption. * agent: Support for unprotected ssh keys. * dirmngr: Fixed name resolving on systems using only v6 nameservers. * dirmngr: Allow the use of TLS over http proxies. * w32: Change directory of the daemons after startup. * wks: New man pages for client and server. A detailed description of the changes found in this 2.1 branch can be found at . Getting the Software ==================== Please follow the instructions found at or read on: GnuPG 2.1.22 may be downloaded from one of the GnuPG mirror sites or direct from its primary FTP server. The list of mirrors can be found at . Note that GnuPG is not available at ftp.gnu.org. The GnuPG source code compressed using BZIP2 and its OpenPGP signature are available here: https://gnupg.org/ftp/gcrypt/gnupg/gnupg-2.1.22.tar.bz2 (6377k) https://gnupg.org/ftp/gcrypt/gnupg/gnupg-2.1.22.tar.bz2.sig or via FTP: ftp://ftp.gnupg.org/gcrypt/gnupg/gnupg-2.1.22.tar.bz2 ftp://ftp.gnupg.org/gcrypt/gnupg/gnupg-2.1.22.tar.bz2.sig An installer for Windows without any graphical frontend except for a very minimal Pinentry tool is available here: https://gnupg.org/ftp/gcrypt/binary/gnupg-w32-2.1.22_20170728.exe (3792k) https://gnupg.org/ftp/gcrypt/binary/gnupg-w32-2.1.22_20170728.exe.sig or via FTP: ftp://ftp.gnupg.org/gcrypt/binary/gnupg-w32-2.1.22_20170728.exe ftp://ftp.gnupg.org/gcrypt/binary/gnupg-w32-2.1.22_20170728.exe.sig The source used to build the Windows installer can be found in the same directory with a ".tar.xz" suffix. The Windows installer comes with TOFU support, many translations, support for Tor, and support for HKPS and the Web Key Directory. Checking the Integrity ====================== In order to check that the version of GnuPG which you are going to install is an original and unmodified one, you can do it in one of the following ways: * If you already have a version of GnuPG installed, you can simply verify the supplied signature. For example to verify the signature of the file gnupg-2.1.22.tar.bz2 you would use this command: gpg --verify gnupg-2.1.22.tar.bz2.sig gnupg-2.1.23.tar.bz2 This checks whether the signature file matches the source file. You should see a message indicating that the signature is good and made by one or more of the release signing keys. Make sure that this is a valid key, either by matching the shown fingerprint against a trustworthy list of valid release signing keys or by checking that the key has been signed by trustworthy other keys. See the end of this mail for information on the signing keys. * If you are not able to use an existing version of GnuPG, you have to verify the SHA-1 checksum. On Unix systems the command to do this is either "sha1sum" or "shasum". Assuming you downloaded the file gnupg-2.1.22.tar.bz2, you run the command like this: sha1sum gnupg-2.1.22.tar.bz2 and check that the output matches the next line: 706b806f7d8d328b4ffa67954c613fdd3dfed1b9 gnupg-2.1.22.tar.bz2 9e517a550da5619445be6820a614faf3e1bb5a46 gnupg-w32-2.1.22_20170728.exe c14b7ad4c03707438e7329de3f2dbf99e2f85dc7 gnupg-w32-2.1.22_20170728.tar.xz Internationalization ==================== This version of GnuPG has support for 26 languages with Chinese, Czech, French, German, Japanese, Norwegian, Russian, and Ukrainian being almost completely translated. We are now in string freeze for 2.2 and updated translations are very welcome. Documentation ============= If you used GnuPG in the past you should read the description of changes and new features at doc/whats-new-in-2.1.txt or online at https://gnupg.org/faq/whats-new-in-2.1.html The file gnupg.info has the complete user manual of the system. Separate man pages are included as well but they have not all the details available as are the manual. It is also possible to read the complete manual online in HTML format at https://gnupg.org/documentation/manuals/gnupg/ or in Portable Document Format at https://gnupg.org/documentation/manuals/gnupg.pdf . The chapters on gpg-agent, gpg and gpgsm include information on how to set up the whole thing. You may also want search the GnuPG mailing list archives or ask on the gnupg-users mailing lists for advise on how to solve problems. Many of the new features are around for several years and thus enough public knowledge is already available. You may also want to follow our postings at and . Support ======== Please consult the archive of the gnupg-users mailing list before reporting a bug . We suggest to send bug reports for a new release to this list in favor of filing a bug at . If you need commercial support check out . If you are a developer and you need a certain feature for your project, please do not hesitate to bring it to the gnupg-devel mailing list for discussion. Maintenance and development of GnuPG is mostly financed by donations. The GnuPG project employs 4 full-time developers, one part-timer, and one contractor. They all work exclusivly on GnuPG and closely related software like Libgcrypt, GPGME, and GPA. Please consider to donate via: https://gnupg.org/donate/ Thanks ====== We have to thank all the people who helped with this release, be it testing, coding, translating, suggesting, auditing, administering the servers, spreading the word, answering questions on the mailing lists, and donating money. Happy hacking, Your GnuPG Team p.s. This is an announcement only mailing list. Please send replies only to the gnupg-users'at'gnupg.org mailing list. p.p.s List of Release Signing Keys: To guarantee that a downloaded GnuPG version has not been tampered by malicious entities we provide signature files for all tarballs and binary versions. The keys are also signed by the long term keys of their respective owners. Current releases are signed by one or more of these five keys: 2048R/4F25E3B6 2011-01-12 [expires: 2019-12-31] Key fingerprint = D869 2123 C406 5DEA 5E0F 3AB5 249B 39D2 4F25 E3B6 Werner Koch (dist sig) rsa2048/E0856959 2014-10-29 [expires: 2019-12-31] Key fingerprint = 46CC 7308 65BB 5C78 EBAB ADCF 0437 6F3E E085 6959 David Shaw (GnuPG Release Signing Key) rsa2048/33BD3F06 2014-10-29 [expires: 2016-10-28] Key fingerprint = 031E C253 6E58 0D8E A286 A9F2 2071 B08A 33BD 3F06 NIIBE Yutaka (GnuPG Release Key) rsa2048/7EFD60D9 2014-10-19 [expires: 2020-12-31] Key fingerprint = D238 EA65 D64C 67ED 4C30 73F2 8A86 1B1C 7EFD 60D9 Werner Koch (Release Signing Key) rsa3072/4B092E28 2017-03-17 [expires: 2027-03-15] Key fingerprint = 5B80 C575 4298 F0CB 55D8 ED6A BCEF 7E29 4B09 2E28 Andre Heinecke (Release Signing Key) You may retrieve these keys from a keyserver using this command gpg --keyserver hkp://keys.gnupg.net --recv-keys \ 249B39D24F25E3B6 04376F3EE0856959 \ 2071B08A33BD3F06 8A861B1C7EFD60D9 BCEF7E294B092E28 The keys are also available at https://gnupg.org/signature_key.html and in any recently released GnuPG tarball in the file g10/distsigkey.gpg . Note that this mail has been signed by a different key. -- Die Gedanken sind frei. Ausnahmen regelt ein Bundesgesetz. -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 194 bytes Desc: not available URL: -------------- next part -------------- _______________________________________________ Gnupg-announce mailing list Gnupg-announce at gnupg.org http://lists.gnupg.org/mailman/listinfo/gnupg-announce From bernhard at intevation.de Mon Jul 31 15:52:48 2017 From: bernhard at intevation.de (Bernhard Reiter) Date: Mon, 31 Jul 2017 15:52:48 +0200 Subject: libreoffice uses gpgme to sign Message-ID: <201707311552.53403.bernhard@intevation.de> LibreOffice https://wiki.documentfoundation.org/ReleaseNotes/5.4 announces the ability to sign documents under GNU/Linux. The notes link the following commit https://cgit.freedesktop.org/libreoffice/core/commit/?id=3e3b37ca4cbc881628a71715b67ac172018cf9f2 which show some gpgme use. Background: That is probably is a result of the public tender https://www.evergabe-online.de/tenderdetails.html?id=133672 (a contract awarded by the procurement department of the German Ministry of the Interior, which is the Ministry that oversees the BSI.) :) Best Regards, Bernhard -- www.intevation.de/~bernhard ? +49 541 33 508 3-3 Intevation GmbH, Osnabr?ck, DE; Amtsgericht Osnabr?ck, HRB 18998 Gesch?ftsf?hrer Frank Koormann, Bernhard Reiter, Dr. Jan-Oliver Wagner -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 473 bytes Desc: This is a digitally signed message part. URL: