From 7cd16e460fe8b9be10a36d267289bea8c7c0fa2b Mon Sep 17 00:00:00 2001 From: John Cardinal Date: Thu, 9 May 2024 19:53:39 +0000 Subject: [PATCH] case 4586 - bouncycastle and also had to do mailkit as it was providing an old version of bounceycastle causing conflict --- server/AyaNova/AyaNova.csproj | 5 +++-- server/AyaNova/util/License.cs | 9 ++++++--- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/server/AyaNova/AyaNova.csproj b/server/AyaNova/AyaNova.csproj index f0750bec..b08e5af2 100644 --- a/server/AyaNova/AyaNova.csproj +++ b/server/AyaNova/AyaNova.csproj @@ -21,10 +21,11 @@ - + + - + diff --git a/server/AyaNova/util/License.cs b/server/AyaNova/util/License.cs index 99febdd4..0f6cdc03 100644 --- a/server/AyaNova/util/License.cs +++ b/server/AyaNova/util/License.cs @@ -11,9 +11,12 @@ using System.Linq; using Microsoft.Extensions.Logging; using Microsoft.EntityFrameworkCore; -//JSON KEY -using Org.BouncyCastle.Security; + +using Org.BouncyCastle.Crypto; using Org.BouncyCastle.OpenSsl; +using Org.BouncyCastle.Security; + +//JSON KEY using Newtonsoft.Json; using Newtonsoft.Json.Linq; @@ -963,7 +966,7 @@ EQIDAQAB PemReader pr = new PemReader(new StringReader(publicPem)); - var KeyParameter = (Org.BouncyCastle.Crypto.AsymmetricKeyParameter)pr.ReadObject(); + var KeyParameter = (AsymmetricKeyParameter)pr.ReadObject(); var signer = SignerUtilities.GetSigner("SHA256WITHRSA"); signer.Init(false, KeyParameter); var expectedSig = Convert.FromBase64String(keySig);