epoc32/include/cctcertinfo.h
author William Roberts <williamr@symbian.org>
Tue, 16 Mar 2010 16:12:26 +0000
branchSymbian2
changeset 2 2fe1408b6811
parent 0 061f57f2323e
child 4 837f303aceeb
permissions -rw-r--r--
Final list of Symbian^2 public API header files
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
2
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
     1
/*
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
     2
* Copyright (c) 2001-2009 Nokia Corporation and/or its subsidiary(-ies).
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
     3
* All rights reserved.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
     4
* This component and the accompanying materials are made available
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
     5
* under the terms of the License "Eclipse Public License v1.0"
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
     6
* which accompanies this distribution, and is available
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
     7
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
     8
*
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
     9
* Initial Contributors:
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    10
* Nokia Corporation - initial contribution.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    11
*
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    12
* Contributors:
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    13
*
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    14
* Description: 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    15
* CCTCertInfo.H
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    16
*
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    17
*/
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    18
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    19
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    20
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    21
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    22
/**
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    23
 @file 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    24
 @internalTechnology
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    25
*/
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    26
 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    27
#ifndef __CCTCERTINFO_H__
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    28
#define __CCTCERTINFO_H__
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    29
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    30
#include <e32base.h>
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    31
#include <s32strm.h>
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    32
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    33
#include <securitydefs.h>
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    34
#include <ct/mcttokentype.h>
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    35
#include <ct/mcttoken.h>
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    36
#include <ct/mcttokenobject.h>
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    37
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    38
/** Mask constants used for serializing iDeletable and iFormat attributes 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    39
*/
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    40
const TUint KReadOnlyFlagMask = 128;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    41
const TUint KFormatMask = 127;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    42
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    43
/** The UID of a CertInfo MCTTokenObject. */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    44
const TInt KCTObjectCertInfo = 0x101F50E6;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    45
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    46
/** The maximum length of a certificate label. */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    47
const TUint32 KMaxCertLabelLength = 64;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    48
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    49
/** Defines a modifiable buffer descriptor to contain a human-readable certificate label. 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    50
*
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    51
* @publishedAll
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    52
* @released */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    53
typedef TBuf<KMaxCertLabelLength> TCertLabel;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    54
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    55
/**
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    56
 * Mix-in class representnig data about a stored certificate.  Provides
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    57
 * implementation of serialization.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    58
 * 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    59
 * Note that for backward compatibility reasons, the issuer hash is not serialised.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    60
 *
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    61
 * @internalTechnology
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    62
 */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    63
class MCertInfo
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    64
	{
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    65
 public:
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    66
	// Internalization/Externalization
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    67
	// Externalize. Writes the data out to a stream
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    68
	
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    69
  /** Externalises an object of this class to a write stream.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    70
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    71
	* The presence of this function means that the standard templated operator<<() 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    72
	* can be used to externalise objects of this class.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    73
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    74
	* @param aStream	Stream to which the object should be externalised. */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    75
	IMPORT_C void ExternalizeL(RWriteStream& aStream) const;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    76
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    77
	// Internalize. Reads the data from a stream 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    78
	/** Internalises an object of this class from a read stream.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    79
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    80
	* The presence of this function means that the standard templated operator>>() 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    81
	* can be used to internalise objects of this class.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    82
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    83
	* Note that this function has assignment semantics: it replaces the old value 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    84
	* of the object with a new value read from the read stream.	
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    85
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    86
	* @param aStream	Stream from which the object should be internalised. */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    87
	IMPORT_C void InternalizeL(RReadStream& aStream);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    88
	
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    89
 protected:
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    90
	IMPORT_C MCertInfo();
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    91
	IMPORT_C MCertInfo(const TDesC& aLabel,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    92
					   TCertificateFormat aFormat,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    93
					   TCertificateOwnerType aCertificateOwnerType, 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    94
					   TInt aSize,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    95
					   const TKeyIdentifier* aSubjectKeyId,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    96
					   const TKeyIdentifier* aIssuerKeyId, 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    97
					   TInt aCertificateId,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    98
					   TBool aDeletable);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
    99
	IMPORT_C MCertInfo(const MCertInfo& aOther);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   100
	IMPORT_C ~MCertInfo();
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   101
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   102
	IMPORT_C void ConstructL(const TDesC8* aIssuerHash);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   103
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   104
	const TDesC8* IssuerHash() const;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   105
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   106
 private:
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   107
	TBool Valid() const;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   108
	const MCertInfo& operator=(const MCertInfo& aOther);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   109
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   110
 protected:
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   111
	TCertLabel iLabel;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   112
	TInt iCertificateId;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   113
	TCertificateFormat iFormat;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   114
	TCertificateOwnerType iCertificateOwnerType;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   115
	TInt iSize;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   116
	TKeyIdentifier iSubjectKeyId;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   117
	TKeyIdentifier iIssuerKeyId;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   118
	TBool iDeletable;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   119
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   120
 private:
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   121
	HBufC8* iIssuerHash;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   122
	};
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   123
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   124
/** Encapsulates information about a stored certificate.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   125
 * 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   126
 * Objects of this type are usually returned by a certificate store, to allow 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   127
 * a client to query the contents of the store.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   128
 * 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   129
 * Note that these objects are normally constructed by certificate stores, not 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   130
 * by clients. 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   131
 *
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   132
 * @publishedAll
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   133
 * @released
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   134
 */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   135
class CCTCertInfo : protected CBase, public MCTTokenObject, public MCertInfo
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   136
	{
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   137
public:
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   138
	/** Construction -- Note that these objects are normally constructed by certificate stores, not by clients. */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   139
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   140
	/** 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   141
	* @publishedPartner
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   142
	* @released
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   143
	*
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   144
	* Creates the certificate information object by copying from an existing object.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   145
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   146
	* @param aCertInfo			The source certificate information.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   147
	* @return					A pointer to the new certificate information object.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   148
	* @leave KErrNoMemory	There is no memory to construct it. */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   149
	IMPORT_C static CCTCertInfo* NewL(const CCTCertInfo& aCertInfo);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   150
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   151
	/** 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   152
	* @publishedPartner
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   153
	* @released
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   154
	*
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   155
	* Creates the certificate information object by copying from an existing object, 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   156
	* and puts a pointer to the new object onto the cleanup stack.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   157
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   158
	* @param aCertInfo			The source certificate information.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   159
	* @return					A pointer to the new certificate information object.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   160
	* @leave KErrNoMemory	There is no memory to construct it. */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   161
	IMPORT_C static CCTCertInfo* NewLC(const CCTCertInfo& aCertInfo);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   162
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   163
	/** 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   164
	* @publishedPartner
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   165
	* @released
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   166
	*
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   167
	* Creates the certificate information object from its constituent parts.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   168
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   169
	* @param aLabel					The certificate's label.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   170
	* @param aFormat				The certificate's format.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   171
	* @param aCertificateOwnerType	The owner type.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   172
	* @param aSize					The size of the certificate.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   173
	* @param aSubjectKeyId			The subject key ID.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   174
	* @param aIssuerKeyId			The issuer key ID.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   175
	* @param aToken					The token that the certificate is within.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   176
	* @param aCertificateId			The ID within the object handle.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   177
	* @param aDeletable				The certificate is deletable.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   178
	* @param aIssuerHash			The hash of the DN of the issuer.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   179
	* @return						A pointer to the new certificate information object. 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   180
	* @leave KErrNoMemory		There is no memory to construct it.*/
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   181
	IMPORT_C static CCTCertInfo* NewL(const TDesC& aLabel, TCertificateFormat aFormat,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   182
		TCertificateOwnerType aCertificateOwnerType, TInt aSize,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   183
		const TKeyIdentifier* aSubjectKeyId, const TKeyIdentifier* aIssuerKeyId,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   184
		MCTToken& aToken, TInt aCertificateId, TBool aDeletable, 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   185
									  const TDesC8* aIssuerHash = NULL);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   186
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   187
	/** 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   188
	* @publishedPartner
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   189
	* @released
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   190
	*
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   191
	* Creates the certificate information object from its constituent parts.	
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   192
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   193
	* @param aLabel					The certificate's label.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   194
	* @param aFormat 				The certificate's format.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   195
	* @param aCertificateOwnerType	The owner type.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   196
	* @param aSize					The size of the certificate.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   197
	* @param aSubjectKeyId			The subject key ID.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   198
	* @param aIssuerKeyId			The issuer key ID.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   199
	* @param aToken					The token that the certificate is within.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   200
	* @param aCertificateId			The ID within the object handle.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   201
	* @return 						A pointer to the new certificate information object.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   202
	* @leave KErrNoMemory		There is no memory to construct it.*/
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   203
	IMPORT_C static CCTCertInfo* NewL(const TDesC& aLabel, TCertificateFormat aFormat,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   204
		TCertificateOwnerType aCertificateOwnerType, TInt aSize,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   205
		const TKeyIdentifier* aSubjectKeyId, const TKeyIdentifier* aIssuerKeyId,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   206
		MCTToken& aToken, TInt aCertificateId);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   207
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   208
	/** 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   209
	* @publishedPartner
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   210
	* @released
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   211
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   212
	* Creates the certificate information object from its constituent parts, 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   213
	* and puts a pointer to the new object onto the cleanup stack.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   214
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   215
	* @param aLabel					The certificate's label.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   216
	* @param aFormat				The certificate's format.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   217
	* @param aCertificateOwnerType	The owner type.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   218
	* @param aSize					The size of the certificate.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   219
	* @param aSubjectKeyId			The subject key ID.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   220
	* @param aIssuerKeyId			The issuer key ID.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   221
	* @param aToken					The token that the certificate is within.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   222
	* @param aCertificateId			The ID within the object handle.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   223
	* @param aDeletable				The certificate is deletable.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   224
	* @param aIssuerHash			The hash of the issuer's DN.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   225
	* @return						A pointer to the new certificate information object. 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   226
	* @leave KErrNoMemory		There is no memory to construct it.*/
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   227
	IMPORT_C static CCTCertInfo* NewLC(const TDesC& aLabel, TCertificateFormat aFormat,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   228
		TCertificateOwnerType aCertificateOwnerType, TInt aSize,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   229
		const TKeyIdentifier* aSubjectKeyId, const TKeyIdentifier* aIssuerKeyId,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   230
		MCTToken& aToken, TInt aCertificateId, TBool aDeletable, 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   231
									   const TDesC8* aIssuerHash = NULL);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   232
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   233
	/**
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   234
	* @publishedPartner
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   235
	* @released
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   236
	*
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   237
	* Creates the certificate information object from its constituent parts, and puts 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   238
	* a pointer to the new object onto the cleanup stack.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   239
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   240
	* @param aLabel					The certificate's label.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   241
	* @param aFormat				The certificate's format.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   242
	* @param aCertificateOwnerType	The owner type.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   243
	* @param aSize					The size of the certificate.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   244
	* @param aSubjectKeyId			The subject key ID.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   245
	* @param aIssuerKeyId			The issuer key ID.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   246
	* @param aToken					The token that the certificate is within.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   247
	* @param aCertificateId			The ID within the object handle.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   248
	* @return						A pointer to the new certificate information object.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   249
	* @leave KErrNoMemory		There is no memory to construct it.*/
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   250
	IMPORT_C static CCTCertInfo* NewLC(const TDesC& aLabel, TCertificateFormat aFormat,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   251
		TCertificateOwnerType aCertificateOwnerType, TInt aSize,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   252
		const TKeyIdentifier* aSubjectKeyId, const TKeyIdentifier* aIssuerKeyId,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   253
		MCTToken& aToken, TInt aCertificateId);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   254
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   255
	/** 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   256
	* @publishedPartner
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   257
	* @released
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   258
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   259
	* Creates the certificate information object by internalising a previously externalised 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   260
	* one.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   261
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   262
	* @param aStream			The stream from which the object is to be internalised.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   263
	* @param aToken				The token that it is within.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   264
	* @return					A pointer to the new certificate information object. 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   265
	* @leave KErrNoMemory	There is no memory to construct it.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   266
	* @see ExternalizeL
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   267
	* @see InternalizeL */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   268
	IMPORT_C static CCTCertInfo* NewL(RReadStream& aStream, MCTToken& aToken);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   269
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   270
	/** 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   271
	* @publishedPartner
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   272
	* @released
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   273
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   274
	* Creates the certificate information object, by internalising a previously externalised 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   275
	* one, and puts a pointer to the new object onto the cleanup stack.	
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   276
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   277
	* @param aStream			The stream from which the object is to be internalised.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   278
	* @param aToken				The token that it is within.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   279
	* @return					A pointer to the new certificate information object. 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   280
	* @leave KErrNoMemory	There is no memory to construct it.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   281
	* @see ExternalizeL
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   282
	* @see InternalizeL */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   283
	IMPORT_C static CCTCertInfo* NewLC(RReadStream& aStream, MCTToken& aToken);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   284
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   285
	/** Gets the subject key ID.	
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   286
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   287
	* @return A reference to a key identifier object. */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   288
	IMPORT_C const TKeyIdentifier& SubjectKeyId() const;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   289
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   290
	/** Gets the issuer key ID.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   291
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   292
	* @return A reference to a key identifier object. */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   293
	IMPORT_C const TKeyIdentifier& IssuerKeyId() const;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   294
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   295
	/** Gets the certificate format.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   296
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   297
	* @return The certificate format. */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   298
	IMPORT_C TCertificateFormat CertificateFormat() const;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   299
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   300
	/** Gets the owner type.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   301
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   302
	* @return The owner type. */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   303
	IMPORT_C TCertificateOwnerType CertificateOwnerType() const;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   304
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   305
	/** Gets the size of the certificate.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   306
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   307
	* Note that this function must be called so that the correct size of descriptor 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   308
	* can be allocated when retrieving the certificate (with MCertStore::Retrieve()).
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   309
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   310
	* @return The size of the certificate. */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   311
	IMPORT_C TInt Size() const;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   312
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   313
	/** Gets a handle for the object.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   314
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   315
	* The primary purpose of the handle is to allow token objects to be 'passed' 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   316
	* between processes.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   317
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   318
	* @return	A handle for the object. 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   319
	* @see TCTTokenObjectHandle */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   320
	IMPORT_C TCTTokenObjectHandle Handle() const;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   321
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   322
	/** Whether the certificate is deletable.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   323
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   324
	* @return	ETrue if it is possible to delete the certificate; EFalse, otherwise. */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   325
	IMPORT_C TBool IsDeletable() const;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   326
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   327
	/** Gets the hash of the issuer's DN.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   328
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   329
	* @return	The hash of the issuer's DN, or NULL if not known. */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   330
	IMPORT_C const TDesC8* IssuerHash() const;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   331
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   332
 public:	
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   333
  // from MCTTokenObject
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   334
	/** Gets the object's human-readable label.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   335
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   336
	* @return	The object's human-readable label.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   337
	* @see MCTTokenObject::Label()*/
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   338
	virtual const TDesC& Label() const;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   339
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   340
	/** Gets a reference to the associated token.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   341
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   342
	* @return	A reference to the associated token.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   343
	* @see MCTTokenObject::Token()*/
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   344
	virtual MCTToken& Token() const;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   345
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   346
	/** Gets a UID representing the type of the token object.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   347
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   348
	* The function overrides MCTTokenObject::Type().
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   349
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   350
	* The meanings of possible UIDs should be documented in the documentation for 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   351
	* the interface that returns them.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   352
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   353
	* @return	A UID representing the type of the token object; this implementation 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   354
	* 			returns KCTObjectCertInfo.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   355
	* @see MCTTokenObject::Type() */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   356
	virtual TUid Type() const;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   357
	
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   358
	// Compares 2 cert infos
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   359
	/** Compares this certificate information object with a specified Certificate 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   360
	* Information object for equality.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   361
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   362
	* @param aCertInfo	The certificate information object to be compared.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   363
	* @return			ETrue, if they are the same; EFalse, otherwise. */
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   364
	IMPORT_C TBool operator ==(const CCTCertInfo& aCertInfo) const;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   365
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   366
	/** Sets the certificate Id.
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   367
	* 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   368
	* @param aCertId The certificate Id.*/
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   369
	IMPORT_C void SetCertificateId(TInt aCertId);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   370
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   371
 protected:
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   372
	IMPORT_C virtual ~CCTCertInfo();
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   373
	
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   374
 private:
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   375
	CCTCertInfo(MCTToken& aToken);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   376
	CCTCertInfo(const TDesC& aLabel, TCertificateFormat aFormat,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   377
				TCertificateOwnerType aCertificateOwnerType, 
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   378
				TInt aSize,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   379
				const TKeyIdentifier* aSubjectKeyId,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   380
				const TKeyIdentifier* aIssuerKeyId,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   381
				MCTToken& aToken, TInt aCertificateId,
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   382
				TBool aDeletable);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   383
	CCTCertInfo(const CCTCertInfo& aCertInfo);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   384
	void ConstructL(RReadStream& aStream);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   385
	void ConstructL(const TDesC8* aIssuerHash);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   386
	
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   387
 private:
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   388
	const CCTCertInfo& operator=(const CCTCertInfo& aOther);
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   389
	
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   390
 private:	
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   391
	MCTToken& iToken;
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   392
	};
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   393
2fe1408b6811 Final list of Symbian^2 public API header files
William Roberts <williamr@symbian.org>
parents: 0
diff changeset
   394
#endif