unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
* Re: Bug#842291: notmuch processes frequently stuck in select()
       [not found]   ` <87inrelinq.fsf@tethera.net>
@ 2016-11-23  8:50     ` David Bremner
  2016-11-23 17:19       ` Daniel Kahn Gillmor
  0 siblings, 1 reply; 5+ messages in thread
From: David Bremner @ 2016-11-23  8:50 UTC (permalink / raw)
  To: Brian May, 842291, Robbie Harwood; +Cc: notmuch

[-- Attachment #1: Type: text/plain, Size: 864 bytes --]

David Bremner <david@tethera.net> writes:

> Brian May <bam@debian.org> writes:
>> strace shows notmuch looping in select.
>>
>> select(10, [9], [], NULL, {1, 0})       = 0 (Timeout)
>> select(10, [9], [], NULL, {1, 0})       = 0 (Timeout)
>> select(10, [9], [], NULL, {1, 0})       = 0 (Timeout)
>> select(10, [9], [], NULL, {1, 0})       = 0 (Timeout)
>> etc
>>
>
> a backtrace would be helpful.
>
> d

Nevermind, I managed to download the list archive for debian-devel and
replicate the bug.

The bug seems to be related to smime signature verification. After
adding the attached mail message (and running notmuch-new), to replicate
the hang it suffices to run

% notmuch show --decrypt id:20161116T143809.GA.21721.stse@fsing.rootsland.net  

As far as workarounds, turning off decryption / signature verification
should allow you to at least view the thread.


[-- Attachment #2: 20161116T143809.GA.21721.stse@fsing.rootsland.net.eml:2, --]
[-- Type: application/octet-stream, Size: 10816 bytes --]

Return-path: <list@bendel.debian.org>
Received: from bendel.debian.org ([82.195.75.100])
	from C=NA,ST=NA,L=Ankh Morpork,O=Debian SMTP,OU=Debian SMTP CA,CN=clientcerts/bendel.debian.org,EMAIL=hostmaster@clientcerts/bendel.debian.org (verified)
	by master.debian.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
	(Exim 4.84_2)
	(envelope-from <list@bendel.debian.org>)
	id 1c70fy-0000O8-Sk
	for debian-list-archive@master.debian.org; Wed, 16 Nov 2016 13:54:58 +0000
Received: by bendel.debian.org (Postfix, from userid 38)
	id C8DD72EB; Wed, 16 Nov 2016 13:54:58 +0000 (UTC)
Old-Return-Path: <stse@fsing.rootsland.net>
X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on bendel.debian.org
X-Spam-Level: 
X-Spam-Status: No, score=-8.1 required=4.0 tests=DKIM_SIGNED,DKIM_VALID,
	DKIM_VALID_AU,DKIM_VERIFIED,LDO_WHITELIST,MURPHY_DRUGS_REL8,RP_MATCHES_RCVD
	autolearn=unavailable autolearn_force=no version=3.4.0
X-Original-To: lists-debian-devel@bendel.debian.org
Delivered-To: lists-debian-devel@bendel.debian.org
Received: from localhost (localhost [127.0.0.1])
	by bendel.debian.org (Postfix) with ESMTP id E8819297
	for <lists-debian-devel@bendel.debian.org>; Wed, 16 Nov 2016 13:54:50 +0000 (UTC)
X-Virus-Scanned: at lists.debian.org with policy bank en-ht
X-Amavis-Spam-Status: No, score=-7.391 tagged_above=-10000 required=5.3
	tests=[BAYES_00=-2, DKIM_SIGNED=0.1, DKIM_VALID=-0.1,
	DKIM_VALID_AU=-0.1, LDO_WHITELIST=-5, MURPHY_DRUGS_REL8=0.02,
	RP_MATCHES_RCVD=-0.311] autolearn=ham autolearn_force=no
Received: from bendel.debian.org ([127.0.0.1])
	by localhost (lists.debian.org [127.0.0.1]) (amavisd-new, port 2525)
	with ESMTP id g6Yh2oZPVGq6 for <lists-debian-devel@bendel.debian.org>;
	Wed, 16 Nov 2016 13:54:46 +0000 (UTC)
X-policyd-weight: using cached result; rate: -6.1
X-Greylist: delayed 445 seconds by postgrey-1.35 at bendel; Wed, 16 Nov 2016 13:54:46 UTC
Received: from fsing.rootsland.net (fsing.rootsland.net [IPv6:2a01:4f8:c17:3852::2])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(Client did not present a certificate)
	by bendel.debian.org (Postfix) with ESMTPS id 3B18D174
	for <debian-devel@lists.debian.org>; Wed, 16 Nov 2016 13:54:45 +0000 (UTC)
Received: from osgiliath.gondor (osgiliath.gondor [IPv6:2a01:198:492::10])
	(using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(Client CN "Stephan Seitz", Issuer "CAcert Class 3 Root" (not verified))
	by fsing.rootsland.net (Postfix) with ESMTPS id 3tJlt027RLz3wpF
	for <debian-devel@lists.debian.org>; Wed, 16 Nov 2016 14:46:48 +0100 (CET)
DKIM-Filter: OpenDKIM Filter v2.9.2 fsing.rootsland.net 3tJlt027RLz3wpF
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=fsing.rootsland.net;
	s=mail20100714; t=1479304008;
	bh=oSsWUURYeCIiWKrX7yjTKTnOze7rfLLhNtsDNi7iMSA=;
	h=Date:From:To:Subject:References:In-Reply-To;
	b=eNAdDn42oVAl6/9eOsSLzr/VrP3MmhMZtKKDL+On1EE7kLPfLau+Am2Y0BLXhsGXn
	 uT80tgafwBG0nHs4XNL2pGsJNTXMW8ljshiFB1klzVQzS6ADG/cg6Tbj8Zr91qbL+S
	 FVEde7SH70yQ8z9c2E3P1LVTtzs0xVg8Cy812A9w=
Received: by osgiliath.gondor (Postfix, from userid 10009)
	id 3tJlsz5QGNzyLq; Wed, 16 Nov 2016 14:46:47 +0100 (CET)
Date: Wed, 16 Nov 2016 14:46:47 +0100
From: Stephan Seitz <stse+debian@fsing.rootsland.net>
To: debian-devel@lists.debian.org
Subject: Re: OpenSSL 1.1.0
Message-ID: <20161116T143809.GA.21721.stse@fsing.rootsland.net>
Mail-Followup-To: debian-devel@lists.debian.org
References: <20160611123036.GA8321@roeckx.be>
 <22571.12184.204754.473038@chiark.greenend.org.uk>
 <22572.20623.82302.920412@chiark.greenend.org.uk>
 <CAKcBokvqZwsdieqZg_5i8EGMZoGaXzeohmrx2P-pbzLSJ7LVNQ@mail.gmail.com>
 <20161116133128.gf6o7pueequkrwi5@bongo.bofh.it>
MIME-Version: 1.0
Content-Type: multipart/signed; protocol="application/x-pkcs7-signature";
	micalg=sha-256; boundary="axsomkoxwo2ilny4"
Content-Disposition: inline
In-Reply-To: <20161116133128.gf6o7pueequkrwi5@bongo.bofh.it>
Organization: Minas Tirith, Gondor
User-Agent: NeoMutt/20161104 (1.7.1)
X-Rc-Virus: 2007-09-13_01
X-Rc-Spam: 2008-11-04_01
Resent-Message-ID: <ykb-u-niu9M.A.79G.yUGLYB@bendel>
Resent-From: debian-devel@lists.debian.org
X-Mailing-List: <debian-devel@lists.debian.org> archive/latest/322800
X-Loop: debian-devel@lists.debian.org
List-Id: <debian-devel.lists.debian.org>
List-URL: <https://lists.debian.org/debian-devel/>
List-Post: <mailto:debian-devel@lists.debian.org>
List-Help: <mailto:debian-devel-request@lists.debian.org?subject=help>
List-Subscribe: <mailto:debian-devel-request@lists.debian.org?subject=subscribe>
List-Unsubscribe: <mailto:debian-devel-request@lists.debian.org?subject=unsubscribe>
Precedence: list
Resent-Sender: debian-devel-request@lists.debian.org
Resent-Date: Wed, 16 Nov 2016 13:54:58 +0000 (UTC)
Delivered-To: debian-list-archive@master.debian.org


--axsomkoxwo2ilny4
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Mi, Nov 16, 2016 at 02:31:28 +0100, Marco d'Itri wrote:
>ChaCha20 is hardly obscure: if it is to you then I fear that your
>opinion on this issue is not informed enough to be useful.

It doesn=E2=80=99t matter in the end.

If no one wants to delay the next release until all applications support=20
OpenSSL 1.1.0 in a secure way even is upstream may not be interested in=20
patching the software for now then we can=E2=80=99t have version 1.1.0.

And there is still the problem that 1.1.0 is not supported as long as the=
=20
available LTS version.

Many greetings,

	Stephan

--=20
| Public Keys: http://fsing.rootsland.net/~stse/keys.html |

--axsomkoxwo2ilny4
Content-Type: application/x-pkcs7-signature
Content-Disposition: attachment; filename="smime.p7s"
Content-Transfer-Encoding: base64

MIIOkwYJKoZIhvcNAQcCoIIOhDCCDoACAQExDzANBglghkgBZQMEAgEFADALBgkqhkiG9w0B
BwGgggvqMIIGCDCCA/CgAwIBAgIBATANBgkqhki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gEFAKCB5DAYBgkqhkiG
9w0BCQMxCwYJKoZIhvcNAQcBMBwGCSqGSIb3DQEJBTEPFw0xNjExMTYxMzQ2NDdaMC8GCSqG
SIb3DQEJBDEiBCAppHQX2oAd2XSmFSDw6EWNc7QqZu0YgtKuw9sFrfb2dTB5BgkqhkiG9w0B
CQ8xbDBqMAsGCWCGSAFlAwQBKjALBglghkgBZQMEARYwCwYJYIZIAWUDBAECMAoGCCqGSIb3
DQMHMA4GCCqGSIb3DQMCAgIAgDANBggqhkiG9w0DAgIBQDAHBgUrDgMCBzANBggqhkiG9w0D
AgIBKDANBgkqhkiG9w0BAQEFAASCAQBzudRPmKhfxljRKpWq1Uhav8bpEWlft56TQr5AAsRi
HkQnVtQ9JDHp7ObJwVGg23Wm7GaVhl8sVnP31CuokbVsylt7lJYKebkvfLNyylAtbkiLC7UD
Szmj7pviMd3Cr0pOBpSAe1yQOzaPDdtWAGM8xA3AQzpjLhtv4Zqdwc5V8mf3E5aAqC1lc8aA
sV9XAhifOYJp/Gr1mi1dJ/lShLhGbBcPNmwn5HtauA4r4wzQdqa9NU4pXyohHljodeuGm7PM
AxYOYJup7LnLcRokin2WUNfpgxoUq69XqiQ6QD0dQ/qKor6mc1dF6talJ/7RVj+nVgcZa1uB
lnSBzM0G9hMy

--axsomkoxwo2ilny4--



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Bug#842291: notmuch processes frequently stuck in select()
  2016-11-23  8:50     ` Bug#842291: notmuch processes frequently stuck in select() David Bremner
@ 2016-11-23 17:19       ` Daniel Kahn Gillmor
  2016-11-23 22:57         ` David Bremner
  2016-11-24 23:18         ` [pkg-gnupg-maint] " Werner Koch
  0 siblings, 2 replies; 5+ messages in thread
From: Daniel Kahn Gillmor @ 2016-11-23 17:19 UTC (permalink / raw)
  To: David Bremner, Brian May, 842291, Robbie Harwood
  Cc: notmuch, Debian GnuPG packaging

[-- Attachment #1: Type: text/plain, Size: 4961 bytes --]

Control: affects 842291 + gpgsm dirmngr

On Wed 2016-11-23 03:50:40 -0500, David Bremner wrote:
> David Bremner <david@tethera.net> writes:
>
>> Brian May <bam@debian.org> writes:
>>> strace shows notmuch looping in select.
>>>
>>> select(10, [9], [], NULL, {1, 0})       = 0 (Timeout)
>>> select(10, [9], [], NULL, {1, 0})       = 0 (Timeout)
>>> select(10, [9], [], NULL, {1, 0})       = 0 (Timeout)
>>> select(10, [9], [], NULL, {1, 0})       = 0 (Timeout)
>>> etc
>>>
>>
>> a backtrace would be helpful.
>>
>> d
>
> Nevermind, I managed to download the list archive for debian-devel and
> replicate the bug.
>
> The bug seems to be related to smime signature verification. After
> adding the attached mail message (and running notmuch-new), to replicate
> the hang it suffices to run
>
> % notmuch show --decrypt id:20161116T143809.GA.21721.stse@fsing.rootsland.net  
>
> As far as workarounds, turning off decryption / signature verification
> should allow you to at least view the thread.

I've noticed similar behavior, and it seems to correlate with gpgsm
asking dirmngr for an update to CRLs related to S/MIME certs.

some CRLs simply do not respond at all (resulting in a timeout), and
some do not respond, or are laggy, when accessed over tor specifically.

I see a couple possible ways to consider resolving this, none of them
great, and i don't know exactly how to implement any of them:

 0) turn off CRL updates entirely during s/mime signature verification

 1) do s/mime signature verification without CRL updates, but schedule
    CRL checks to happen in the background for dirmngr, so that future
    verifications will reflect the cert validity

 2) have dirmngr avoid checking CRLs that it knows it has already
    updated recently

 3) tell dirmngr to use much shorter CRL fetch timeouts


Some example traffic from my dirmngr that uses tor (complete with
timestamps indicating just how bad the delays can be):

Nov 22 14:08:24 alice dirmngr[11976]: no CRL available for issuer id 770B4DA5913F2572B9F679AE0819FB7D77572689
Nov 22 14:08:24 alice dirmngr[11976]: fetching CRL from 'http://crl.ll.mit.edu/getcrl/LLCA3'
Nov 22 14:08:44 alice dirmngr[11976]: resolving 'crl.ll.mit.edu' failed: No data
Nov 22 14:08:44 alice dirmngr[11976]: can't connect to 'crl.ll.mit.edu': host not found
Nov 22 14:08:44 alice dirmngr[11976]: error retrieving 'http://crl.ll.mit.edu/getcrl/LLCA3': Unknown host
Nov 22 14:08:44 alice dirmngr[11976]: crl_fetch via DP failed: Unknown host
Nov 22 14:08:45 alice dirmngr[11976]: no CRL available for issuer id 770B4DA5913F2572B9F679AE0819FB7D77572689
Nov 22 14:08:45 alice dirmngr[11976]: fetching CRL from 'http://crl.ll.mit.edu/getcrl/LLCA3'
Nov 22 14:09:05 alice dirmngr[11976]: resolving 'crl.ll.mit.edu' failed: No data
Nov 22 14:09:05 alice dirmngr[11976]: can't connect to 'crl.ll.mit.edu': host not found
Nov 22 14:09:05 alice dirmngr[11976]: error retrieving 'http://crl.ll.mit.edu/getcrl/LLCA3': Unknown host
Nov 22 14:09:05 alice dirmngr[11976]: crl_fetch via DP failed: Unknown host
Nov 22 14:09:05 alice dirmngr[11976]: no CRL available for issuer id 26FD002905277B015EE9B2A3C092A348F28A4C6B
Nov 22 14:09:05 alice dirmngr[11976]: fetching CRL from 'http://crl.startssl.com/sca-client1.crl'
Nov 22 14:09:25 alice dirmngr[11976]: resolving 'crl.startssl.com' failed: No data
Nov 22 14:09:25 alice dirmngr[11976]: can't connect to 'crl.startssl.com': host not found
Nov 22 14:09:25 alice dirmngr[11976]: error retrieving 'http://crl.startssl.com/sca-client1.crl': Unknown host
Nov 22 14:09:25 alice dirmngr[11976]: crl_fetch via DP failed: Unknown host
Nov 22 14:09:25 alice dirmngr[11976]: no CRL available for issuer id 26FD002905277B015EE9B2A3C092A348F28A4C6B
Nov 22 14:09:25 alice dirmngr[11976]: fetching CRL from 'http://crl.startssl.com/sca-client1.crl'
Nov 22 14:09:45 alice dirmngr[11976]: resolving 'crl.startssl.com' failed: No data
Nov 22 14:09:45 alice dirmngr[11976]: can't connect to 'crl.startssl.com': host not found
Nov 22 14:09:45 alice dirmngr[11976]: error retrieving 'http://crl.startssl.com/sca-client1.crl': Unknown host
Nov 22 14:09:45 alice dirmngr[11976]: crl_fetch via DP failed: Unknown host

that's a 20-second lag between each failed check, adding up to 80
seconds delay in rendering a single thread where 4 messages were signed
by S/MIME keys signed by two different authorities.

Fwiw, crl.ll.mit.edu doesn't seem to respond over tor on port 80 at all
in some cases, and in other cases takes nearly a minute to reply:

0 dkg@alice:/tmp/cdtemp.Ue45bu$ time wget -q 'http://crl.ll.mit.edu/getcrl/LLCA3'

real	0m0.694s
user	0m0.008s
sys	0m0.008s
0 dkg@alice:/tmp/cdtemp.Ue45bu$ time torsocks wget -q 'http://crl.ll.mit.edu/getcrl/LLCA3'

real	0m58.828s
user	0m0.008s
sys	0m0.008s
0 dkg@alice:/tmp/cdtemp.Ue45bu$ 


Any thoughts on the best way to pursue this?

    --dkg

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 962 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Bug#842291: notmuch processes frequently stuck in select()
  2016-11-23 17:19       ` Daniel Kahn Gillmor
