A Java Keystore is a container for authorization certificates or public key certificates, and is often used by Java-based applications for encryption, authentication, and serving over HTTPS. Its entries are protected by a keystore password. A keystore entry is identified by an alias, and it consists of keys and certificates that form a trust chain.
1 KeyStore Object
KeyStore is a class able to instantiate
KeyStore Management for different
The type can be specified when generating a
KeyStore instance. If no keystore type is passed as parameter, default keystore type is automaticaly instanciated.
|jks||The proprietary keystore implementation provided by the SUN provider.|
|pkcs12||The transfer syntax for personal identity information as defined in PKCS #12.|
<script> var ksp12 = new Ax.ks.KeyStore('pkcs12'); var ksjks = new Ax.ks.KeyStore('jks'); var ksdef = new Ax.ks.KeyStore(); console.log("ksp12: " + ksp12); console.log("ksjks: " + ksjks); console.log("ksdef: " + ksdef); </script>
1.1 KeyStore Load
To load a keystore into the
KeyStore class you can use method load(File, Pass)
<script> var ksc = new Ax.ks.KeyStore('pkcs12').load(new Ax.io.File('/tmp/7USDIS113019541.p12'), 'TBrA7MqN'); console.log(ksc); </script>