Re: [CFRG] RGLC on draft-irtf-cfrg-frost-11

Armando Faz <armfazh@cloudflare.com> Tue, 29 November 2022 16:41 UTC

Return-Path: <armfazh@cloudflare.com>
X-Original-To: cfrg@ietfa.amsl.com
Delivered-To: cfrg@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 85820C14F5E1 for <cfrg@ietfa.amsl.com>; Tue, 29 Nov 2022 08:41:44 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.097
X-Spam-Level:
X-Spam-Status: No, score=-2.097 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, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_ZEN_BLOCKED_OPENDNS=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001, URIBL_DBL_BLOCKED_OPENDNS=0.001, URIBL_ZEN_BLOCKED_OPENDNS=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=cloudflare.com
Received: from mail.ietf.org ([50.223.129.194]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id b4Br13kaVxld for <cfrg@ietfa.amsl.com>; Tue, 29 Nov 2022 08:41:40 -0800 (PST)
Received: from mail-yb1-xb29.google.com (mail-yb1-xb29.google.com [IPv6:2607:f8b0:4864:20::b29]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 96E32C14F72B for <cfrg@irtf.org>; Tue, 29 Nov 2022 08:40:53 -0800 (PST)
Received: by mail-yb1-xb29.google.com with SMTP id o127so2700466yba.5 for <cfrg@irtf.org>; Tue, 29 Nov 2022 08:40:53 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cloudflare.com; s=google; h=cc:to:subject:message-id:date:from:mime-version:from:to:cc:subject :date:message-id:reply-to; bh=kUZelpPNkJ1ea5o2mp9tOk0DEIbGJfSBxVFqpfucY64=; b=C+DEwHajw011Qv5kVe/fdHPNQ4Sblq1H0uwbyyMly/u5ram89GGy5e2X6To0lOrbIN BU3EZnazXvGDu1lKrg9O/1IDwmbZgWW1Db0UbIVMEVHH44/C1nDbpjvBHT3xBK697vL+ rz4lYr0RHvzwn9MNL0LtYpdTCTZA1kU/jjSeo=
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:mime-version:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=kUZelpPNkJ1ea5o2mp9tOk0DEIbGJfSBxVFqpfucY64=; b=mbvIRjILJTa1vl3wKVE+qSO2ZXkDSOm4uD22gHoIaU1L5Rgts852TIDIP/aZNBxICH Fo81ZKLKiVt5pR35Kx8ff1Ic4pLXYKjHRWUs6RYHLAjSw/Dz8TuCus1PGS8tuTFN+8Zp I2hiCzBvRN9eVkQIZV4xzD/sTAczRdhptddFwPi6EU4LZUs21KlWepKozow2Umv3lWkY wmwdR5fYaaFy3r71bYO4j2vhvmOXjuP5c8zNZe9PnZUo2foYNtEuQyqX1unItk7Esedy W7WL5QpEJchmxA1sEDBgiiYrbu7ZyodstAGR8gq+yCySfz27AE552ZceKHrvxRTs51rR obNQ==
X-Gm-Message-State: ANoB5pnAzR4+ncoWMs81MEGE/G0GaI6enww+PWZLLp7YSFQ1Gw1YJ4bd vf1sQ8CWva5O/jrnUGqg2i/WBN0T6XZES6QSL6yVn2cPT7ZhVA==
X-Google-Smtp-Source: AA0mqf6JeprYvnfV07Vjw7JzJ10cRvqeo3avB8Obkxv/VR+FphFCErw/vsV/Tg9WC6mLVgQdLT3xe41vHaxhlTWgb1g=
X-Received: by 2002:a25:cacf:0:b0:6f4:3ced:d718 with SMTP id a198-20020a25cacf000000b006f43cedd718mr17179834ybg.180.1669740052538; Tue, 29 Nov 2022 08:40:52 -0800 (PST)
MIME-Version: 1.0
From: Armando Faz <armfazh@cloudflare.com>
Date: Tue, 29 Nov 2022 08:39:00 -0800
Message-ID: <CABZxKYmJGW-fe8VQ2FFN3_WVcTotkRDjYBrV_GZXWSVKrwAo+w@mail.gmail.com>
To: cfrg-chairs@ietf.org
Cc: IRTF CFRG <cfrg@irtf.org>, draft-irtf-cfrg-frost@ietf.org
Content-Type: text/plain; charset="UTF-8"
Archived-At: <https://mailarchive.ietf.org/arch/msg/cfrg/HzKUEO_2ga-a4gthw_ioDWixUSs>
Subject: Re: [CFRG] RGLC on draft-irtf-cfrg-frost-11
X-BeenThere: cfrg@irtf.org
X-Mailman-Version: 2.1.39
Precedence: list
List-Id: Crypto Forum Research Group <cfrg.irtf.org>
List-Unsubscribe: <https://www.irtf.org/mailman/options/cfrg>, <mailto:cfrg-request@irtf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/cfrg/>
List-Post: <mailto:cfrg@irtf.org>
List-Help: <mailto:cfrg-request@irtf.org?subject=help>
List-Subscribe: <https://www.irtf.org/mailman/listinfo/cfrg>, <mailto:cfrg-request@irtf.org?subject=subscribe>
X-List-Received-Date: Tue, 29 Nov 2022 16:41:44 -0000

Hi CFRG and FROST authors,

I have reviewed draft-irtf-cfrg-frost-11  Commit: 113bd5a74,
I have implemented FROST ciphersuites P-256 and ristretto255 in Go
CIRCL library (https://github.com/cloudflare/circl/pull/349), test
vectors match. But I haven't verified those for EdDSA.

Here are some comments:

#1
- we introduce separate domain-separated hashes
+ we introduce domain-separated hashes

#2
- to Scalar elements of the prime-order group scalar field
+ to Scalar elements of the prime-order group.

#3
- These sections describes these operations in more detail.
+ These sections describe these operations in more detail.

Like this one, there are a few other errors that can be easily catched
by a spellchecker.

#4
- A polynomial of maximum degree t+1 is represented as a list of t coefficients
+ A polynomial of maximum degree t is represented as a list of t+1 coefficients

#5
derive_lagrange_coefficient
I think it is more accurate to name this function as
"lagrange_basis_at_0"  since the Lagrange basis is defined as  l_i(x)
= \prod i\neq j (x-x_j)/(x_i-x_j), which must be evaluated at 0.

#6
In Section 5. (without reading the Appendix) it is not clear what is
the (mathematical) relation, if any, between the key shares (sk_i),
and the signing key (sk).

#7
Is this statement true with respect to EdDSA as in RFC8032?

"FROST produces signatures that are indistinguishable from those
produced with a single participant using a signing key s with
corresponding public key PK, where s is a Scalar value and PK =
G.ScalarBaseMult(s)."

Let
  s0 = sign(m,s,pk) using RFC8032;
  s1 = threshold_sign(m,s,pk) using FROST.

any s1 can be distinguished as a FROST signature as is expected to be
different from s0 because FROST signing is not deterministic.

#8
- The nonce values produced by this function MUST NOT be reused in
more than one invocation of FROST, and it MUST be generated from a
source of secure randomness.
+ The nonce values produced by this function MUST NOT be reused in
more than one invocation of FROST, and they MUST be generated from a
source of secure randomness.

#9
- Moreover, each participant MUST ensure that their identifier appears
in commitment_list along with their commitment from the first round.
+ Moreover, each participant MUST ensure that its identifier and the
commitments  (from the first round) appear in the commitment_list.

- signing set than the the aggregated response
+ signing set than the aggregated response

#10
The alternative check [S]B = R + [k]A' is not safe or interoperable in practice.

I understand why it is not interoperable, but why is it not safe? A
comment about these two restrictions is appreciated.

Also, unify name of variables in the verification equation: [S]B = R + [k]A'

#11
For FROST(Ed448, SHAKE256) ciphersuite:

SerializeScalar(s): Implemented by outputting the little-endian
48-byte encoding of the Scalar value.
DeserializeScalar(buf): Implemented by attempting to deserialize a
Scalar from a little-endian 48-byte string.

Scalars are 57-byte strings.

#12
For FROST(Ed448, SHAKE256) ciphersuite:
Ed448 allows specifying a context string, and the FROST ciphersuite
vanishes the context string. why?
Note it is still possible to include the Ed448 context string in H2,
so it makes this ciphersuite fully compatible with RFC8032.

#13
"This includes checking that the coordinates of the resulting point
are in the correct range, that the point is on the curve, and that the
point is not the point at infinity. Additionally, this function
validates that the resulting element is not the group identity
element."

It looks like the second sentence is redundant.

#14
For secp256r1:
partial public-key validation as defined in section 5.6.2.3.4 of [KEYAGREEMENT].

For secp256k1:
partial public-key validation as defined in section 3.2.2.1 of [SEC1].

Are these validation methods different? If not, why make a distinction?

#15
- H(contextString \|\| "pre-hash" \|\| m)
+ H(contextString || "pre-hash" || m)

#16
- create secret shares of s, denoted s_i for i = 0, ...,
MAX_PARTICIPANTS, to be sent to all MAX_PARTICIPANTS participants.
+ create secret shares of s, denoted s_i for i = 1, ...,
MAX_PARTICIPANTS, to be sent to all MAX_PARTICIPANTS participants.

#17
...participants MUST abort if they do not have the same view of vss_commitment.

In practice, how this checking is performed (without adding a
communication round)?

#18
- that any cooperating subset of MIN_PARTICIPANTS participants
+ that any cooperating subset of at least MIN_PARTICIPANTS participants

#19
"invalid parameters", if MIN_PARTICIPANTS > MAX_PARTICIPANTS or if
MIN_PARTICIPANTS is less than 2

This prevents splitting the secret between two entities, is this correct?

Also note that in the Test Vector Section
MIN_PARTICIPANTS = 2

#20
Section 4.2.1 is only useful for App C. So it can be moved there.

#21
"points, a set of t distinct points on a polynomial f"

Note that (1,2) != (1,3), these points are different, but they are an
invalid input to polynomial_interpolation function

#22
Adding references to Feldman and Shamir secret sharing.

#23
Outputs: 1 if sk_i is valid, and 0 otherwise
Better to return true/false?

#24
In verify_signature_share, at which point the Coordinator learns the
PK_i from participants?

#25
In the VSS section:
"We now define how the Coordinator and participants can derive group
info, which is an input into the FROST signing protocol."

If the group info is the input of the FROST protocol, then VSS is a dependency?

#26
Appendix D is equal to Section 4.3 of VOPRF. Should this section be
replaced by reference or by a verbatim copy of Sec 4.3?

https://datatracker.ietf.org/doc/html/draft-irtf-cfrg-voprf#section-4.3

#27

Exponents do not render ok. (*we should fix this also in VOPRF draft)

p - 2<sup>b</sup>| < 2<sup>(b/2)</sup>,

The ASCII version looks ok:  | p - 2^b | < 2^(b/2)

-- 
Armando Faz
Cloudflare Inc.