[Plants] Re: An independent Rust implementation of the -07 formats, interop-tested against demo/

Angel <angeltoranzoportela@gmail.com> Fri, 02 October 2026 08:38 UTC

Received: from mail-oo2-x0f.google.com (mail-oo2-x0f.google.com [IPv6:2607:f8b0:4864:31::f]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by mx.ietf.org (Postfix) with ESMTPS id 68A8942 for <plants@ietf.org>; Fri, 02 Oct 2026 08:38:51 +0000 (UTC)
Authentication-Results: mx.ietf.org; dkim=pass header.d=gmail.com header.s=20251104 header.b=nVk6ePtp; spf=pass (mx.ietf.org: domain of angeltoranzoportela@gmail.com designates 2607:f8b0:4864:31::f as permitted sender) smtp.mailfrom=angeltoranzoportela@gmail.com; dmarc=pass (policy=none) header.from=gmail.com; arc=pass ("google.com:s=arc-20260327:i=1")
Received: by mail-oo2-x0f.google.com with SMTP id 006d021491bc7-6df14b93e47so328085eaf.2 for <plants@ietf.org>; Fri, 02 Oct 2026 01:38:51 -0700 (PDT)
ARC-Seal: i=1; a=rsa-sha256; t=1790930330; cv=none; d=google.com; s=arc-20260327; b=EnL6ESCpBRHutMrCY1X6RsYuUCG4whbA7c4sOvpa0w7As+nBjV4ktGObvBl7AYeS8s ECgYdjnERXLy/G1xpxIMSb6zPjNtlbqTMc8z3QLA/pKxnJoS71+aGWtHYszoSxkrYu5i NQSENYf5v4lYRzDNPLijjxhQHOb4Ie8FDsNI9KpfuyQowt6vUdPZZlrWexvwUrMXqNG3 u3SVrc7yll+00cR7qiqaXw+1ZRXM0P20FxbIL+irrAc71fx9OX2Gv7yHmG5I0m9VC05/ XVcCdwPW2TobybVg/RrH35lo0tJGpXOOTxZLYvrgGhqhyY1YNBjsWiFZQW8HqpmP5FWQ A5yQ==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20260327; h=content-transfer-encoding:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=6bqZecx0IRJUW3kRkikmj/Q+tsGBGJS3gDkcWC1T0h4=; fh=sBcTFEJY+T6D2ut3P6DYkXFMfKEvdIpHeUYz5bx6baE=; b=crYVTSI/k01sf9FK3o/SfwwR5LDC+UPUthKsQ8n8XL935x4I7LxKeaec5PHp4RvzIr 2GEd9C1hxpjxu8HY23iQ1Q+yopDT0k6lF8rvpea/PoQuknQ4Zrcen5zMEQ0U/vzh8FT5 qamHVKl1wxyZQXc85mY/QJ2Yok5p3a0OexiIAZwGd3QHgAPr1wnNIDMp5hkuO2skkjVq pLkYZtwV7SSiCBk2NrqXzkJzBVZGFZ+59mgjdnsJZ5WvgeF7TAL9xVP6nXvvwe20lk1t jNZJDFds0/QwIWqy689UEzGa6q45NvwMm5ZeGDK+HT/aU+m8pTvxC5y0zVBEn0iSRPpH 40Mw==; darn=ietf.org
ARC-Authentication-Results: i=1; mx.google.com; arc=none
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1790930330; x=1791535130; darn=ietf.org; h=content-transfer-encoding:content-type:to:subject:message-id:date :from:in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to:content-type; bh=6bqZecx0IRJUW3kRkikmj/Q+tsGBGJS3gDkcWC1T0h4=; b=nVk6ePtpeCUDfI7p2hOpMK78KhDqeuA1y1NnHkxVbzBwqXexz6dV/3hwOTD1HuZDPW FgTskrydi/fbEdiDRad1Lc/g4KxGoAhTsGW34f8NIuxa5cOsRIgRd1opGksenSig5w/a Ja1TbptR2hVhO1MCe6p/aOWKJ7tMC9HuqRy6pe0gW9f4ntoeGbdaAE820fiMy+7/fX4G x7Zf7DTdoTaBFq+l7g5f4tfwj12VrF2or9tq80SPhQ3sWJvYf+G33RFhUJrY32tVbW9Y SQ5BtS25Hrdl2Lj18lswTMmfS/elqNTKapFT8xSMouMuNjUila6cUiKlooHRuaJ9aQzy c5pA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1790930330; x=1791535130; h=content-transfer-encoding:content-type: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:content-type; bh=6bqZecx0IRJUW3kRkikmj/Q+tsGBGJS3gDkcWC1T0h4=; b=YzVZQ1we5oecc4sHtw3lbSjWGtw8dNekGTpNbaDKoQSuk4Or/gzPs+pnCT2F7hQ+Z6 w+qxNKB+V3CphclkLWm4DAp9jYCf0+A/2F2SMqOVTaZM8v0kgbs2xlH0r84TAhjbN+gH ewRNynuQ0t9krIQp9x0vjnpaklG+mwFwXDg5P7BQ18F/EzFw/9ogDjULTzQyIaO6P0Po tBgo9evzt4HZV4LgbFOme5yxyT/8rHp9trZudEBaAmU6hb4GPj74GhzkV3j9qgeU/XEq 9TnjXItM2iaiWqredM/fYrwGsrUTBLbcwQXxNlxxD07qoF9Ilf3HjJ6Cst6HSCBoIXNr AWng==
X-Gm-Message-State: AFuF++m37Xa6LD/lxLjiRZsULhaSAy2ub/Qg/WSk/d2TUiWpU5GB2eg+ 64OUA8utWuSeDx2berIc2hRNACG8ho79u9D/+XgZgWId1IGnV9WjNgZ/6mh2WtPuwOON4LTUC0u gt47NuvJJFFZR/Gsrile3omDMko3MXXH4Zm6Y
X-Gm-Gg: AYBFou1zgFS2GGCqjSHTiVNHrQAPq0p2+nDOM0qDN6WRLD6ggAWRzjFaq9fn1/6nLEN WQKgLheIPkF4B5KIfs9puVcblSjHqNOGt5f/uRU2wIV+W90w6K6mKSh7z0BhqaAnDGLghgJiTff yv91uBiOD5jKAIU+kTV81V5xRpI4N8rkgXYRe2m2mjdAuSLTAroK2kdmkPJdAMySdzsi+brThf3 tODYDckeUm/mXQT/Zj6jkfQGXe/iiNBSUrrXmKGnXyalbVHrhYv9PdwzoEgZvaq/jH2ceTaGexO lx5E37n2fqTvzedgctJfY6CL77V1XhA6P7DHgSuiWV9ZaswfljzBMoxqdcvSzbKHWbOo6y/mJNe ZUq03Mf3E/54=
X-Received: by 2002:a4a:e845:0:b0:6d8:d121:a978 with SMTP id 006d021491bc7-6df330995eemr1556779eaf.19.1790930330532; Fri, 02 Oct 2026 01:38:50 -0700 (PDT)
MIME-Version: 1.0
References: <CANetTsm3iVV7L7A57iJiEknAJBV37E8e=_cvo+N4K8=FS7JW+g@mail.gmail.com>
In-Reply-To: <CANetTsm3iVV7L7A57iJiEknAJBV37E8e=_cvo+N4K8=FS7JW+g@mail.gmail.com>
From: Angel <angeltoranzoportela@gmail.com>
Date: Fri, 02 Oct 2026 10:38:39 +0200
X-Gm-Features: AclHuK-RLoY0P2rv7U7HnNEWmDK6fqNzc-0SSR2OeL8qgMziAgp0j-TCGilWwmA
Message-ID: <CANetTsnUja8bG+1dgjbeP1+biyXTXc8XC7T4=Sp2SJYzMS6TuQ@mail.gmail.com>
To: plants@ietf.org
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Spamd-Bar: --
Message-ID-Hash: HF32IHWOGNAAW6A42HAUWC63BXJBEJ7N
X-Message-ID-Hash: HF32IHWOGNAAW6A42HAUWC63BXJBEJ7N
X-MailFrom: angeltoranzoportela@gmail.com
X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header
X-Mailman-Version: 3.3.10
Precedence: list
Subject: [Plants] Re: An independent Rust implementation of the -07 formats, interop-tested against demo/
List-Id: "PKI, Logs, And Tree Signatures" <plants.ietf.org>
Archived-At: <https://mailarchive.ietf.org/arch/msg/plants/TrQxn5Wp0CQ1rM3CRN_aXFRkqAY>
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>

Hi all,

A short follow-up. mtc-core is now also measured against OpenSSL's MTC pull
request (openssl/openssl#33014, at ecf0476) and Bob Beck's mtc (c6cdfe2):
certificates in both directions, a TLS 1.3 handshake through s_server and
s_client, and OpenSSL's test/mtc corpus. All verdicts agree except one, and
that one is a question for the draft rather than a bug.

test/mtc/mtc-landmark-1-iana-alg.pem is a -06 landmark certificate with the
IANA id-alg-mtcProof (1.3.6.1.5.5.7.6.67) in both signature fields, while its
issuer keeps the experimental trust anchor ID attribute
(1.3.6.1.4.1.44363.47.3). OpenSSL and mtc accept it, recognising each field on
its own. mtc-core refuses it: it reads the issuer with the attribute of the
OID set that the signature algorithm names, one set per certificate. No CA I
have measured writes this shape, and the proof is unaffected, since the log
entry omits the signature algorithm.

During the OID transition, should a relying party accept a certificate that
mixes the IANA and the experimental OIDs, or require one set per certificate?
If the answer is to accept, I will change mtc-core; if not, the fixture might
want the IANA issuer attribute too.

Details: https://github.com/atoranzo/mtc-core (AUDIT.md §19 to §22).

Thanks,
Ángel

El mié, 30 sept 2026 a las 16:02, Angel
(<angeltoranzoportela@gmail.com>) escribió:
>
> Hi all,
>
> I'd like to report an independent implementation of the current
> draft-ietf-plants-merkle-tree-certs formats and the results of testing it
> against the reference implementation in the working group's repository.
>
> What it is: mtc-core, <https://github.com/atoranzo/mtc-core>, MIT OR
> Apache-2.0. It implements the issuance log (RFC 9162 MTH over SHA-256,
> subtrees, inclusion and consistency proofs), MTCLogEntry /
> TBSCertificateLogEntry, the CosignedMessage and subtree signatures with
> ML-DSA (44/65/87), MTCProof and the certificate, the landmark sequence, the
> CA flow (log, checkpoint, covering subtrees, cosignatures, standalone and
> landmark-relative certificates), the CA certificate with the
> MTCCertificationAuthority extension (unsigned, RFC 9925), and the relying
> party's verification procedure including the single-pass entry hash. It
> targets the working repository as of 2026-09-29, i.e. the OIDs
> draft_oids.md assigns to plants-07 (id-alg-mtcProof = ...47.5).
>
> What was tested:
>
> - The four accumulated test vectors (65,058 cases, trees up to 130 leaves)
>   and the large subtree vectors (2^48-1, 2^63-1, 2^64-1 leaves).
> - Against demo/ at commit 99097c9e (Go 1.27.1), in both directions, with
>   negatives: the 26 certificates demo generates from its own mtc.json
>   (plants-07) get the same 26 verdicts from my verifier as from
>   `demo verify` (21 OK, 5 FAIL, each negative failing for the reason it was
>   built for); 9 certificates from my CA (4 deliberately broken) get the
>   expected verdicts from `demo verify`, with my CA certificate and with
>   demo's own (both CAs use demo's ML-DSA-44 test seed for 32473.1, so key
>   generation and signatures were compared byte for byte); and demo's log of
>   2122 entries rebuilt from its entry tiles reproduces its checkpoint root.
>   The procedure and script are in the repository (interop/), and the run
>   is recorded in AUDIT.md.
>
> If a documented run between two independent codebases is useful for the
> working group's interoperability milestone, everything above is
> reproducible from the repository with the commands in interop/README.md.
>
> Two things I noticed in demo/, filed as issues #341 and #342: the
> checkpoint's signature lines carry a bare subtree signature with timestamp
> zero rather than a tlog-cosignature timestamped_signature, which mtc-tlog
> seems to require; and the sample policy.txt's trusted-subtree hashes do not
> match the output of the shipped mtc.json, so the demo rejects its own
> landmark-relative certificates with the sample policy.
>
> What it is not: it is not audited; cosigners with ECDSA or Ed25519 keys are
> not verified (their cosignatures are ignored); the relying-party policy is
> the minimal "the CA plus a fixed set of cosigners", with no groups; the log
> is not persisted and there is no ACME, CSR parsing or witness client; it is
> not measured at scale. Interoperability is measured against one
> implementation only.
>
> Provenance: the code and prose were written with AI assistance; GENAI.md
> in the repository says how it was used and AUDIT.md records each verified
> change with its counters. I am the only author and accountable for it.
>
> I'm aware of the Note Well. Corrections and questions very welcome,
> especially on the two issues above.
>
> Ángel Toranzo Portela