[Plants] Re: Higher forgery resistance almost for free?
Bas Westerbaan <bas@cloudflare.com> Fri, 27 March 2026 17:33 UTC
Return-Path: <bas@cloudflare.com>
X-Original-To: plants@mail2.ietf.org
Delivered-To: plants@mail2.ietf.org
Received: from localhost (localhost [127.0.0.1]) by mail2.ietf.org (Postfix) with ESMTP id 41AF0D28C00D for <plants@mail2.ietf.org>; Fri, 27 Mar 2026 10:33:00 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ietf.org; s=ietf1; t=1774632780; bh=g5QMIYk0LCUpsAlWRa4gYy7duK8566O7QLe9OW7LKSw=; h=References:In-Reply-To:From:Date:Subject:To:Cc; b=oIDLXjrqd5WL5/Sd5PGgbWzpgJFo8fBE+aE/ylv3R/iq6NcGDIrzUHylWzuZLMEgp f6Euhooe5WGKgxv3X8AXp+W3XGfzlAEkFtLvDlO5L2SkbPvdni98JV6cimlEyrqEzt nAS6+MF8AzxJde4+vSp03OUky1nopspjZ7Ic4gi4=
X-Virus-Scanned: amavisd-new at ietf.org
X-Spam-Flag: NO
X-Spam-Score: -2.098
X-Spam-Level:
X-Spam-Status: No, score=-2.098 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIMWL_WL_MED=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_NONE=0.001] autolearn=unavailable autolearn_force=no
Authentication-Results: mail2.ietf.org (amavisd-new); dkim=pass (2048-bit key) header.d=cloudflare.com
Received: from mail2.ietf.org ([166.84.6.31]) by localhost (mail2.ietf.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id dAht4lCCTk9X for <plants@mail2.ietf.org>; Fri, 27 Mar 2026 10:32:59 -0700 (PDT)
Received: from mail-lf1-x12f.google.com (mail-lf1-x12f.google.com [IPv6:2a00:1450:4864:20::12f]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature ECDSA (P-256) server-digest SHA256) (No client certificate requested) by mail2.ietf.org (Postfix) with ESMTPS id 9472DD28BFFB for <plants@ietf.org>; Fri, 27 Mar 2026 10:32:59 -0700 (PDT)
Received: by mail-lf1-x12f.google.com with SMTP id 2adb3069b0e04-5a281b091c2so3078749e87.0 for <plants@ietf.org>; Fri, 27 Mar 2026 10:32:59 -0700 (PDT)
ARC-Seal: i=1; a=rsa-sha256; t=1774632778; cv=none; d=google.com; s=arc-20240605; b=LXerstY2W5QSgEBu7uz7r3mPYCpM8duHGcZV4rn7hAFg7cTKu5iQb+2UexpJbSBT+5 o3GFfqFcuVoTfQ2U45Y0XQ4q30HFtMxHOqiPUC3yweBEO8KQPPnqSbtQJYyuWqpr1I3x dWpWwuuIeazR84mDKAqkztorZwlJfUv52kPfTyzwfBH67ItwsOOK3pcWdEPAntb1XTwQ bXJOgtQL6fNnPsg/99cT2SGYCxGf5rWBPy74VxAF2YCqyqTkkexq10YNH/wZkzIjXmUZ UZZgjUBNfZmiqXt30UJ+4k6Gr+9RBkgYqLeiv1PkOxo4uJM8H+zfEPE2HX289eeVR03o 6+ng==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:dkim-signature; bh=xcG/mdpPWyfVUrXczq5bwYikUZDfRS7qCJHvhHZAa34=; fh=cMay6GXtkkW55vr108SB6Lkpyla3wyINBwEy4Pk+b1k=; b=h9npUaNlOQToO7KyKh01fRkne4KsWMTxp2ZWM1RKEMQ8LX/nITzfCViWTMpduREwqd 9TOSm0pN0EbL8mDVUf5nd7KgP18xdU7U2OWIksFAq8x9w+f6N3BoIwbIdFUHMsBD9cu6 q/5krfg6DetyoZp/kL85OfFTIvuiL840913MFEcoxW6rExkodSu9ra2ybo9fpyolCyAe r1dx1k6Uos7MecxHKQVvPNd8d6hde1fa5E2d+gCEava25p3+oPY/kL8V1bCbooFIVPS6 n2qlkEurrsQpP4aCQCYZWGhK4nXB9xzMIX5GYU55E8j8jEmYle7H9bCRDLFpn5fSTORZ hEvg==; darn=ietf.org
ARC-Authentication-Results: i=1; mx.google.com; arc=none
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cloudflare.com; s=google09082023; t=1774632778; x=1775237578; darn=ietf.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=xcG/mdpPWyfVUrXczq5bwYikUZDfRS7qCJHvhHZAa34=; b=fOVB2VBQVNUDkGgNHGnEyYNs+NVEnbl5mDZjevh368p+vDSIjrxdF8X7H9dQdZCNjK Fc8tRSz25qunNqsCweno2IgsjcYGJir/pCdvp3P6gOHtPgc74Y92P+CxIcxp8Uwa0Uym SMRV096rczdFXXNfQekJu7lA1QkZBGswJNh7X5W4z1jfjjUB9bL+NyrajZLIJSusrXwU a4h39gjryJc8YulIY63mwOVvayqyc/J8J2eEIlLssRcK0tyRKwBiReuTpwKi9fJyPAn5 JTAa2dh3ZNQUHVO9wlUZCtI5xnPrusHrhcumjfSlJr952B/mfLkq4QXlnMeexb4l/02y qoLA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1774632778; x=1775237578; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=xcG/mdpPWyfVUrXczq5bwYikUZDfRS7qCJHvhHZAa34=; b=QRqc1AXW/Hg7JocP30v46vfehqgYnVWPDjvHRuiZGwDUqKxfhi2ZcssW1Fg52puXhC TMmZ1WMoAYJH5xpWc21KmY+k29NANNcC3Lv8F96OcBAJMft0s6e4W541mLUE7FerhJrh tKG2b+JiNPNFP4So+DIxR5rtttXJf3XS9Ahw7en0XjPXmYpPVqgz4lAf+Y5OKwomw5m4 wnUP+m2SKSR9rdeSDAOmLcxQWa/fKlBEIzEQYtSXR3kea1WCW8/0rbOgO1xnKjQc4Oqh +4wS6hqy3h6X4UbIO6vn3T/rJsD3w/AI6pWW9BwXPlrWG5UZq/+aWvFxqIpgkC6E9Ef9 GQtQ==
X-Forwarded-Encrypted: i=1; AJvYcCUS9VpE9gdgCINPXZGLZBYBKz/O6DN44RrpAqBSqBAVWLwfowRP0GV99W3hof9oWqzIGSXMX7U=@ietf.org
X-Gm-Message-State: AOJu0YzNbqPJemnGrpz+UF1LYQ6bwJaXSzDkEl7DpcDri/NG4G1E65xZ laUptANZ7l5pRg+D3KSkM5PzTA3klAo6ZWJzrCymJQX/t32TIotxy9vuWOdVpK0rI2rsPsfqTX2 fes+BEKssHi+b+ZvC0WxXPGyO67lpeFzixVJhNn1TQNCIQFDnpVSkVM2ceQ==
X-Gm-Gg: ATEYQzxi/+0qvIfElzc1fOtQB6XvNRpZtN1sXW6TMdFLY7M8ScPb8C57up0SXabSjMg MiqXch4SjIIDQDx6uUAng+YcJsPSrVPD6S7/gVjNAflppMAARU6InemAIrgKmGAJ3idGrcesHyK WzFsz4RIzYaXMaGI78Wxr2XxUdHQhS2qItcJlieYHYu80b/gQboyUoRlSlsaqtnJT8BjgJ/pa6s DB8CsLNVFUQUzdFRdz65DPY9NxQTRahQarNpg+gLt95bbapQle9UC5N3SIhg4Ehlw3n1ePUWajA PvZEaiafq8srcL3SVA7kLEkY5ON/uPXntXfCfxt3ctWj/LzKoH4H96HLLw==
X-Received: by 2002:a05:6512:1381:b0:5a1:d0d:1ba9 with SMTP id 2adb3069b0e04-5a2ab7e8cbbmr1690872e87.7.1774632778121; Fri, 27 Mar 2026 10:32:58 -0700 (PDT)
MIME-Version: 1.0
References: <CAMjbhoV1d6Ayfei=GaG8NnFTcWUq8sZ-u5oCM8xp2wXAQRQdbw@mail.gmail.com> <PH3PPFA3FE8A23FBA824621E615DA42D2B0C157A@PH3PPFA3FE8A23F.namprd11.prod.outlook.com>
In-Reply-To: <PH3PPFA3FE8A23FBA824621E615DA42D2B0C157A@PH3PPFA3FE8A23F.namprd11.prod.outlook.com>
From: Bas Westerbaan <bas@cloudflare.com>
Date: Fri, 27 Mar 2026 18:32:45 +0100
X-Gm-Features: AQROBzAAC4iKIFOp8-J9USFivnbvhgroe8ykuPKIAUPvzcE-bRtJ-eTSI-qE444
Message-ID: <CAMjbhoVdtvNYUA_Ucdv-R+6f+y7Sr63RnFG5B==i4oVMp7LHug@mail.gmail.com>
To: "Scott Fluhrer (sfluhrer)" <sfluhrer=40cisco.com@dmarc.ietf.org>
Content-Type: multipart/alternative; boundary="00000000000058de67064e04e440"
Message-ID-Hash: RESCW2F3B7TBX6VERRSEKS3DQXMP6ODO
X-Message-ID-Hash: RESCW2F3B7TBX6VERRSEKS3DQXMP6ODO
X-MailFrom: bas@cloudflare.com
X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header
CC: Bas Westerbaan <bas=40cloudflare.com@dmarc.ietf.org>, "plants@ietf.org" <plants@ietf.org>
X-Mailman-Version: 3.3.9rc6
Precedence: list
Subject: [Plants] Re: Higher forgery resistance almost for free?
List-Id: "PKI, Logs, And Tree Signatures" <plants.ietf.org>
Archived-At: <https://mailarchive.ietf.org/arch/msg/plants/92VUITFLqFv-1eYaTCXQiLPuXkY>
List-Archive: <https://mailarchive.ietf.org/arch/browse/plants>
List-Help: <mailto:plants-request@ietf.org?subject=help>
List-Owner: <mailto:plants-owner@ietf.org>
List-Post: <mailto:plants@ietf.org>
List-Subscribe: <mailto:plants-join@ietf.org>
List-Unsubscribe: <mailto:plants-leave@ietf.org>
By the way, I agree with the randomizer idea (and also don't forget to > include the Merkle tree position when you hash together two nodes - a cheap > way to prevent multitarget attacks). > An earlier draft did, but the current one doesn't as it's based on plain rfc6962 CT-log trees. Indeed there is a multi-target attack there: say, find some x such that H_internal(H_leaf(leaf), x) matches an existing internal node. Then we can create a fake inclusion proof, of course updating the claimed index appropriately. That's similarly in the 256 - lg(number of certificates in tree) regime as the multi-target attack on the SPKI hash. Some notes here: This would be a surprisingly short authentication path, and a verifier could detect it. That doesn't help much: restricting ourselves to only targeting the lower nodes just removes half the targets. Hashing the leaf index into the leaf would also prevent this. Still, the other multi-target attack I mentioned still exists. Best, Bas > > > ------------------------------ > *From:* Bas Westerbaan <bas=40cloudflare.com@dmarc.ietf.org> > *Sent:* Friday, March 27, 2026 12:10 PM > *To:* plants@ietf.org <plants@ietf.org> > *Subject:* [Plants] Higher forgery resistance almost for free? > > Hey all, > > For the certificate transparency use case we need to make sure that a > Certificate Authority can't issue a certificate without it being public. We > don't want the CA to able to issue two completely different certificates, > one harmless and one malicious at the same leaf. That requires > collision resistance of the hash. Hence we use SHA-256 to gain 128-bit of > transparency security. > > A 256-bit hash in Merkle trees can give much more than 128-bit forgery > resistance—256 bits even. This is well known: CNSA 2 is even happy with LMS > using SHA-256 truncated to 192 bits, which of course only achieves 192-bit > security. > > So MTC as-is has 256-bit forgery resistance? Not quite: we need to make > some changes, and there are some caveats. > > In the current draft, the leafs (TBSCertificateLogEntry) are mostly > predictable by an attacker. Thus with 128-bit work, an attacker can find a > collision: a harmless TBSCertificateLogEntry which it'll ask the CA to > issue which has the same hash as a nefarious TBSCertificateLogEntry. [1] > > The standard way to solve this is to make the leaf unpredictable to the > attacker, by including a CA-picked random value (randomizer) in each leaf. > [2] That'll boost the forgery resistance above 192 bits and well along to > 256-bits [3]. > > The downside is that we need to add that 32-byte randomizer in each > certificate. > > Worth it? > > I would say so. > > Best, > > Bas > > > > > > [1] There are some minor hurdles: it'll need to guess the serial number > correctly. And it'll need some immaterial field to vary to create attempts > for the colission. Oh, and of course 128-bit work, but we're suspending > disbelief for a moment. > > [2] Add 32-byte randomizer field in MerkleTreeCertEntry and MTCProof. > > [3] There is a multi-target attack against subjectPublicKeyInfoHash. > Suppose there are 2^30 leafs with the same algorithm in > subjectPublicKeyInfo. Then we only need to try 2^226 randomly generated > subjectPublicKeyInfos to find a second preimage with some leaf. The > standard way to thwart this is to add an * address* (leaf index) to the > hash. That's not ideal, as plain SHA-256(subjectPublicKeyInfo) is quite > standard now. The randomizer acts as an address for the leafs themselves. > There is still an issue though. > > Even with addresses, SHA-256 isn't "distinct-function multi-target > second-primage resistant" (DM-SPR) because it has a small internal state. > This allows for a clever multi-target attack negating the addresses by > finding successive colissions on the internal state, which was pointed out > by Antonov, and improved by Perlner, Kelsey, and Cooper. See section 3.3 of > ( https://eprint.iacr.org/2022/1061.pdf ). The attack requires room in > the message for the logarithmically many collision values after the > address. It'll depend on the algorithm whether that's feasable for the > subjectPublicKeyInfo, and we can remove that room by moving > subjectPublicKeyHash earlier in TBSCertificateLogEntry. The rigorous > solution is not to use SHA-256, but a hash that is DM-SPR, such as > SHAKE-256. But is that worth it? With a trillion certificates the attack is > still in the order of 217-bit work. > > _______________________________________________ > Plants mailing list -- plants@ietf.org > To unsubscribe send an email to plants-leave@ietf.org >
- [Plants] Higher forgery resistance almost for fre… Bas Westerbaan
- [Plants] Re: Higher forgery resistance almost for… Filippo Valsorda
- [Plants] Re: Higher forgery resistance almost for… Scott Fluhrer (sfluhrer)
- [Plants] Re: Higher forgery resistance almost for… Filippo Valsorda
- [Plants] Re: Higher forgery resistance almost for… Bas Westerbaan
- [Plants] Re: Higher forgery resistance almost for… cwwynn@uwe.nsa.gov
- [Plants] Re: Higher forgery resistance almost for… David Benjamin
- [Plants] Re: Higher forgery resistance almost for… David Benjamin
- [Plants] Re: Higher forgery resistance almost for… cwwynn@uwe.nsa.gov
- [Plants] Re: Higher forgery resistance almost for… Russ Housley
- [Plants] Re: Higher forgery resistance almost for… Bas Westerbaan
- [Plants] Re: Higher forgery resistance almost for… Viktor Dukhovni
- [Plants] Re: Higher forgery resistance almost for… Bas Westerbaan
- [Plants] Re: Higher forgery resistance almost for… Michael Richardson
- [Plants] Re: Higher forgery resistance almost for… Bas Westerbaan
- [Plants] Re: Higher forgery resistance almost for… Bas Westerbaan
- [Plants] Re: Higher forgery resistance almost for… Filippo Valsorda
- [Plants] Re: Higher forgery resistance almost for… Brendan McMillion
- [Plants] Re: Higher forgery resistance almost for… Andrew Ayer
- [Plants] Re: Higher forgery resistance almost for… Bas Westerbaan
- [Plants] Re: Higher forgery resistance almost for… David Benjamin
- [Plants] Re: Higher forgery resistance almost for… Amir Herzberg
- [Plants] Re: Higher forgery resistance almost for… Bas Westerbaan
- [Plants] Re: Higher forgery resistance almost for… Amir Herzberg
- [Plants] Re: Higher forgery resistance almost for… Chase Abbott
- [Plants] Re: Higher forgery resistance almost for… Bas Westerbaan
- [Plants] Re: Higher forgery resistance almost for… David Benjamin
- [Plants] Re: Higher forgery resistance almost for… Andreas Hülsing