Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@michaeljyeates
Last active May 8, 2019 19:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 3 You must be signed in to fork a gist
  • Save michaeljyeates/59e23c23598038c01136b55b9b2ef1df to your computer and use it in GitHub Desktop.
Save michaeljyeates/59e23c23598038c01136b55b9b2ef1df to your computer and use it in GitHub Desktop.
#!/bin/bash
if [[ $1 == "" ]]; then
echo "Search for vanity keys - Usage : ./vanity.sh STRING"
exit 1
fi
echo "Finding keys containing : $1"
while true; do
output=$(cleos create key --to-console)
pub=$(cut -d ' ' -f 5 <<< "${output//[$'\r\n']}")
if [[ $pub =~ .*$1.* ]]; then
echo $output
fi
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment