My understanding is that bootnode --genkey commands generate private key of node, and bootnode --writeaddress commands generate public key of node.

However, why node needs private key and public key?

Main usage of node's public key seems to be an identifier of nodes. If the node key is only used as identifier, no need for cryptography.

What is nodekey of bootnode command?

1 Answer 1


Bootnodes must be identified by an enode. Enodes are derived from private key.

Full quote:

Each ethereum node, including a bootnode is identified by an enode identifier. These identifiers are derived from a key. Therefore you will need to give the bootnode such key.

Source: https://github.com/ethereum/go-ethereum/wiki/Setting-up-private-network-or-local-cluster#setup-bootnode

  • Thank you. Then, what if private key leaks? Is there any risk of leaking nodekey ? Jan 23, 2020 at 9:08
  • 1
    I am not sure @久保圭司. I suppose you can obtain the enode identifier and you MIGHT (again, not sure) connect to this node or even play as a "node in the middle" (take this node identity). But again, this is pure speculation from me. Jan 23, 2020 at 9:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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