|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.security.cert.CertStoreSpi org.bouncycastle.jce.provider.X509LDAPCertStoreSpi
public class X509LDAPCertStoreSpi
This is a general purpose implementation to get X.509 certificates and CRLs from a LDAP location.
At first a search is performed in the ldap*AttributeNames of the
X509LDAPCertStoreParameters
with the given
information of the subject (for all kind of certificates) or issuer (for
CRLs), respectively, if a X509CertSelector is given with that details. For
CRLs, CA certificates and cross certificates a coarse search is made only for
entries with that content to get more possibly matchign results.
Field Summary | |
---|---|
private static java.lang.String |
LDAP_PROVIDER
Initial Context Factory. |
private X509LDAPCertStoreParameters |
params
|
private static java.lang.String |
REFERRALS_IGNORE
Processing referrals.. |
private static java.lang.String |
SEARCH_SECURITY_LEVEL
Security level to be used for LDAP connections. |
private static java.lang.String |
URL_CONTEXT_PREFIX
Package Prefix for loading URL context factories. |
Constructor Summary | |
---|---|
X509LDAPCertStoreSpi(java.security.cert.CertStoreParameters params)
|
Method Summary | |
---|---|
private java.util.Set |
certSubjectSerialSearch(java.security.cert.X509CertSelector xselector,
java.lang.String[] attrs,
java.lang.String attrName,
java.lang.String subjectAttributeName)
|
private javax.naming.directory.DirContext |
connectLDAP()
|
java.util.Collection |
engineGetCertificates(java.security.cert.CertSelector selector)
|
java.util.Collection |
engineGetCRLs(java.security.cert.CRLSelector selector)
|
private java.util.Set |
getCACertificates(java.security.cert.X509CertSelector xselector)
|
private java.util.Set |
getCrossCertificates(java.security.cert.X509CertSelector xselector)
|
private java.util.Set |
getEndCertificates(java.security.cert.X509CertSelector xselector)
|
private java.lang.String |
parseDN(java.lang.String subject,
java.lang.String subjectAttributeName)
|
private java.util.Set |
search(java.lang.String attributeName,
java.lang.String attributeValue,
java.lang.String[] attrs)
Returns a Set of byte arrays with the certificate or CRL encodings. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private X509LDAPCertStoreParameters params
private static java.lang.String LDAP_PROVIDER
private static java.lang.String REFERRALS_IGNORE
private static final java.lang.String SEARCH_SECURITY_LEVEL
private static final java.lang.String URL_CONTEXT_PREFIX
Constructor Detail |
---|
public X509LDAPCertStoreSpi(java.security.cert.CertStoreParameters params) throws java.security.InvalidAlgorithmParameterException
java.security.InvalidAlgorithmParameterException
Method Detail |
---|
private javax.naming.directory.DirContext connectLDAP() throws javax.naming.NamingException
javax.naming.NamingException
private java.lang.String parseDN(java.lang.String subject, java.lang.String subjectAttributeName)
public java.util.Collection engineGetCertificates(java.security.cert.CertSelector selector) throws java.security.cert.CertStoreException
engineGetCertificates
in class java.security.cert.CertStoreSpi
java.security.cert.CertStoreException
private java.util.Set certSubjectSerialSearch(java.security.cert.X509CertSelector xselector, java.lang.String[] attrs, java.lang.String attrName, java.lang.String subjectAttributeName) throws java.security.cert.CertStoreException
java.security.cert.CertStoreException
private java.util.Set getEndCertificates(java.security.cert.X509CertSelector xselector) throws java.security.cert.CertStoreException
java.security.cert.CertStoreException
private java.util.Set getCACertificates(java.security.cert.X509CertSelector xselector) throws java.security.cert.CertStoreException
java.security.cert.CertStoreException
private java.util.Set getCrossCertificates(java.security.cert.X509CertSelector xselector) throws java.security.cert.CertStoreException
java.security.cert.CertStoreException
public java.util.Collection engineGetCRLs(java.security.cert.CRLSelector selector) throws java.security.cert.CertStoreException
engineGetCRLs
in class java.security.cert.CertStoreSpi
java.security.cert.CertStoreException
private java.util.Set search(java.lang.String attributeName, java.lang.String attributeValue, java.lang.String[] attrs) throws java.security.cert.CertStoreException
attributeName
- The attribute name to look for in the LDAP.attributeValue
- The value the attribute name must have.attrs
- The attributes in the LDAP which hold the certificate,
certificate pair or CRL in a found entry.
java.security.cert.CertStoreException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |