Last active
December 15, 2015 23:39
-
-
Save dzeikei/5341753 to your computer and use it in GitHub Desktop.
Get public key from a HTTPS server
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Grab the certificate from the HTTPS server (e.g. Google) | |
$ openssl s_client -connect google.com:443 | |
Generate a Java keystore from certificate | |
$ wget http://bouncycastle.org/download/bcprov-jdk16-146.jar | |
$ keytool -importcert -file your_signing_certificate.pem -keystore app.keystore -provider org.bouncycastle.jce.provider.BouncyCastleProvider -providerpath bcprov-jdk16-146.jar -storetype BKS |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment