anon.crypto
Class JAPCertificate.X509CertificateGenerator
java.lang.Object
org.bouncycastle.asn1.x509.V3TBSCertificateGenerator
anon.crypto.JAPCertificate.X509CertificateGenerator
- Enclosing class:
- JAPCertificate
private static final class JAPCertificate.X509CertificateGenerator
- extends org.bouncycastle.asn1.x509.V3TBSCertificateGenerator
This class is used to create, duplicate and sign X509 certificates.
Method Summary |
org.bouncycastle.asn1.x509.X509CertificateStructure |
sign(PKCS12 a_pkcs12Certificate)
|
org.bouncycastle.asn1.x509.X509CertificateStructure |
sign(org.bouncycastle.asn1.x509.X509Name a_issuer,
IMyPrivateKey a_privateKey)
|
Methods inherited from class org.bouncycastle.asn1.x509.V3TBSCertificateGenerator |
generateTBSCertificate, setEndDate, setEndDate, setExtensions, setIssuer, setSerialNumber, setSignature, setStartDate, setStartDate, setSubject, setSubjectPublicKeyInfo |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
JAPCertificate.X509CertificateGenerator
public JAPCertificate.X509CertificateGenerator(X509DistinguishedName a_ownerAlias,
java.util.Date a_validFrom,
java.util.Date a_validTo,
IMyPublicKey a_publicKey,
X509Extensions a_extensions,
java.math.BigInteger a_serialNumber)
- Prepares a new X509 certificate from an owner alias and a public key.
The SubjectKeyIdentifier extension is added and calculated using a SHA1 hash over
the BIT STRING from SubjectPublicKeyInfo as defined in RFC2459.
- Parameters:
a_ownerAlias
- the certificate`s common name; an alias to the public key`s ownera_validFrom
- the date from which the certificate is valida_validTo
- the date on which the certificate looses validitya_publicKey
- the public key that is enclosed in the certificatea_extensions
- some X509 extensions (may be null)a_serialNumber
- the serial number for this certificate (may be null)
- Throws:
java.io.IOException
- if the public key`s encoding is invalid
JAPCertificate.X509CertificateGenerator
public JAPCertificate.X509CertificateGenerator(org.bouncycastle.asn1.x509.TBSCertificateStructure tbs)
- Prepares a new X509 certificate from an existing X509 certificate.
- Parameters:
tbs
- X509CertificateStructure
sign
public org.bouncycastle.asn1.x509.X509CertificateStructure sign(PKCS12 a_pkcs12Certificate)
sign
public org.bouncycastle.asn1.x509.X509CertificateStructure sign(org.bouncycastle.asn1.x509.X509Name a_issuer,
IMyPrivateKey a_privateKey)