Top Constructors Methods
org.apache.tomcat.util.security

public Class KeyStoreUtil

extends Object
Class Inheritance
Imports
java.io.ByteArrayInputStream, .ByteArrayOutputStream, .IOException, .InputStream, java.security.KeyStore, .NoSuchAlgorithmException, java.security.cert.CertificateException

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public static void
load(KeyStore
The KeyStore to load from the InputStream
keystore
,
InputStream
The InputStream to use to populate the KeyStore
is
,
char[]
The password to access the KeyStore
storePass
)

Loads a KeyStore from an InputStream working around the known JDK bug https://bugs.openjdk.java.net/browse/JDK-8157404.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

KeyStoreUtilback to summary
private KeyStoreUtil()

Method Detail

loadback to summary
public static void load(KeyStore keystore, InputStream is, char[] storePass) throws NoSuchAlgorithmException, CertificateException, IOException

Loads a KeyStore from an InputStream working around the known JDK bug https://bugs.openjdk.java.net/browse/JDK-8157404. This code can be removed once the minimum Java version for Tomcat is 13.

Parameters
keystore:KeyStore

The KeyStore to load from the InputStream

is:InputStream

The InputStream to use to populate the KeyStore

storePass:char[]

The password to access the KeyStore

Exceptions
NoSuchAlgorithmException:
If the algorithm specified to validate the integrity of the KeyStore cannot be found
CertificateException:
If one or more certificates can't be loaded into the KeyStore
IOException:
If an I/O occurs reading from the given InputStream