#include <wtlscertchain.h>
Link against:
wtlscert.lib
class CWTLSCertChain : public CBase;
Description
Implements a WTLS certificate chain.
Derivation
CBase
-
Base class for all classes to be instantiated on the heap.
CWTLSCertChain
- Implements a WTLS certificate chain.
Members
Defined in CWTLSCertChain
:
AppendCertsL(const TPtrC8 &)
Appends the specified encoded certificate to the chain.
Cert(TInt)const
Gets the certificate at the specified index.
ChainHasRoot()const
Tests whether the root certificate of the chain is locatable.
Count()const
Gets the number of WTLS certificates in the chain.
NewL(RFs &,const TPtrC8 &,const CArrayPtr< CWTLSCertificate > &)
Creates a certificate chain using the binary data in aEncodedCerts.
NewL(RFs &,const TPtrC8 &,const TUid)
Creates a certificate chain using the binary data in aEncodedCerts.
NewLC(RFs &,const TPtrC8 &,const CArrayPtr< CWTLSCertificate > &)
Creates a certificate chain using the binary data in aEncodedCerts and puts a po...
NewLC(RFs &,const TPtrC8 &,const TUid)
Creates a certificate chain using the binary data in aEncodedCerts and puts a po...
ValidateL(CWTLSValidationResult &,const TTime &,TRequestStatus &)
Validates the chain.
~CWTLSCertChain()
Destructor.
Inherited from CBase
:
Construction and destruction
NewL(RFs &,const TPtrC8 &,const TUid)
IMPORT_C static CWTLSCertChain* NewL(RFs &aFs, const TPtrC8 &aEncodedCerts, const TUid aClient);
Description
Creates a certificate chain using the binary data in aEncodedCerts.
Parameters
RFs &aFs |
An open file server session.
|
const TPtrC8 &aEncodedCerts |
One or more concatenated DER encoded WTLS certificates. The first certificate will be interpreted as the end entity certificate
to be validated; subsequent certificates may be in any order and may be used by the chain as intermediate certificates, but
not root certificates.
|
const TUid aClient |
The uid of the client. It is a value identifying the application to the chain; this will be used to select a subset of stored
certificates to use as candidate root certificates.
|
|
Return value
NewLC(RFs &,const TPtrC8 &,const TUid)
IMPORT_C static CWTLSCertChain* NewLC(RFs &aFs, const TPtrC8 &aEncodedCerts, const TUid aClient);
Description
Creates a certificate chain using the binary data in aEncodedCerts and puts a pointer to the new object onto the cleanup stack.
Parameters
RFs &aFs |
An open file server session
|
const TPtrC8 &aEncodedCerts |
One or more concatenated DER encoded WTLS certificates. The first certificate will be interpreted as the end entity certificate
to be validated; subsequent certificates may be in any order and may be used by the chain as intermediate certificates, but
not root certificates.
|
const TUid aClient |
The uid of the client. It is a value identifying the application to the chain; this will be used to select a subset of stored
certificates to use as candidate root certificates.
|
|
Return value
NewL(RFs &,const TPtrC8 &,const CArrayPtr< CWTLSCertificate > &)
IMPORT_C static CWTLSCertChain* NewL(RFs &aFs, const TPtrC8 &aEncodedCerts, const CArrayPtr< CWTLSCertificate > &aRootCerts);
Description
Creates a certificate chain using the binary data in aEncodedCerts.
Parameters
RFs &aFs |
An open file server session.
|
const TPtrC8 &aEncodedCerts |
One or more concatenated DER encoded WTLS certificates. The first certificate will be interpreted as the end entity certificate
to be validated; subsequent certificates may be in any order and may be used by the chain as intermediate certificates, but
not root certificates. Any self signed certificates supplied here after the first one will be discarded, as self signed certificates
cannot by definition be intermediate certificates.
|
const CArrayPtr < CWTLSCertificate > &aRootCerts |
An array of certificates which the chain will treat as candidate root certificates. If one of these overloads is used, the
chain will not look in stores for root certificates, but will only use the certificates supplied here.
|
|
Return value
NewLC(RFs &,const TPtrC8 &,const CArrayPtr< CWTLSCertificate > &)
IMPORT_C static CWTLSCertChain* NewLC(RFs &aFs, const TPtrC8 &aEncodedCerts, const CArrayPtr< CWTLSCertificate > &aRootCerts);
Description
Creates a certificate chain using the binary data in aEncodedCerts and puts a pointer to the new object onto the cleanup stack.
Parameters
RFs &aFs |
An open file server session.
|
const TPtrC8 &aEncodedCerts |
One or more concatenated DER encoded WTLS certificates. The first certificate will be interpreted as the end entity certificate
to be validated; subsequent certificates may be in any order and may be used by the chain as intermediate certificates, but
not root certificates. Any self signed certificates supplied here after the first one will be discarded as self signed certificates
cannot by definition be intermediate certificates.
|
const CArrayPtr < CWTLSCertificate > &aRootCerts |
An array of certificates which the chain will treat as candidate root certificates. If one of these overloads is used, the
chain will not look in stores for root certificates, but will only use the certificates supplied here.
|
|
Return value
IMPORT_C ~CWTLSCertChain();
Description
Destructor.
Frees all resources owned by the object.
ValidateL(CWTLSValidationResult &,const TTime &,TRequestStatus &)
IMPORT_C void ValidateL(CWTLSValidationResult &aValidationResult, const TTime &aValidationTime, TRequestStatus &aStatus);
Description
Validates the chain.
Parameters
CWTLSValidationResult &aValidationResult |
On completion, this contains the result of the validation.
|
const TTime &aValidationTime |
The time for which validation should be performed, usually the current time.
|
TRequestStatus &aStatus |
An asynchronous request status object.
|
|
IMPORT_C TInt Count() const;
Description
Gets the number of WTLS certificates in the chain.
Return value
TInt
|
The number of WTLS certificates in the chain.
|
|
IMPORT_C const CWTLSCertificate& Cert(TInt aIndex) const;
Description
Gets the certificate at the specified index.
Parameters
TInt aIndex |
The ordinal number representing the position of the certificate within the chain.
|
|
Return value
IMPORT_C TBool ChainHasRoot() const;
Description
Tests whether the root certificate of the chain is locatable.
Note that the value is only significant after a successfull call to CWTLSCertChain::ValidateL(CWTLSValidationResult &,const TTime &,TRequestStatus &)
.
Return value
TBool
|
ETrue if the chain has a root; EFalse, otherwise.
|
|
AppendCertsL(const TPtrC8 &)
IMPORT_C void AppendCertsL(const TPtrC8 &aEncodedCerts);
Description
Appends the specified encoded certificate to the chain.
Parameters
const TPtrC8 &aEncodedCerts |
One or more concatenated DER encoded WTLS certificates. These certificates will be used as candidates. The first certificate
will be interpreted as the end entity certificate to be validated; subsequent certificates may be in any order and may be
used by the chain as intermediate certificates, but not root certificates.
|
|