Improve Steam detection (#127)

Improve Steam detection. Fixes #114
This commit is contained in:
SilasLaspada
2022-06-30 17:18:12 -06:00
committed by GitHub
parent 1733f60a0f
commit 3203c3ac83
2 changed files with 18 additions and 0 deletions

View File

@@ -111,6 +111,10 @@ namespace BurnOutSharp.FileType
if (fileContent.Contains("SecuROM protected application"))
Utilities.AppendToDictionary(protections, file, "SecuROM");
// Steam
if (fileContent.Contains("All use of the Program is governed by the terms of the Steam Agreement as described below."))
Utilities.AppendToDictionary(protections, file, "Steam");
// XCP
if (fileContent.Contains("http://cp.sonybmg.com/xcp/"))
Utilities.AppendToDictionary(protections, file, "XCP");

View File

@@ -46,8 +46,21 @@ namespace BurnOutSharp.ProtectionType
{
var matchers = new List<PathMatchSet>
{
// These checks are grouped together due to the names being generic on their own (Redump entry 91450).
new PathMatchSet(new List<PathMatch>
{
// TODO: Identify based on "Steam(TM)" being present in "Description" but not in "File Description".
new PathMatch("steam.exe", useEndsWith: true),
new PathMatch("steam.ini", useEndsWith: true),
// TODO: Identify file using MSI property parsing.
new PathMatch("steam.msi", useEndsWith: true),
}, "Steam"),
new PathMatchSet(new PathMatch("steam_api.dll", useEndsWith: true), "Steam"),
new PathMatchSet(new PathMatch("steam_api64.dll", useEndsWith: true), "Steam"),
new PathMatchSet(new PathMatch("steam_install_agreement.rtf", useEndsWith: true), "Steam"),
new PathMatchSet(new PathMatch("SteamInstall.bom", useEndsWith: true), "Steam"),
new PathMatchSet(new PathMatch("SteamInstall.exe", useEndsWith: true), "Steam"),
new PathMatchSet(new PathMatch("SteamInstall.info", useEndsWith: true), "Steam"),
@@ -81,6 +94,7 @@ namespace BurnOutSharp.ProtectionType
{
new PathMatchSet(new PathMatch("steam_api.dll", useEndsWith: true), "Steam"),
new PathMatchSet(new PathMatch("steam_api64.dll", useEndsWith: true), "Steam"),
new PathMatchSet(new PathMatch("steam_install_agreement.rtf", useEndsWith: true), "Steam"),
new PathMatchSet(new PathMatch("SteamInstall.bom", useEndsWith: true), "Steam"),
new PathMatchSet(new PathMatch("SteamInstall.exe", useEndsWith: true), "Steam"),
new PathMatchSet(new PathMatch("SteamInstall.info", useEndsWith: true), "Steam"),