package at.gv.egovernment.moa.spss.tsl.connector; import iaik.xml.crypto.tsl.ex.TSLEngineDiedException; import iaik.xml.crypto.tsl.ex.TSLSearchException; import java.io.File; import java.util.ArrayList; import java.util.Date; import java.security.cert.X509Certificate; public interface TSLConnectorInterface { /** * Initial the MOA TSL Connector.
* The hashcache directory must be set via "System-Property "iaik.xml.crypto.tsl.BinaryHashCache.DIR"!!! * * @author TLenz * @param euTSLURL - URL to TrustList * @param TSLWorkingDirectoryPath - Path to a folder which should be used by the TSL engine. (/A/B/.../) * @param jdbcURL - ... * @param jdbcDriverClass - ... */ void initialize(String euTSLURL, String TSLWorkingDirectoryPath, String jdbcURL, String jdbcDriverClass) throws TSLEngineDiedException; /** * Perform an update of all certificates which are on EU TSL and all MS TSLs and create an locale TSL database. * The old locale TSL database is removed and a new database is created. * * @author TLenz * @param dateTime - ... * @param serviceLevelStatus - String Array of ServiceLevelStatus. For example new String[]{"accredited","undersupervision"} * @return List of certificates with the selected properties */ ArrayList updateAndGetQualifiedCACertificates(Date dateTime, String[] serviceLevelStatus) throws TSLEngineDiedException, TSLSearchException ; /** * Perform an update of all certificates which are on EU TSL and all MS TSLs and create an locale TSL database. * The old locale TSL database is removed and a new database is created. * * @author TLenz * @param dateTime - ... * @param countries - String Array of country codes. For example new Sting[]{"AT","IT","BE"} * @param serviceLevelStatus - String Array of ServiceLevelStatus. For example new String[]{"accredited","undersupervision"} * @return List of certificates with the selected properties */ ArrayList updateAndGetQualifiedCACertificates(Date dateTime, String[] countries, String[] serviceLevelStatus) throws TSLEngineDiedException, TSLSearchException ; /** * Check the http://uri.etis.org/TrstSvc/Svctype/CA/QC characteristic of a certificate by using the TSL information. * This method uses information from the local TSL database. * * @author TLenz * @param certificate - An X509 certificate. * @return Return true, if the certificate comprises the http://uri.etis.org/TrstSvc/Svctype/CA/QC characteristic. */ boolean checkQC(X509Certificate[] certificate) throws TSLSearchException, TSLEngineDiedException; /** * Check the http://uri.etis.org/TrstSvc/eSigDir-1999-93-ECTrustedList/SvcInfoExt/QCWithSSCD characteristic of a certificate by using the TSL information. * This method uses information from the local TSL database. * * @author TLenz * @param certificate - An X509 certificate. * @return Return true, if the certificate comprises the http://uri.etis.org/TrstSvc/eSigDir-1999-93-ECTrustedList/SvcInfoExt/QCWithSSCD characteristic. */ boolean checkSSCD(X509Certificate[] certificate) throws TSLSearchException, TSLEngineDiedException; /** * Get a list of certificates form the local TSL database with the selected properties. * * @author TLenz * @param dateTime - ... * @param serviceLevelStatus - String Array of ServiceLevelStatus. For example new String[]{"accredited","undersupervision"} * @return List of certificates with the selected properties */ ArrayList getQualifiedCACertificates(Date dateTime, String[] serviceLevelStatus) throws TSLEngineDiedException, TSLSearchException; /** * Get a list of certificates form the local TSL database with the selected properties. * * @author TLenz * @param dateTime - ... * @param countries - String Array of countrie codes. For example new Sting[]{"AT","IT","BE"} * @param serviceLevelStatus - String Array of ServiceLevelStatus. For example new String[]{"accredited","undersupervision"} * @return List of certificates with the selected properties */ ArrayList getQualifiedCACertificates(Date dateTime, String[] countries, String[] serviceLevelStatus) throws TSLEngineDiedException, TSLSearchException; }