|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.opcfoundation.ua.cert.PkiDirectoryCertificateStore
public class PkiDirectoryCertificateStore
| Constructor Summary | |
|---|---|
PkiDirectoryCertificateStore()
Create a new validator using the default baseDir ("PKI\CA"), trustedDir ("certs"), rejectedDir ("rejected") and revokedDir ("crl"). |
|
PkiDirectoryCertificateStore(String baseDir)
Create a new validator using a baseDir and default subdirs: trustedDir ("certs"), rejectedDir ("rejected") and revokedDir ("crl"). |
|
PkiDirectoryCertificateStore(String baseDir,
String trustedDir,
String rejectedDir,
String revocationDir)
Create a new validator using a baseDir and subdirectory names, trustedDir, rejectedDir and revocationDir. |
|
| Method Summary | |
|---|---|
void |
addCertificate(ValidationResult type,
Cert certificate)
Add a certificate to the store. |
void |
addListener(DefaultCertificateStoreListener listener)
|
void |
addRejectedCertificate(Cert certificate)
Add a certificate to the rejected certificates. |
void |
addRevocationList(X509CRL crl)
Add a certificate revocation list to the store. |
void |
addTrustedCertificate(Cert certificate)
Add a certificate to the trusted certificates. |
void |
clear(boolean removeFiles)
Clears the certificate lists. |
File |
getBaseDir()
|
File |
getFileForCert(Cert cert)
Returns File for the given Certificate. |
Set<Cert> |
getRejectedCerts()
Get all certificates that are stored as Rejected. |
File |
getRejectedDir()
|
File |
getRevocationDir()
|
Set<X509CRL> |
getRevocationLists()
Get all revocation lists the store has. |
Set<Cert> |
getTrustedCerts()
Get all certificates that are stored as Trusted. |
File |
getTrustedDir()
|
boolean |
isStoreAcceptOnceCertificates()
|
void |
refresh()
Refresh certificates. |
void |
removeListener(DefaultCertificateStoreListener listener)
|
void |
setStoreAcceptOnceCertificates(boolean keepAcceptOnceCerts)
Defines whether certificates that are accepted with AcceptOnce status are stored in the certificate store or not. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public PkiDirectoryCertificateStore()
public PkiDirectoryCertificateStore(String baseDir)
baseDir - the path to the base directory where the certificate
directories are kept.
public PkiDirectoryCertificateStore(String baseDir,
String trustedDir,
String rejectedDir,
String revocationDir)
baseDir - the path to the base directory where the certificate
directories are kept. Use null, if you wish to define the
other directories with absolute paths.trustedDir - the name of the directory in which the trusted certificates
are kept. If baseDir is defined, this is a relative path to
that, e.g. a subdirectory name.rejectedDir - the name of the directory in which the rejected certificates
are kept. If baseDir is defined, this is a relative path to
that, e.g. a subdirectory name.revocationDir - the name of the directory in which revoked certificates are
kept. If baseDir is defined, this is a relative path to that,
e.g. a subdirectory name.| Method Detail |
|---|
public void addListener(DefaultCertificateStoreListener listener)
public void addRejectedCertificate(Cert certificate)
certificate - the certificate to addpublic void addRevocationList(X509CRL crl)
crl - revocation list to addpublic void addTrustedCertificate(Cert certificate)
certificate - the certificate to addpublic Set<Cert> getTrustedCerts()
CertificateStoreCertificateStore.getRevocationLists()
revocation lists.
getTrustedCerts in interface CertificateStorepublic Set<Cert> getRejectedCerts()
CertificateStore
getRejectedCerts in interface CertificateStorepublic Set<X509CRL> getRevocationLists()
CertificateStore
getRevocationLists in interface CertificateStore
public void addCertificate(ValidationResult type,
Cert certificate)
CertificateStore
addCertificate in interface CertificateStoretype - trusted, rejected or accept once.certificate - the certificate to add.public File getTrustedDir()
public File getRejectedDir()
public File getRevocationDir()
public boolean isStoreAcceptOnceCertificates()
public void removeListener(DefaultCertificateStoreListener listener)
public File getFileForCert(Cert cert)
cert - the certificate
public void setStoreAcceptOnceCertificates(boolean keepAcceptOnceCerts)
Default: true
keepAcceptOnceCerts - true if accept once certs should be storedpublic void refresh()
public File getBaseDir()
public void clear(boolean removeFiles)
removeFiles - if true, removes all certificate files as well. Be careful
with this!
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||