From 6467ef97d570ede8af349f7a79d9ebab63429302 Mon Sep 17 00:00:00 2001 From: Matt Nadareski Date: Sun, 24 Jan 2021 21:23:05 -0800 Subject: [PATCH] Only scan Wise internals if scanning archives --- BurnOutSharp/FileType/Executable.cs | 1 - BurnOutSharp/ProtectionType/WiseInstaller.cs | 9 ++++++--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/BurnOutSharp/FileType/Executable.cs b/BurnOutSharp/FileType/Executable.cs index 5698c108..7f5638a0 100644 --- a/BurnOutSharp/FileType/Executable.cs +++ b/BurnOutSharp/FileType/Executable.cs @@ -258,7 +258,6 @@ namespace BurnOutSharp.FileType // If we're looking for packers too, run scans if (scanner.ScanPackers) { - // Armadillo protection = Armadillo.CheckContents(fileContent, scanner.IncludePosition); if (!string.IsNullOrWhiteSpace(protection)) diff --git a/BurnOutSharp/ProtectionType/WiseInstaller.cs b/BurnOutSharp/ProtectionType/WiseInstaller.cs index 94c77f09..ed0162f4 100644 --- a/BurnOutSharp/ProtectionType/WiseInstaller.cs +++ b/BurnOutSharp/ProtectionType/WiseInstaller.cs @@ -21,9 +21,12 @@ namespace BurnOutSharp.ProtectionType if (file == null || !File.Exists(file)) return protections; - var subProtections = Scan(scanner, file); - Utilities.PrependToKeys(subProtections, file); - Utilities.AppendToDictionary(protections, subProtections); + if (scanner.ScanArchives) + { + var subProtections = Scan(scanner, file); + Utilities.PrependToKeys(subProtections, file); + Utilities.AppendToDictionary(protections, subProtections); + } return protections; }