mirror of
https://github.com/SabreTools/BinaryObjectScanner.git
synced 2026-07-19 23:35:01 +00:00
Use content matching helper, part 4
This commit is contained in:
@@ -11,7 +11,11 @@ namespace BurnOutSharp.ProtectionType
|
||||
var matchers = new List<Matcher>
|
||||
{
|
||||
// MGS CDCheck
|
||||
new Matcher(new byte?[] { 0x4D, 0x47, 0x53, 0x20, 0x43, 0x44, 0x43, 0x68, 0x65, 0x63, 0x6B }, "Microsoft Game Studios CD Check"),
|
||||
new Matcher(new byte?[]
|
||||
{
|
||||
0x4D, 0x47, 0x53, 0x20, 0x43, 0x44, 0x43, 0x68,
|
||||
0x65, 0x63, 0x6B
|
||||
}, "Microsoft Game Studios CD Check"),
|
||||
|
||||
// CDCheck
|
||||
new Matcher(new byte?[] { 0x43, 0x44, 0x43, 0x68, 0x65, 0x63, 0x6B }, "Executable-Based CD Check"),
|
||||
@@ -26,10 +30,19 @@ namespace BurnOutSharp.ProtectionType
|
||||
var matchers = new List<Matcher>
|
||||
{
|
||||
// GetDriveType
|
||||
new Matcher(new byte?[] { 0x47, 0x65, 0x74, 0x44, 0x72, 0x69, 0x76, 0x65, 0x54, 0x79, 0x70, 0x65 }, "Executable-Based CD Check"),
|
||||
new Matcher(new byte?[]
|
||||
{
|
||||
0x47, 0x65, 0x74, 0x44, 0x72, 0x69, 0x76, 0x65,
|
||||
0x54, 0x79, 0x70, 0x65
|
||||
}, "Executable-Based CD Check"),
|
||||
|
||||
// GetVolumeInformation
|
||||
new Matcher(new byte?[] { 0x47, 0x65, 0x74, 0x56, 0x6F, 0x6C, 0x75, 0x6D, 0x65, 0x49, 0x6E, 0x66, 0x6F, 0x72, 0x6D, 0x61, 0x74, 0x69, 0x6F, 0x6E }, "Executable-Based CD Check"),
|
||||
new Matcher(new byte?[]
|
||||
{
|
||||
0x47, 0x65, 0x74, 0x56, 0x6F, 0x6C, 0x75, 0x6D,
|
||||
0x65, 0x49, 0x6E, 0x66, 0x6F, 0x72, 0x6D, 0x61,
|
||||
0x74, 0x69, 0x6F, 0x6E
|
||||
}, "Executable-Based CD Check"),
|
||||
};
|
||||
|
||||
return Utilities.GetContentMatches(file, fileContent, matchers, includePosition);
|
||||
|
||||
Reference in New Issue
Block a user