Skip to content

Secp256r1 #367

Answered by yelhousni
SherLzp asked this question in Q&A
Mar 29, 2023 · 1 comments · 1 reply
Discussion options

You must be logged in to vote

Hi @SherLzp !

  1. q is the modulus 115792089237316195423570985008687907853269984665640564039457584007908834671663and r is 2^64. So -1/q % 2^64 is 15580212934572586289.
  2. These are the 64-bit limbs of (q-1)/2 in decimal. e.g. write (q-1)/2 in binary and take the first 64 bits. This is 1111111111111111111111111111111111111111111111111111111111111111 in binary and 18446744073709551615 in decimal.

You shouldn't care about these as they are auto-generated. You just need to put the curve moduli in the config file (e.g. for secp256k1) and the fp/ and fr/ packages are auto-generated.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@SherLzp
Comment options

Answer selected by SherLzp
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants