How to get SHA256 Key

Last Updated on : 2023-12-07 03:15:41download

This topic describes how to get the SHA256 key.

Generate the keystore file

Note: The suffix of the currently generated file is .jks ,instead of the previous .keyStore.

  1. On the menu bar, choose Build > Generate Signed APK.
    How to get SHA256 Key
  2. Select APK and follow the instructions to create the keystore file.
    How to get SHA256 Key

Get the SHA256 key

  1. Run the command in the same level directory to filter out the generated .jks files.
    keytool -list -v -keystore xx.jks
    enter password
    
  2. Get the SHA256 key from the file.
    Valid from Tue Mar 16 10:22:14 CST 2021 to Sun Mar 06 10:22:14 CST 2061
    Certificate fingerprint:
    MD5: 6B:8C:94:15:35:7C:2E:E8:6E:76:7F:8C:F9:4B:05:BC
    SHA1: 8F:AC:5D:50:65:22:C2:2A:E4:96:3D:8F:9E:DC:5B:43:11:49:55:B1
    SHA256: 0B:98:89:D8:D5:FC:B1:23:9A:76:B1:2B:8F:4C:5E:24:BF:E7:60:E8:FF:EF:E9:40: 48:14:60:D3:62:00:5C:5F
    Signature algorithm name: SHA256withRSA
    Subject public key algorithm: 2048-bit RSA key
    Version: 3