Skip to content

Instantly share code, notes, and snippets.

@0xjjpa
Last active March 11, 2024 06:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save 0xjjpa/8583f2e87f0490395a5d29387b7066e7 to your computer and use it in GitHub Desktop.
Save 0xjjpa/8583f2e87f0490395a5d29387b7066e7 to your computer and use it in GitHub Desktop.
Generate an Ethereum compatible private key one-liner using OpenSSL
openssl ecparam -name secp256k1 -genkey -noout \
| openssl ec -outform DER 2>/dev/null \
| tail -c +8 | head -c 32 \
| xxd -p -c 32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment