diff --git a/WPinternals/Models/PhoneInfo/LumiaBootManagerPhoneInfo.cs b/WPinternals/Models/UEFIApps/BootMgr/LumiaBootManagerPhoneInfo.cs similarity index 97% rename from WPinternals/Models/PhoneInfo/LumiaBootManagerPhoneInfo.cs rename to WPinternals/Models/UEFIApps/BootMgr/LumiaBootManagerPhoneInfo.cs index abb60d3..c034c13 100644 --- a/WPinternals/Models/PhoneInfo/LumiaBootManagerPhoneInfo.cs +++ b/WPinternals/Models/UEFIApps/BootMgr/LumiaBootManagerPhoneInfo.cs @@ -21,7 +21,7 @@ using System; using WPinternals.HelperClasses; -namespace WPinternals +namespace WPinternals.Models.UEFIApps.BootMgr { internal class LumiaBootManagerPhoneInfo { @@ -39,7 +39,7 @@ internal class LumiaBootManagerPhoneInfo public byte BootManagerProtocolVersionMajor; public byte BootManagerProtocolVersionMinor; - public UInt32 TransferSize; + public uint TransferSize; public bool MmosOverUsbSupported; internal void Log(LogType Type) diff --git a/WPinternals/Models/PhoneInfo/CommonPhoneInfo.cs b/WPinternals/Models/UEFIApps/CommonPhoneInfo.cs similarity index 59% rename from WPinternals/Models/PhoneInfo/CommonPhoneInfo.cs rename to WPinternals/Models/UEFIApps/CommonPhoneInfo.cs index 98cdd8e..68e8054 100644 --- a/WPinternals/Models/PhoneInfo/CommonPhoneInfo.cs +++ b/WPinternals/Models/UEFIApps/CommonPhoneInfo.cs @@ -18,9 +18,30 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. + +// Copyright (c) 2018, Rene Lergner - @Heathcliff74xda +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the "Software"), +// to deal in the Software without restriction, including without limitation +// the rights to use, copy, modify, merge, publish, distribute, sublicense, +// and/or sell copies of the Software, and to permit persons to whom the +// Software is furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +// DEALINGS IN THE SOFTWARE. + using WPinternals.HelperClasses; -namespace WPinternals +namespace WPinternals.Models.UEFIApps { internal class CommonPhoneInfo { diff --git a/WPinternals/Models/PhoneInfo/LumiaFlashAppPhoneInfo.cs b/WPinternals/Models/UEFIApps/Flash/LumiaFlashAppPhoneInfo.cs similarity index 83% rename from WPinternals/Models/PhoneInfo/LumiaFlashAppPhoneInfo.cs rename to WPinternals/Models/UEFIApps/Flash/LumiaFlashAppPhoneInfo.cs index 4921084..a242dac 100644 --- a/WPinternals/Models/PhoneInfo/LumiaFlashAppPhoneInfo.cs +++ b/WPinternals/Models/UEFIApps/Flash/LumiaFlashAppPhoneInfo.cs @@ -21,7 +21,7 @@ using System; using WPinternals.HelperClasses; -namespace WPinternals +namespace WPinternals.Models.UEFIApps.Flash { internal class LumiaFlashAppPhoneInfo { @@ -37,13 +37,13 @@ internal class LumiaFlashAppPhoneInfo public byte FlashAppProtocolVersionMajor; public byte FlashAppProtocolVersionMinor; - public UInt32 TransferSize; + public uint TransferSize; public bool MmosOverUsbSupported; - public UInt32 SdCardSizeInSectors; - public UInt32 WriteBufferSize; - public UInt32 EmmcSizeInSectors; + public uint SdCardSizeInSectors; + public uint WriteBufferSize; + public uint EmmcSizeInSectors; public string PlatformID; - public UInt16 SecureFfuSupportedProtocolMask; + public ushort SecureFfuSupportedProtocolMask; public bool AsyncSupport; public bool PlatformSecureBootEnabled; @@ -79,14 +79,14 @@ internal void Log(LogType Type) break; } - LogFile.Log($"SecureBoot: {((!PlatformSecureBootEnabled || !UefiSecureBootEnabled) ? "Disabled" : "Enabled")} (Platform Secure Boot: {(PlatformSecureBootEnabled ? "Enabled" : "Disabled")}, UEFI Secure Boot: {(UefiSecureBootEnabled ? "Enabled" : "Disabled")})", Type); + LogFile.Log($"SecureBoot: {(!PlatformSecureBootEnabled || !UefiSecureBootEnabled ? "Disabled" : "Enabled")} (Platform Secure Boot: {(PlatformSecureBootEnabled ? "Enabled" : "Disabled")}, UEFI Secure Boot: {(UefiSecureBootEnabled ? "Enabled" : "Disabled")})", Type); - if ((Type == LogType.ConsoleOnly) || (Type == LogType.FileAndConsole)) + if (Type == LogType.ConsoleOnly || Type == LogType.FileAndConsole) { LogFile.Log($"Flash app security: {(!IsBootloaderSecure ? "Disabled" : "Enabled")}", LogType.ConsoleOnly); } - if ((Type == LogType.FileOnly) || (Type == LogType.FileAndConsole)) + if (Type == LogType.FileOnly || Type == LogType.FileAndConsole) { LogFile.Log($"Flash app security: {(!IsBootloaderSecure ? "Disabled" : "Enabled")} (FFU security: {(SecureFfuEnabled ? "Enabled" : "Disabled")}, RDC: {(RdcPresent ? "Present" : "Not found")}, Authenticated: {(Authenticated ? "True" : "False")})", LogType.FileOnly); } diff --git a/WPinternals/Models/PhoneInfo/LumiaPhoneInfoAppPhoneInfo.cs b/WPinternals/Models/UEFIApps/PhoneInfo/LumiaPhoneInfoAppPhoneInfo.cs similarity index 67% rename from WPinternals/Models/PhoneInfo/LumiaPhoneInfoAppPhoneInfo.cs rename to WPinternals/Models/UEFIApps/PhoneInfo/LumiaPhoneInfoAppPhoneInfo.cs index 38f2212..d6a8429 100644 --- a/WPinternals/Models/PhoneInfo/LumiaPhoneInfoAppPhoneInfo.cs +++ b/WPinternals/Models/UEFIApps/PhoneInfo/LumiaPhoneInfoAppPhoneInfo.cs @@ -18,9 +18,30 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. + +// Copyright (c) 2018, Rene Lergner - @Heathcliff74xda +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the "Software"), +// to deal in the Software without restriction, including without limitation +// the rights to use, copy, modify, merge, publish, distribute, sublicense, +// and/or sell copies of the Software, and to permit persons to whom the +// Software is furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +// DEALINGS IN THE SOFTWARE. + using WPinternals.HelperClasses; -namespace WPinternals +namespace WPinternals.Models.UEFIApps.PhoneInfo { internal class LumiaPhoneInfoAppPhoneInfo { @@ -51,7 +72,7 @@ internal void Log(LogType Type) LogFile.Log($"Product code: {ProductCode}", Type); } - if (Type != LogType.ConsoleOnly && (Imei != null)) + if (Type != LogType.ConsoleOnly && Imei != null) { LogFile.Log($"IMEI: {Imei}", LogType.FileOnly); }