You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The document currently doesn't note input limits for hash_to_field, and I'm wondering if we should consider adding these limits. HPKE has similar limits for some of its functions.
The limit is ultimately defined by the underlying hash function, which, for hash_to_field built on expand_message_xmd is an MD-style hash with an explicit limit, but for hash_to_field built on expand_message_xof is a XOF-based construction with no explicit limit. (FIPS 202 says that the message is a "bit string of any length that is the input to a SHA-3 function.")
In practice, hitting these limits is unlikely to happen, since SHA-256 and SHA-512 (and SHA-384) have limits of 2^61 and 2^125 (2^125), respectively. However, I wonder if we should note this for expand_message_xmd.
Since the bounds are enormous, maybe it makes sense just to put in a quick reminder that one should respect the input size limit, but not go so far as to give an expression for it. Or maybe not. Not clear to me...
Yeah, at a minimum, noting the limit exists seems necessary. We can ask the list to see if folks think an expression quantifying it would be additionally helpful (or harmful).
The document currently doesn't note input limits for
hash_to_field
, and I'm wondering if we should consider adding these limits. HPKE has similar limits for some of its functions.The limit is ultimately defined by the underlying hash function, which, for
hash_to_field
built onexpand_message_xmd
is an MD-style hash with an explicit limit, but forhash_to_field
built onexpand_message_xof
is a XOF-based construction with no explicit limit. (FIPS 202 says that the message is a "bit string of any length that is the input to a SHA-3 function.")In practice, hitting these limits is unlikely to happen, since SHA-256 and SHA-512 (and SHA-384) have limits of 2^61 and 2^125 (2^125), respectively. However, I wonder if we should note this for
expand_message_xmd
.Here's the definition of
expand_message_xmd
:Based on this, the length of the input to
H
, denotedmsg_prime
, is computed as:Based on the limit of
H
, denotedH_limit
, we could say that the limit of inputs to expand_message_xmd for suites that use this limit is:@kwantam, what do you think?
The text was updated successfully, but these errors were encountered: