diff --git a/src/GlobalSignCAProxy/GlobalSignCAProxy.cs b/src/GlobalSignCAProxy/GlobalSignCAProxy.cs index 2b7939d..4c261d9 100644 --- a/src/GlobalSignCAProxy/GlobalSignCAProxy.cs +++ b/src/GlobalSignCAProxy/GlobalSignCAProxy.cs @@ -19,11 +19,15 @@ using Newtonsoft.Json; +using Org.BouncyCastle.Crypto.Tls; + using System; using System.Collections.Concurrent; using System.Collections.Generic; using System.Linq; +using System.Text; using System.Threading; +using System.Web.Services.Configuration; namespace Keyfactor.Extensions.AnyGateway.GlobalSign { @@ -82,7 +86,21 @@ public override EnrollmentResult Enroll(ICertificateDataReader certificateDataRe { Logger.Warn("Subject is missing a CN value. Using SAN domain lookup instead"); } + StringBuilder rawSanList = new StringBuilder(); + rawSanList.Append("Raw SAN List:\n"); + foreach (var sanType in san.Keys) + { + rawSanList.Append($"SAN Type: {sanType}. Values: "); + foreach (var indivSan in san[sanType]) + { + rawSanList.Append($"{indivSan},"); + } + rawSanList.Append('\n'); + } + Logger.Trace(rawSanList.ToString()); + var sanDict = new Dictionary(san, StringComparer.OrdinalIgnoreCase); + Logger.Trace($"DNS SAN Count: {sanDict["dns"].Count()}"); if (commonName == null) { foreach (string dnsSan in sanDict["dns"])