- All Implemented Interfaces:
Serializable,Comparable<KeyStoreType>,Constable
The semantic keyStoreType of the Keystore.
The specific documentation is inspired from https://www.java67.com/2012/12/difference-between-truststore-vs.html.
Whats the difference? keystore is used to store server's own certificate while truststore is used to store the certificate of other parties issued by CA.
- Author:
- Oliver Wolff
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionA keystore is used to store your credential (server or client) needed when you are setting up server side on SSL.A truststore is used to store others credential: Certificates from CAs or you company, Customers,... java-property: javax.net.ssl.trustStore Default location for Java installations: Oracle: JAVA_HOME/JRE/Security/cacerts Zulu / OpenJDK: JAVA_HOME/lib/security/cacerts . -
Method Summary
Modifier and TypeMethodDescriptionstatic KeyStoreTypeReturns the enum constant of this class with the specified name.static KeyStoreType[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
TRUST_STORE
A truststore is- used to store others credential: Certificates from CAs or you company, Customers,...
- java-property: javax.net.ssl.trustStore
- Default location for Java installations:
- Oracle: JAVA_HOME/JRE/Security/cacerts
- Zulu / OpenJDK: JAVA_HOME/lib/security/cacerts
-
KEY_STORE
A keystore is- used to store your credential (server or client)
- needed when you are setting up server side on SSL. It is used to store server's identity certificate, which server will present to a client on the connection while trust store setup on client side must contain to make the connection work. If you browser to connect to any website over SSL it verifies certificate presented by server against its truststore.
- java-property: javax.net.ssl.keyStore
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-