mirror of
https://github.com/SabreTools/BinaryObjectScanner.git
synced 2026-02-10 13:52:16 +00:00
* Add detection class and test class for PACE Anti-Piracy Interlok * Remove unnecessary empty lines after end of class. * Added missing null check for pex section strings. * Add newline above getversion * GetFirstSectionStrings assigned to variable. * Change getversion in InterLok to use regex. * Final? getversion regex cleanup
22 lines
660 B
C#
22 lines
660 B
C#
using System.IO;
|
|
using BinaryObjectScanner.Protection;
|
|
using Xunit;
|
|
|
|
namespace BinaryObjectScanner.Test.Protection
|
|
{
|
|
public class InterLokTests
|
|
{
|
|
[Fact]
|
|
public void CheckPortableExecutableTest()
|
|
{
|
|
string file = "filename";
|
|
SabreTools.Models.PortableExecutable.Executable model = new();
|
|
Stream source = new MemoryStream();
|
|
SabreTools.Serialization.Wrappers.PortableExecutable pex = new(model, source);
|
|
|
|
var checker = new InterLok();
|
|
string? actual = checker.CheckExecutable(file, pex, includeDebug: false);
|
|
Assert.Null(actual);
|
|
}
|
|
}
|
|
} |