0
0
mirror of https://github.com/sp-tarkov/modules.git synced 2025-02-13 07:50:46 -05:00
modules/project/SPT.Core/Patches/SslCertificatePatch.cs

23 lines
557 B
C#

using System.Reflection;
using System.Security.Cryptography.X509Certificates;
using SPT.Reflection.Patching;
using HarmonyLib;
namespace SPT.Core.Patches
{
public class SslCertificatePatch : ModulePatch
{
protected override MethodBase GetTargetMethod()
{
return AccessTools.Method(typeof(SslCertPatchClass), nameof(SslCertPatchClass.ValidateCertificate), new[] { typeof(X509Certificate) });
}
[PatchPrefix]
private static bool PatchPrefix(ref bool __result)
{
__result = true;
return false; // Skip original
}
}
}