Files
BinaryObjectScanner/BurnOutSharp/PackerType/WinZipSFX.cs
SilasLaspada a39ae9facf Add support for WinZip SFX archives (#23)
* Add inital check for WinZip SFX archives

Every version of WinZip SFX has the string "WinZip Self-Extractor" in it,

* Add basic version detection

Versions 3+ and 2.x are identified radically differently, so make separate methods for them.

* Implement version 3+ detection

Should be very thorough detection, detects every 3+ file I have accurately.

* Cleanup code

General clanup

* Improve version 3+ detection

Use an XML string to determine the version.

* Harden against false positives

* Implement basic extraction

* Partial 2.X version detection

Very crude but effective 2.X detection for 2.0 versions

* Add version detection for 2.1 RC2 variants

* Add 2.1 version detection

* Add 2.2 version detection

Aside from clean-ups, this is the final functional addition

* Address comments
2021-03-13 20:18:03 -08:00

495 lines
31 KiB
C#
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
using System;
using System.Collections.Generic;
using System.IO;
using System.Reflection;
using System.Text;
using System.Xml;
using SharpCompress.Archives;
using SharpCompress.Archives.Zip;
namespace BurnOutSharp.PackerType
{
public class WinZipSFX : IContentCheck, IScannable
{
/// <inheritdoc/>
public bool ShouldScan(byte[] magic) => true;
/// <inheritdoc/>
public string CheckContents(string file, byte[] fileContent, bool includePosition = false)
{
// Every single version has the string "WinZip Self-Extractor", and every 3+ version has a "version=" string due to internally including an XML
// "WinZip Self-Extractor"
byte[] check = new byte[] { 0x57, 0x69, 0x6E, 0x5A, 0x69, 0x70, 0x20, 0x53, 0x65, 0x6C, 0x66, 0x2D, 0x45, 0x78, 0x74, 0x72, 0x61, 0x63, 0x74, 0x6F, 0x72 };
if (fileContent.Contains(check, out int position))
{
// "<?xml"
byte[] check2 = new byte[] { 0x3C, 0x3F, 0x78, 0x6D, 0x6C };
if (fileContent.Contains(check2, out int xmlStartPosition))
return $"WinZip SFX {GetV3PlusVersion(fileContent, position, xmlStartPosition)}" + (includePosition ? $" (Index {position})" : string.Empty);
else
return $"WinZip SFX {GetV2Version(fileContent, position)}" + (includePosition ? $" (Index {position})" : string.Empty);
}
return null;
}
/// <inheritdoc/>
public Dictionary<string, List<string>> Scan(Scanner scanner, string file)
{
if (!File.Exists(file))
return null;
using (var fs = File.OpenRead(file))
{
return Scan(scanner, fs, file);
}
}
/// <inheritdoc/>
public Dictionary<string, List<string>> Scan(Scanner scanner, Stream stream, string file)
{
// If the zip file itself fails
try
{
string tempPath = Path.Combine(Path.GetTempPath(), Guid.NewGuid().ToString());
Directory.CreateDirectory(tempPath);
// Should be using stream instead of file, but stream fails to extract anything. My guess is that the executable portion of the archive is causing stream to fail, but not file.
using (ZipArchive zipFile = ZipArchive.Open(file))
{
foreach (var entry in zipFile.Entries)
{
// If an individual entry fails
try
{
// If we have a directory, skip it
if (entry.IsDirectory)
continue;
string tempFile = Path.Combine(tempPath, entry.Key);
entry.WriteToFile(tempFile);
}
catch { }
}
}
// Collect and format all found protections
var protections = scanner.GetProtections(tempPath);
// If temp directory cleanup fails
try
{
Directory.Delete(tempPath, true);
}
catch { }
// Remove temporary path references
Utilities.StripFromKeys(protections, tempPath);
return protections;
}
catch { }
return null;
}
private static string GetV3PlusVersion(byte[] fileContent, int position, int xmlStartPosition)
{
/* If false positives do end up being an issue, there's one more consistnet string that may be used:
"_winzip_" (Found in almost every WinZip SFX archive, and every single 3+ one.)
Hex: 0x5F, 0x77, 0x69, 0x6E, 0x7A, 0x69, 0x70, 0x5F */
// Find the end of the XML so it can be imported and parsed
// </assembly>
byte[] check = new byte[] { 0x3C, 0x2F, 0x61, 0x73, 0x73, 0x65, 0x6D, 0x62, 0x6C, 0x79, 0x3E };
if (fileContent.Contains(check, out int position2))
{
int offset = position2 + 11 - xmlStartPosition;
string XML = Encoding.ASCII.GetString(fileContent, xmlStartPosition, offset);
// Load and parse the XML to find the version string, and run the Version 2.X finder if the XML fails to parse.
try
{
XmlDocument xmlDoc = new XmlDocument();
xmlDoc.LoadXml(XML);
string xmlVersion = xmlDoc["assembly"]["assemblyIdentity"].GetAttributeNode("version").InnerXml;
// 3.0.7158 is the only 3+ version that doesn't contain the "W.i.n.Z.i.p. .S.e.l.f.-.E.x.t.r.a.c.t.o.r." string.
if (xmlVersion == "3.0.7158.0")
return "3.0.7158";
// "W.i.n.Z.i.p. .S.e.l.f.-.E.x.t.r.a.c.t.o.r."
check = new byte[] { 0x57, 0x00, 0x69, 0x00, 0x6E, 0x00, 0x5A, 0x00, 0x69, 0x00, 0x70, 0x00, 0x20, 0x00, 0x53, 0x00, 0x65, 0x00, 0x6C, 0x00, 0x66, 0x00, 0x2D, 0x00, 0x45, 0x00, 0x78, 0x00, 0x74, 0x00, 0x72, 0x00, 0x61, 0x00, 0x63, 0x00,0x74, 0x00, 0x6F, 0x00, 0x72, 0x00 };
if (fileContent.Contains(check, out int position3))
{
// Some version strings don't exactly match the public version number
switch (xmlVersion)
{
case "3.1.7556.0":
return "3.1.7556";
case "3.1.8421.0":
return "4.0.8421";
case "3.1.8672.0":
return "4.0.8672";
case "4.0.1221.0":
return "4.0.12218";
default:
return $"(Unknown Version - {xmlVersion})";
}
}
return GetV2Version(fileContent, position);
}
catch
{
return GetV2Version(fileContent, position);
}
}
return GetV2Version(fileContent, position);
}
private static string GetV2Version(byte[] fileContent, int position)
{
// ".$....j.¸..ŽØ.. .´.Í!Ë...............NE. †............ .@t1..........K.@.X.X.d.l.˜...................ò.“2P.“2....Q...….î.Q.à..WZ-SE-01............."
byte[] check = new byte[] { 0x2E, 0x24, 0x00, 0x00, 0x00, 0x1E, 0x6A, 0x00, 0xB8, 0x00, 0x00, 0x8E,
0xD8, 0x8D, 0x16, 0x20, 0x00, 0xB4, 0x09, 0xCD, 0x21, 0xCB, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x4E, 0x45, 0x11, 0x20, 0x86, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
0x00, 0x0A, 0x03, 0x03, 0x00, 0x00, 0x20, 0x00, 0x40, 0x74, 0x31, 0x01,
0x00, 0x00, 0x00, 0x03, 0x00, 0x03, 0x00, 0x04, 0x00, 0x4B, 0x00, 0x40,
0x00, 0x58, 0x00, 0x58, 0x00, 0x64, 0x00, 0x6C, 0x00, 0x98, 0x01, 0x00,
0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x03, 0xF2, 0x00, 0x93, 0x32, 0x50, 0x1D, 0x93,
0x32, 0x00, 0x00, 0x00, 0x00, 0x51, 0x0C, 0x00, 0x04, 0x85, 0x1B, 0xEE,
0x08, 0x51, 0x0D, 0xE0, 0x0F, 0x08, 0x57, 0x5A, 0x2D, 0x53, 0x45, 0x2D,
0x30, 0x31, 0x00, 0x00, 0x00, 0x01, 0x00, 0x08, 0x00, 0x0D, 0x00, 0x16,
0x00, 0x00, 0x06 };
if (fileContent.Contains(check, out int position2))
return "Version 2.0 (16-bit)";
// ".$....j.¸..ŽØ.. .´.Í!Ë...............NE. Í............ .@ú6..........K.@.X.—.£...ß......................8P..8....Q.....p.Q.`....€......L#..0.8......€......]#t....€....Ñ$”....€.......WINSFX.WZ-SE-01..............."
check = new byte[] { 0x2E, 0x24, 0x00, 0x00, 0x00, 0x1E, 0x6A, 0x00, 0xB8, 0x00, 0x00, 0x8E,
0xD8, 0x8D, 0x16, 0x20, 0x00, 0xB4, 0x09, 0xCD, 0x21, 0xCB, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x4E, 0x45, 0x11, 0x20, 0xCD, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
0x00, 0x02, 0x03, 0x03, 0x00, 0x00, 0x20, 0x00, 0x40, 0xFA, 0x36, 0x01,
0x00, 0x00, 0x00, 0x03, 0x00, 0x03, 0x00, 0x05, 0x00, 0x4B, 0x00, 0x40,
0x00, 0x58, 0x00, 0x97, 0x00, 0xA3, 0x00, 0xAD, 0x00, 0xDF, 0x01, 0x00,
0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x03, 0x15, 0x01, 0x19, 0x38, 0x50, 0x1D, 0x19,
0x38, 0x00, 0x00, 0x00, 0x00, 0x51, 0x0C, 0x00, 0x04, 0x8F, 0x1E, 0x70,
0x09, 0x51, 0x0D, 0x60, 0x10, 0x01, 0x00, 0x0E, 0x80, 0x01, 0x00, 0x00,
0x00, 0x00, 0x00, 0x4C, 0x23, 0x11, 0x00, 0x30, 0x1C, 0x38, 0x00, 0x00,
0x00, 0x00, 0x00, 0x03, 0x80, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x5D,
0x23, 0x74, 0x01, 0x10, 0x1C, 0x01, 0x80, 0x00, 0x00, 0x00, 0x00, 0xD1,
0x24, 0x94, 0x00, 0x10, 0x1C, 0x02, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x06, 0x57, 0x49, 0x4E, 0x53, 0x46, 0x58, 0x08, 0x57, 0x5A, 0x2D,
0x53, 0x45, 0x2D, 0x30, 0x31, 0x00, 0x00, 0x00, 0x01, 0x00, 0x08, 0x00,
0x11, 0x00, 0x16, 0x00, 0x1A, 0x00, 0x00, 0x06 };
if (fileContent.Contains(check, out position2))
return "Version 2.0 (16-bit, Software Installation)";
// ".$....j.¸..ŽØ.. .´.Í!Ë...............NE. €............ .@ $..........K.@.X.X.d.j....................ï.-%P.-%....Q...ƒ.¬.Q.`..WZ-SE-01..........."
check = new byte[] { 0x2E, 0x24, 0x00, 0x00, 0x00, 0x1E, 0x6A, 0x00, 0xB8, 0x00, 0x00, 0x8E,
0xD8, 0x8D, 0x16, 0x20, 0x00, 0xB4, 0x09, 0xCD, 0x21, 0xCB, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x4E, 0x45, 0x11, 0x20, 0x80, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
0x00, 0x0A, 0x03, 0x03, 0x00, 0x00, 0x20, 0x00, 0x40, 0xA0, 0x24, 0x01,
0x00, 0x00, 0x00, 0x03, 0x00, 0x03, 0x00, 0x03, 0x00, 0x4B, 0x00, 0x40,
0x00, 0x58, 0x00, 0x58, 0x00, 0x64, 0x00, 0x6A, 0x00, 0x92, 0x01, 0x00,
0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x03, 0xEF, 0x00, 0x2D, 0x25, 0x50, 0x1D, 0x2D,
0x25, 0x00, 0x00, 0x00, 0x00, 0x51, 0x0C, 0x00, 0x04, 0x83, 0x14, 0xAC,
0x08, 0x51, 0x0D, 0x60, 0x0E, 0x08, 0x57, 0x5A, 0x2D, 0x53, 0x45, 0x2D,
0x30, 0x31, 0x00, 0x00, 0x00, 0x01, 0x00, 0x08, 0x00, 0x11, 0x00, 0x00,
0x06 };
if (fileContent.Contains(check, out position2))
return "Version 2.0 (16-bit, Compact)";
// "WZ-SE-01.............KERNEL.KEYBOARD.USER.GDI..GWinZip(R) Self-Extractor Copyright (c) 1995,96 Nico Mak Computing, Inc.....................È...WV..Ä~.Å"
check = new byte[] { 0x57, 0x5A, 0x2D, 0x53, 0x45, 0x2D, 0x30, 0x31, 0x00, 0x00, 0x00, 0x01,
0x00, 0x08, 0x00, 0x11, 0x00, 0x16, 0x00, 0x00, 0x06, 0x4B, 0x45, 0x52,
0x4E, 0x45, 0x4C, 0x08, 0x4B, 0x45, 0x59, 0x42, 0x4F, 0x41, 0x52, 0x44,
0x04, 0x55, 0x53, 0x45, 0x52, 0x03, 0x47, 0x44, 0x49, 0x00, 0x00, 0x47,
0x57, 0x69, 0x6E, 0x5A, 0x69, 0x70, 0x28, 0x52, 0x29, 0x20, 0x53, 0x65,
0x6C, 0x66, 0x2D, 0x45, 0x78, 0x74, 0x72, 0x61, 0x63, 0x74, 0x6F, 0x72,
0x20, 0x43, 0x6F, 0x70, 0x79, 0x72, 0x69, 0x67, 0x68, 0x74, 0x20, 0x28,
0x63, 0x29, 0x20, 0x31, 0x39, 0x39, 0x35, 0x2C, 0x39, 0x36, 0x20, 0x4E,
0x69, 0x63, 0x6F, 0x20, 0x4D, 0x61, 0x6B, 0x20, 0x43, 0x6F, 0x6D, 0x70,
0x75, 0x74, 0x69, 0x6E, 0x67, 0x2C, 0x20, 0x49, 0x6E, 0x63, 0x2E, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xC8, 0x00, 0x00, 0x00, 0x57,
0x56, 0x1E, 0x06, 0xC4, 0x7E, 0x0A, 0xC5 };
if (fileContent.Contains(check, out position2))
return "Version 2.0 (16-bit + MS-DOS)";
// "WinZip(R) Self-Extractor Copyright (c) 1995,96 Nico Mak Computing, Inc..............8œ92....ˆP..............ˆP..ˆP..ˆP..VW95SE.SFX"
check = new byte[] { 0x57, 0x69, 0x6E, 0x5A, 0x69, 0x70, 0x28, 0x52, 0x29, 0x20, 0x53, 0x65,
0x6C, 0x66, 0x2D, 0x45, 0x78, 0x74, 0x72, 0x61, 0x63, 0x74, 0x6F, 0x72,
0x20, 0x43, 0x6F, 0x70, 0x79, 0x72, 0x69, 0x67, 0x68, 0x74, 0x20, 0x28,
0x63, 0x29, 0x20, 0x31, 0x39, 0x39, 0x35, 0x2C, 0x39, 0x36, 0x20, 0x4E,
0x69, 0x63, 0x6F, 0x20, 0x4D, 0x61, 0x6B, 0x20, 0x43, 0x6F, 0x6D, 0x70,
0x75, 0x74, 0x69, 0x6E, 0x67, 0x2C, 0x20, 0x49, 0x6E, 0x63, 0x2E, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x38, 0x9C, 0x39, 0x32, 0x00, 0x00, 0x00, 0x00, 0x88, 0x50, 0x00, 0x00,
0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x88, 0x50, 0x00, 0x00, 0x88, 0x50, 0x00, 0x00, 0x88, 0x50, 0x00, 0x00,
0x56, 0x57, 0x39, 0x35, 0x53, 0x45, 0x2E, 0x53, 0x46, 0x58 };
if (fileContent.Contains(check, out position2))
return "Version 2.0 (32-bit)";
// "WinZip(R) Self-Extractor Copyright (c) 1995,96 Nico Mak Computing, Inc..............]œ92....ˆP..............ˆP..ˆP..ˆP..VW95SRE.SFX"
check = new byte[] { 0x57, 0x69, 0x6E, 0x5A, 0x69, 0x70, 0x28, 0x52, 0x29, 0x20, 0x53, 0x65,
0x6C, 0x66, 0x2D, 0x45, 0x78, 0x74, 0x72, 0x61, 0x63, 0x74, 0x6F, 0x72,
0x20, 0x43, 0x6F, 0x70, 0x79, 0x72, 0x69, 0x67, 0x68, 0x74, 0x20, 0x28,
0x63, 0x29, 0x20, 0x31, 0x39, 0x39, 0x35, 0x2C, 0x39, 0x36, 0x20, 0x4E,
0x69, 0x63, 0x6F, 0x20, 0x4D, 0x61, 0x6B, 0x20, 0x43, 0x6F, 0x6D, 0x70,
0x75, 0x74, 0x69, 0x6E, 0x67, 0x2C, 0x20, 0x49, 0x6E, 0x63, 0x2E, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x5D, 0x9C, 0x39, 0x32, 0x00, 0x00, 0x00, 0x00, 0x88, 0x50, 0x00, 0x00,
0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x88, 0x50, 0x00, 0x00, 0x88, 0x50, 0x00, 0x00, 0x88, 0x50, 0x00, 0x00,
0x56, 0x57, 0x39, 0x35, 0x53, 0x52, 0x45, 0x2E, 0x53, 0x46, 0x58 };
if (fileContent.Contains(check, out position2))
return "Version 2.0 (32-bit, Software Installation)";
// ".$....j.¸..ŽØ....´.Í!Ë...............NE. ¾............ .@V>..........K.@.X...œ.¤.Ð.....................€@P..@....Q..."4.Q.0....€......:$..0..€.....€......K$t....€....¿%”....€.......WZ-SE-01............."
check = new byte[] { 0x2E, 0x24, 0x00, 0x00, 0x00, 0x1E, 0x6A, 0x00, 0xB8, 0x02, 0x00, 0x8E,
0xD8, 0x8D, 0x16, 0x00, 0x00, 0xB4, 0x09, 0xCD, 0x21, 0xCB, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x4E, 0x45, 0x11, 0x20, 0xBE, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
0x00, 0x02, 0x03, 0x03, 0x00, 0x00, 0x20, 0x00, 0x40, 0x56, 0x3E, 0x01,
0x00, 0x00, 0x00, 0x03, 0x00, 0x03, 0x00, 0x04, 0x00, 0x4B, 0x00, 0x40,
0x00, 0x58, 0x00, 0x90, 0x00, 0x9C, 0x00, 0xA4, 0x00, 0xD0, 0x01, 0x00,
0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x03, 0x0E, 0x01, 0x80, 0x40, 0x50, 0x1D, 0x81,
0x40, 0x00, 0x00, 0x00, 0x00, 0x51, 0x0C, 0x00, 0x04, 0x9B, 0x22, 0x34,
0x03, 0x51, 0x0D, 0x30, 0x0A, 0x01, 0x00, 0x0E, 0x80, 0x01, 0x00, 0x00,
0x00, 0x00, 0x00, 0x3A, 0x24, 0x11, 0x00, 0x30, 0x1C, 0x01, 0x80, 0x00,
0x00, 0x00, 0x00, 0x03, 0x80, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x4B,
0x24, 0x74, 0x01, 0x10, 0x1C, 0x01, 0x80, 0x00, 0x00, 0x00, 0x00, 0xBF,
0x25, 0x94, 0x00, 0x10, 0x1C, 0x02, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x08, 0x57, 0x5A, 0x2D, 0x53, 0x45, 0x2D, 0x30, 0x31, 0x00, 0x00,
0x00, 0x01, 0x00, 0x08, 0x00, 0x0D, 0x00, 0x16, 0x00, 0x00, 0x06 };
if (fileContent.Contains(check, out position2))
return "Version 2.1 RC2 (16-bit)";
// ".$....j.¸..ŽØ....´.Í!Ë...............NE. ¾............ .@¬C..........K.@.X...œ.¤.Ð.....................ÐEP.ÑE....Q...c%Š.Q.€....€......-'..0..€.....€......>'t....€....²(”....€.......WZ-SE-01............."
check = new byte[] { 0x2E, 0x24, 0x00, 0x00, 0x00, 0x1E, 0x6A, 0x00, 0xB8, 0x02, 0x00, 0x8E,
0xD8, 0x8D, 0x16, 0x00, 0x00, 0xB4, 0x09, 0xCD, 0x21, 0xCB, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x4E, 0x45, 0x11, 0x20, 0xBE, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
0x00, 0x02, 0x03, 0x03, 0x00, 0x00, 0x20, 0x00, 0x40, 0xAC, 0x43, 0x01,
0x00, 0x00, 0x00, 0x03, 0x00, 0x03, 0x00, 0x04, 0x00, 0x4B, 0x00, 0x40,
0x00, 0x58, 0x00, 0x90, 0x00, 0x9C, 0x00, 0xA4, 0x00, 0xD0, 0x01, 0x00,
0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x03, 0x0E, 0x01, 0xD0, 0x45, 0x50, 0x1D, 0xD1,
0x45, 0x00, 0x00, 0x00, 0x00, 0x51, 0x0C, 0x00, 0x04, 0x63, 0x25, 0x8A,
0x03, 0x51, 0x0D, 0x80, 0x0A, 0x01, 0x00, 0x0E, 0x80, 0x01, 0x00, 0x00,
0x00, 0x00, 0x00, 0x2D, 0x27, 0x11, 0x00, 0x30, 0x1C, 0x01, 0x80, 0x00,
0x00, 0x00, 0x00, 0x03, 0x80, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3E,
0x27, 0x74, 0x01, 0x10, 0x1C, 0x01, 0x80, 0x00, 0x00, 0x00, 0x00, 0xB2,
0x28, 0x94, 0x00, 0x10, 0x1C, 0x02, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x08, 0x57, 0x5A, 0x2D, 0x53, 0x45, 0x2D, 0x30, 0x31, 0x00, 0x00,
0x00, 0x01, 0x00, 0x08, 0x00, 0x11, 0x00, 0x16, 0x00, 0x00, 0x06 };
if (fileContent.Contains(check, out position2))
return "Version 2.1 RC2 (16-bit, Software Installation)";
// ".$....j.¸..ŽØ....´.Í!Ë...............NE. €............ .@„+..........K.@.X.X.d.j....................ï..,P..,....Q...õ.Þ.Q....WZ-SE-01..........."
check = new byte[] { 0x2E, 0x24, 0x00, 0x00, 0x00, 0x1E, 0x6A, 0x00, 0xB8, 0x02, 0x00, 0x8E,
0xD8, 0x8D, 0x16, 0x00, 0x00, 0xB4, 0x09, 0xCD, 0x21, 0xCB, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x4E, 0x45, 0x11, 0x20, 0x80, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
0x00, 0x0A, 0x03, 0x03, 0x00, 0x00, 0x20, 0x00, 0x40, 0x84, 0x2B, 0x01,
0x00, 0x00, 0x00, 0x03, 0x00, 0x03, 0x00, 0x03, 0x00, 0x4B, 0x00, 0x40,
0x00, 0x58, 0x00, 0x58, 0x00, 0x64, 0x00, 0x6A, 0x00, 0x92, 0x01, 0x00,
0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x03, 0xEF, 0x00, 0x11, 0x2C, 0x50, 0x1D, 0x11,
0x2C, 0x00, 0x00, 0x00, 0x00, 0x51, 0x0C, 0x00, 0x04, 0xF5, 0x17, 0xDE,
0x02, 0x51, 0x0D, 0x90, 0x08, 0x08, 0x57, 0x5A, 0x2D, 0x53, 0x45, 0x2D,
0x30, 0x31, 0x00, 0x00, 0x00, 0x01, 0x00, 0x08, 0x00, 0x11, 0x00, 0x00,
0x06 };
if (fileContent.Contains(check, out position2))
return "Version 2.1 RC2 (16-bit, Compact)";
// "WZ-SE-01.............KERNEL.KEYBOARD.USER.GDI..GWinZip(R) Self-Extractor Copyright (c) 1995,96 Nico Mak Computing, Inc......................VÍn.E.î..¡."
check = new byte[] { 0x57, 0x5A, 0x2D, 0x53, 0x45, 0x2D, 0x30, 0x31, 0x00, 0x00, 0x00, 0x01,
0x00, 0x08, 0x00, 0x11, 0x00, 0x16, 0x00, 0x00, 0x06, 0x4B, 0x45, 0x52,
0x4E, 0x45, 0x4C, 0x08, 0x4B, 0x45, 0x59, 0x42, 0x4F, 0x41, 0x52, 0x44,
0x04, 0x55, 0x53, 0x45, 0x52, 0x03, 0x47, 0x44, 0x49, 0x00, 0x00, 0x47,
0x57, 0x69, 0x6E, 0x5A, 0x69, 0x70, 0x28, 0x52, 0x29, 0x20, 0x53, 0x65,
0x6C, 0x66, 0x2D, 0x45, 0x78, 0x74, 0x72, 0x61, 0x63, 0x74, 0x6F, 0x72,
0x20, 0x43, 0x6F, 0x70, 0x79, 0x72, 0x69, 0x67, 0x68, 0x74, 0x20, 0x28,
0x63, 0x29, 0x20, 0x31, 0x39, 0x39, 0x35, 0x2C, 0x39, 0x36, 0x20, 0x4E,
0x69, 0x63, 0x6F, 0x20, 0x4D, 0x61, 0x6B, 0x20, 0x43, 0x6F, 0x6D, 0x70,
0x75, 0x74, 0x69, 0x6E, 0x67, 0x2C, 0x20, 0x49, 0x6E, 0x63, 0x2E, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x8D, 0x56, 0xCD, 0x6E, 0x1C,
0x45, 0x10, 0xEE, 0x04, 0x09, 0xA1, 0x15 };
if (fileContent.Contains(check, out position2))
return "Version 2.1 RC2 (16-bit + MS-DOS)";
// "WinZip(R) Self-Extractor Copyright (c) 1995,96 Nico Mak Computing, Inc..............„”3....ˆP..............ˆP..ˆP..ˆP..VW95SE.SFX"
check = new byte[] { 0x57, 0x69, 0x6E, 0x5A, 0x69, 0x70, 0x28, 0x52, 0x29, 0x20, 0x53, 0x65,
0x6C, 0x66, 0x2D, 0x45, 0x78, 0x74, 0x72, 0x61, 0x63, 0x74, 0x6F, 0x72,
0x20, 0x43, 0x6F, 0x70, 0x79, 0x72, 0x69, 0x67, 0x68, 0x74, 0x20, 0x28,
0x63, 0x29, 0x20, 0x31, 0x39, 0x39, 0x35, 0x2C, 0x39, 0x36, 0x20, 0x4E,
0x69, 0x63, 0x6F, 0x20, 0x4D, 0x61, 0x6B, 0x20, 0x43, 0x6F, 0x6D, 0x70,
0x75, 0x74, 0x69, 0x6E, 0x67, 0x2C, 0x20, 0x49, 0x6E, 0x63, 0x2E, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x84, 0x82, 0x94, 0x33, 0x00, 0x00, 0x00, 0x00, 0x88, 0x50, 0x00, 0x00,
0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x88, 0x50, 0x00, 0x00, 0x88, 0x50, 0x00, 0x00, 0x88, 0x50, 0x00, 0x00,
0x56, 0x57, 0x39, 0x35, 0x53, 0x45, 0x2E, 0x53, 0x46, 0x58 };
if (fileContent.Contains(check, out position2))
return "Version 2.1 RC2 (32-bit)";
// "WinZip(R) Self-Extractor Copyright (c) 1995,96 Nico Mak Computing, Inc..............°”3....ˆP..............ˆP..ˆP..ˆP..VW95SRE.SFX"
check = new byte[] { 0x57, 0x69, 0x6E, 0x5A, 0x69, 0x70, 0x28, 0x52, 0x29, 0x20, 0x53, 0x65,
0x6C, 0x66, 0x2D, 0x45, 0x78, 0x74, 0x72, 0x61, 0x63, 0x74, 0x6F, 0x72,
0x20, 0x43, 0x6F, 0x70, 0x79, 0x72, 0x69, 0x67, 0x68, 0x74, 0x20, 0x28,
0x63, 0x29, 0x20, 0x31, 0x39, 0x39, 0x35, 0x2C, 0x39, 0x36, 0x20, 0x4E,
0x69, 0x63, 0x6F, 0x20, 0x4D, 0x61, 0x6B, 0x20, 0x43, 0x6F, 0x6D, 0x70,
0x75, 0x74, 0x69, 0x6E, 0x67, 0x2C, 0x20, 0x49, 0x6E, 0x63, 0x2E, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0xB0, 0x82, 0x94, 0x33, 0x00, 0x00, 0x00, 0x00, 0x88, 0x50, 0x00, 0x00,
0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x88, 0x50, 0x00, 0x00, 0x88, 0x50, 0x00, 0x00, 0x88, 0x50, 0x00, 0x00,
0x56, 0x57, 0x39, 0x35, 0x53, 0x52, 0x45, 0x2E, 0x53, 0x46, 0x58 };
if (fileContent.Contains(check, out position2))
return "Version 2.1 RC2 (32-bit, Software Installation)";
// ".$....j.¸..ŽØ....´.Í!Ë...............NE. ¾............ .:~>..........K.@.X...œ.¤.Ð..................... @P.¡@....Q...«"4.Q.0....€......J$..0..€.....€......[$t....€....Ï%”....€.......WZ-SE-01............."
check = new byte[] { 0x2E, 0x24, 0x00, 0x00, 0x00, 0x1E, 0x6A, 0x00, 0xB8, 0x02, 0x00, 0x8E,
0xD8, 0x8D, 0x16, 0x00, 0x00, 0xB4, 0x09, 0xCD, 0x21, 0xCB, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x4E, 0x45, 0x11, 0x20, 0xBE, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
0x00, 0x02, 0x03, 0x03, 0x00, 0x00, 0x20, 0x00, 0x3A, 0x7E, 0x3E, 0x01,
0x00, 0x00, 0x00, 0x03, 0x00, 0x03, 0x00, 0x04, 0x00, 0x4B, 0x00, 0x40,
0x00, 0x58, 0x00, 0x90, 0x00, 0x9C, 0x00, 0xA4, 0x00, 0xD0, 0x01, 0x00,
0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x03, 0x0E, 0x01, 0xA0, 0x40, 0x50, 0x1D, 0xA1,
0x40, 0x00, 0x00, 0x00, 0x00, 0x51, 0x0C, 0x00, 0x04, 0xAB, 0x22, 0x34,
0x03, 0x51, 0x0D, 0x30, 0x0A, 0x01, 0x00, 0x0E, 0x80, 0x01, 0x00, 0x00,
0x00, 0x00, 0x00, 0x4A, 0x24, 0x11, 0x00, 0x30, 0x1C, 0x01, 0x80, 0x00,
0x00, 0x00, 0x00, 0x03, 0x80, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x5B,
0x24, 0x74, 0x01, 0x10, 0x1C, 0x01, 0x80, 0x00, 0x00, 0x00, 0x00, 0xCF,
0x25, 0x94, 0x00, 0x10, 0x1C, 0x02, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x08, 0x57, 0x5A, 0x2D, 0x53, 0x45, 0x2D, 0x30, 0x31, 0x00, 0x00,
0x00, 0x01, 0x00, 0x08, 0x00, 0x0D, 0x00, 0x16, 0x00, 0x00, 0x06 };
if (fileContent.Contains(check, out position2))
return "Version 2.1 (16-bit)";
// ".$....j.¸..ŽØ....´.Í!Ë...............NE. ¾............ .:.D..........K.@.X...œ.¤.Ð.....................0FP.1F....Q...—%Š.Q.€....€......a'..0..€.....€......r't....€....æ(”....€.......WZ-SE-01............."
check = new byte[] { };
if (fileContent.Contains(check, out position2))
return "Version 2.1 (16-bit, Software Installation)";
// ".$....j.¸..ŽØ....´.Í!Ë...............NE. €............ .:.+..........K.@.X.X.d.j....................ï..,P..,....Q...û.Þ.Q....WZ-SE-01..........."
check = new byte[] { 0x2E, 0x24, 0x00, 0x00, 0x00, 0x1E, 0x6A, 0x00, 0xB8, 0x02, 0x00, 0x8E,
0xD8, 0x8D, 0x16, 0x00, 0x00, 0xB4, 0x09, 0xCD, 0x21, 0xCB, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x4E, 0x45, 0x11, 0x20, 0x80, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
0x00, 0x0A, 0x03, 0x03, 0x00, 0x00, 0x20, 0x00, 0x3A, 0x90, 0x2B, 0x01,
0x00, 0x00, 0x00, 0x03, 0x00, 0x03, 0x00, 0x03, 0x00, 0x4B, 0x00, 0x40,
0x00, 0x58, 0x00, 0x58, 0x00, 0x64, 0x00, 0x6A, 0x00, 0x92, 0x01, 0x00,
0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x03, 0xEF, 0x00, 0x1D, 0x2C, 0x50, 0x1D, 0x1D,
0x2C, 0x00, 0x00, 0x00, 0x00, 0x51, 0x0C, 0x00, 0x04, 0xFB, 0x17, 0xDE,
0x02, 0x51, 0x0D, 0x90, 0x08, 0x08, 0x57, 0x5A, 0x2D, 0x53, 0x45, 0x2D,
0x30, 0x31, 0x00, 0x00, 0x00, 0x01, 0x00, 0x08, 0x00, 0x11, 0x00, 0x00,
0x06 };
if (fileContent.Contains(check, out position2))
return "Version 2.1 (16-bit, Compact)";
// "WZ-SE-01.............KERNEL.KEYBOARD.USER.GDI..GWinZip(R) Self-Extractor Copyright (c) 1995,96 Nico Mak Computing, Inc......................VÍn.Å.®€„.."
check = new byte[] { 0x57, 0x5A, 0x2D, 0x53, 0x45, 0x2D, 0x30, 0x31, 0x00, 0x00, 0x00, 0x01,
0x00, 0x08, 0x00, 0x11, 0x00, 0x16, 0x00, 0x00, 0x06, 0x4B, 0x45, 0x52,
0x4E, 0x45, 0x4C, 0x08, 0x4B, 0x45, 0x59, 0x42, 0x4F, 0x41, 0x52, 0x44,
0x04, 0x55, 0x53, 0x45, 0x52, 0x03, 0x47, 0x44, 0x49, 0x00, 0x00, 0x47,
0x57, 0x69, 0x6E, 0x5A, 0x69, 0x70, 0x28, 0x52, 0x29, 0x20, 0x53, 0x65,
0x6C, 0x66, 0x2D, 0x45, 0x78, 0x74, 0x72, 0x61, 0x63, 0x74, 0x6F, 0x72,
0x20, 0x43, 0x6F, 0x70, 0x79, 0x72, 0x69, 0x67, 0x68, 0x74, 0x20, 0x28,
0x63, 0x29, 0x20, 0x31, 0x39, 0x39, 0x35, 0x2C, 0x39, 0x36, 0x20, 0x4E,
0x69, 0x63, 0x6F, 0x20, 0x4D, 0x61, 0x6B, 0x20, 0x43, 0x6F, 0x6D, 0x70,
0x75, 0x74, 0x69, 0x6E, 0x67, 0x2C, 0x20, 0x49, 0x6E, 0x63, 0x2E, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x8D, 0x56, 0xCD, 0x6E, 0x1C,
0xC5, 0x16, 0xAE, 0x80, 0x84, 0x90, 0x05 };
if (fileContent.Contains(check, out position2))
return "Version 2.1 (16-bit + MS-DOS)";
// "WinZip(R) Self-Extractor Copyright (c) 1995,96 Nico Mak Computing, Inc..............UÍÌ3....ˆP..............ˆP..ˆP..ˆP..VW95SE.SFX"
check = new byte[] { 0x57, 0x69, 0x6E, 0x5A, 0x69, 0x70, 0x28, 0x52, 0x29, 0x20, 0x53, 0x65,
0x6C, 0x66, 0x2D, 0x45, 0x78, 0x74, 0x72, 0x61, 0x63, 0x74, 0x6F, 0x72,
0x20, 0x43, 0x6F, 0x70, 0x79, 0x72, 0x69, 0x67, 0x68, 0x74, 0x20, 0x28,
0x63, 0x29, 0x20, 0x31, 0x39, 0x39, 0x35, 0x2C, 0x39, 0x36, 0x20, 0x4E,
0x69, 0x63, 0x6F, 0x20, 0x4D, 0x61, 0x6B, 0x20, 0x43, 0x6F, 0x6D, 0x70,
0x75, 0x74, 0x69, 0x6E, 0x67, 0x2C, 0x20, 0x49, 0x6E, 0x63, 0x2E, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x55, 0xCD, 0xCC, 0x33, 0x00, 0x00, 0x00, 0x00, 0x88, 0x50, 0x00, 0x00,
0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x88, 0x50, 0x00, 0x00, 0x88, 0x50, 0x00, 0x00, 0x88, 0x50, 0x00, 0x00,
0x56, 0x57, 0x39, 0x35, 0x53, 0x45, 0x2E, 0x53, 0x46, 0x58 };
if (fileContent.Contains(check, out position2))
return "Version 2.1 (32-bit)";
// "WinZip(R) Self-Extractor Copyright (c) 1995,96 Nico Mak Computing, Inc..............{ÍÌ3....ˆP..............ˆP..ˆP..ˆP..VW95SRE.SFX"
check = new byte[] { 0x57, 0x69, 0x6E, 0x5A, 0x69, 0x70, 0x28, 0x52, 0x29, 0x20, 0x53, 0x65,
0x6C, 0x66, 0x2D, 0x45, 0x78, 0x74, 0x72, 0x61, 0x63, 0x74, 0x6F, 0x72,
0x20, 0x43, 0x6F, 0x70, 0x79, 0x72, 0x69, 0x67, 0x68, 0x74, 0x20, 0x28,
0x63, 0x29, 0x20, 0x31, 0x39, 0x39, 0x35, 0x2C, 0x39, 0x36, 0x20, 0x4E,
0x69, 0x63, 0x6F, 0x20, 0x4D, 0x61, 0x6B, 0x20, 0x43, 0x6F, 0x6D, 0x70,
0x75, 0x74, 0x69, 0x6E, 0x67, 0x2C, 0x20, 0x49, 0x6E, 0x63, 0x2E, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x7B, 0xCD, 0xCC, 0x33, 0x00, 0x00, 0x00, 0x00, 0x88, 0x50, 0x00, 0x00,
0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x88, 0x50, 0x00, 0x00, 0x88, 0x50, 0x00, 0x00, 0x88, 0x50, 0x00, 0x00,
0x56, 0x57, 0x39, 0x35, 0x53, 0x52, 0x45, 0x2E, 0x53, 0x46, 0x58 };
if (fileContent.Contains(check, out position2))
return "Version 2.1 (32-bit, Software Installation)";
// I'm not as sure about version 2.2 detection, so check for _winzip_ to prevent any false positives
// "_winzip_"
check = new byte[] { 0x5F, 0x77, 0x69, 0x6E, 0x7A, 0x69, 0x70, 0x5F };
if (fileContent.Contains(check, out position2))
// "....$.......Ò'~SF..F..F..F..êF...@..—F...Z..—F..RichF..........................PE..L...i.[:........à........J...*......Ø9.......`....@."
check = new byte[] { 0x2E, 0x0D, 0x0D, 0x0A, 0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0xD2, 0x27, 0x7E, 0x53, 0x96, 0x46, 0x10, 0x00, 0x96, 0x46, 0x10, 0x00,
0x96, 0x46, 0x10, 0x00, 0x96, 0x46, 0x10, 0x00, 0xEA, 0x46, 0x10, 0x00,
0x12, 0x40, 0x16, 0x00, 0x97, 0x46, 0x10, 0x00, 0x11, 0x5A, 0x12, 0x00,
0x97, 0x46, 0x10, 0x00, 0x52, 0x69, 0x63, 0x68, 0x96, 0x46, 0x10, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x50, 0x45, 0x00, 0x00, 0x4C, 0x01, 0x05, 0x00, 0x69, 0x1B, 0x5B, 0x3A,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x0F, 0x01,
0x0B, 0x01, 0x05, 0x0A, 0x00, 0x4A, 0x00, 0x00, 0x00, 0x2A, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0xD8, 0x39, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00,
0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00 };
if (fileContent.Contains(check, out int position3))
return "Version 2.2.4003";
// "....$.......Ò'~SF..F..F..F...F...@..—F...Z..—F..RichF..........................PE..L.....[:........à........V...*.......?.......p....@."
check = new byte[] { 0x2E, 0x0D, 0x0D, 0x0A, 0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0xD2, 0x27, 0x7E, 0x53, 0x96, 0x46, 0x10, 0x00, 0x96, 0x46, 0x10, 0x00,
0x96, 0x46, 0x10, 0x00, 0x96, 0x46, 0x10, 0x00, 0x1B, 0x46, 0x10, 0x00,
0x12, 0x40, 0x16, 0x00, 0x97, 0x46, 0x10, 0x00, 0x11, 0x5A, 0x12, 0x00,
0x97, 0x46, 0x10, 0x00, 0x52, 0x69, 0x63, 0x68, 0x96, 0x46, 0x10, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x50, 0x45, 0x00, 0x00, 0x4C, 0x01, 0x05, 0x00, 0x81, 0x1B, 0x5B, 0x3A,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x0F, 0x01,
0x0B, 0x01, 0x05, 0x0A, 0x00, 0x56, 0x00, 0x00, 0x00, 0x2A, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x8F, 0x3F, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00,
0x00, 0x70, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00 };
if (fileContent.Contains(check, out position3))
return "Version 2.2.4003 (Software Installation)";
return "Unknown Version 2.X";
}
}
}