Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.

Commit 583a100

Browse files
committed
Removing unused function
1 parent 41cb3ff commit 583a100

File tree

1 file changed

+0
-34
lines changed

1 file changed

+0
-34
lines changed

src/Common/src/Interop/Unix/System.Security.Cryptography.Native/Interop.OpenSsl.cs

Lines changed: 0 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -399,40 +399,6 @@ private static unsafe int AlpnServerSelectCallback(IntPtr ssl, out byte* outp, o
399399
return Ssl.SSL_TLSEXT_ERR_NOACK;
400400
}
401401

402-
private static void AddX509Names(SafeX509NameStackHandle nameStack, StoreLocation storeLocation, HashSet<string> issuerNameHashSet)
403-
{
404-
using (var store = new X509Store(StoreName.Root, storeLocation))
405-
{
406-
store.Open(OpenFlags.ReadOnly);
407-
408-
foreach (var certificate in store.Certificates)
409-
{
410-
//Check if issuer name is already present
411-
//Avoiding duplicate names
412-
if (!issuerNameHashSet.Add(certificate.Issuer))
413-
{
414-
continue;
415-
}
416-
417-
using (SafeX509Handle certHandle = Crypto.X509UpRef(certificate.Handle))
418-
{
419-
using (SafeX509NameHandle nameHandle = Crypto.DuplicateX509Name(Crypto.X509GetIssuerName(certHandle)))
420-
{
421-
if (Crypto.PushX509NameStackField(nameStack, nameHandle))
422-
{
423-
// The handle ownership has been transferred into the STACK_OF(X509_NAME).
424-
nameHandle.SetHandleAsInvalid();
425-
}
426-
else
427-
{
428-
throw new CryptographicException(SR.net_ssl_x509Name_push_failed_error);
429-
}
430-
}
431-
}
432-
}
433-
}
434-
}
435-
436402
private static int BioRead(SafeBioHandle bio, byte[] buffer, int count)
437403
{
438404
Debug.Assert(buffer != null);

0 commit comments

Comments
 (0)