Re: [openpgp] Possible ambiguity in description of regular expressions: [^][]

Daniel Kahn Gillmor <> Sat, 09 January 2021 18:11 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id 2CB323A11A4 for <>; Sat, 9 Jan 2021 10:11:27 -0800 (PST)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -2.099
X-Spam-Status: No, score=-2.099 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: (amavisd-new); dkim=neutral reason="invalid (unsupported algorithm ed25519-sha256)" header.b=fcwLvkfN; dkim=pass (2048-bit key) header.b=qBZ6pudS
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id 4du5mI7Qct7c for <>; Sat, 9 Jan 2021 10:11:25 -0800 (PST)
Received: from ( [IPv6:2001:470:1:116::7]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by (Postfix) with ESMTPS id 433043A119A for <>; Sat, 9 Jan 2021 10:11:24 -0800 (PST)
DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/simple;;; q=dns/txt; s=2019; t=1610215883; h=from : to : subject : in-reply-to : references : date : message-id : mime-version : content-type : from; bh=ug6YXXL5ZMuyjr5kxuQ3rGHYboGuo8O4DY9IC4b+weA=; b=fcwLvkfNB6n/inVbGZH41IchPzEthTabWGUKXyhKikInjbLY32rkUfGmY7kWiIy0v0T8f GYeiZdvLLKN4lBxDg==
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple;;; q=dns/txt; s=2019rsa; t=1610215883; h=from : to : subject : in-reply-to : references : date : message-id : mime-version : content-type : from; bh=ug6YXXL5ZMuyjr5kxuQ3rGHYboGuo8O4DY9IC4b+weA=; b=qBZ6pudSawr7Gcsd5I65LLvz+QXtuGWpmjwBOR2YeTZk8h0+xeIe5zbW66LbqALSKXY6j L8bGjP4tELbxsF8L9JeB47EuyR2vzxQnyvjrunlv4QvYJaevawq7+WVEf2q5R9U4Qzi6DWp 7QELAEFj9Q68JQ7XIwWrCg+++4u2glqaYANHIoIpi5FdLgcGHfpYwwU3jW0Rm1KBPIIMkA+ Uek0CgNyvaxWXxRR+daROUZnib0Ej/soJXvUExMQIBafCd6wvGfeFEMtISqfybsekkTDjQ1 DwBFCZ3rGTUKvS8W6zcjj9Sbu9i6F/3xsOs/XMkNFoOp1MiwePywY5kOo7TA==
Received: from (unknown []) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by (Postfix) with ESMTPSA id 9F9ECF9A5; Sat, 9 Jan 2021 13:11:23 -0500 (EST)
Received: by (Postfix, from userid 1000) id 5E4E520391; Sat, 9 Jan 2021 08:42:03 -0500 (EST)
From: Daniel Kahn Gillmor <>
To: Ángel <>,
In-Reply-To: <>
References: <> <> <> <> <> <> <> <>
Autocrypt:; prefer-encrypt=mutual; keydata= mDMEXEK/AhYJKwYBBAHaRw8BAQdAr/gSROcn+6m8ijTN0DV9AahoHGafy52RRkhCZVwxhEe0K0Rh bmllbCBLYWhuIEdpbGxtb3IgPGRrZ0BmaWZ0aGhvcnNlbWFuLm5ldD6ImQQTFggAQQIbAQULCQgH AgYVCgkICwIEFgIDAQIeAQIXgAIZARYhBMS8Lds4zOlkhevpwvIGkReQOOXGBQJd5Hw3BQkFpJWB AAoJEPIGkReQOOXGDYEA/j0ERjPxDleKMZ2LDcWc/3o5cLFwAVzBKQHppu0Be5IWAP0aeTnyEqlp RTE7M8zugwkhYeUYfYu0BjecDUMnYz6iDLgzBF3kewUWCSsGAQQB2kcPAQEHQK1IuW0GZmcrs2mx CYMl8IHse0tMF8cP7eBNXevrlx2ZiPUEGBYIACYCGwIWIQTEvC3bOMzpZIXr6cLyBpEXkDjlxgUC XeR7TwUJAiGl/gCBdiAEGRYIAB0WIQQsv6x2UaqQJzY+dXHEDyVUMvKBDwUCXeR7BQAKCRDEDyVU MvKBD7KmAQCHs+7588C4jto6fMje0Nu97zzoppjJM7lrGF2rVnbHvwD+MgmGUbHzPSUrTWnZBQDi /QM595bxNrBA4N1CiXhs2AMJEPIGkReQOOXGpp0BAM7YeBnt/UNvxJAGm4DidSfHU7RDMWe6Tgux HrH21cDkAQC9leNFXJsQ7F2ZniRPHa8CkictcQEKPL8VCWpfe8LbArg4BF3ke5wSCisGAQQBl1UB BQEBB0Cf+EiAXtntQMf51xpqb6uZ5O0eCLAZtkg0SXHjA1JlEwMBCAeIfgQYFggAJhYhBMS8Lds4 zOlkhevpwvIGkReQOOXGBQJd5HucAhsMBQkCIaVkAAoJEPIGkReQOOXGdYcBANYnW7VyL2CncKH1 iO4Zr0IwfdIv6rai1PUHL98pVi3cAP9tMh85CKGDa0Xi/fptQH41meollLW5tLb/bEWMuUNuBQ==
Date: Sat, 09 Jan 2021 08:42:01 -0500
Message-ID: <>
MIME-Version: 1.0
Content-Type: multipart/signed; boundary="=-=-="; micalg="pgp-sha256"; protocol="application/pgp-signature"
Archived-At: <>
Subject: Re: [openpgp] Possible ambiguity in description of regular expressions: [^][]
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "Ongoing discussion of OpenPGP issues." <>
List-Unsubscribe: <>, <>
List-Archive: <>
List-Post: <>
List-Help: <>
List-Subscribe: <>, <>
X-List-Received-Date: Sat, 09 Jan 2021 18:11:27 -0000

On Sat 2021-01-09 01:08:10 +0100, Ángel wrote:
> Finally, another point to consider would be whether to match only the
> email address portion. Yes, User ID could contain something else, but
> this delegation of partial trust only seem useful when combined with a
> hierarchical structure, such as those to be found on the email address
> part. It seems rare to require a matching on the display name part.
> And allowing that would greatly decrease its security. Basically a
> wildcard not on the left-most side could be bypassed by including the
> required characters on the display name.

This stuff is very rarely used in the wild, and to the extent that it
is, it's used as a hierarchical match on the domain side of an e-mail
address, as found in the user ID (which itself is not typically treated
as a true RFC 2822 name-addr, despite the text in the spec, see and related discussion).

Seems like the right way to address the most common (though still
uncommon) use case is to make a new explicit subpacket that is just
about handling a DNS suffix; to clearly define the interaction between
multiple subpackets; and to deprecate the regex for that particular use
case. (maybe deprecate the regex subpacket in general, as i've not seen
any other legit use, and there are clearly gaps in the spec for it)

That work is not really in-scope given our current charter, but if
someone wants to write something like that down in a more formal way, i
can imagine it being something for the WG to take on after we finish the
cryptographic refresh and consider re-chartering.