installationservices/swi/source/sisregistry/server/sisregistryserver.cpp
changeset 60 245df5276b97
parent 42 d17dc5398051
equal deleted inserted replaced
53:ae54820ef82c 60:245df5276b97
     1 /*
     1 /*
     2 * Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
     2 * Copyright (c) 2004-2010 Nokia Corporation and/or its subsidiary(-ies).
     3 * All rights reserved.
     3 * All rights reserved.
     4 * This component and the accompanying materials are made available
     4 * This component and the accompanying materials are made available
     5 * under the terms of the License "Eclipse Public License v1.0"
     5 * under the terms of the License "Eclipse Public License v1.0"
     6 * which accompanies this distribution, and is available
     6 * which accompanies this distribution, and is available
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
    46 	ESidToPackage,          			// accessible by all clients
    46 	ESidToPackage,          			// accessible by all clients
    47 	ESeparatorMinimumWriteUserData, // accessible by NetworkServices + WriteUserData clients only
    47 	ESeparatorMinimumWriteUserData, // accessible by NetworkServices + WriteUserData clients only
    48 	ESeparatorMinimumTCB, 			// accessible by TCB clients only
    48 	ESeparatorMinimumTCB, 			// accessible by TCB clients only
    49 	ESeparatorMinimumReadUserData2, 	// accessible by ReadUserData clients only
    49 	ESeparatorMinimumReadUserData2, 	// accessible by ReadUserData clients only
    50 	ESetComponentState,             // requests coming from SIF
    50 	ESetComponentState,             // requests coming from SIF
       
    51 	EAddAppRegInfo,                 // TCB only
    51 	ESeparatorEndAll,     			// not supported from there on
    52 	ESeparatorEndAll,     			// not supported from there on
    52 	};
    53 	};
    53 
    54 
    54 const TUint8 CSisRegistryServer::iElementsIndex[iRangeCount] = 
    55 const TUint8 CSisRegistryServer::iElementsIndex[iRangeCount] = 
    55 	{
    56 	{
    62 	0,  // all clients can have access	
    63 	0,  // all clients can have access	
    63 	4,  // WriteUserData clients only
    64 	4,  // WriteUserData clients only
    64 	2,	// Used by SWIS only, so TCB is needed - check on cap and SID.
    65 	2,	// Used by SWIS only, so TCB is needed - check on cap and SID.
    65 	1,  // ReadUserData clients only
    66 	1,  // ReadUserData clients only
    66 	5,   // requests coming from SIF
    67 	5,   // requests coming from SIF
       
    68 	6,  // all clients having TCB
    67 	CPolicyServer::ENotSupported,  
    69 	CPolicyServer::ENotSupported,  
    68 	};
    70 	};
    69 
    71 
    70 const CPolicyServer::TPolicyElement CSisRegistryServer::iPolicyElements[] = 
    72 const CPolicyServer::TPolicyElement CSisRegistryServer::iPolicyElements[] = 
    71 	{
    73 	{
    73 	{_INIT_SECURITY_POLICY_C1(ECapabilityReadUserData), CPolicyServer::EFailClient},
    75 	{_INIT_SECURITY_POLICY_C1(ECapabilityReadUserData), CPolicyServer::EFailClient},
    74 	{_INIT_SECURITY_POLICY_S1(KSwisSecureId, ECapabilityTCB), CPolicyServer::EFailClient},
    76 	{_INIT_SECURITY_POLICY_S1(KSwisSecureId, ECapabilityTCB), CPolicyServer::EFailClient},
    75 	{_INIT_SECURITY_POLICY_S0(KDaemonSecureId), CPolicyServer::EFailClient}, 
    77 	{_INIT_SECURITY_POLICY_S0(KDaemonSecureId), CPolicyServer::EFailClient}, 
    76 	{_INIT_SECURITY_POLICY_C2(ECapabilityWriteUserData, ECapabilityNetworkServices), CPolicyServer::EFailClient},
    78 	{_INIT_SECURITY_POLICY_C2(ECapabilityWriteUserData, ECapabilityNetworkServices), CPolicyServer::EFailClient},
    77 	{_INIT_SECURITY_POLICY_S0(KSifServerSecureId), CPolicyServer::EFailClient},
    79 	{_INIT_SECURITY_POLICY_S0(KSifServerSecureId), CPolicyServer::EFailClient},
       
    80 	{_INIT_SECURITY_POLICY_C1(ECapabilityTCB), CPolicyServer::EFailClient},
    78 	};
    81 	};
    79 
    82 
    80 const CPolicyServer::TPolicy CSisRegistryServer::iPolicy =
    83 const CPolicyServer::TPolicy CSisRegistryServer::iPolicy =
    81 	{
    84 	{
    82 	CPolicyServer::EAlwaysPass, // so that any client can connect	
    85 	CPolicyServer::EAlwaysPass, // so that any client can connect