This class provides several utilities to KeyStore.
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static String[] | Returns: arguments combinedthe name of the tool, can be "keytool" or "jarsigner" tool, String the pre-configured options file file, String the name of the command, with the "-" prefix,
must not be null c1, String the alternative command name, with the "-" prefix,
null if none. For example, "genkey" is alt name for
"genkeypair". A command can only have one alt name now. c2, String[] existing arguments args)Prepends matched options from a pre-configured options file. |
| public static String | |
| public static KeyStore | |
| public static char[] | |
| public static boolean | |
| public static boolean | |
| public static void | loadProviderByClass(String
the class name provClass, String optional arg arg, ClassLoader optional class loader cl)Loads a security provider by a fully-qualified class name. |
| public static void | loadProviderByName(String
the name provName, String optional arg arg)Loads a security provider as a service. |
| public static String | |
| private static void | parseArgsLine(List<String>
the list to fill into list, String the line s)Parses an option line likes -genkaypair -dname "CN=Me" and add the results into a list |
| public static boolean |
| KeyStoreUtil | back to summary |
|---|---|
| private KeyStoreUtil() | |
| expandArgs | back to summary |
|---|---|
| public static String[] expandArgs(String tool, String file, String c1, String c2, String[] args) throws IOException, ExpandException Prepends matched options from a pre-configured options file.
| |
| getCacerts | back to summary |
|---|---|
| public static String getCacerts() Returns the file name of the keystore with the configured CA certificates. | |
| getCacertsKeyStore | back to summary |
|---|---|
| public static KeyStore getCacertsKeyStore() throws Exception Returns the keystore with the configured CA certificates. | |
| getPassWithModifier | back to summary |
|---|---|
| public static char[] getPassWithModifier(String modifier, String arg, ResourceBundle rb, Collator collator) | |
| isSelfSigned | back to summary |
|---|---|
| public static boolean isSelfSigned(X509Certificate cert) Returns true if the certificate is self-signed, false otherwise. | |
| isWindowsKeyStore | back to summary |
|---|---|
| public static boolean isWindowsKeyStore(String storetype) Returns true if KeyStore has a password. This is true except for MSCAPI KeyStores | |
| loadProviderByClass | back to summary |
|---|---|
| public static void loadProviderByClass(String provClass, String arg, ClassLoader cl) Loads a security provider by a fully-qualified class name.
| |
| loadProviderByName | back to summary |
|---|---|
| public static void loadProviderByName(String provName, String arg) Loads a security provider as a service.
| |
| niceStoreTypeName | back to summary |
|---|---|
| public static String niceStoreTypeName(String storetype) Returns standard-looking names for storetype | |
| parseArgsLine | back to summary |
|---|---|
| private static void parseArgsLine(List<String> list, String s) throws IOException, ExpandException Parses an option line likes -genkaypair -dname "CN=Me" and add the results into a list | |
| signedBy | back to summary |
|---|---|
| public static boolean signedBy(X509Certificate end, X509Certificate ca) | |