Create a new key:
keytool -genkey -alias keyAlias -keyalg RSA -validity 1000 -keystore d:\keyPath\keyName.keystore -dname "CN=firstName,OU=organizational unit ,O=organization,L=city ,ST=province,C=country unit" -keypass password
import keyName.keystore into keyName.cer:
keytool -import -v -file d:\keyName.cer -keystore d:\keyPath\keyName.keystore
See key information:
keytool -list -v -keystore c:\keyName.keystore -alias keyAlias -storepass keyword -keypass passwrod
generate cer key:
keytool -gencert -alias server c:\keyName.keystore -infile c:\keyName.cer