Interface semper.certificate.Certificate
All Packages Class Hierarchy This Package Previous Next Index
Interface semper.certificate.Certificate
- public interface Certificate
- extends Object
- extends Streamable
-
changeCASign(String)
-
Set signature for this signed by the CA whose
Distinguished Name is stored in the Certificate.
-
getCADN()
-
Retrieve the CA's name that issued this certificate.
-
getCASign()
-
Retrieve signature for this signed by the CA whose
Distinguished Name is stored in the Certificate.
-
getHashID()
-
Retrieve the algorithm ID of the algorithm used to hash
this Certificate with.
-
getNotValidAfter()
-
Retrieve the Date after which this certificate isn't valid.
-
getNotValidBefore()
-
Retrieve the Date before which this certificate isn't valid.
-
getPublicKey()
-
Retrieve the Public Key stored in this certificate.
-
getScope()
-
Retrieve the scope for this Certificate.
-
getSerialNr()
-
Retrieve this Certificates SerialNr, with which it is identified
by the CAthat issued this certificate.
-
getSignatureID()
-
Retrieve the algorithm ID of the algorithm used to sign
this Certificate with.
-
getStatus()
-
Retrieve the status of the Certificate.
-
getType()
-
Retrieve the type of Certificate.
-
getUserDN()
-
Retrieve certificate owners name.
-
getWhyRevoked()
-
Retrieve reason why this Certificate was revoked.
-
setCADN(String)
-
Set the CA's name that issued this certificate.
-
setHashID(int)
-
Set the algorithm ID of the algorithm used to hash
this Certificate with.
-
setNotValidAfter(Date)
-
Set the Date after which this certificate isn't valid.
-
setNotValidBefore(Date)
-
Set the Date before which this certificate isn't valid.
-
setPublicKey(CryptoKeyInfo)
-
Set the Public Key certified with this certificate.
-
setScope(int)
-
Set the scope for this Certificate.
-
setSerialNr(long)
-
Set this Certificates SerialNr, with which it is identified
by the CA that issued this certificate.
-
setSignatureID(int)
-
Set the algorithm ID of the algorithm used to sign
this Certificate with.
-
setStatus(int)
-
Set the status of the Certificate.
-
setType(int)
-
Set the type of Certificate.
-
setUserDN(String)
-
Set certificate owners name.
-
setWhyRevoked(int)
-
Set reason why this Certificate was revoked.
-
verifyCertificate()
-
verify certificates correctness (ie whether signature matches its
contents).
getCADN
public abstract String getCADN()
- Retrieve the CA's name that issued this certificate. This name
is stored in the certificate.
getUserDN
public abstract String getUserDN()
- Retrieve certificate owners name. This name
is stored in the certificate.
getSerialNr
public abstract long getSerialNr()
- Retrieve this Certificates SerialNr, with which it is identified
by the CAthat issued this certificate. This SerialNr
is stored in the certificate.
getPublicKey
public abstract CryptoKeyInfo getPublicKey()
- Retrieve the Public Key stored in this certificate.
getScope
public abstract int getScope()
- Retrieve the scope for this Certificate. This might (for instance
by SecuDEs X.509 v2 certificates) return SCOPE_NYI
getType
public abstract int getType()
- Retrieve the type of Certificate. This might (for instance
by SecuDEs X.509 v2 certificates) return TYPE_NYI
getNotValidBefore
public abstract Date getNotValidBefore()
- Retrieve the Date before which this certificate isn't valid.
getNotValidAfter
public abstract Date getNotValidAfter()
- Retrieve the Date after which this certificate isn't valid.
getStatus
public abstract int getStatus()
- Retrieve the status of the Certificate. If status isn't implemented,
(like in SecuDE) Certificates are assumed to be valid if they exist.
Certificate Manager at CA should remove Certificates with a possibly
bad status until other modules are available, that can handle status
as well.
getCASign
public abstract byte[] getCASign()
- Retrieve signature for this signed by the CA whose
Distinguished Name is stored in the Certificate.
getWhyRevoked
public abstract int getWhyRevoked()
- Retrieve reason why this Certificate was revoked. Might
change to a string later on. RCModules, that can't implement it
yet can instead return REVOC_REASON_NYI.
getSignatureID
public abstract int getSignatureID()
- Retrieve the algorithm ID of the algorithm used to sign
this Certificate with. The types should correspond to the possible
types defined in the CryptoConstants class (RSA, DSA etc.)
getHashID
public abstract int getHashID()
- Retrieve the algorithm ID of the algorithm used to hash
this Certificate with. The types should correspond to the possible
types defined in the CryptoConstants class (MD2C, MD4, RIPE_MD, SHA etc.)
setCADN
public abstract void setCADN(String name)
- Set the CA's name that issued this certificate. This name
is stored in the certificate.
- Parameters:
- : - CA's name.
setUserDN
public abstract void setUserDN(String name)
- Set certificate owners name. This name
is stored in the certificate.
- Parameters:
- : - users name.
setSerialNr
public abstract void setSerialNr(long serialNr)
- Set this Certificates SerialNr, with which it is identified
by the CA that issued this certificate. This SerialNr
is stored in the certificate.
- Parameters:
- : - new serialNr.
setPublicKey
public abstract void setPublicKey(CryptoKeyInfo newKey)
- Set the Public Key certified with this certificate.
- Parameters:
- : - new Key.
setScope
public abstract void setScope(int scope)
- Set the scope for this Certificate. This might (for instance
by SecuDEs X.509 v2 certificates) be an empty method.
- Parameters:
- : - scope for the certificate.
setType
public abstract void setType(int type)
- Set the type of Certificate. This might (for instance
by SecuDEs X.509 v2 certificates) be an empty method.
- Parameters:
- : - type of certificate.
setNotValidBefore
public abstract void setNotValidBefore(Date notValidBefore)
- Set the Date before which this certificate isn't valid.
- Parameters:
- : - start date of certificates validity period.
setNotValidAfter
public abstract void setNotValidAfter(Date notValidAfter)
- Set the Date after which this certificate isn't valid.
- Parameters:
- : - end date of certificates validity period.
setStatus
public abstract void setStatus(int status)
- Set the status of the Certificate. If status isn't implemented,
(like in SecuDE) might be an empty method. For future implementations
of certificate-modules should definitely be implemented, as the
current solution is born out of need, not desire.
- Parameters:
- : - status of certificate.
changeCASign
public abstract void changeCASign(String myName) throws CertificateException
- Set signature for this signed by the CA whose
Distinguished Name is stored in the Certificate.
- Parameters:
- myName - is the distinguished name of this CA.
- Throws: CertificateException
- is thrown, if the signature couldn't
get changed.
setWhyRevoked
public abstract void setWhyRevoked(int whyRevoked)
- Set reason why this Certificate was revoked. Might
change to a string later on.
- Parameters:
- : - reason.
setSignatureID
public abstract void setSignatureID(int signatureID)
- Set the algorithm ID of the algorithm used to sign
this Certificate with. The types should correspond to the possible
types defined in the CryptoConstants class (RSA, DSA etc.)
- Parameters:
- : - signature algorithm ID.
setHashID
public abstract void setHashID(int hashID)
- Set the algorithm ID of the algorithm used to hash
this Certificate with. The types should correspond to the possible
types defined in the CryptoConstants class (MD2C, MD4, RIPE_MD, SHA etc.)
- Parameters:
- : - hashing ID.
verifyCertificate
public abstract boolean verifyCertificate() throws CertificateException
- verify certificates correctness (ie whether signature matches its
contents).
- Parameters:
- s: - The public key used to generate the signature.
- Throws: CertificateException
- if some error occurred while verifying.
All Packages Class Hierarchy This Package Previous Next Index