os/security/cryptoservices/certificateandkeymgmt/inc/unifiedcertstore_v2.h
author sl@SLION-WIN7.fritz.box
Fri, 15 Jun 2012 03:10:57 +0200
changeset 0 bde4ae8d615e
permissions -rw-r--r--
First public contribution.
     1 /*
     2 * Copyright (c) 2001-2009 Nokia Corporation and/or its subsidiary(-ies).
     3 * All rights reserved.
     4 * This component and the accompanying materials are made available
     5 * under the terms of the License "Eclipse Public License v1.0"
     6 * which accompanies this distribution, and is available
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
     8 *
     9 * Initial Contributors:
    10 * Nokia Corporation - initial contribution.
    11 *
    12 * Contributors:
    13 *
    14 * Description: 
    15 * UNIFIEDCERTSTORE.H
    16 * The unified certificate store implementation
    17 *
    18 */
    19 
    20 
    21 /**
    22  @file 
    23  @publishedAll
    24  @released
    25 */
    26  
    27 #ifndef __UNIFIEDCERTSTORE_H__
    28 #define __UNIFIEDCERTSTORE_H__
    29 
    30 class CCertificate;
    31 
    32 #include <signed.h>
    33 #include <e32std.h>
    34 #include <f32file.h>
    35 #include <e32property.h>
    36 #include <sacls.h>
    37 #include <mcertstore.h>
    38 #include <ct/rmpointerarray.h>
    39 #include <ct/rcpointerarray.h>
    40 
    41 
    42 
    43 
    44 /**  
    45  *
    46  * Publish and Subscribe - UnifiedCertSTore Category
    47  * Aliased here to System Category to prevent SC break.
    48  *
    49  */
    50 const TUid KUnifiedCertStorePropertyCat = {KUidSystemCategoryValue};
    51 
    52 /**  
    53  *
    54  * Publish and subscribe key for UnifiedCertSTore.
    55  */
    56 enum TUnifiedCertStoreKey
    57 	{
    58 	/**  
    59  	 *
    60  	 * The Publish and subscribe key for the certstore changes.
    61 	 * If the client of the UnifiedCertstore needs to be notified when
    62 	 * certificate addition, removal and trust&application setting occurs,
    63 	 * the client needs to subscribe to KUnifiedCertStorePropertyCat and
    64 	 * EUnifiedCertStoreFlag.
    65 	 *
    66 	 * Aliased here to KUidUnifiedCertstore flag to avoid SC break.
    67  	 */
    68  	EUnifiedCertStoreFlag = KUidUnifiedCertstoreFlag
    69  	};
    70 
    71 /**
    72  *
    73  * The Unique ID for unknown hardware certstore, used as the input parameter when it is to be filtered.
    74  * @deprecated. Used only for Data compatibility.
    75  */
    76 
    77 const TInt KUnknownHardwareCertStore = 0;
    78 
    79 
    80 /**
    81  *
    82  * The Unique ID for mutable software certstore, used as the input parameter when it is to be filtered.
    83  *
    84  */
    85 
    86 const TInt KThirdPartyCertStore = 1;
    87 
    88 
    89 /**
    90  *
    91  * The Unique ID for SIM certstore, used as the input parameter when it is to be filtered.
    92  *
    93  */
    94 
    95 const TInt KSIMCertStore  = 2;
    96 
    97 /**
    98  *
    99  * The Unique ID for WIM certstore, used as the input parameter when it is to be filtered.
   100  *  
   101  */
   102 
   103 const TInt KWIMCertStore  = 3;
   104 
   105 /**  
   106  *
   107  * The Unique ID for UICC certstore, used as the input parameter when it is to be filtered.
   108  *  
   109  */
   110 const TInt KUICCCertStore = 4;
   111 
   112 /**  
   113  *
   114  * The Unique ID for immutable software certstore, used as the input parameter when it is to be filtered.
   115  *  
   116  */
   117 
   118 const TInt KManufactureCertStore = 5;
   119 
   120 // Forward declarations
   121 class MCTCertStore;
   122 class MCTWritableCertStore;
   123 class MCTTokenInterface;
   124 class MCTToken;
   125 class MCTTokenType;
   126 class CCTCertInfo;
   127 class CCertAttributeFilter;
   128 class CCTTokenTypeInfo;
   129 class TCTTokenObjectHandle;
   130 class CCheckedCertStore;
   131 
   132 // This class is forward declared to avoid including its definition in this
   133 // exported header file because it must only be used internally.
   134 class CUnifiedCertStoreWorkingVars;
   135 class CX500DistinguishedName;
   136 
   137 /**
   138  * The unified certificate store.
   139  * 
   140  * This class provides a certificate store whose contents are the sum of the
   141  * contents of all certificate store implementations on the device.  It is
   142  * intended as the single point of access for clients wishing to use certificate
   143  * stores.
   144  *
   145  * Since this class is intended for widespread use, capability checks relating
   146  * to certificate access are documented here even though the checks are actually
   147  * made in the individual cert store implementations.
   148  * 
   149  */
   150 NONSHARABLE_CLASS(CUnifiedCertStore) : public CActive, public MCertStore
   151 	{
   152 public:
   153 	/** 
   154 	 * Creates a new CUnifiedCertStore
   155 	 *
   156 	 * @param aFs			A file server session. It must already be open.
   157 	 * @param aOpenForWrite	ETrue if the stores must be opened with write access
   158 	 *						(e.g. for adding certificates) and EFalse if the user 
   159 	 *						only needs read-only access.
   160 	 * @return				A pointer to an instance of the CUnifiedCertStore class.
   161 	 */
   162 	IMPORT_C static CUnifiedCertStore* NewL(RFs& aFs, TBool aOpenForWrite);
   163 	
   164 	/** 
   165 	 * Creates a new CUnifiedCertStore and pushes it on the cleanup stack.
   166 	 *
   167 	 * @param aFs			A file server session. It must already be open.
   168 	 * @param aOpenForWrite	ETrue if the stores must be opened with write access
   169 	 *						(e.g. for adding certificates) and EFalse if the user
   170 	 *						only needs read-only access.
   171 	 * @return				A pointer to an instance of the CUnifiedCertStore class.
   172 	 */
   173 	IMPORT_C static CUnifiedCertStore* NewLC(RFs& aFs, TBool aOpenForWrite);
   174  	/** 
   175  	 * Creates a new CUnifiedCertStore with the sequence filter, so that multiple certstores that are managed
   176 	 * by it will be filtered and ordered.
   177  	 *
   178  	 * @param aFs			A file server session. It must already be open.
   179  	 * @param aOpenForWrite	ETrue if the stores must be opened with write access
   180  	 *						(e.g. for adding certificates) and EFalse if the user
   181  	 *						only needs read-only access. Ownership is taken.
   182  	 * @param aOrderFilter  An array of the unique sequence IDs specifying CertStore ordering.
   183  	 * @return				A pointer to an instance of the CUnifiedCertStore class.
   184  	 */
   185  	IMPORT_C static CUnifiedCertStore* NewL(RFs& aFs, 
   186  	                                        TBool aOpenForWrite,
   187  	                                        RArray<TInt>& aOrderFilter);
   188  	/** 
   189  	 * Creates a new CUnifiedCertStore with the sequence filter, so that multiple certstores that are managed
   190 	 * by it will be filtered and ordered, and it is pushed on the cleanup stack.
   191  	 *
   192  	 * @param aFs			A file server session. It must already be open.
   193  	 * @param aOpenForWrite	ETrue if the stores must be opened with write access
   194  	 *						(e.g. for adding certificates) and EFalse if the user
   195  	 *						only needs read-only access. Ownership is taken.
   196  	 * @param aOrderFilter  An array of the unique sequence IDs specifying CertStore ordering.
   197  	 * @return				A pointer to an instance of the CUnifiedCertStore class.
   198  	 */
   199  	IMPORT_C static CUnifiedCertStore* NewLC(RFs& aFs, 
   200  	                                         TBool aOpenForWrite,
   201  	                                         RArray<TInt>& aOrderFilter);
   202 	
   203 	/**
   204 	 * The destructor destroys all the resources owned by this object.
   205 	 */
   206 	IMPORT_C ~CUnifiedCertStore();
   207 	
   208 	/**
   209 	 * Initializes the manager. 
   210 	 * 
   211 	 * It must be called after the manager has been constructed
   212 	 * and before any call to the manager functions.
   213 	 * 
   214 	 * This is an asynchronous request.
   215 	 * 
   216 	 * @param aStatus	The request status object; contains the result of the Initialize() 
   217 	 * 					request when complete. Set to KErrCancel if any outstanding request is cancelled.
   218 	 */
   219 	IMPORT_C void Initialize(TRequestStatus& aStatus);
   220 
   221 	/** 
   222 	 * Cancels an ongoing Initialize() operation.
   223 	 *
   224 	 * The operation completes with KErrCancel.
   225 	 */
   226 	IMPORT_C void CancelInitialize();
   227 
   228 public:	// Implementation of MCertStore interface
   229 
   230 	/** Lists all certificates that satisfy the supplied filter.
   231 	*
   232 	* @param aCertInfos	An array that the returned certificates are added to .
   233 	* @param aFilter	A filter to restrict which certificates are returned.
   234 	* @param aStatus	The request status object.
   235 	* 
   236 	*/
   237 	virtual void List(RMPointerArray<CCTCertInfo>& aCertInfos,
   238 					  const CCertAttributeFilter& aFilter, TRequestStatus& aStatus);
   239 	virtual void CancelList();
   240 	virtual void GetCert(CCTCertInfo*& aCertInfo, const TCTTokenObjectHandle& aHandle, 
   241 						 TRequestStatus& aStatus);
   242 	virtual void CancelGetCert();
   243 
   244 	/** Gets the list of applications . Applications are represented by UIDs .
   245 	* 	
   246 	* @param aCertInfos		An array of certificates .
   247 	* @param aApplications	An array that the returned application UIDs are added to.
   248 	* @param aStatus		The request status object.
   249 	*
   250 	*/
   251 	virtual void Applications(const CCTCertInfo& aCertInfo, 
   252 							  RArray<TUid>& aApplications, TRequestStatus &aStatus);
   253 	virtual void CancelApplications();
   254 	virtual void IsApplicable(const CCTCertInfo& aCertInfo, TUid aApplication, 
   255 							  TBool& aIsApplicable, TRequestStatus& aStatus);
   256 	virtual void CancelIsApplicable();
   257 	virtual void Trusted(const CCTCertInfo& aCertInfo, TBool& aTrusted, 
   258 						 TRequestStatus& aStatus);
   259 	virtual void CancelTrusted();
   260 	virtual void Retrieve(const CCTCertInfo& aCertInfo, TDes8& aEncodedCert,
   261 						  TRequestStatus& aStatus);
   262 	virtual void CancelRetrieve();
   263 
   264 public:	// Functions defined in MCTWritableCertStore except Add functions
   265 
   266 	/**
   267 	 * Removes a certificate.
   268 	 * 
   269 	 * @param aCertInfo				The certificate to be removed.
   270 	 * @param aStatus				The request status object; contains the result of the Remove() 
   271 	 * 								request when complete. Set to KErrCancel if an outstanding request is cancelled.
   272 	 *
   273 	 * @capability WriteUserData	This requires the WriteUserData capability when
   274 	 *								applied to user certificates.
   275 	 * @capability WriteDeviceData	This requires the WriteDeviceData capability
   276 	 *								when applied to CA certificates.
   277 	 * @leave KErrPermissionDenied	If the caller doesn't have the required
   278 	 *								capabilities.
   279 	 */
   280 	IMPORT_C void Remove(const CCTCertInfo& aCertInfo, TRequestStatus& aStatus);
   281 	
   282 	/** 
   283 	 * Cancels an ongoing Remove() operation.
   284 	 *
   285 	 * The operation completes with KErrCancel.
   286 	 */
   287 	IMPORT_C void CancelRemove();
   288 	
   289 	/**
   290 	 * Replaces the current applicability settings with the settings in the
   291 	 * supplied array.
   292 	 * 
   293 	 * This should only be called for CA certificates - it has no meaning for
   294 	 * user certificates.
   295 	 * 
   296 	 * @param aCertInfo		The certificate whose applicability should be updated.
   297 	 * @param aApplications	The new applicability settings. Ownership of this
   298 	 * 						remains with the caller, and it must remain valid for the
   299 	 * 						lifetime of the call.
   300 	 * @param aStatus		The request status object; contains the result of the SetApplicability() 
   301 	 * 						request when complete. Set to KErrCancel, if an outstanding request is cancelled.
   302 	 *
   303 	 * @capability WriteDeviceData	This requires the WriteDeviceData capability.
   304 	 * @leave KErrPermissionDenied	If the caller doesn't have the required capabilities.
   305 	 */
   306 	IMPORT_C void SetApplicability(const CCTCertInfo& aCertInfo, 
   307 		const RArray<TUid>& aApplications, TRequestStatus &aStatus);
   308 	
   309 	/** 
   310 	 * Cancels an ongoing SetApplicability() operation.
   311 	 *
   312 	 * The operation completes with KErrCancel.
   313 	 */
   314 	IMPORT_C void CancelSetApplicability();
   315 	
   316 	/**
   317 	 * Changes the trust settings.
   318 	 * 
   319 	 * A CA certificate is trusted if the user is willing to use it for authenticating
   320 	 * servers. It has no meaning with other types of certificates.
   321 	 * 
   322 	 * @param aCertInfo	The certificate to be updated.
   323 	 * @param aTrusted	ETrue, if trusted; EFalse, otherwise.
   324 	 * @param aStatus	The request status object; contains the result of the SetTrust() 
   325 	 * 					request when complete. Set to KErrCancel, if an outstanding request is cancelled.
   326 	 *
   327 	 * @capability WriteDeviceData This requires the WriteDeviceData capability.
   328 	 * @leave KErrPermissionDenied If the caller doesn't have the required capabilities.
   329 	 */
   330 	IMPORT_C void SetTrust(const CCTCertInfo& aCertInfo, TBool aTrusted, 
   331 		TRequestStatus& aStatus);
   332 	
   333 	/** 
   334 	 * Cancels an ongoing SetTrust() operation.
   335 	 *
   336 	 * The operation completes with KErrCancel.
   337 	 */
   338 	IMPORT_C void CancelSetTrust();
   339 
   340 public:
   341 	/**
   342 	 * Lists all certificates that have a particular subject DN.
   343 	 * 
   344 	 * @param aCertInfos	An array that the returned certificates are added to
   345 	 * @param aFilter		A filter to restrict which certificates are returned.
   346 	 * @param aIssuer		Only certificates with this issuer DN will be returned
   347 	 * @param aStatus		Asynchronous request status.
   348 	 */
   349 	IMPORT_C void List(RMPointerArray<CCTCertInfo>& aCertInfos,
   350 					   const CCertAttributeFilter& aFilter, 
   351 					   const TDesC8& aIssuer, 
   352 					   TRequestStatus& aStatus);
   353 
   354 	/**
   355 	 * Lists all certificates that have a particular issuer.
   356 	 * 
   357 	 * @param aCertInfos	An array that the returned certificates are added to
   358 	 * @param aFilter		A filter to restrict which certificates are returned.
   359 	 * @param aIssuers		Only certificates with this issuer will be returned
   360 	 * @param aStatus		Asynchronous request status.
   361 	 */
   362 	IMPORT_C void List(RMPointerArray<CCTCertInfo>& aCertInfos,
   363 					   const CCertAttributeFilter& aFilter, 
   364 					   RPointerArray<const TDesC8> aIssuers, 
   365 					   TRequestStatus& aStatus);
   366 
   367 	/**
   368 	 * Retrieves a certificate as a parsed object.
   369 	 *
   370 	 * This will only work for certificates that have a CCertificate-derived
   371 	 * representation, in other words X509 and WTLS certificates.  If called for
   372 	 * a URL certificate, KErrNotSupported is returned.
   373 	 * 
   374 	 * @param aCertInfo	The certificate to retrieve
   375 	 * @param aCert		The returned certificate.  This object can safely be up-cast
   376 	 *					to a CX509Certificate or CWTLSCertificate if it's known that
   377 	 *					that is the certificate format.
   378 	 * @param aStatus	Asynchronous request status.
   379 	 * 
   380 	 * @capability ReadUserData		This requires the ReadUserData capability when
   381 	 *								applied to user certificates, as these may contain
   382 	 *								sensitive user data.
   383 	 * @leave KErrPermissionDenied	If called for a user certificate when the
   384 	 *								caller doesn't have the ReadUserData capability.
   385 	 */
   386 	IMPORT_C void Retrieve(const CCTCertInfo& aCertInfo, CCertificate*& aCert,
   387 						   TRequestStatus& aStatus);
   388 	
   389 	/** 
   390 	 * Gets the number of certificate stores.
   391 	 *
   392 	 * @return	The total number of certificate stores.
   393 	 */
   394 	IMPORT_C TInt CertStoreCount() const;
   395 	
   396 	/**
   397 	 * Gets a particular certificate store.
   398 	 * 
   399 	 * @param aIndex	The index of the required certificate store.
   400 	 *					A number between 0 and CertStoreCount() - 1.
   401 	 * @return			The certificate store.
   402 	 */
   403 	IMPORT_C MCTCertStore& CertStore(TInt aIndex);
   404 	
   405 	/** 
   406 	 * Gets the number of writeable certificate stores.
   407 	 *
   408 	 * @return	The number of writeable certificate stores.
   409 	 */
   410 	IMPORT_C TInt WritableCertStoreCount() const;
   411 	
   412 	/**
   413 	 * Gets a particular writeable certificate store.
   414 	 *
   415 	 * @param aIndex	The index of the required certificate store.
   416 	 *					A number between 0 and WriteableCertStoreCount() - 1.
   417 	 * @return			The writeable certificate store.
   418 	 */
   419 	IMPORT_C MCTWritableCertStore& WritableCertStore(TInt aIndex);
   420 	
   421 	/** 
   422 	 * Gets the number of read-only certificate stores.
   423 	 *
   424 	 * @return	The number of read-only certificate stores.
   425 	 */
   426 	IMPORT_C TInt ReadOnlyCertStoreCount() const;
   427 	
   428 	/**
   429 	 * Gets a particular read-only certificate store.
   430 	 * 
   431 	 * @param aIndex	The index of the required certificate store.
   432 	 *					A number between 0 and ReadOnlyCertStoreCount() - 1.
   433 	 * @return			The read-only certificate store.
   434 	 */
   435 	IMPORT_C MCTCertStore& ReadOnlyCertStore(TInt aIndex);
   436 
   437 private:
   438 	enum TState
   439 		{
   440 		EIdle,
   441 
   442 		EInitializeGetTokenList,
   443 		EInitializeGetToken,
   444 		EInitializeGetWritableInterface,
   445 		EInitializeGetReadableInterface,
   446 		EInitializeGetReadableInterfaceFinished,
   447 		EInitializeFinished,
   448 
   449 		EList,
   450 		ERetrieve,
   451 		ERetrieveForList,
   452 
   453 		EGetCert,
   454 		EApplications,
   455 		EIsApplicable,
   456 		ETrusted,
   457 		ERetrieveData,
   458 		ERemove,
   459 		ESetApplicability,
   460 		ESetTrust
   461 		};
   462 	enum TCompareResults
   463 		{
   464 		ENo,
   465 		EYes,
   466 		EMaybe
   467 		};
   468 private:
   469 	CUnifiedCertStore(RFs& aFs, TBool aOpenForWrite);
   470 	void ConstructL(RArray<TInt>& aOrderFilter);
   471 	void DoCancel();
   472 	void RunL();
   473 	TInt RunError(TInt aError);
   474 
   475 	// Implementations for asynchronous operations
   476 	void InitializeL();
   477 	void ListL(RMPointerArray<CCTCertInfo>& aCertInfos,
   478 			   const CCertAttributeFilter& aFilter);
   479 	void ListL(RMPointerArray<CCTCertInfo>& aCertInfos,
   480 			  const CCertAttributeFilter& aFilter, 
   481 			  RPointerArray<const TDesC8> aIssuers);
   482 	void RetrieveL(const CCTCertInfo& aCertInfo, CCertificate*& aCert);
   483 	void GetCertL(CCTCertInfo*& aCertInfo, const TCTTokenObjectHandle& aHandle);
   484 	void ApplicationsL(const CCTCertInfo& aCertInfo, RArray<TUid>& aApplications);
   485 	void IsApplicableL(const CCTCertInfo& aCertInfo, TUid aApplication, 
   486 					   TBool& aIsApplicable);
   487 	void TrustedL(const CCTCertInfo& aCertInfo, TBool& aTrusted);
   488 	void RetrieveDataL(const CCTCertInfo& aCertInfo, TDes8& aEncodedCert);
   489 	void RemoveL(const CCTCertInfo& aCertInfo);
   490 	void SetApplicabilityL(const CCTCertInfo& aCertInfo,
   491 						   const RArray<TUid>& aApplications);
   492 	void SetTrustL(const CCTCertInfo& aCertInfo, TBool aTrusted);
   493 
   494 	// Helper functions
   495 	void AllocWorkingVarsL();
   496 	void BeginAsyncOp(TRequestStatus& aStatus, TState aState);	
   497 	void DestroyTemporaryMembers();
   498 	MCTCertStore* GetCertStore(const TCTTokenObjectHandle& aHandle);
   499 	void FindCertStoreL(const TCTTokenObjectHandle& aHandle);
   500 	void FindWritableCertStoreL(const TCTTokenObjectHandle& aHandle);
   501 	TCompareResults CompareCertInfoDN(const CCTCertInfo* aCertInfo);
   502 	TBool MatchL(const CX500DistinguishedName& aName) const;
   503 	void Complete(TInt aError);
   504 	void CancelOutstandingRequest();
   505  	
   506  	// Filters CertStores according to specified order.
   507  	void ApplyOrderingL(RCPointerArray<CCTTokenTypeInfo>& aTokenTypes);
   508  	
   509  	void FilterTokenTypesL(RCPointerArray<CCTTokenTypeInfo>& aSearchTokenTypes,
   510 						RCPointerArray<CCTTokenTypeInfo>& aTempTokenTypes,
   511 						TInt aOrderAttribute);
   512  
   513 private:
   514 	/**
   515 	 * A file server session, this is not logically a part of this class
   516 	 * but is needed for the client store and the file certstore.
   517 	 */
   518 	RFs& iFs;
   519 
   520 	TBool iOpenedForWrite;
   521 
   522 	RPointerArray<CCheckedCertStore> iReadOnlyCertStores;
   523 	RPointerArray<CCheckedCertStore> iWritableCertStores;
   524 	RPointerArray<CCheckedCertStore> iCertStores;
   525 
   526 	TBool iCurrentlyDoingReadOnly;
   527 
   528 	/**
   529 	 * This a TokenType retrieved from the iTokenTypes array.
   530 	 * We use this to get a list of Tokens and to open these Tokens.
   531 	 */
   532 	MCTTokenType* iTokenType;
   533 
   534 	/**
   535 	 * This is the list of Tokens for one of the Token Types of iTokenTypes.
   536 	 */
   537 	RCPointerArray<HBufC> iTokens;
   538 
   539 	/** All the UIDs of hardware token types */
   540 	RArray<TUid> iHardwareTypeUids;
   541 	/**
   542 	 * This is used as an index for the iTokens array when we try 
   543 	 * to get an interface to each of the tokens.
   544 	 */
   545 	TInt iIndexTokens;
   546 
   547 	/**
   548 	 * A Token interface. We will use the interface to get a readable or writable
   549 	 * certstore interface. The value is updated at EInitializeGetToken and used
   550 	 * at EInitializeGetWritableInterface.
   551 	 */
   552 	MCTToken* iToken;
   553 
   554 	/**
   555 	 * We use this to (temporarily) store the interface we obtained from iToken.
   556 	 * It will be inserted in iWritableCertStores or iCertStores.
   557 	 */
   558 	MCTTokenInterface* iTokenInterface;
   559 
   560  	/**
   561  	The index of the plugin certstore that is being processed
   562  	*/
   563 	TInt iIndex;
   564 
   565 	/**
   566 	 * This is the status of the caller of an asynchronous function. It must be set
   567 	 * to KRequestPending by the function while doing the processing.
   568 	 */
   569 	TRequestStatus* iClientStatus;
   570 
   571 	TState iState;
   572 
   573 	TBool iIsInitialized;
   574 
   575 	/**
   576 	 * This member holds all the variables that are only used to store temporary results
   577 	 * while performing a given operation. It must be initialized at the start of the
   578 	 * operation and deleted at the end of it whether the opeartion completes successfully
   579 	 * or not. When no operation is being performed it must be 0.
   580 	 */
   581 	CUnifiedCertStoreWorkingVars* iWorkingVars;
   582 
   583 	/**
   584 	 * The cert store in use by an outstanding async operation.
   585 	 */
   586 	MCTCertStore *iCurrentCertStore;
   587 
   588 	/**
   589 	 * The writable cert store in use by an outstanding async operation.
   590 	 */
   591 	MCTWritableCertStore *iCurrentWritableCertStore;
   592 
   593 	// Padding to keep class size constant
   594 	TInt32 iUnused1;
   595 	TInt32 iUnused2;
   596 	                  
   597  	// An array of Uids specifying Token Type ordering
   598  	RArray<TInt> iOrderAttributes;
   599  	
   600  	// Publish and subscribe property which is used to notify the 
   601 	// cerificate addition,removal and application&trust setting.
   602  	RProperty iPSCertstoreChangeProperty;
   603 
   604 	};
   605 
   606 #endif