dev.galasa.framework.spi.IKeyStore Maven / Gradle / Ivy
/*
* Copyright contributors to the Galasa project
*
* SPDX-License-Identifier: EPL-2.0
*/
package dev.galasa.framework.spi;
import java.io.InputStream;
import java.security.KeyStore;
/**
* A class to represent a Java Keystore and allow for easy appending and generation
*
*
*
*/
public interface IKeyStore {
/**
* Returns the Java keystore
*
* @return KeyStore
*/
public KeyStore getKeyStore();
/**
*
* Allows a Base64 encoded PEM cert to be appended to the Keystore
*
*
* @param cert
* @throws CertificateStoreException
*/
public void appendPemAsString(String aliasId, String cert) throws CertificateStoreException;
/**
*
* Allows a PEM cert file to be appended to the Keystore
*
* @param aliasId
* @param certFile
* @throws CertificateStoreException
*/
public void appendPem(String aliasId, InputStream certFile) throws CertificateStoreException;
/**
*
* Allows a Base64 encoded DER cert to be appended to the Keystore
*
* @param aliasId
* @param certFile
* @throws CertificateStoreException
*/
public void appendDer(String aliasId, InputStream certFile) throws CertificateStoreException;
/**
*
* Allows a certificate to be retrieved from the the certificate store based on its
* ID tag and added to this keystore.
*
*
* @param certificateId
* @throws CertificateStoreException
*/
public void appendCertficateById(String aliasId, String certificateId) throws CertificateStoreException;
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy