mirror of
https://github.com/volodymyrsmirnov/MalwareMultiScan.git
synced 2025-08-25 14:01:13 +00:00
basic architecture change: consul + hangfire
This commit is contained in:
32
MalwareMultiScan.Backends/Backends/ComodoScanBackend.cs
Normal file
32
MalwareMultiScan.Backends/Backends/ComodoScanBackend.cs
Normal file
@@ -0,0 +1,32 @@
|
||||
using System.Text.RegularExpressions;
|
||||
using MalwareMultiScan.Backends.Backends.Abstracts;
|
||||
using MalwareMultiScan.Backends.Services.Interfaces;
|
||||
|
||||
namespace MalwareMultiScan.Backends.Backends
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public class ComodoScanBackend : AbstractLocalProcessScanBackend
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public ComodoScanBackend(IProcessRunner processRunner) : base(processRunner)
|
||||
{
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public override string Id { get; } = "comodo";
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override string BackendPath { get; } = "/opt/COMODO/cmdscan";
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override Regex MatchRegex { get; } =
|
||||
new Regex(@".* ---> Found Virus, Malware Name is (?<threat>.*)",
|
||||
RegexOptions.Compiled | RegexOptions.Multiline);
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override string GetBackendArguments(string path)
|
||||
{
|
||||
return $"-v -s {path}";
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user