Skip to content

Instantly share code, notes, and snippets.

@lucas-maicoin
Created June 28, 2018 01:50
Show Gist options
  • Save lucas-maicoin/20af5a0518526b4d3e30798fa033ce96 to your computer and use it in GitHub Desktop.
Save lucas-maicoin/20af5a0518526b4d3e30798fa033ce96 to your computer and use it in GitHub Desktop.
EOS public/private keys

create public/private key

$ cleos create key
Private key: 5Jxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Public key: EOS5ZxpFzmqybRZjoBt9Xavb3PrYBG8LNf91aag2KaCdE1nEb2G8Y

import public/private key into a wallet

$ cleos wallet import 5Jxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
imported private key for: EOS5ZxpFzmqybRZjoBt9Xavb3PrYBG8LNf91aag2KaCdE1nEb2G8Y

create public/private key inside a wallet

$ cleos wallet create_key -n max
Created new private key with a public key of: "EOS5XomYMeH5eaNApRr46cjqSSd8YD4VckBWUschPzo53FEPPKQqW"

list all public keys for all unlocked wallets

$ cleos wallet keys
[
  "EOS5ZxpFzmqybRZjoBt9Xavb3PrYBG8LNf91aag2KaCdE1nEb2G8Y",
  "EOS6MRyAjQq8ud7hVNYcfnVPJqcVpscN5So8BhtHuGYqET5GDW5CV",
  "EOS7nSQEwdC5rTBu9CPAoQib8gpb9SyWoTrZ5ZXdqk5Ae8FrDd5vW"
]

list all private keys for an unlocked wallet

$ cleos wallet private_keys -n max
password: 
[
  [
    "EOS5ZxpFzmqybRZjoBt9Xavb3PrYBG8LNf91aag2KaCdE1nEb2G8Y",
    "5Jxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
  ]
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment