199 references to SafeSslHandle
System.Net.Security (199)
_generated\0\LibraryImports.g.cs (93)
2427
internal static partial global::Microsoft.Win32.SafeHandles.
SafeSslHandle
SslCreate(global::Microsoft.Win32.SafeHandles.SafeSslContextHandle ctx)
2433
global::Microsoft.Win32.SafeHandles.
SafeSslHandle
__retVal = default;
2436
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedOut __retVal_native__marshaller = new();
2479
internal static partial global::Interop.Ssl.SslErrorCode SslGetError(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, int ret)
2486
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
2516
internal static partial void SslSetQuietShutdown(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, int mode)
2522
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
2559
internal static partial void SslSetConnectState(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl)
2565
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
2594
internal static partial void SslSetAcceptState(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl)
2600
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
2629
internal static unsafe partial int SslSetAlpnProtos(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, byte* protos, int len)
2636
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
2666
internal static partial nint SslGetVersion(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl)
2673
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
2703
internal static partial bool SslSetTlsExtHostName(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, string host)
2713
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
2757
internal static unsafe partial int SslSetSession(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, nint session)
2764
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
2794
internal static partial void SslGetAlpnSelected(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, out nint protocol, out int len)
2802
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
2834
internal static partial int SslWrite(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, ref byte buf, int num, out global::Interop.Ssl.SslErrorCode error)
2843
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
2879
internal static partial int SslRead(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, ref byte buf, int num, out global::Interop.Ssl.SslErrorCode error)
2888
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
2949
internal static partial int SslRenegotiate(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, out global::Interop.Ssl.SslErrorCode error)
2957
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
2989
internal static partial bool IsSslRenegotiatePending(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl)
2997
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
3038
internal static partial int SslShutdown(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl)
3045
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
3075
internal static partial void SslSetBio(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, global::Microsoft.Win32.SafeHandles.SafeBioHandle rbio, global::Microsoft.Win32.SafeHandles.SafeBioHandle wbio)
3085
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
3120
internal static partial int SslSetFd(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, global::System.Net.Sockets.SafeSocketHandle socket)
3129
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
3162
internal static partial void SslSetAcceptMovingWriteBuffer(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl)
3168
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
3197
internal static partial int SslDoHandshake(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, out global::Interop.Ssl.SslErrorCode error)
3206
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
3241
internal static unsafe partial int SslHandshake(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, byte* inputPtr, int inputLen, out int consumed, byte* outputPtr, int outputCap, out int outputWritten, out int outputPending, out global::Interop.Ssl.SslErrorCode errorCode)
3253
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
3291
internal static unsafe partial int SslEncrypt(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, byte* plaintextPtr, int plaintextLen, byte* outputPtr, int outputCap, out int outputWritten, out int outputPending, out global::Interop.Ssl.SslErrorCode errorCode)
3302
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
3339
internal static unsafe partial int SslDecrypt(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, byte* inputPtr, int inputLen, out int consumed, byte* outputPtr, int outputCap, out int leftoverOffset, out int leftoverLength, out global::Interop.Ssl.SslErrorCode errorCode)
3351
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
3389
internal static partial bool IsSslStateOK(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl)
3397
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
3716
internal static partial nint SslGetPeerCertificate(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl)
3723
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
3753
internal static partial void SslUpdateOcspStaple(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, nint cert)
3759
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
3788
internal static partial nint SslGetCertificate(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl)
3795
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
3833
private static partial global::Microsoft.Win32.SafeHandles.SafeSharedX509StackHandle SslGetPeerCertChain_private(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl)
3843
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
3885
internal static partial int SslGetPeerFinished(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, nint buf, int count)
3892
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
3922
internal static partial int SslGetFinished(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, nint buf, int count)
3929
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
3959
internal static partial bool SslSessionReused(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl)
3967
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
4025
internal static partial nint SslGetSession(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl)
4032
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
4070
private static partial global::Microsoft.Win32.SafeHandles.SafeSharedX509NameStackHandle SslGetClientCAList_private(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl)
4080
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
4122
internal static partial bool SslGetCurrentCipherId(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, out int cipherId)
4131
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
4166
private static unsafe partial byte* GetOpenSslCipherSuiteName(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, int cipherSuite, out int isTls12OrLower)
4174
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
4206
internal static partial void SslSetVerifyPeer(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, bool failIfNoPeerCert)
4213
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
4243
internal static partial int SslSetRetryVerify(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl)
4250
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
4288
internal static partial int SslSetData(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, nint data)
4295
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
4333
internal static partial int SslUseCertificate(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, global::Microsoft.Win32.SafeHandles.SafeX509Handle certPtr)
4342
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
4375
internal static partial int SslUsePrivateKey(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, global::System.Security.Cryptography.SafeEvpPKeyHandle keyPtr)
4384
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
4417
internal static unsafe partial void SslSetClientCertCallback(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, int set)
4423
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
4452
internal static partial void SslSetPostHandshakeAuth(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, int value)
4458
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
4487
internal static unsafe partial int SslSetSigalgs(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, byte* str)
4494
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
4524
internal static unsafe partial int SslSetClientSigalgs(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, byte* str)
4531
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
4617
internal static partial bool SslAddExtraChainCert(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, global::Microsoft.Win32.SafeHandles.SafeX509Handle x509)
4627
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
4663
private static unsafe partial bool SslAddClientCAs(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, nint* x509s, int count)
4671
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
4704
private static unsafe partial void CryptoNative_SslStapleOcsp(global::Microsoft.Win32.SafeHandles.
SafeSslHandle
ssl, byte* buf, int len)
4710
global::System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller<global::Microsoft.Win32.SafeHandles.
SafeSslHandle
>.ManagedToUnmanagedIn __ssl_native__marshaller = new();
src\runtime\src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.OpenSsl.cs (17)
106
internal static SafeChannelBindingHandle? QueryChannelBinding(
SafeSslHandle
context, ChannelBindingKind bindingType)
326
internal static void UpdateClientCertificate(
SafeSslHandle
ssl, SslAuthenticationOptions sslAuthenticationOptions)
361
internal static unsafe
SafeSslHandle
AllocateSslHandle(SslAuthenticationOptions sslAuthenticationOptions)
363
SafeSslHandle
? sslHandle = null;
416
sslHandle =
SafeSslHandle
.Create(sslCtxHandle, sslAuthenticationOptions);
619
internal static unsafe void ConfigureSignatureAlgorithms(
SafeSslHandle
sslHandle, bool enablePss, bool enablePkcs1)
687
internal static SecurityStatusPal SslRenegotiate(
SafeSslHandle
sslContext, out byte[]? outputBuffer)
708
internal static unsafe SecurityStatusPalErrorCode DoSslHandshake(
SafeSslHandle
context, ReadOnlySpan<byte> input, out int consumed, ref ProtocolToken token)
821
internal static unsafe Ssl.SslErrorCode Encrypt(
SafeSslHandle
context, ReadOnlySpan<byte> input, ref ProtocolToken outToken)
918
private static unsafe void DrainOutputBioSpill(
SafeSslHandle
context, ref ProtocolToken outToken)
936
SafeSslHandle
context,
997
internal static IntPtr GetPeerCertificate(
SafeSslHandle
context)
1002
internal static SafeSharedX509StackHandle GetPeerCertificateChain(
SafeSslHandle
context)
1011
private static void QueryUniqueChannelBinding(
SafeSslHandle
context, SafeChannelBindingHandle bindingHandle)
1029
SafeSslHandle
? sslHandle = null;
1040
sslHandle = options!.SafeSslHandle as
SafeSslHandle
;
1159
static (X509Certificate2 certificate, X509Chain chain) GetPeerCertChainFromStoreCtx(
SafeSslHandle
sslHandle, IntPtr storeCtx, SslAuthenticationOptions options)
src\runtime\src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.Ssl.cs (57)
30
internal static partial
SafeSslHandle
SslCreate(SafeSslContextHandle ctx);
33
internal static partial SslErrorCode SslGetError(
SafeSslHandle
ssl, int ret);
36
internal static partial void SslSetQuietShutdown(
SafeSslHandle
ssl, int mode);
42
internal static partial void SslSetConnectState(
SafeSslHandle
ssl);
45
internal static partial void SslSetAcceptState(
SafeSslHandle
ssl);
48
internal static unsafe partial int SslSetAlpnProtos(
SafeSslHandle
ssl, byte* protos, int len);
51
internal static partial IntPtr SslGetVersion(
SafeSslHandle
ssl);
55
internal static partial bool SslSetTlsExtHostName(
SafeSslHandle
ssl, string host);
61
internal static unsafe partial int SslSetSession(
SafeSslHandle
ssl, IntPtr session);
64
internal static partial void SslGetAlpnSelected(
SafeSslHandle
ssl, out IntPtr protocol, out int len);
66
internal static unsafe ReadOnlySpan<byte> SslGetAlpnSelected(
SafeSslHandle
ssl)
79
internal static partial int SslWrite(
SafeSslHandle
ssl, ref byte buf, int num, out SslErrorCode error);
82
internal static partial int SslRead(
SafeSslHandle
ssl, ref byte buf, int num, out SslErrorCode error);
103
internal static partial int SslRenegotiate(
SafeSslHandle
ssl, out SslErrorCode error);
107
internal static partial bool IsSslRenegotiatePending(
SafeSslHandle
ssl);
113
internal static partial int SslShutdown(
SafeSslHandle
ssl);
116
internal static partial void SslSetBio(
SafeSslHandle
ssl, SafeBioHandle rbio, SafeBioHandle wbio);
122
internal static partial int SslSetFd(
SafeSslHandle
ssl, SafeSocketHandle socket);
125
internal static partial void SslSetAcceptMovingWriteBuffer(
SafeSslHandle
ssl);
128
internal static partial int SslDoHandshake(
SafeSslHandle
ssl, out SslErrorCode error);
132
SafeSslHandle
ssl,
144
SafeSslHandle
ssl,
155
SafeSslHandle
ssl,
167
internal static partial bool IsSslStateOK(
SafeSslHandle
ssl);
214
internal static partial IntPtr SslGetPeerCertificate(
SafeSslHandle
ssl);
217
internal static partial void SslUpdateOcspStaple(
SafeSslHandle
ssl, IntPtr cert);
220
internal static partial IntPtr SslGetCertificate(
SafeSslHandle
ssl);
226
private static partial SafeSharedX509StackHandle SslGetPeerCertChain_private(
SafeSslHandle
ssl);
228
internal static SafeSharedX509StackHandle SslGetPeerCertChain(
SafeSslHandle
ssl)
236
internal static partial int SslGetPeerFinished(
SafeSslHandle
ssl, IntPtr buf, int count);
239
internal static partial int SslGetFinished(
SafeSslHandle
ssl, IntPtr buf, int count);
243
internal static partial bool SslSessionReused(
SafeSslHandle
ssl);
250
internal static partial IntPtr SslGetSession(
SafeSslHandle
ssl);
256
private static partial SafeSharedX509NameStackHandle SslGetClientCAList_private(
SafeSslHandle
ssl);
260
internal static partial bool SslGetCurrentCipherId(
SafeSslHandle
ssl, out int cipherId);
263
private static unsafe partial byte* GetOpenSslCipherSuiteName(
SafeSslHandle
ssl, int cipherSuite, out int isTls12OrLower);
266
internal static partial void SslSetVerifyPeer(
SafeSslHandle
ssl, [MarshalAs(UnmanagedType.Bool)] bool failIfNoPeerCert);
269
internal static partial int SslSetRetryVerify(
SafeSslHandle
ssl);
275
internal static partial int SslSetData(
SafeSslHandle
ssl, IntPtr data);
281
internal static partial int SslUseCertificate(
SafeSslHandle
ssl, SafeX509Handle certPtr);
284
internal static partial int SslUsePrivateKey(
SafeSslHandle
ssl, SafeEvpPKeyHandle keyPtr);
287
internal static unsafe partial void SslSetClientCertCallback(
SafeSslHandle
ssl, int set);
290
internal static partial void SslSetPostHandshakeAuth(
SafeSslHandle
ssl, int value);
293
internal static unsafe partial int SslSetSigalgs(
SafeSslHandle
ssl, byte* str);
296
internal static unsafe partial int SslSetClientSigalgs(
SafeSslHandle
ssl, byte* str);
360
internal static unsafe int SslSetAlpnProtos(
SafeSslHandle
ssl, List<SslApplicationProtocol> applicationProtocols)
368
internal static unsafe int SslSetAlpnProtos(
SafeSslHandle
ssl, Span<byte> serializedProtocols)
378
internal static partial bool SslAddExtraChainCert(
SafeSslHandle
ssl, SafeX509Handle x509);
382
private static unsafe partial bool SslAddClientCAs(
SafeSslHandle
ssl, IntPtr* x509s, int count);
384
internal static unsafe bool SslAddClientCAs(
SafeSslHandle
ssl, Span<IntPtr> x509handles)
393
private static unsafe partial void CryptoNative_SslStapleOcsp(
SafeSslHandle
ssl, byte* buf, int len);
395
internal static unsafe void SslStapleOcsp(
SafeSslHandle
ssl, ReadOnlySpan<byte> stapledResponse)
405
internal static bool AddExtraChainCertificates(
SafeSslHandle
ssl, ReadOnlyCollection<X509Certificate2> chain)
424
internal static unsafe string? GetOpenSslCipherSuiteName(
SafeSslHandle
ssl, TlsCipherSuite cipherSuite, out bool isTls12OrLower)
431
internal static SafeSharedX509NameStackHandle SslGetClientCAList(
SafeSslHandle
ssl)
525
public static
SafeSslHandle
Create(SafeSslContextHandle context, SslAuthenticationOptions options)
559
SafeSslHandle
handle = Interop.Ssl.SslCreate(context);
src\runtime\src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.SslCtx.cs (1)
257
internal bool TrySetSession(
SafeSslHandle
sslHandle, string name)
System\Net\CertificateValidationPal.Unix.cs (4)
39
IntPtr remoteCertificate = Interop.OpenSsl.GetPeerCertificate((
SafeSslHandle
)securityContext);
58
Interop.OpenSsl.GetPeerCertificateChain((
SafeSslHandle
)securityContext))
100
if (ctx is not
SafeSslHandle
ssl)
141
using (SafeSharedX509NameStackHandle names = Interop.Ssl.SslGetClientCAList((
SafeSslHandle
)securityContext))
System\Net\Security\CipherSuitesPolicyPal.Linux.cs (2)
39
using (
SafeSslHandle
ssl =
SafeSslHandle
.Create(innerContext, new SslAuthenticationOptions() { IsServer = false }))
System\Net\Security\SslConnectionInfo.Linux.cs (2)
11
public void UpdateSslConnectionInfo(
SafeSslHandle
sslContext)
37
private static TlsCipherSuite SslGetCurrentCipherSuite(
SafeSslHandle
ssl)
System\Net\Security\SslStreamPal.Unix.cs (14)
76
Interop.Ssl.SslErrorCode errorCode = Interop.OpenSsl.Encrypt((
SafeSslHandle
)securityContext, input.Span, ref token);
102
(
SafeSslHandle
)securityContext,
146
(
SafeSslHandle
)securityContext,
158
SecurityStatusPal status = Interop.OpenSsl.SslRenegotiate((
SafeSslHandle
)context, out _);
174
connectionInfo.UpdateSslConnectionInfo((
SafeSslHandle
)securityContext);
182
Interop.OpenSsl.UpdateClientCertificate((
SafeSslHandle
)context!, sslAuthenticationOptions);
201
SecurityStatusPalErrorCode errorCode = Interop.OpenSsl.DoSslHandshake((
SafeSslHandle
)context, inputBuffer, out consumed, ref token);
220
errorCode = Interop.OpenSsl.DoSslHandshake((
SafeSslHandle
)context, inputBuffer.Slice(consumed), out int c, ref token);
226
if (token.Size == 0 && Interop.Ssl.IsSslRenegotiatePending((
SafeSslHandle
)context))
228
errorCode = Interop.OpenSsl.DoSslHandshake((
SafeSslHandle
)context, inputBuffer.Slice(consumed), out int c, ref token);
258
Interop.Ssl.SslSetQuietShutdown((
SafeSslHandle
)context, 0);
260
int status = Interop.Ssl.SslShutdown((
SafeSslHandle
)context);
264
status = Interop.Ssl.SslShutdown((
SafeSslHandle
)context);
270
Interop.Ssl.SslErrorCode code = Interop.Ssl.SslGetError((
SafeSslHandle
)context, status);
System\Net\Security\TlsSession.cs (1)
512
if (_securityContext is not Microsoft.Win32.SafeHandles.
SafeSslHandle
sslHandle ||
System\Net\Security\TlsSession.OpenSsl.cs (8)
224
SafeSslHandle
ssl = EnsureFdSslHandle();
248
SafeSslHandle
ssl = (
SafeSslHandle
)_securityContext!;
272
SafeSslHandle
ssl = (
SafeSslHandle
)_securityContext!;
283
private
SafeSslHandle
EnsureFdSslHandle()
285
if (_securityContext is
SafeSslHandle
existing && !existing.IsInvalid)
289
SafeSslHandle
handle = Interop.OpenSsl.AllocateSslHandle(_options);