From 454e00613af82174fe867b50fe55d8b7359f7410 Mon Sep 17 00:00:00 2001 From: Taloth Saldono Date: Thu, 14 Jan 2021 22:04:54 +0100 Subject: [PATCH] Fixed: Unnecessary certificate validation errors on localhost/loopback (cherry picked from commit c28cafba0a1b92f065541ebdae9db06ab1e5ac82) --- .../Security/X509CertificateValidationService.cs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/NzbDrone.Core/Security/X509CertificateValidationService.cs b/src/NzbDrone.Core/Security/X509CertificateValidationService.cs index 7b6afca75..ba58e1eff 100644 --- a/src/NzbDrone.Core/Security/X509CertificateValidationService.cs +++ b/src/NzbDrone.Core/Security/X509CertificateValidationService.cs @@ -41,6 +41,11 @@ namespace NzbDrone.Core.Security return true; } + if (request.RequestUri.Host == "localhost" || request.RequestUri.Host == "127.0.0.1") + { + return true; + } + var ipAddresses = GetIPAddresses(request.RequestUri.Host); var certificateValidation = _configService.CertificateValidation;