Generate Public Key From Private Ethereum

Oct 17, 2018 This article is to provide a guide on how to generate ECDSA private key, then derive to Ethereum wallet address by using PHP 7.0. The code requires PHP 7.0 with OpenSSL extension and PHP. Public Key Cryptography, or Asymmetric Cryptography, is a cryptographic system that uses pairs of keys: Public Key and Private Key. It is one of the most important (if not the most important) part of cryptocurrency protocols, and it is used in sev.

Please use https://github.com/ethcore/parity/tree/master/ethkey

Ethereum keys generator.

Usage

Examples

info <secret>

Display info about private key.

  • <secret> - ethereum secret, 32 bytes long

--

generate brain <seed>

Generate new brain-wallet keypair using 16384 iterations.

  • <seed> - brain-wallet seed, any string

--

generate random

Generate new keypair randomly.

Generate Public Key From Private Ethereum

--

generate prefix <prefix> <iterations>

Generate new keypair randomly with address starting with prefix.

Ethereum Private Network

  • <prefix> - desired address prefix, 0 - 32 bytes long.
  • <iterations> - maximum number of tries before generation is assumed to be a failure.

--

sign <secret> <message>

Generate Public Key From Private Ethereum To Dollar

Sign a message with a secret.

  • <secret> - ethereum secret, 32 bytes long
  • <message> - message to sign, 32 bytes long

--

verify public <public> <signature> <message>

Verify the signature.

  • <public> - ethereum public, 64 bytes long
  • <signature> - message signature, 65 bytes long
  • <message> - message, 32 bytes long

--

verify address <address> <signature> <message>

Verify the signature.

  • <address> - ethereum address, 20 bytes long
  • <signature> - message signature, 65 bytes long
  • <message> - message, 32 bytes long

Ethereum Private Chain

this project is a part of the ethcore toolchain

Ethereum Private Key Generator

  • ethkey - Ethereum keys generator and signer.
  • ethstore - Ethereum key management.
  • ethabi - Ethereum function calls encoding.