List of usage examples for java.security.cert X509CRLSelector getDateAndTime
public Date getDateAndTime()
From source file:mitm.common.security.crlstore.dao.X509CRLStoreDAOHibernate.java
private void addSelectorCriterias(X509CRLSelector crlSelector, Criteria criteria) { Collection<X500Principal> crlSelectorIssuers = crlSelector.getIssuers(); if (crlSelectorIssuers != null && crlSelectorIssuers.size() > 0) { Disjunction issuerCriteria = Restrictions.disjunction(); for (X500Principal issuer : crlSelectorIssuers) { String issuerCanonical = X500PrincipalInspector.getCanonical(issuer); issuerCriteria.add(Restrictions.eq("crl.issuer", issuerCanonical)); }//from w w w. j a v a2s .c o m criteria.add(issuerCriteria); } Date dateAndTime = crlSelector.getDateAndTime(); if (dateAndTime != null) { criteria.add(Restrictions.lt("crl.thisUpdate", dateAndTime)); criteria.add(Restrictions.gt("crl.nextUpdate", dateAndTime)); } }