Re: [openpgp] Sec. Considerations MUST about S2K [was: Re: I-D Action: draft-ietf-openpgp-crypto-refresh-02.txt]
Ángel <angel@16bits.net> Sat, 27 March 2021 03:14 UTC
Return-Path: <angel@16bits.net>
X-Original-To: openpgp@ietfa.amsl.com
Delivered-To: openpgp@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 9DC5F3A1BA3 for <openpgp@ietfa.amsl.com>; Fri, 26 Mar 2021 20:14:02 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.899
X-Spam-Level:
X-Spam-Status: No, score=-1.899 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_BLOCKED=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id IPdc1UQVCoTU for <openpgp@ietfa.amsl.com>; Fri, 26 Mar 2021 20:13:58 -0700 (PDT)
Received: from mail.direccionemail.com (mail.direccionemail.com [199.195.249.9]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id ECF253A1BA2 for <openpgp@ietf.org>; Fri, 26 Mar 2021 20:13:57 -0700 (PDT)
Message-ID: <bef0bff9eb8e3ce01c1eddd3bd5fa01afb7c6fa3.camel@16bits.net>
From: Ángel <angel@16bits.net>
To: openpgp@ietf.org
Date: Sat, 27 Mar 2021 04:13:52 +0100
In-Reply-To: <fe514371632287e762d6f320edaf106a93dca047.camel@16bits.net>
References: <7d8bdda1-4e5c-6c10-f3cd-1d191fad595c@nohats.ca> <87h7lzavvc.wl-neal@walfield.org>,<87mtvqcdtk.fsf@fifthhorseman.net> <1614483966879.85613@cs.auckland.ac.nz> <4a4f4ca9aa11c850bfcd5ebde7e3d57f51fdf38a.camel@16bits.net> <fe514371632287e762d6f320edaf106a93dca047.camel@16bits.net>
Content-Type: text/plain; charset="ISO-8859-15"
Content-Transfer-Encoding: quoted-printable
MIME-Version: 1.0
Archived-At: <https://mailarchive.ietf.org/arch/msg/openpgp/ml5gzuQtSY6ANBejs8Xk66x_abQ>
Subject: Re: [openpgp] Sec. Considerations MUST about S2K [was: Re: I-D Action: draft-ietf-openpgp-crypto-refresh-02.txt]
X-BeenThere: openpgp@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "Ongoing discussion of OpenPGP issues." <openpgp.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/openpgp>, <mailto:openpgp-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/openpgp/>
List-Post: <mailto:openpgp@ietf.org>
List-Help: <mailto:openpgp-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/openpgp>, <mailto:openpgp-request@ietf.org?subject=subscribe>
X-List-Received-Date: Sat, 27 Mar 2021 03:14:03 -0000
On 2021-03-25 at 01:31 +0100, Ángel wrote: > On 2021-02-28 at 23:09 +0100, Ángel wrote: > > I would suggest a didactic approach, something like > > > Simple S2K and Salted S2K specifiers are not particularly secure > > > when used with a low-entropy secret, such as those typically > > > provided > > > by users, and implementations SHOULD avoid using these methods on > > > encryption of both keys and messages. > > > > Best regards > > As there were no further opinions, I have proposed this on > > https://gitlab.com/openpgp-wg/rfc4880bis/-/merge_requests/42 On https://mailarchive.ietf.org/arch/msg/openpgp/Ym5J-1SQd-AwFLT0ypqyDCqUU18 Paul comments on this point: > > > but I had already covered a proposal for that one in the previous > > > https://gitlab.com/openpgp-wg/rfc4880bis/-/merge_requests/42 > > I would need to hear from more people about this change to see if there > is consensus for this. > > speaking with no roles others than an individual: > > You suggest: > > - Implementations SHOULD use salted or iterated-and-salted S2K specifiers, > - as simple S2K specifiers are more vulnerable to dictionary attacks. > + Simple S2K and Salted S2K specifiers are not particularly secure when used > + with a low-entropy secret, such as those typically provided by users, and > + implementations SHOULD avoid using these methods on encryption of both keys and messages. > [...] > - A compliant application MUST only use iterated and salted S2K to protect private keys, > - as defined in {{iterated-and-salted-s2k}}, "Iterated and Salted S2K". > > I think merging these two as you done is fine. I would try to use "SHOULD NOT use" > instead of "SHOULD avoid". > > I don't think the phrasing of "not particularly secure". Can it not just say "weak" or > "vulnerable to low cost attacks" ? > > Also, if it is this bad, why is this a SHOULD and not a MUST ? That is, > when would be a valid reason for an implementation to ignore the SHOULD? Recapping: - Text from RFC 6637 said «MUST only use iterated and salted S2K» - Neal pointed that precludes private S2K algorithms, and suggested «MUST NOT use Simple S2K and MUST NOT use Salted S2K» - dkg noted they could be allowed if the string is known to be of high entropy. - Peter translated that to «Where it's likely that a low-entropy secret is being employed, a compliant application SHOULD use [...]» - I finally rephrased it adding the explanation on why we don't like those two methods. So: > why is this a SHOULD and not a MUST ? Because of the scenario brought up by dkg that a system which knows that the string is high-entropy ("good key equivalent") should not be prohibited from using those. If we agree this is a legitimate concern, this should be kept as a SHOULD. No point into getting into the specific scenarios it may be allowed or not. On the other hand, the working group may consider that's not a compelling reason to SHOULD it, and to use an iterated and salted even if you have a perfect-grade passphrase. I see value in both propositions. I'm fine with changing SHOULD avoid into SHOULD NOT. That asks for changing the both into either, as well. Not a problem. > I don't think the phrasing of "not particularly secure". Can it not > just say "weak" or "vulnerable to low cost attacks" ? What about simply "are not secure" ? Best regards
- [openpgp] I-D Action: draft-ietf-openpgp-crypto-r… internet-drafts
- Re: [openpgp] I-D Action: draft-ietf-openpgp-cryp… Paul Wouters
- Re: [openpgp] I-D Action: draft-ietf-openpgp-cryp… Derek Atkins
- Re: [openpgp] I-D Action: draft-ietf-openpgp-cryp… Robert J. Hansen
- Re: [openpgp] I-D Action: draft-ietf-openpgp-cryp… Werner Koch
- Re: [openpgp] I-D Action: draft-ietf-openpgp-cryp… Derek Atkins
- Re: [openpgp] I-D Action: draft-ietf-openpgp-cryp… Ángel
- Re: [openpgp] I-D Action: draft-ietf-openpgp-cryp… Ángel
- [openpgp] Incorporated RFC 6637: SHA2-384 recomme… Neal H. Walfield
- Re: [openpgp] I-D Action: draft-ietf-openpgp-cryp… Neal H. Walfield
- Re: [openpgp] I-D Action: draft-ietf-openpgp-cryp… Neal H. Walfield
- [openpgp] textual cleanup (no substantive changes) Neal H. Walfield
- [openpgp] Deprecate non-integrity-protected encry… Neal H. Walfield
- Re: [openpgp] I-D Action: draft-ietf-openpgp-cryp… Neal H. Walfield
- Re: [openpgp] Deprecate non-integrity-protected e… Neal H. Walfield
- Re: [openpgp] I-D Action: draft-ietf-openpgp-cryp… Daniel Kahn Gillmor
- Re: [openpgp] I-D Action: draft-ietf-openpgp-cryp… Daniel Kahn Gillmor
- Re: [openpgp] I-D Action: draft-ietf-openpgp-cryp… Daniel Kahn Gillmor
- [openpgp] Sec. Considerations MUST about S2K [was… Daniel Kahn Gillmor
- [openpgp] v5 fingerprints in ECDH brian m. carlson
- [openpgp] Curve448 in ECDH brian m. carlson
- Re: [openpgp] Sec. Considerations MUST about S2K … Peter Gutmann
- Re: [openpgp] Curve448 in ECDH Paul Wouters
- Re: [openpgp] v5 fingerprints in ECDH Paul Wouters
- Re: [openpgp] Curve448 in ECDH brian m. carlson
- Re: [openpgp] I-D Action: draft-ietf-openpgp-cryp… Paul Wouters
- Re: [openpgp] I-D Action: draft-ietf-openpgp-cryp… Paul Wouters
- Re: [openpgp] Curve448 in ECDH Paul Wouters
- Re: [openpgp] Curve448 in ECDH brian m. carlson
- Re: [openpgp] Sec. Considerations MUST about S2K … Ángel
- Re: [openpgp] ECC Curve OIDs section Ángel
- Re: [openpgp] who creates old-rfc registries? Ángel
- Re: [openpgp] I-D Action: draft-ietf-openpgp-cryp… Ángel
- Re: [openpgp] I-D Action: draft-ietf-openpgp-cryp… Neal H. Walfield
- Re: [openpgp] Sec. Considerations MUST about S2K … Ángel
- Re: [openpgp] Sec. Considerations MUST about S2K … Ángel
- Re: [openpgp] I-D Action: draft-ietf-openpgp-cryp… Paul Wouters