167

I need to use mapview control in android and I can't seem to understand how to run keytool. Is it installed with eclipse? I can't seem to find a download link.

Thanks

nik the lion
  • 458
  • 1
  • 9
  • 22
Amit Raz
  • 5,370
  • 8
  • 36
  • 63

10 Answers10

206

keytool is part of the standard java distribution.

In a windows 64-bit machine, you would normally find the jdk at

C:\Program Files\Java\jdk1.8.0_121\bin

It is used for managing keys and certificates you can sign things with, in your case, probably a jar file.

If you provide more details of what you need to do, we could probably give you a more specific answer.

Veverke
  • 9,208
  • 4
  • 51
  • 95
biziclop
  • 48,926
  • 12
  • 77
  • 104
  • 2
    how can I use it? it is not available from the cmd propmp in windows – Amit Raz Jan 28 '11 at 16:01
  • 2
    Your link points to the Java 1.3 (very old!) documentation. The docs for the Java SE 6 version are here: http://download.oracle.com/javase/6/docs/technotes/tools/solaris/keytool.html – Jesper Jan 28 '11 at 16:01
  • 21
    @Amit if you have the JDK installed and added the `bin` folder of your JDK to the `PATH` you should be able to use the `keytool`. – Jesper Jan 28 '11 at 16:02
  • 16
    Funny, the question is "where", not "what", is keytool... why was this even accepted. – Zoomzoom May 12 '16 at 19:05
  • 2
    @Zoomzoom: Thought the same after ending up here. Edited the question to fix this. – Veverke Mar 01 '17 at 10:22
  • Installing entire JDK is not necessary if you need just keytool. It is sufficient to install JRE (Jave Runtime) - it is smaller than JDK (Java Development Kit) – VeganHunter Jul 24 '19 at 23:25
205

keytool is a tool to manage (public/private) security keys and certificates and store them in a Java KeyStore file (stored_file_name.jks).
It is provided with any standard JDK/JRE distributions.
You can find it under the following folder %JAVA_HOME%\bin.

Ahmed Nabil
  • 17,392
  • 11
  • 61
  • 88
evandrix
  • 6,041
  • 4
  • 27
  • 38
12

For me it turned out to be in c/Program Files/Java/jdk1.7.0_25/bin (Windows 8). A more general answer to this question is that it will most likely be in the bin sub directory of wherever your jdk is installed.

Adam Davis
  • 379
  • 5
  • 16
9

keytool it's a binary file into the JDK folder ... just add your JDK as environment variable by adding the following line

C:\Program Files\Java\jdk1.8.0_65\bin
Mohammed Amine
  • 129
  • 1
  • 5
6

If you are working with a Mac... the keytool is part of the Java SDK and can be found in the following location /System/Library/Java/JavaVirtualMachines/[VERSION].jdk/Contents/Home/bin/keytool

crazyDiamond
  • 1,070
  • 2
  • 16
  • 20
5

here: C:\Program Files\Java\jre7\bin it is an exe keytool.exe

user3142006
  • 71
  • 1
  • 2
4

It is in path/to/jdk/bin. Make sure that $JAVA_HOME is defined, and $JAVA_HOME/bin is added to $PATH, or else the 'keytool' command won't be recognized when called.

Asher A
  • 327
  • 2
  • 3
3

If you have Android installed in windows, you will also find it here: C:\Program Files\Android\jdk\microsoft_dist_openjdk_1.8.0.25\jre\bin

CloudArch
  • 291
  • 2
  • 3
2

If you have java installed of course keytool is in there. What you need to do is to add it on your PATH variable.

Den Isahac
  • 1,335
  • 11
  • 26
2

For Android Studio users

If you have Android installed in windows, you will also find it here:

C:\Program Files\Android\Android Studio\jre\bin

Add this path in Enviourment variables and save it After then you can use keytool on your terminal/command prompt

Chetan
  • 195
  • 2
  • 6