Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cSHAKE String #35

Closed
kc2rxo opened this issue Mar 3, 2023 · 3 comments
Closed

cSHAKE String #35

kc2rxo opened this issue Mar 3, 2023 · 3 comments

Comments

@kc2rxo
Copy link
Contributor

kc2rxo commented Mar 3, 2023

There is a comment in the document asking the following question about the cSHAKE hash use.

Should the cSHAKE string be:

  1. "Remote ID Auth Hash" -- current
  2. DET Context ID (i.e. 0x00B5 A69C 795D F5D5 F008 7F56 843F 2C40)
  3. New Context ID
@kc2rxo
Copy link
Contributor Author

kc2rxo commented Jul 12, 2023

Looks like this is still left hanging. We can keep it as is or do we have a preference to change it?

@rgmhtt
Copy link

rgmhtt commented Jul 31, 2023

First per SP800-185 pg 7, "L" (the 2nd argument) is in bits, not bytes. So

cSHAKE128(ASTM Message, 64, "", "Remote ID Auth Hash")

Then, "Remote ID Auth Hash" is a perfectly good value of "S", the customization bit string. Though sometimes a bit representation is provided so there are no mistakes. Take, pg 10 in above for KMAC:

N ="KMAC" = 11010010 10110010 10000010 11000010

Presenting in hex is also acceptable so it is not too long. Thus there is no question of the text to bit encoding rules.

Finally, replace:

  Informative Note: [RFC9374] specifies cSHAKE128 but is open for
  the expansion of other OGAs.

with

  Informative Note: For OGAs other than "5" [RFC9374], use the construct
 appropriate for the associated hash.  e.g. for "2" which is ECDSA/SHA-384:

       Ltrunc( SHA-384( ASTM Message | "Remote ID Auth Hash" ), 8 )

@kc2rxo
Copy link
Contributor Author

kc2rxo commented Sep 20, 2023

Added in -35

@kc2rxo kc2rxo closed this as completed Sep 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants