|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--iaik.x509.ocsp.utils.TrustedResponders
A simple repository for mapping trust between responders to ca certificates.
If a basic OCSP response
is not
signed by the same issuer that has signed the target certificate
the OCSP client has to check if the response signer is authorized to
sign the response. In this case the certificate of the response signer
has to be issued by the issuer of the target certificate and has to
contain the ExtendedKeyUsage
extension indicating the id-kp-OCSPSigning purpose.
This class provides a simple mechanism allowing to specify the set of CAs
for which each responder is trusted.
Responders are identified by its ResponderID
.
When calling method addTrustedResponderEntry
supply the ID of the responder in mind and a
CA certificate which has authorized this responder for signing the response, e.g.:
// targetCerts[0] contains the certificate for which revocation information shall be requested // targetCerts[0] is signed by targetCerts[1] X509Certificate[] targetCerts = ...; // responder cert is the cert used by the responder for signing a response X509Certificate responderCert = ...; // we want to trust this responders for signing responses for certs issued by targetCerts[1] TrustedResponders trustedResponders = new TrustedResponders(); ResponderID responderID = new ResponderID((Name)responderCerts.getSubjectDN()); trustedResponders.add(responderID, targetCerts[1]);Note: this class provides are very simple trust repository utility maintained by a hashtable with one entry for each particular responderID. Each responder entry has its trusted CA certificates attached; so one CA certificate may appear repeatedly (e.g. for responder 1 and responder 2,...). An application may which to implement a more comprehensive strategy.
Constructor Summary | |
TrustedResponders()
Default constructor. |
Method Summary | |
boolean |
addTrustedResponderEntry(ResponderID responderID,
X509Certificate caCert)
Trust the given reponderID for signing responses for certs issued by the given CA. |
void |
clearAllEntries()
Clear all entries. |
boolean |
isTrustedResponder(ResponderID responderID,
X509Certificate responderCert,
X509Certificate caCert)
Checks if we can trust the given responder for signing responses for certs issued by the given CA. |
boolean |
removeTrustedResponder(ResponderID responderID)
Removes the given responder from the trust repository. |
boolean |
removeTrustedResponderEntry(ResponderID responderID,
X509Certificate caCert)
Do not longer trust the given responder for signing responses for certs issued by the given CA cert. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public TrustedResponders()
Method Detail |
public boolean addTrustedResponderEntry(ResponderID responderID, X509Certificate caCert)
responderID
- the ID of the responder to trust for signing responses for
certs issued by the given CA certcaCert
- responses for certs issued by this CA cert can be signed by
the given responderpublic boolean removeTrustedResponder(ResponderID responderID)
responderID
- the ID of the responder to removepublic boolean removeTrustedResponderEntry(ResponderID responderID, X509Certificate caCert)
responderID
- the ID of the responder not to trust longer for signing
responses for certs issued by the given CA certcaCert
- responses for certs issued by this CA cert cannot be signed by
the given responderpublic boolean isTrustedResponder(ResponderID responderID, X509Certificate responderCert, X509Certificate caCert)
responderID
- the ID of the resonder in mindcaCert
- the CA certresponderCert
- the cert of the responderpublic void clearAllEntries()
|
This Javadoc may contain text parts from Internet Standard specifications (RFC 2459, 3280, 3039, 2560, 1521, 821, 822, 2253, 1319, 1321, ,2630, 2631, 2268, 3058, 2984, 2104, 2144, 2040, 2311, 2279, see copyright note) and RSA Data Security Public-Key Cryptography Standards (PKCS#1,3,5,7,8,9,10,12, see copyright note). | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |