Skip to content

Instantly share code, notes, and snippets.

@ottosch
Last active April 4, 2024 21:47
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 ottosch/a80f993a08eb76dbc35bb4df72db847a to your computer and use it in GitHub Desktop.
Save ottosch/a80f993a08eb76dbc35bb4df72db847a to your computer and use it in GitHub Desktop.
Outputs apk's signing certificate hash
# print with colons
keytool -printcert -jarfile apk_file 2>/dev/null | grep SHA256 | cut -f2- -d':' | tr -cd '[[:xdigit:]]:'; echo
# print without colons
keytool -printcert -jarfile apk_file 2>/dev/null | grep SHA256 | cut -f2- -d':' | tr -cd '[[:xdigit:]]'; echo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment