Skip to content

Commit 086b5b1

Browse files
committed
[sw,cryptolib] Update ECC random scalar gen function header
This commit updates the ECC random secret scalar generation function header. I checked the implementation for FIPS 186-5 compliance and updated the header comment accordingly. Signed-off-by: Hakim Filali <[email protected]>
1 parent 6d41f4b commit 086b5b1

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

sw/otbn/crypto/p384_keygen.s

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@
1313
*
1414
* Returns t, a random value that is nonzero mod n, in shares.
1515
*
16-
* This follows a modified version of the method in FIPS 186-4 sections B.4.1
17-
* and B.5.1 for generation of secret scalar values d and k. The computation
18-
* in FIPS 186-4 is:
19-
* seed = RBG(seedlen) // seedlen >= 448
16+
* This follows a modified version of the method in FIPS 186-5 sections A.2.2
17+
* and A.3.2 for generation of secret scalar values d and k. The computation
18+
* in FIPS 186-5 is:
19+
* seed = RBG(seedlen) // seedlen >= 384
2020
* return (seed mod (n-1)) + 1
2121
*
2222
* The important features here are that (a) the seed is at least 64 bits longer

0 commit comments

Comments
 (0)