3

What are the technical specifications of a private key?

https://getmonero.org/technical-specs/ doesn't say.

https://en.bitcoin.it/wiki/Private_key shows: "In Bitcoin, a private key is a 256-bit number, which can be represented one of several ways. Here is a private key in hexadecimal - 256 bits in hexadecimal is 32 bytes, or 64 characters in the range 0-9 or A-F. "

I need to generate a private key by coin flipping.

1 Answer 1

3

A private spend key is a positive integer lesser than l = 7237005577332262213973186563042994240857116359379907606001950938285454250989 (which is a 253-bit integer). The usual process to make a private spend key is to generate a random 256-bit integer and then reduce it modulo l.

The private spend keys are usually represented in one of the following ways:

  • 32 bytes (little-endian order)
  • 64 hexadecimal characters
  • 25 words (mnemonic seed with 1 checksum word)

You can generate the 256-bit number with coin flips, but then you have to compute its remainder modulo l. Also, instead of using a simple coin flip to determine each bit (e.g. 0 for head, 1 for tail), it is better to use double flips to have better randomness in case the coin has a bias (e.g. 0 for head-tail, 1 for tail-head, ignore head-head and tail-tail).

1

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.