Well there’s never really been a great place on the web for me to find out how, and after a lot of searching and trial and error, I found a way that works. If you have the JDK correctly installed and working in the classpath, go to Start->Run->cmd and hit enter, or vista users Start->type in cmd in the searchbox->enter / click the only thing that shows up. Now type in “cd C:/path/to/your/directory” to get to the current directory of your jar file.
keytool -genkey -alias YOURALIAS -keystore YOURSTORE -keypass KEYPASS -dname "cn=YOUR NAME" -storepass STOREPASS
jarsigner -keystore YOURSTORE -storepass STOREPASS -keypass KEYPASS -signedjar SIGNEDJAR.jar ORIGJAR.jar YOURALIAS
keytool -export -keystore YOURSTORE -storepass STOREPASS -alias YOURALIAS -file YOURCERT.cer
Just replace what’s in capitals for your own values, and it should work happily.
** NOTICE: Wordpress is one big failure at wordwrapping. I had to split each of these into two lines. The second line should still be on the first line in the command prompt, and there should be a space between “YOURSTORE -keypass” like that.
