2 instantiations of SafeEvpPKeyHandle
System.Security.Cryptography (2)
System\Security\Cryptography\SafeEvpPKeyHandle.OpenSsl.cs (2)
12internal static readonly SafeEvpPKeyHandle InvalidHandle = new SafeEvpPKeyHandle(); 58SafeEvpPKeyHandle safeHandle = new SafeEvpPKeyHandle();
116 references to SafeEvpPKeyHandle
System.Net.Quic (1)
src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.X509.cs (1)
31internal static partial SafeEvpPKeyHandle GetX509EvpPublicKey(SafeX509Handle x509);
System.Net.Security (5)
src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.OpenSsl.cs (1)
877private static void SetSslCertificate(SafeSslContextHandle contextPtr, SafeX509Handle certPtr, SafeEvpPKeyHandle keyPtr)
src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.Ssl.cs (1)
174internal static partial int SslUsePrivateKey(SafeSslHandle ssl, SafeEvpPKeyHandle keyPtr);
src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.SslCtxOptions.cs (1)
22internal static partial int SslCtxUsePrivateKey(SafeSslContextHandle ctx, SafeEvpPKeyHandle keyPtr);
src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.X509.cs (1)
31internal static partial SafeEvpPKeyHandle GetX509EvpPublicKey(SafeX509Handle x509);
System\Net\Security\SslStreamCertificateContext.Linux.cs (1)
28internal readonly SafeEvpPKeyHandle KeyHandle;
System.Security.Cryptography (109)
src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.EvpPkey.cs (22)
14internal static partial SafeEvpPKeyHandle EvpPkeyCreate(); 17private static partial SafeEvpPKeyHandle CryptoNative_EvpPKeyDuplicate( 18SafeEvpPKeyHandle currentKey, 21internal static SafeEvpPKeyHandle EvpPKeyDuplicate( 22SafeEvpPKeyHandle currentKey, 25SafeEvpPKeyHandle pkey = CryptoNative_EvpPKeyDuplicate( 42internal static partial int EvpPKeySize(SafeEvpPKeyHandle pkey); 45internal static partial int UpRefEvpPkey(SafeEvpPKeyHandle handle); 48private static unsafe partial SafeEvpPKeyHandle CryptoNative_DecodeSubjectPublicKeyInfo( 54private static unsafe partial SafeEvpPKeyHandle CryptoNative_DecodePkcs8PrivateKey( 59internal static unsafe SafeEvpPKeyHandle DecodeSubjectPublicKeyInfo( 63SafeEvpPKeyHandle handle; 82internal static unsafe SafeEvpPKeyHandle DecodePkcs8PrivateKey( 86SafeEvpPKeyHandle handle; 133internal static ArraySegment<byte> RentEncodePkcs8PrivateKey(SafeEvpPKeyHandle pkey) 184internal static ArraySegment<byte> RentEncodeSubjectPublicKeyInfo(SafeEvpPKeyHandle pkey) 218private static partial SafeEvpPKeyHandle CryptoNative_LoadPrivateKeyFromEngine( 222internal static SafeEvpPKeyHandle LoadPrivateKeyFromEngine( 229SafeEvpPKeyHandle pkey = CryptoNative_LoadPrivateKeyFromEngine(engineName, keyName); 241private static partial SafeEvpPKeyHandle CryptoNative_LoadPublicKeyFromEngine( 245internal static SafeEvpPKeyHandle LoadPublicKeyFromEngine( 252SafeEvpPKeyHandle pkey = CryptoNative_LoadPublicKeyFromEngine(engineName, keyName);
src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.EvpPkey.Dsa.cs (2)
13internal static partial SafeDsaHandle EvpPkeyGetDsa(SafeEvpPKeyHandle pkey); 17internal static partial bool EvpPkeySetDsa(SafeEvpPKeyHandle pkey, SafeDsaHandle key);
src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.EvpPkey.Ecdh.cs (2)
15internal static partial SafeEvpPKeyCtxHandle EvpPKeyCtxCreate(SafeEvpPKeyHandle pkey, SafeEvpPKeyHandle peerkey, out uint secretLength);
src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.EvpPkey.EcKey.cs (2)
13internal static partial SafeEcKeyHandle EvpPkeyGetEcKey(SafeEvpPKeyHandle pkey); 17internal static partial bool EvpPkeySetEcKey(SafeEvpPKeyHandle pkey, SafeEcKeyHandle key);
src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.EvpPkey.Rsa.cs (14)
15private static partial SafeEvpPKeyHandle CryptoNative_EvpPKeyCreateRsa(IntPtr rsa); 17internal static SafeEvpPKeyHandle EvpPKeyCreateRsa(IntPtr rsa) 21SafeEvpPKeyHandle pkey = CryptoNative_EvpPKeyCreateRsa(rsa); 33private static partial SafeEvpPKeyHandle CryptoNative_RsaGenerateKey(int keySize); 35internal static SafeEvpPKeyHandle RsaGenerateKey(int keySize) 37SafeEvpPKeyHandle pkey = CryptoNative_RsaGenerateKey(keySize); 50SafeEvpPKeyHandle pkey, 59SafeEvpPKeyHandle pkey, 85SafeEvpPKeyHandle pkey, 94SafeEvpPKeyHandle pkey, 120SafeEvpPKeyHandle pkey, 129SafeEvpPKeyHandle pkey, 155SafeEvpPKeyHandle pkey, 164SafeEvpPKeyHandle pkey,
src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.X509.cs (1)
31internal static partial SafeEvpPKeyHandle GetX509EvpPublicKey(SafeX509Handle x509);
src\libraries\Common\src\System\Security\Cryptography\ECDiffieHellmanOpenSsl.cs (1)
95using (SafeEvpPKeyHandle handle = _key.UpRefKeyHandle())
src\libraries\Common\src\System\Security\Cryptography\ECDiffieHellmanOpenSsl.Derive.cs (2)
112SafeEvpPKeyHandle? ourKey = null; 113SafeEvpPKeyHandle? theirKey = null;
src\libraries\Common\src\System\Security\Cryptography\ECDiffieHellmanOpenSslPublicKey.cs (3)
13internal ECDiffieHellmanOpenSslPublicKey(SafeEvpPKeyHandle pkeyHandle) 80internal SafeEvpPKeyHandle DuplicateKeyHandle() 83SafeEvpPKeyHandle pkeyHandle = Interop.Crypto.EvpPkeyCreate();
src\libraries\Common\src\System\Security\Cryptography\ECOpenSsl.cs (2)
45internal SafeEvpPKeyHandle UpRefKeyHandle() 50SafeEvpPKeyHandle pkeyHandle = Interop.Crypto.EvpPkeyCreate();
src\libraries\Common\src\System\Security\Cryptography\RSAOpenSsl.cs (23)
20private Lazy<SafeEvpPKeyHandle>? _key; 41_key = new Lazy<SafeEvpPKeyHandle>(GenerateKey); 58_key = new Lazy<SafeEvpPKeyHandle>(GenerateKey); 90SafeEvpPKeyHandle key = GetKey(); 118SafeEvpPKeyHandle key = GetKey(); 169SafeEvpPKeyHandle key, 212SafeEvpPKeyHandle key = GetKey(); 237SafeEvpPKeyHandle? key = GetKey(); 243SafeEvpPKeyHandle key, 286SafeEvpPKeyHandle key = GetKey(); 304SafeEvpPKeyHandle key = GetKey(); 323SafeEvpPKeyHandle key = GetKey(); 343SafeEvpPKeyHandle key = GetKey(); 544SafeEvpPKeyHandle newKey = Interop.Crypto.DecodeSubjectPublicKeyInfo( 591SafeEvpPKeyHandle newKey = Interop.Crypto.DecodePkcs8PrivateKey( 650SafeEvpPKeyHandle handle = _key.Value; 656private void SetKey(SafeEvpPKeyHandle newKey) 660_key = new Lazy<SafeEvpPKeyHandle>(newKey); 710private SafeEvpPKeyHandle GetKey() 714SafeEvpPKeyHandle key = _key.Value; 724private SafeEvpPKeyHandle GenerateKey() 790SafeEvpPKeyHandle key = GetKey(); 830SafeEvpPKeyHandle key = GetKey();
System\Security\Cryptography\DSAOpenSsl.cs (4)
25/// Create an DSAOpenSsl from an <see cref="SafeEvpPKeyHandle"/> whose value is an existing 39public DSAOpenSsl(SafeEvpPKeyHandle pkeyHandle) 88public SafeEvpPKeyHandle DuplicateKeyHandle() 91SafeEvpPKeyHandle pkeyHandle = Interop.Crypto.EvpPkeyCreate();
System\Security\Cryptography\ECDiffieHellmanOpenSsl.cs (4)
13/// Create an ECDiffieHellmanOpenSsl from an <see cref="SafeEvpPKeyHandle"/> whose value is an existing 25public ECDiffieHellmanOpenSsl(SafeEvpPKeyHandle pkeyHandle) 76public SafeEvpPKeyHandle DuplicateKeyHandle() 79SafeEvpPKeyHandle pkeyHandle = Interop.Crypto.EvpPkeyCreate();
System\Security\Cryptography\ECDsaOpenSsl.cs (4)
13/// Create an ECDsaOpenSsl from an <see cref="SafeEvpPKeyHandle"/> whose value is an existing 25public ECDsaOpenSsl(SafeEvpPKeyHandle pkeyHandle) 76public SafeEvpPKeyHandle DuplicateKeyHandle() 80SafeEvpPKeyHandle pkeyHandle = Interop.Crypto.EvpPkeyCreate();
System\Security\Cryptography\RSAOpenSsl.cs (6)
22_key = new Lazy<SafeEvpPKeyHandle>(); 47SafeEvpPKeyHandle pkey = Interop.Crypto.EvpPKeyCreateRsa(handle); 54/// Create an RSAOpenSsl from an <see cref="SafeEvpPKeyHandle"/> whose value is an existing 68public RSAOpenSsl(SafeEvpPKeyHandle pkeyHandle) 76SafeEvpPKeyHandle newKey = Interop.Crypto.EvpPKeyDuplicate( 88public SafeEvpPKeyHandle DuplicateKeyHandle()
System\Security\Cryptography\SafeEvpPKeyHandle.OpenSsl.cs (5)
12internal static readonly SafeEvpPKeyHandle InvalidHandle = new SafeEvpPKeyHandle(); 51public SafeEvpPKeyHandle DuplicateHandle() 58SafeEvpPKeyHandle safeHandle = new SafeEvpPKeyHandle(); 115public static SafeEvpPKeyHandle OpenPrivateKeyFromEngine(string engineName, string keyId) 168public static SafeEvpPKeyHandle OpenPublicKeyFromEngine(string engineName, string keyId)
System\Security\Cryptography\X509Certificates\OpenSslExportProvider.cs (1)
26SafeEvpPKeyHandle? privateKey = ((OpenSslX509CertificateReader)certificatePal).PrivateKeyHandle;
System\Security\Cryptography\X509Certificates\OpenSslPkcs12Reader.cs (1)
66internal static SafeEvpPKeyHandle GetPrivateKey(AsymmetricAlgorithm key)
System\Security\Cryptography\X509Certificates\OpenSslX509CertificateReader.cs (7)
20private SafeEvpPKeyHandle? _privateKey; 540internal void SetPrivateKey(SafeEvpPKeyHandle privateKey) 545internal SafeEvpPKeyHandle? PrivateKeyHandle 572using (SafeEvpPKeyHandle publicKeyHandle = Interop.Crypto.GetX509EvpPublicKey(_cert)) 582using (SafeEvpPKeyHandle publicKeyHandle = Interop.Crypto.GetX509EvpPublicKey(_cert)) 610private OpenSslX509CertificateReader CopyWithPrivateKey(SafeEvpPKeyHandle privateKey) 771SafeEvpPKeyHandle keyHandle = _privateKey.DuplicateHandle();
System\Security\Cryptography\X509Certificates\OpenSslX509ChainProcessor.cs (3)
1328private static readonly bool s_defaultAbort = SafeEvpPKeyHandle.OpenSslVersion < OpenSSL_1_1_0_RTM; 1411if (SafeEvpPKeyHandle.OpenSslVersion >= 0x3_00_00_00_0) 1416if (SafeEvpPKeyHandle.OpenSslVersion >= 0x1_01_01_00_0)
System.Security.Cryptography.OpenSsl (1)
System.Security.Cryptography.OpenSsl.cs (1)
8[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Security.Cryptography.SafeEvpPKeyHandle))]