installationservices/swi/source/sisregistry/server_legacy/sisregistryserversession.h
changeset 0 ba25891c3a9e
child 5 3eebb1e54d3a
equal deleted inserted replaced
-1:000000000000 0:ba25891c3a9e
       
     1 /*
       
     2 * Copyright (c) 2004-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 * CSisRegistrySession class definition
       
    16 *
       
    17 */
       
    18 
       
    19 
       
    20 /**
       
    21  @file 
       
    22  @released
       
    23  @internalComponent
       
    24 */
       
    25 #ifndef __SISREGISTRYSERVERSESSION_H__
       
    26 #define __SISREGISTRYSERVERSESSION_H__
       
    27 
       
    28 #include <e32base.h>
       
    29 #include <e32cmn.h>
       
    30 #include <swi/msisuihandlers.h>
       
    31 #include "sisregistryclientserver.h"
       
    32 #include "sisregistryserver.h"
       
    33 #include "sisregistrycache.h"
       
    34 
       
    35 // Forward Declarations
       
    36 class CX509Certificate;
       
    37 
       
    38 namespace Swi
       
    39 {
       
    40 /**
       
    41  * This enum is used to make IPC indexes used as arguments in function calls less obscure.
       
    42  * @internalComponent
       
    43  * @released
       
    44  */
       
    45 
       
    46 enum TIpcIndexes
       
    47 	{
       
    48 	EIpcArgument0 = 0,  ///< IPC indexes arguments 0
       
    49 	EIpcArgument1,      ///< IPC indexes arguments 1
       
    50 	EIpcArgument2,      ///< IPC indexes arguments 2
       
    51 	EIpcArgument3       ///< IPC indexes arguments 3
       
    52 	};
       
    53 	
       
    54 
       
    55 // Swi: Forward Declarations 
       
    56 class CIntegrityServices;
       
    57 class CSisRegistryPackage;
       
    58 class CSisRegistryCache;
       
    59 class CSisRevocationManager;
       
    60 class CSecurityManager;
       
    61 class CSisControllerVerifier;
       
    62 
       
    63 
       
    64 /**
       
    65  * @internalComponent
       
    66  * @released
       
    67  */
       
    68 
       
    69 class CSisRegistrySession : public CSession2
       
    70 	{
       
    71 public:
       
    72 	void CreateL();
       
    73 
       
    74 private:
       
    75 	~CSisRegistrySession();
       
    76 	
       
    77 	CSisRegistryServer& Server();
       
    78 	void ServiceL(const RMessage2& aMessage);
       
    79 	void ServiceError(const RMessage2& aMessage,TInt aError);
       
    80 	
       
    81  	void PanicClient(const RMessagePtr2& aMessage, TSisRegistryPanic aPanic);
       
    82 	
       
    83 	//////// Requests processing ////////
       
    84 	// general 
       
    85 	void RequestInstalledUidsL(const RMessage2& aMessage);
       
    86 	void RequestInstalledPackagesL(const RMessage2& aMessage);
       
    87 	void UidInstalledL(const RMessage2& aMessage);
       
    88 	void ControllerInstalledL(const RMessage2& aMessage);
       
    89 	void RequestRegistryEntryL(const RMessage2& aMessage);
       
    90 	void RequestSidToPackageL(const RMessage2& aMessage);
       
    91 	void RequestSidToFileNameL(const RMessage2& aMessage);
       
    92  	void RequestModifiableL(const RMessage2& aMessage);
       
    93  	void RequestHashL(const RMessage2& aMessage);	
       
    94 	void IsSidPresentL(const RMessage2& aMessage);
       
    95 	void ShutdownAllAppsL(const RMessage2& aMessage);
       
    96 	void PackageExistsInRomL(const RMessage2& aMessage);
       
    97 	void RequestStubFileEntriesL(const RMessage2& aMessage);
       
    98 	
       
    99 	// subsession oriented 
       
   100 	void OpenRegistryUidEntryL(const RMessage2& aMessage);
       
   101 	void OpenRegistryPackageEntryL(const RMessage2& aMessage);
       
   102 	void OpenRegistryNamesEntryL(const RMessage2& aMessage);
       
   103 	void CloseRegistryEntryL(const RMessage2& aMessage);
       
   104 	void RequestVersionRegistryEntryL(const RMessage2& aMessage);
       
   105 	void RequestPackageNameRegistryEntryL(const RMessage2& aMessage);
       
   106 	void RequestLocalizedVendorNameRegistryEntryL(const RMessage2& aMessage);
       
   107 	void RequestUniqueVendorNameRegistryEntryL(const RMessage2& aMessage);
       
   108 	void RequestUidRegistryEntryL(const RMessage2& aMessage);
       
   109 	void RequestLanguageRegistryEntryL(const RMessage2& aMessage);
       
   110 	void RequestPropertyRegistryEntryL(const RMessage2& aMessage);
       
   111 	void RequestFileNamesRegistryEntryL(const RMessage2& aMessage);
       
   112 	
       
   113 	void RequestFileDescriptionsRegistryEntryL(const RMessage2& aMessage);
       
   114 	
       
   115 	void RequestSidsRegistryEntryL(const RMessage2& aMessage);
       
   116 	void RequestSelectedDriveRegistryEntryL(const RMessage2& aMessage);
       
   117 	void RequestInstalledDrivesRegistryEntryL(const RMessage2& aMessage);
       
   118 	void RequestInstallTypeRegistryEntryL(const RMessage2& aMessage);
       
   119 	void RequestCertificateChainsRegistryEntryL(const RMessage2& aMessage);
       
   120 	void RequestHashRegistryEntryL(const RMessage2& aMessage);
       
   121     void RequestEmbeddedPackageRegistryEntryL(const RMessage2& aMessage);
       
   122     void RequestEmbeddingPackagesRegistryEntryL(const RMessage2& aMessage);
       
   123     void RequestPackageAugmentationsRegistryEntryL(const RMessage2& aMessage);
       
   124     void RequestPackageAugmentationsNumberL(const RMessage2& aMessage);
       
   125 	void RequestSizeRegistryEntryL(const RMessage2& aMessage);
       
   126 	void RequestPackageRegistryEntryL(const RMessage2& aMessage);
       
   127 
       
   128 	void UidPresentRegistryEntryL(const RMessage2& aMessage);
       
   129 	void SignedRegistryEntryL(const RMessage2& aMessage);
       
   130 	void RegistryEntryTrustL(const RMessage2& aMessage);
       
   131 	void TrustTimeStampL(const RMessage2& aMessage);
       
   132 	void TrustStatusEntryL(const RMessage2& aMessage);
       
   133 	void RevocationCheckEntryL(const RMessage2& aMessage);
       
   134 	void CancelRevocationCheckEntryL(const RMessage2& aMessage);
       
   135 	void InRomRegistryEntryL(const RMessage2& aMessage);
       
   136 	void PreInstalledRegistryEntryL(const RMessage2& aMessage);
       
   137 	void AugmentationRegistryEntryL(const RMessage2& aMessage);
       
   138 	void RequestControllersL(const RMessage2& aMessage);
       
   139 
       
   140 	// support for the writeable interface
       
   141 	void RegisterEntryL(const RMessage2& aMessage, TBool aNewEntry);	
       
   142 	void DeleteEntryL(const RMessage2& aMessage);
       
   143 	void RequestDependenciesRegistryEntryL(const RMessage2& aMessage);
       
   144 	void RequestDependentPackagesRegistryEntryL(const RMessage2& aMessage);
       
   145 	void AddDriveL(const RMessage2& aMessage);
       
   146 	void RemoveDriveL(const RMessage2& aMessage);
       
   147 	void DeletablePreInstalledRegistryEntryL(const RMessage2& aMessage);
       
   148 	void SignedBySuCertRegistryEntryL(const RMessage2& aMessage);
       
   149 
       
   150 	// Regenerate the registry cache from the disk
       
   151 	void RegenerateCacheL(const RMessage2& aMessage);
       
   152 	
       
   153 	/// Tells the server cache to update the trust status of the entry with
       
   154 	/// the specified uid. 
       
   155 	void UpdateTrustStatusL(const TUid& uid, 
       
   156 	                        const TSisTrustStatus& status );
       
   157 	
       
   158 	void VerifyControllerL(const RMessage2& aMessage);
       
   159 	
       
   160 	//Request to get the value of RemoveWithLastDependent flag
       
   161 	void RemoveWithLastDependentL(const RMessage2& aMessage);
       
   162 	//Request to set the value of RemoveWithLastDependent flag
       
   163 	void SetRemoveWithLastDependentL(const RMessage2& aMessage);
       
   164 
       
   165 	// Non-removable
       
   166 	void RequestRemovablePackagesL(const RMessage2& aMessage);
       
   167 	void IsRemovableL(const RMessage2& aMessage);
       
   168 	
       
   169 	void RecoverL(const RMessage2& aMessage);
       
   170 	
       
   171 	void LoggingFileInfoL(const RMessage2& aMessage);
       
   172 
       
   173 	void RequestMatchingSupportedLanguagesL(const RMessage2& aMessage);
       
   174 private:
       
   175     friend class CSisRevocationManager;
       
   176 	RFs iFs;
       
   177 
       
   178     CSisRevocationManager* iRevocationManager;
       
   179     CSisControllerVerifier* iSisControllerVerifier;
       
   180     RPointerArray<HBufC8> 	iControllerArray;
       
   181 	};
       
   182 	
       
   183 inline CSisRegistryServer& CSisRegistrySession::Server()
       
   184 	{
       
   185 	// cast to remove const-ness
       
   186 	return *static_cast<CSisRegistryServer*>(const_cast<CServer2*>(CSession2::Server()));
       
   187 	}
       
   188 	
       
   189 } //namespace
       
   190 
       
   191 #endif // __SISREGISTRYSERVERSESSION_H__