class OpenSSLCertificateGeneratorImpl

This class is the subclass of CertificateGeneratorImpl,it implements the methods used to initialize and generate a Certificate which contains an OpenSSLX509CertficateImpl.

Inheritance:


Public Methods

[more] OpenSSLCertificateGeneratorImpl ()
Constructs this object
[more] ~OpenSSLCertificateGeneratorImpl ()
Deletes this object
[more]void setSubject (const DistinguishedName& subject)
Sets the subject of this certificate.
[more]void setSubjectPublicKey (const PublicKey& subjectKey)
Sets the public key of this certificate.
[more]void setIssuer (const DistinguishedName& issuer)
Sets the issuer of this certificate.
[more]void setValidity (int days)
Sets the number of days that the certificate will be valid
[more]void setSerialNumber (long serialNumber)
Sets the serial number of this certificate.
[more]void setVersionNumber (long versionNumber)
Sets the version number of this certificate.
[more]Certificate generate (const string& algorithm, const PrivateKey& privateKey)
Signs the certificate using the signature algorithm specified by algorithm and the guarantor's private key specified by privateKey.
[more]string paramString () const
Returns string of items of this certificate for correctness check


Inherited from CertificateGeneratorImpl:


Documentation

This class is the subclass of CertificateGeneratorImpl,it implements the methods used to initialize and generate a Certificate which contains an OpenSSLX509CertficateImpl. Once a certificate has been generated and signed it can no longer be modified. The methods includes setting the subject, subject's publicKey, issuer, validity, serial number, version number. It generates and signs the Certificate with a specified algorithm and privateKey. Also, it will display the Certificate as a string. The certificate generation is done by calls to the openssl libraries.

o OpenSSLCertificateGeneratorImpl()
Constructs this object

o ~OpenSSLCertificateGeneratorImpl()
Deletes this object

ovoid setSubject(const DistinguishedName& subject)
Sets the subject of this certificate.

Parameters:
subject - DistinguishedName is the subject of this certificate

ovoid setSubjectPublicKey(const PublicKey& subjectKey)
Sets the public key of this certificate.

Parameters:
subjectKey - PublicKey contains an OpenSSLPublicKeyImpl that contains the public key of the subject

ovoid setIssuer(const DistinguishedName& issuer)
Sets the issuer of this certificate.

Parameters:
issuer - DistinguishedName is the issuer of this certificate

ovoid setValidity(int days)
Sets the number of days that the certificate will be valid

Parameters:
days - int the number of days that the certificate will be valid

ovoid setSerialNumber(long serialNumber)
Sets the serial number of this certificate.

Parameters:
serialNumber - long the serial number

ovoid setVersionNumber(long versionNumber)
Sets the version number of this certificate.

Parameters:
versionNumber - long the version number

oCertificate generate(const string& algorithm, const PrivateKey& privateKey)
Signs the certificate using the signature algorithm specified by algorithm and the guarantor's private key specified by privateKey. the privateKey should reference an OpenSSLPrivateKeyImpl.

Throws:
SecurityException: unrecognized public key
SecurityException: unrecognized private key
SecurityException: signature failed
Parameters:
- algorithm string the specified algorithm
privateKey - PrivateKey the private key of the guarantor
Returns:
the generated certificate
See Also:
generate

ostring paramString() const
Returns string of items of this certificate for correctness check


This class has no child classes.
Author:
Srilekha Mudumbai Abdelilah Essiari
Version:
1.1 00/05/01

Alphabetic index HTML hierarchy of classes or Java



This page was generated with the help of DOC++.