diff -r 09b1ac925e3f -r 03674e5abf46 cpsecplugins/cpadvancedsecplugin/inc/cpcertdatacontainer.h --- a/cpsecplugins/cpadvancedsecplugin/inc/cpcertdatacontainer.h Tue Aug 31 16:04:40 2010 +0300 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,216 +0,0 @@ -/* -* Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "Eclipse Public License v1.0" -* which accompanies this distribution, and is available -* at the URL "http://www.eclipse.org/legal/epl-v10.html". -* -* Initial Contributors: -* Nokia Corporation - initial contribution. -* -* Contributors: -* -* Description: Declaration of the CCertManUIKeeper class -* -*/ - -#ifndef CPCERTDATACONTAINER_H -#define CPCERTDATACONTAINER_H - -// INCLUDES -#include -#include -#include - -// FORWARD DECLARATIONS -class CpCertManUISyncWrapper; -class CpCertManUICertData; - -// CONSTANTS -const TUid KCMDeviceCertStoreTokenUid = { 0x101FB668 }; -const TUid KCMDeviceKeyStoreTokenUid = { 0x101FB66A }; -const TUid KCMTrustedServerTokenUid = { 0x101FB66F }; -const TUid KCMFileKeyStoreTokenUid = { 0x101F7333 }; -const TUid KCMFileCertStoreTokenUid = { 0x101F501A }; - - -// CLASS DECLARATION - -/** -* CpCertDataContainer retrieves and holds certificates. -* -*/ -class CpCertDataContainer : public CBase - { - public: // functions - - /** - * Default constructor - */ - CpCertDataContainer(); - - /** - * Destructor. - */ - ~CpCertDataContainer(); - - /** - * NewL - */ - static class CpCertDataContainer* NewL(); - - /** - * NewLC - */ - static class CpCertDataContainer* NewLC(); - - CUnifiedCertStore*& CertManager(); - - CUnifiedKeyStore*& KeyManager(); - - /** - * Checks that cacerts.dat file is not corrupt - * and returns CA certificates from it. - */ - void RefreshCAEntriesL(); - - /** - * Checks that cacerts.dat file is not corrupt - * and returns user certificates from it. - */ - void RefreshUserCertEntriesL(); - - /** - * Returns peer certificates. - */ - void RefreshPeerCertEntriesL(); - - /** - * Returns peer certificates. - */ - void RefreshDeviceCertEntriesL(); - - /** - * Shows error note - */ - void ShowErrorNoteL(TInt aError); - - public: //data - - /** - * To store CA certificate entries for Authority and Trust view - * Includes label from x509certnameparser. - */ - RMPointerArray iCALabelEntries; - - /** - * To store CA certificate entries for Authority and Trust view - * Includes label from x509certnameparser. - */ - RMPointerArray iUserLabelEntries; - - /** - * To store Peer certificate entries for Trusted Site view - * Includes label from x509certnameparser. - */ - RMPointerArray iPeerLabelEntries; - - /** - * To store Peer certificate entries for Device certificate view - * Includes label from x509certnameparser. - */ - RMPointerArray iDeviceLabelEntries; - - /** - * Used to wrap asynchronous calls - */ - CpCertManUISyncWrapper* iWrapper; - - /** - * File session handle. - */ - RFs iRfs; - - private: // functions - - void ConstructL(); - - private: //data - - /** - * To list certificates with criteria. - */ - CCertAttributeFilter* iFilter; - - /** - * To list keys with criteria. - */ - - TCTKeyAttributeFilter* iKeyFilter; - - /** - * UnifiedCertStore - */ - CUnifiedCertStore* iStore; - - /** - * UnifiedKeyStore - */ - CUnifiedKeyStore* iKeyStore; - - /** - * To store CA certificate entries. - */ - RMPointerArray iCAEntries; - - /** - * To store User certificate entries. - */ - RMPointerArray iUserEntries; - - /** - * To store Peer certificate entries. - */ - RMPointerArray iPeerEntries; - - /** - * To store Device certificate entries. - */ - RMPointerArray iDeviceEntries; - - /** - * To store Key entries - */ - RMPointerArray iKeyEntries; - - }; - -/** -* Small helper class to put label and certificate in same class. -* -*/ -class CpCertManUICertData : public CBase - { - public: - - CpCertManUICertData(); - - void Release(); - - HBufC* iCAEntryLabel; - HBufC* iUserEntryLabel; - HBufC* iPeerEntryLabel; - HBufC* iDeviceEntryLabel; - CCTCertInfo* iCAEntry; - CCTCertInfo* iUserEntry; - CCTCertInfo* iPeerEntry; - CCTCertInfo* iDeviceEntry; - - private: - ~CpCertManUICertData(); - - }; - - -#endif // CPCERTDATACONTAINER_H