|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.geronimo.security.ca.GeronimoCertificationAuthority
public class GeronimoCertificationAuthority
A Certification Authority implementation using KeystoreInstance to store CA's private key, CertificateStore to store issued certificates and CertificateRequestStore to store certificate requests
| Field Summary | |
|---|---|
static GBeanInfo |
GBEAN_INFO
|
| Constructor Summary | |
|---|---|
GeronimoCertificationAuthority(ServerInfo serverInfo,
KeystoreInstance caKeystore,
CertificateStore certStore,
CertificateRequestStore certReqStore,
Kernel kernel,
AbstractName abstractName)
Constructor |
|
| Method Summary | |
|---|---|
void |
doFail()
Fails the GBean. |
void |
doStart()
Starts the GBean. |
void |
doStop()
Stops the target. |
Certificate |
getCertificate()
This method returns CA's own certificate. |
Certificate |
getCertificate(BigInteger sNo)
This method retrieves a certificate with the specified serial number. |
String |
getCertificateBase64Text(BigInteger sNo)
This method retrieves a certificate with the specified serial number. |
static GBeanInfo |
getGBeanInfo()
|
BigInteger |
getHighestSerialNumber()
This method returns the highest serial number used by the CA. |
X500Principal |
getName()
This method returns CA's name. |
BigInteger |
getNextSerialNumber()
This method returns the next serial number that can be used to issue a certificate and increments the highest serial number. |
boolean |
isCertificateIssued(BigInteger sNo)
This method checks if a Certificate with a given serial number is already issued. |
boolean |
isLocked()
This method checks if the CA is locked. |
Certificate |
issueCertificate(X500Principal subject,
PublicKey publicKey,
BigInteger sNo,
Date validFromDate,
Date validToDate,
String algorithm)
This method issues a certificate. |
void |
issueOwnCertificate(BigInteger sNo,
Date validFromDate,
Date validToDate,
String algorithm)
This method makes the CA issue a self-signed certificate with given details. |
void |
lock()
This method locks the CA. |
void |
unlock(char[] password)
This method unlocks the CA. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final GBeanInfo GBEAN_INFO
| Constructor Detail |
|---|
public GeronimoCertificationAuthority(ServerInfo serverInfo,
KeystoreInstance caKeystore,
CertificateStore certStore,
CertificateRequestStore certReqStore,
Kernel kernel,
AbstractName abstractName)
instance - KeystoreInstance containing CA's private-key and certificatecertStore - CertificateStore for storing certificates issued by this CAcertReqStore - CeetificateRequestStore for storing certificates requests| Method Detail |
|---|
public boolean isLocked()
isLocked in interface CertificationAuthoritypublic void lock()
lock in interface CertificationAuthority
public void unlock(char[] password)
throws CertificationAuthorityException
unlock in interface CertificationAuthoritypassword - Password to unlock the CA.
CertificationAuthorityException
public X500Principal getName()
throws CertificationAuthorityException
getName in interface CertificationAuthorityException - if CA is locked.
CertificationAuthorityException
public Certificate getCertificate()
throws CertificationAuthorityException
getCertificate in interface CertificationAuthorityException - if CA is locked.
CertificationAuthorityException
public void issueOwnCertificate(BigInteger sNo,
Date validFromDate,
Date validToDate,
String algorithm)
throws CertificationAuthorityException
issueOwnCertificate in interface CertificationAuthoritysNo - Serial number for self-signed certificatevalidFromDate - Certificate validity period start datevalidToDate - Certificate validity period end datealgorithm - Signature algorithm for self-signed certificate
CertificationAuthorityException
public Certificate issueCertificate(X500Principal subject,
PublicKey publicKey,
BigInteger sNo,
Date validFromDate,
Date validToDate,
String algorithm)
throws CertificationAuthorityException
issueCertificate in interface CertificationAuthoritysubject - Subject X500PrincipalpublicKey - Subject's public keysNo - Serial number for the certificate to be issuedvalidFromDate - Certificate validity period start datevalidToDate - Certificate validity period end datealgorithm - Signature algorithm for the certificate
CertificationAuthorityException
public BigInteger getHighestSerialNumber()
throws CertificationAuthorityException
getHighestSerialNumber in interface CertificationAuthorityCertificationAuthorityException
public boolean isCertificateIssued(BigInteger sNo)
throws CertificationAuthorityException
isCertificateIssued in interface CertificationAuthoritysNo - The serial number of the the certificate to be looked for
CertificationAuthorityException
public BigInteger getNextSerialNumber()
throws CertificationAuthorityException
getNextSerialNumber in interface CertificationAuthorityCertificationAuthorityException
public Certificate getCertificate(BigInteger sNo)
throws CertificationAuthorityException
getCertificate in interface CertificationAuthoritysNo - The serial number of the certificate to be retrieved
CertificationAuthorityException
public String getCertificateBase64Text(BigInteger sNo)
throws CertificationAuthorityException
getCertificateBase64Text in interface CertificationAuthoritysNo - The serial number of the certificate to be retrieved
CertificationAuthorityExceptionpublic void doFail()
GBeanLifecycle
doFail in interface GBeanLifecycle
public void doStart()
throws Exception
GBeanLifecycle
doStart in interface GBeanLifecycleException - if the target failed to start; this will cause a transition to the failed state
public void doStop()
throws Exception
GBeanLifecycle
doStop in interface GBeanLifecycleException - if the target failed to stop; this will cause a transition to the failed statepublic static GBeanInfo getGBeanInfo()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||