diff --git a/Steamless.Unpacker.Variant20.x86/Classes/SteamStubHeader.cs b/Steamless.Unpacker.Variant20.x86/Classes/SteamStubHeader.cs index c5ebaa3..deb0d7a 100644 --- a/Steamless.Unpacker.Variant20.x86/Classes/SteamStubHeader.cs +++ b/Steamless.Unpacker.Variant20.x86/Classes/SteamStubHeader.cs @@ -59,6 +59,38 @@ namespace Steamless.Unpacker.Variant20.x86.Classes public byte[] StubData; // Misc stub data, such as strings, error messages, etc. } + /// + /// SteamStub DRM Variant 2.0 Header + /// + /// Size: 884 bytes + /// + [StructLayout(LayoutKind.Sequential)] + public struct SteamStub32Var20_884_Header + { + public uint XorKey1; // Xor key used to encode the header data. + public uint XorKey2; // Xor key used to encode the header data. + public uint GetModuleHandleA_idata; // The address of GetModuleHandleA inside of the .idata section. + public uint GetProcAddress_idata; // The address of GetProcAddress inside of the .idata section. + public uint LoadLibraryA_idata; // The address of LoadLibraryA inside of the .idata section. + public uint GetProcAddress_custom; // The address of the custom GetProcAddress implementation function. + public uint Flags; // Protection flags used with the file. + public uint Unknown0000; // Unknown (Used as part of a hash check when (Flags & 0x10) is set.) + public uint BindSectionVirtualAddress; // The virtual address to the .bind section. + public uint BindSectionCodeSize; // The size of the code stub inside of the .bind section. + public uint BindSectionHash; // Hash that is calculated based on the .bind code section and .bind stub header data. (Only used if (Flags & 1) is set.) + public uint OEP; // The original file OEP to be invoked after the stub has finished. + public uint CodeSectionVirtualAddress; // The virtual address to the code section. (.text) + public uint CodeSectionSize; // The size of the code section. + public uint CodeSectionXorKey; // The starting key to xor decode against. (Only used if (Flags & 4) is set.) + public uint SteamAppId; // The steam application id of the packed file. + + [MarshalAs(UnmanagedType.ByValArray, SizeConst = 0x08)] + public byte[] SteamAppIDString; // The SteamAppID of the packed file, in string format. + + [MarshalAs(UnmanagedType.ByValArray, SizeConst = 0x32C)] + public byte[] StubData; // Misc stub data, such as strings, error messages, etc. + } + /// /// SteamStub DRM Variant 2.0 Header /// diff --git a/Steamless.Unpacker.Variant20.x86/Main.cs b/Steamless.Unpacker.Variant20.x86/Main.cs index ccdce91..84bf5c5 100644 --- a/Steamless.Unpacker.Variant20.x86/Main.cs +++ b/Steamless.Unpacker.Variant20.x86/Main.cs @@ -201,6 +201,9 @@ namespace Steamless.Unpacker.Variant20.x86 case 856: this.StubHeader = Pe32Helpers.GetStructure(headerData); break; + case 884: + this.StubHeader = Pe32Helpers.GetStructure(headerData); + break; case 952: this.StubHeader = Pe32Helpers.GetStructure(headerData); break; diff --git a/Steamless.Unpacker.Variant20.x86/Properties/AssemblyInfo.cs b/Steamless.Unpacker.Variant20.x86/Properties/AssemblyInfo.cs index f344064..a0feef6 100644 --- a/Steamless.Unpacker.Variant20.x86/Properties/AssemblyInfo.cs +++ b/Steamless.Unpacker.Variant20.x86/Properties/AssemblyInfo.cs @@ -36,5 +36,5 @@ using System.Runtime.InteropServices; [assembly: AssemblyCulture("")] [assembly: ComVisible(false)] [assembly: Guid("4f11f26d-2946-467f-a4e9-9e2a619a1fd3")] -[assembly: AssemblyVersion("1.0.0.2")] -[assembly: AssemblyFileVersion("1.0.0.2")] \ No newline at end of file +[assembly: AssemblyVersion("1.0.0.3")] +[assembly: AssemblyFileVersion("1.0.0.3")] \ No newline at end of file diff --git a/Steamless/Properties/AssemblyInfo.cs b/Steamless/Properties/AssemblyInfo.cs index 43718be..b82ef37 100644 --- a/Steamless/Properties/AssemblyInfo.cs +++ b/Steamless/Properties/AssemblyInfo.cs @@ -37,5 +37,5 @@ using System.Windows; [assembly: AssemblyCulture("")] [assembly: ComVisible(false)] [assembly: ThemeInfo(ResourceDictionaryLocation.None, ResourceDictionaryLocation.SourceAssembly)] -[assembly: AssemblyVersion("3.1.0.2")] -[assembly: AssemblyFileVersion("3.1.0.2")] \ No newline at end of file +[assembly: AssemblyVersion("3.1.0.3")] +[assembly: AssemblyFileVersion("3.1.0.3")] \ No newline at end of file