Class DbCertStatusStore

  • All Implemented Interfaces:
    Closeable, AutoCloseable
    Direct Known Subclasses:
    CrlDbCertStatusStore

    public class DbCertStatusStore
    extends org.xipki.ocsp.api.OcspStore
    OcspStore for XiPKI OCSP database.
    Since:
    2.0.0
    Author:
    Lijun Liao (xipki)
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected org.xipki.datasource.DataSourceWrapper datasource  
      • Fields inherited from class org.xipki.ocsp.api.OcspStore

        ignoreExpiredCert, ignoreNotYetValidCert, includeArchiveCutoff, includeCrlId, maxNextUpdatePeriod, minNextUpdatePeriod, name, retentionInterval, unknownCertBehaviour, updateInterval
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void close()  
      static org.xipki.security.HashAlgo getCertHashAlgo​(org.xipki.datasource.DataSourceWrapper datasource)  
      protected org.xipki.ocsp.api.CertStatusInfo getCertStatus0​(Instant time, org.xipki.ocsp.api.RequestIssuer reqIssuer, BigInteger serialNumber, boolean includeCertHash, boolean includeRit, boolean inheritCaRevocation)  
      org.xipki.security.X509Cert getIssuerCert​(org.xipki.ocsp.api.RequestIssuer reqIssuer)  
      protected org.xipki.ocsp.server.store.IssuerStore getIssuerStore()  
      protected List<Runnable> getScheduledServices()  
      void init​(Map<String,​?> sourceConf, org.xipki.datasource.DataSourceWrapper datasource)
      Initialize the store.
      boolean isHealthy()  
      protected boolean isInitialized()  
      boolean knowsIssuer​(org.xipki.ocsp.api.RequestIssuer reqIssuer)  
      protected void updateIssuerStore​(boolean force)  
      • Methods inherited from class org.xipki.ocsp.api.OcspStore

        getCertStatus, getMaxNextUpdatePeriod, getMinNextUpdatePeriod, getName, getRetentionInterval, getUnknownCertBehaviour, getUpdateInterval, isIgnoreExpiredCert, isIgnoreExpiredCrls, isIgnoreNotYetValidCert, isIncludeArchiveCutoff, isIncludeCrlId, overviewString, setIgnoreExpiredCert, setIgnoreNotYetValidCert, setIncludeArchiveCutoff, setIncludeCrlId, setName, setNextUpdatePeriodLimit, setRetentionInterval, setUnknownCertBehaviour, setUpdateInterval
    • Field Detail

      • datasource

        protected org.xipki.datasource.DataSourceWrapper datasource
    • Constructor Detail

      • DbCertStatusStore

        public DbCertStatusStore()
    • Method Detail

      • getScheduledServices

        protected List<Runnable> getScheduledServices()
      • getIssuerStore

        protected org.xipki.ocsp.server.store.IssuerStore getIssuerStore()
      • updateIssuerStore

        protected void updateIssuerStore​(boolean force)
      • getCertStatus0

        protected org.xipki.ocsp.api.CertStatusInfo getCertStatus0​(Instant time,
                                                                   org.xipki.ocsp.api.RequestIssuer reqIssuer,
                                                                   BigInteger serialNumber,
                                                                   boolean includeCertHash,
                                                                   boolean includeRit,
                                                                   boolean inheritCaRevocation)
                                                            throws org.xipki.ocsp.api.OcspStoreException
        Specified by:
        getCertStatus0 in class org.xipki.ocsp.api.OcspStore
        Throws:
        org.xipki.ocsp.api.OcspStoreException
      • isHealthy

        public boolean isHealthy()
        Specified by:
        isHealthy in class org.xipki.ocsp.api.OcspStore
      • init

        public void init​(Map<String,​?> sourceConf,
                         org.xipki.datasource.DataSourceWrapper datasource)
                  throws org.xipki.ocsp.api.OcspStoreException
        Initialize the store.
        Specified by:
        init in class org.xipki.ocsp.api.OcspStore
        Parameters:
        sourceConf - the store source configuration. It contains following key-value pairs:
        • caCerts: optional

          CA certificate files to be included / excluded.

        datasource - DataSource.
        Throws:
        org.xipki.ocsp.api.OcspStoreException
      • close

        public void close()
      • knowsIssuer

        public boolean knowsIssuer​(org.xipki.ocsp.api.RequestIssuer reqIssuer)
        Specified by:
        knowsIssuer in class org.xipki.ocsp.api.OcspStore
      • getIssuerCert

        public org.xipki.security.X509Cert getIssuerCert​(org.xipki.ocsp.api.RequestIssuer reqIssuer)
        Specified by:
        getIssuerCert in class org.xipki.ocsp.api.OcspStore
      • isInitialized

        protected boolean isInitialized()
      • getCertHashAlgo

        public static org.xipki.security.HashAlgo getCertHashAlgo​(org.xipki.datasource.DataSourceWrapper datasource)
                                                           throws org.xipki.datasource.DataAccessException,
                                                                  NoSuchAlgorithmException
        Throws:
        org.xipki.datasource.DataAccessException
        NoSuchAlgorithmException