@ 2016-11-23 22:57         ` David Bremner
  2016-11-24 23:18         ` [pkg-gnupg-maint] " Werner Koch
  1 sibling, 0 replies; 5+ messages in thread
From: David Bremner @ 2016-11-23 22:57 UTC (permalink / raw)
  To: Daniel Kahn Gillmor, Brian May, 842291, Robbie Harwood
  Cc: notmuch, Debian GnuPG packaging

Daniel Kahn Gillmor <dkg@fifthhorseman.net> writes:
>
>  0) turn off CRL updates entirely during s/mime signature verification
>
>  1) do s/mime signature verification without CRL updates, but schedule
>     CRL checks to happen in the background for dirmngr, so that future
>     verifications will reflect the cert validity
>
>  2) have dirmngr avoid checking CRLs that it knows it has already
>     updated recently
>
>  3) tell dirmngr to use much shorter CRL fetch timeouts
>

>
> Any thoughts on the best way to pursue this?
>
>     --dkg

Maybe the issue is in gmime's usage of gpgme. If I understand correctly
(which is far from a sure thing), pkcs7_verify calls gpgme_op_verify
which is synchronous, and (apparently) does not support timeouts. An
alternate strategy would be to call gpgme_op_verify_start, and then call
gpgme_wait, which has a nonblocking mode. I don't really understand the
S/MIME model, but naively it seems OK for signature verification to fail
if the CRL check doesn't finish quickly.

d

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [pkg-gnupg-maint] Bug#842291: notmuch processes frequently stuck in select()
  2016-11-23 17:19       ` Daniel Kahn Gillmor
  2016-11-23 22:57         ` David Bremner
@ 2016-11-24 23:18         ` Werner Koch
  2016-11-29 18:10           ` David Bremner
  1 sibling, 1 reply; 5+ messages in thread
From: Werner Koch @ 2016-11-24 23:18 UTC (permalink / raw)
  To: Daniel Kahn Gillmor
  Cc: David Bremner, Brian May, 842291, Robbie Harwood, notmuch,
	Debian GnuPG packaging

[-- Attachment #1: Type: text/plain, Size: 1313 bytes --]

On Wed, 23 Nov 2016 18:19, dkg@fifthhorseman.net said:

>  0) turn off CRL updates entirely during s/mime signature verification

The gpgsm option is --disable-crl-checks.  

>  1) do s/mime signature verification without CRL updates, but schedule
>     CRL checks to happen in the background for dirmngr, so that future
>     verifications will reflect the cert validity

As above but use 

  dirmngr-client--url --load-crl URLOFCRL

You need to known the URL of the CRL, though.

>  2) have dirmngr avoid checking CRLs that it knows it has already
>     updated recently

A CRL carries a next-update date which is homored by dirmngr.  Further
dirmngr doesn't avoids to download a CRL unless 30 minutes have passed
since the lassed download.

>  3) tell dirmngr to use much shorter CRL fetch timeouts

gpgsm -k  --enable-crl-check --force-crl-refresh  USERID

> that's a 20-second lag between each failed check, adding up to 80

That seems to be caused by DNS lookups.  For example ADNS keeps on
trying even if it has received an ENETUNREACH and thus no UDP query
packet has been sent out.   We will very likely replace ADNS by a more
flexible library in the next GnuPG version.


Salam-Shalom,

   Werner

-- 
Die Gedanken sind frei.  Ausnahmen regelt ein Bundesgesetz.

[-- Attachment #2: Type: application/pgp-signature, Size: 194 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [pkg-gnupg-maint] Bug#842291: notmuch processes frequently stuck in select()
  2016-11-24 23:18         ` [pkg-gnupg-maint] " Werner Koch
@ 2016-11-29 18:10           ` David Bremner
  0 siblings, 0 replies; 5+ messages in thread
From: David Bremner @ 2016-11-29 18:10 UTC (permalink / raw)
  To: Daniel Kahn Gillmor
  Cc: Brian May, 842291, Robbie Harwood, notmuch,
	Debian GnuPG packaging

Werner Koch <wk@gnupg.org> writes:

> On Wed, 23 Nov 2016 18:19, dkg@fifthhorseman.net said:
>
>>  0) turn off CRL updates entirely during s/mime signature verification
>
> The gpgsm option is --disable-crl-checks.  
>
>>  1) do s/mime signature verification without CRL updates, but schedule
>>     CRL checks to happen in the background for dirmngr, so that future
>>     verifications will reflect the cert validity

A notmuch user reported on IRC that adding disable-crl-checks to
~/.gnupg/dirmngr.conf eliminated the long pauses when verifying s/mime
signatures.

This will prevent the user from noticing Certificate revokations, so
it's not without cost in security, but perhaps it's temporary workaround
until we figure out some better solution.

d

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2016-11-29 18:11 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <147759452918.27740.4112596085176407099.reportbug@thriss.redhat.com>
     [not found] ` <20161123065714.u7gvw4trvn2jznzg@prune.linuxpenguins.xyz>
     [not found]   ` <87inrelinq.fsf@tethera.net>
2016-11-23  8:50     ` Bug#842291: notmuch processes frequently stuck in select() David Bremner
2016-11-23 17:19       ` Daniel Kahn Gillmor
2016-11-23 22:57         ` David Bremner
2016-11-24 23:18         ` [pkg-gnupg-maint] " Werner Koch
2016-11-29 18:10           ` David Bremner

Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).