Re: [Cfrg] I-D Action: draft-irtf-cfrg-hash-to-curve-07.txt

"Riad S. Wahby" <rsw@jfet.org> Tue, 28 April 2020 16:31 UTC

Return-Path: <rswatjfet.org@gmail.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 D64533A08E5 for <cfrg@ietfa.amsl.com>; Tue, 28 Apr 2020 09:31:19 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.218
X-Spam-Level:
X-Spam-Status: No, score=-2.218 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, FREEMAIL_FORGED_FROMDOMAIN=0.25, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.25, RCVD_IN_MSPIKE_H2=-0.82, SPF_HELO_NONE=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 Z_luuh1CwtyV for <cfrg@ietfa.amsl.com>; Tue, 28 Apr 2020 09:31:18 -0700 (PDT)
Received: from mail-pf1-f175.google.com (mail-pf1-f175.google.com [209.85.210.175]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 8E2ED3A08E3 for <cfrg@irtf.org>; Tue, 28 Apr 2020 09:31:18 -0700 (PDT)
Received: by mail-pf1-f175.google.com with SMTP id 18so9699351pfv.8 for <cfrg@irtf.org>; Tue, 28 Apr 2020 09:31:18 -0700 (PDT)
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to; bh=XsYQQXzaVTvaLTYF0K4XQdv/yROvUH6JiPOC4u/qMEQ=; b=CHsaOLjMEcKgcWxzDYObtCntiiGGVLT/z207uPxg6tEJsgewkPQqxpzl+MtcaxT5OT ZqOV4jS52U/fRQdWgUIc/hdmg4mGGzJ0mDHiSYWkGvvWv2UfIrnU7NEM6nY0+FIe4FPa mBv05CgsdH4zoIkhp75qOFFZRAbouh9i0/PTps150hTliOn3fVSllGAkSonnW0supSd7 tNxbjuuHp9TxumPklX/JJo3YncqkLcwwKZqDRx1E5FNhCPt8qUX2hJEXHjl/hAryWGBG LuluxJrVzqUWbt9qyWTn06/V0PCFhJm+YvsXdnywfIlGzcS8G1Ztg6a8Rd0Oia6ZkkVz 1wmQ==
X-Gm-Message-State: AGi0PuYLS+KIBBraSvZu2bUGYHjIXp3IfZ2pKvXdTRSGruT7UjCAOg8e AzVA+NVRZErLlVY+KUSgJIGrArq2
X-Google-Smtp-Source: APiQypIfK6uMU/fTtoSwrty1BQZzvRAKLXGlyBpnH3ZJGUayu+YH2cCxOqSq8h50BDPstimJzRAygw==
X-Received: by 2002:a63:e60a:: with SMTP id g10mr12542404pgh.51.1588091477996; Tue, 28 Apr 2020 09:31:17 -0700 (PDT)
Received: from localhost (graviton.stanford.edu. [171.67.76.22]) by smtp.gmail.com with ESMTPSA id x12sm912282pfo.62.2020.04.28.09.31.15 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 28 Apr 2020 09:31:16 -0700 (PDT)
Date: Tue, 28 Apr 2020 09:31:15 -0700
From: "Riad S. Wahby" <rsw@jfet.org>
To: Björn Haase <bjoern.m.haase@web.de>
Cc: cfrg@irtf.org
Message-ID: <20200428163115.gbsmbwul6ykch734@muon>
References: <158800880970.26618.7101783350063977264@ietfa.amsl.com> <ab4265a0-bbb6-bf79-3561-c8225659b7f7@web.de>
MIME-Version: 1.0
Content-Type: text/plain; charset="iso-8859-1"
Content-Disposition: inline
Content-Transfer-Encoding: 8bit
In-Reply-To: <ab4265a0-bbb6-bf79-3561-c8225659b7f7@web.de>
Archived-At: <https://mailarchive.ietf.org/arch/msg/cfrg/f8Pj4iklz1gjm5ZIYgAEUCYMqYs>
Subject: Re: [Cfrg] I-D Action: draft-irtf-cfrg-hash-to-curve-07.txt
X-BeenThere: cfrg@irtf.org
X-Mailman-Version: 2.1.29
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, 28 Apr 2020 16:31:20 -0000

Hi Björn,

Björn Haase <bjoern.m.haase@web.de> wrote:
> Iwould understand a zero-padding that would first insert some
> information that should be maintained confidential and a Z_pad string
> that fills up the remaining rest of the input block of the hash function
> with zeros. However, I did not get the point, why filling the first
> block with zeros should provide any advantage.

Good question! The answer is that this zero block allows one to prove
this construction indifferentiable from a random oracle when the M-D
compression function is modeled as a random oracle (which is effectively
the strongest statement we could hope for in this context).

In particular, prepending a block of zeros instantiates an NMAC
construction, as described in Section 3.5 of the following paper
(the full version linked below gives a security proof).

    Coron, Dodis, Malinaud, and Puniya. "Merkle-Damgaard revisited:
    How to construct a hash function." Proc. CRYPTO 2005.
    https://cs.nyu.edu/~dodis/ps/merkle.pdf

This is discussed in the "Security Considerations" section of the
document. I will go back and double check that Section 5 makes
a clear forward ref to that discussion.

Thanks for the feedback and take care,

-=rsw