-4

Where is public and private key of application is located & how to get it ?

sForSujit
  • 987
  • 1
  • 10
  • 24
Gaurav Takte
  • 607
  • 5
  • 22
  • what public and private keys are you referring to? – Aman Grover Jul 14 '17 at 10:19
  • Public key and Private key is used when you have to update your application on play store. – Gaurav Takte Jul 14 '17 at 10:21
  • https://developer.android.com/studio/publish/app-signing.html – Suraj Rao Jul 14 '17 at 10:23
  • https://stackoverflow.com/questions/11446121/how-do-i-generate-a-keystore-for-google-play – Suraj Rao Jul 14 '17 at 10:23
  • 1
    you are probably trying to build an android apk. There are multiple environments for building apks, you did not specify which one you are using. For debug mode, many environments create keys automatically. For production mode you should carefully read all steps to take and ask questions on stackoverflow if a step does not succeed. Do not ask general question: it doesn't work, help! – anneb Jul 14 '17 at 10:23

1 Answers1

2

Probably you are talking about this:

1.) Create a key using

keytool -genkey -v -keystore my-release-key.keystore -alias alias_name keyalg RSA -keysize 2048 -validity 10000 

2.) Sign the APK using:

jarsigner -verbose -sigalg SHA1withRSA -digestalg SHA1 -keystore my-release-key.keystore my_application.apk alias_name

For details you can look here.

Trishant Pahwa
  • 2,559
  • 2
  • 14
  • 31