Getting certificate details from an apk

Try the following:

openssl pkcs7 -inform DER -in CERT.RSA -noout -print_certs -text

unzip -p Name-of-apk.apk META-INF/CERT.RSA | keytool -printcert is what I used .

It produces information such as the owner, issuer, serial number, valid through, certificate fingerprints, signature algorithms and version.


The easiest of all:

keytool -printcert -jarfile file.apk

This also works for Android App Bundles (.aab)