diff options
Diffstat (limited to 'source')
-rw-r--r-- | source/CEH/commands_impl.cpp | 7 | ||||
-rw-r--r-- | source/LCDriver.cpp | 8 | ||||
-rw-r--r-- | source/LCDriver.h | 8 | ||||
-rw-r--r-- | source/LCDriver.rc | 6 | ||||
-rw-r--r-- | source/LCDriverMethods.cpp | 19 | ||||
-rw-r--r-- | source/LCDriverMethods.h | 1 | ||||
-rw-r--r-- | source/LcdVersion.cpp | 2 | ||||
-rw-r--r-- | source/config/commands.xml | 11 |
8 files changed, 58 insertions, 4 deletions
diff --git a/source/CEH/commands_impl.cpp b/source/CEH/commands_impl.cpp index 768f075..96fee23 100644 --- a/source/CEH/commands_impl.cpp +++ b/source/CEH/commands_impl.cpp @@ -77,6 +77,13 @@ ErrorCode_e LoaderRpcInterfaceImpl::DoneRPC_System_AuthenticateImpl(uint16 Sessi return E_SUCCESS; } +ErrorCode_e LoaderRpcInterfaceImpl::DoneRPC_System_DeauthenticateImpl(uint16 Session, ErrorCode_e Status) +{ + cmdResult_->GeneralResponse_Session = Session; + + return E_SUCCESS; +} + ErrorCode_e LoaderRpcInterfaceImpl::DoRPC_System_GetControlKeysImpl(uint16 Session) { cmdResult_->GeneralResponse_Session = Session; diff --git a/source/LCDriver.cpp b/source/LCDriver.cpp index 914483e..9c7643b 100644 --- a/source/LCDriver.cpp +++ b/source/LCDriver.cpp @@ -254,6 +254,14 @@ LCDRIVER_API int __cdecl System_Authenticate(LCDContext Context, int iType, int return Context->m_pObject->Do_System_Authenticate(iType, piSize, puchdata); } +LCDRIVER_API int __cdecl System_Deauthenticate(LCDContext Context, int iType) +{ + VERIFY_CONTEXT_STARTED(Context); + + return Context->m_pObject->Do_System_Deauthenticate(iType); + +} + LCDRIVER_API int __cdecl System_GetControlKeys(LCDContext Context, TSIMLockKeys *pSIMLockKeys) { VERIFY_CONTEXT_STARTED(Context); diff --git a/source/LCDriver.h b/source/LCDriver.h index 9f6db6e..b375c5e 100644 --- a/source/LCDriver.h +++ b/source/LCDriver.h @@ -375,6 +375,14 @@ extern "C" LCDRIVER_API int __cdecl System_Authenticate(LCDContext Context, int iType, int *piSize, unsigned char *puchdata); /// <summary> + /// This command deauthenticates the ME from prior + /// authentications to prevent unauthorized access. + /// </summary> + /// <param name="iType">Deauthentication type:0 = deauthenticate until next reboot of the ME,1 = permanent deauthentication.</param> + /// <returns> Status of the command.</returns> + LCDRIVER_API int __cdecl System_Deauthenticate(LCDContext Context, int iType); + + /// <summary> /// This command is used by the loader to retrieve the SimLock control keys from the host to authenticate a user. /// The command is used in the authentication context. /// </summary> diff --git a/source/LCDriver.rc b/source/LCDriver.rc index 7eff992..7537f6f 100644 --- a/source/LCDriver.rc +++ b/source/LCDriver.rc @@ -81,15 +81,15 @@ BEGIN BEGIN
BLOCK "000904b0"
BEGIN
- VALUE "Comments", "Build date: 2011-11-17"
+ VALUE "Comments", "Build date: 2011-11-18"
VALUE "CompanyName", "STEricsson AB"
VALUE "FileDescription", "LCDriver Dynamic Link Library"
VALUE "FileVersion", "1, 0, 0, 1"
VALUE "InternalName", "Loader Communication Driver"
VALUE "LegalCopyright", "Copyright (C) STEricsson AB 2011"
- VALUE "PrivateBuild", "Change-Id: I90074ddf7bca008f8f34777b749dc5bb44346d24"
+ VALUE "PrivateBuild", "Change-Id: Ib80d54f56d6be1b9aaf64e29b3f9e3cffb748faf"
VALUE "ProductName", "CXC 173 0865, LCDriver DLL"
- VALUE "ProductVersion", "PU1"
+ VALUE "ProductVersion", "PU2"
END
END
BLOCK "VarFileInfo"
diff --git a/source/LCDriverMethods.cpp b/source/LCDriverMethods.cpp index 13997ea..2791c3d 100644 --- a/source/LCDriverMethods.cpp +++ b/source/LCDriverMethods.cpp @@ -745,6 +745,25 @@ ErrorExit: } /// <summary> +/// This command deauthenticates the ME from prior +/// authentications to prevent unauthorized access. +/// </summary> +/// <param name="iType">Deauthentication type:0 = deauthenticate until next reboot of the ME,1 = permanent deauthentication.</param> +/// <returns> Status of the command.</returns> +int CLCDriverMethods::Do_System_Deauthenticate(int iType) +{ + uint16 uiSessionOut = 0; + int ReturnValue = E_SUCCESS; + + VERIFY_SUCCESS(IsMainThreadAlive()); + VERIFY_SUCCESS(m_pLoaderRpcFunctions->DoRPC_System_Deauthenticate(uiSessionOut, iType)); + VERIFY_SUCCESS(WaitForEvent(EVENT_GR_RECEIVED | EVENT_CMD_RECEIVED, GROUP_SYSTEM, COMMAND_SYSTEM_DEAUTHENTICATE)); + +ErrorExit: + return ReturnValue; +} + +/// <summary> /// This command is used by the loader to retrieve the SimLock control keys from the host to authenticate a user. /// The command is used in the authentication context. /// </summary> diff --git a/source/LCDriverMethods.h b/source/LCDriverMethods.h index 037b880..6e4ae2a 100644 --- a/source/LCDriverMethods.h +++ b/source/LCDriverMethods.h @@ -70,6 +70,7 @@ public: int Do_System_SetSystemTime(uint32 EpochTime); int Do_System_SwitchCommunicationDevice(uint32 Device, uint32 DeviceParam); int Do_System_StartCommRelay(uint32 HostDeviceId, uint32 TargetDeviceId, uint32 ControlDeviceId); + int Do_System_Deauthenticate(int iType); int Do_Flash_ProcessFile(const char *pchPath, const char *pchType, int iUseBulk, int iDeleteBuffers); int Do_Flash_ListDevices(TDevices *pDevices, int *piDeviceSize); diff --git a/source/LcdVersion.cpp b/source/LcdVersion.cpp index 4b46588..ee2bb29 100644 --- a/source/LcdVersion.cpp +++ b/source/LcdVersion.cpp @@ -16,6 +16,6 @@ * var char *LCD_VersionList[] * brief ASCII string list variable holding the LCD version/build time/product number.. */ -char *LCD_VersionList[] = {"R1V", +char *LCD_VersionList[] = {"PX2", NULL }; diff --git a/source/config/commands.xml b/source/config/commands.xml index 650cbfe..d0c2b24 100644 --- a/source/config/commands.xml +++ b/source/config/commands.xml @@ -387,6 +387,17 @@ </permissions> </command> + <command number="16" name="System Deauthenticate" ADbg="false" source="PC"> supportedcmdtype="longrunning"> + <interface type="loader" name="Deauthenticate"/> + <documentation> + This command is used by the Loader to deauthenticates the ME from prior authentications to prevent unauthorized access. + </documentation> + <input> + <value type="uint32" name="Type">Deauthentication type: 1 = permanent deauthentication, 0 = deauthenticate until next reboot of the ME.</value> + </input> + <output> + </output> + </command> </group> <group number="2" name="Flash application"> |