57 references to SecurityStatusPalErrorCode
System.Net.Security (57)
src\runtime\src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.OpenSsl.cs (9)
675
SecurityStatusPalErrorCode
palErrorCode = (ex?.HResult & 0X7FFFFF) switch
678
339 /*SSL_R_NO_RENEGOTIATION*/ =>
SecurityStatusPalErrorCode
.NoRenegotiation,
679
_ =>
SecurityStatusPalErrorCode
.InternalError
684
return new SecurityStatusPal(
SecurityStatusPalErrorCode
.OK);
687
internal static unsafe
SecurityStatusPalErrorCode
DoSslHandshake(SafeSslHandle context, ReadOnlySpan<byte> input, out int consumed, ref ProtocolToken token)
735
return
SecurityStatusPalErrorCode
.CredentialsNeeded;
779
return
SecurityStatusPalErrorCode
.ContinueNeeded;
788
return stateOk ?
SecurityStatusPalErrorCode
.OK :
SecurityStatusPalErrorCode
.ContinueNeeded;
System\Net\Security\NegotiateStream.cs (1)
944
(int)
SecurityStatusPalErrorCode
.LogonDenied => new InvalidCredentialException(SR.net_auth_bad_client_creds, e),
System\Net\Security\SslStream.IO.cs (14)
219
if (token.Status.ErrorCode !=
SecurityStatusPalErrorCode
.OK)
221
if (token.Status.ErrorCode ==
SecurityStatusPalErrorCode
.NoRenegotiation)
242
while (token.Status.ErrorCode ==
SecurityStatusPalErrorCode
.ContinueNeeded);
326
else if (token.Status.ErrorCode ==
SecurityStatusPalErrorCode
.OK)
371
token.Status.ErrorCode ==
SecurityStatusPalErrorCode
.IllegalMessage)
377
if (token.Status.ErrorCode ==
SecurityStatusPalErrorCode
.CertValidationFailed && token.GetException() is Exception certException)
387
else if (token.Status.ErrorCode ==
SecurityStatusPalErrorCode
.OK)
701
if (token.Status.ErrorCode !=
SecurityStatusPalErrorCode
.TryAgain)
722
if (token.Status.ErrorCode !=
SecurityStatusPalErrorCode
.OK)
748
if (token.Status.ErrorCode ==
SecurityStatusPalErrorCode
.TryAgain)
754
else if (token.Status.ErrorCode ==
SecurityStatusPalErrorCode
.OK)
917
if (status.ErrorCode !=
SecurityStatusPalErrorCode
.OK)
931
if (status.ErrorCode ==
SecurityStatusPalErrorCode
.Renegotiate)
940
else if (status.ErrorCode ==
SecurityStatusPalErrorCode
.ContextExpired)
System\Net\Security\SslStream.Protocol.cs (14)
854
if (token.Status.ErrorCode ==
SecurityStatusPalErrorCode
.HandshakeStarted)
862
if (token.Status.ErrorCode ==
SecurityStatusPalErrorCode
.OK)
884
if (token.Status.ErrorCode ==
SecurityStatusPalErrorCode
.CredentialsNeeded)
1013
waitToken.Status = new SecurityStatusPal(
SecurityStatusPalErrorCode
.TryAgain);
1025
if (token.Status.ErrorCode !=
SecurityStatusPalErrorCode
.OK)
1060
if (NetEventSource.Log.IsEnabled() && status.ErrorCode ==
SecurityStatusPalErrorCode
.OK)
1073
if (status.ErrorCode ==
SecurityStatusPalErrorCode
.Renegotiate)
1319
if (status.ErrorCode !=
SecurityStatusPalErrorCode
.OK)
1349
if (status.ErrorCode !=
SecurityStatusPalErrorCode
.OK)
1482
return ((Status.ErrorCode !=
SecurityStatusPalErrorCode
.OK) && (Status.ErrorCode !=
SecurityStatusPalErrorCode
.ContinueNeeded));
1490
return (Status.ErrorCode ==
SecurityStatusPalErrorCode
.OK);
1498
return (Status.ErrorCode ==
SecurityStatusPalErrorCode
.Renegotiate);
1506
return (Status.ErrorCode ==
SecurityStatusPalErrorCode
.ContextExpired);
System\Net\Security\SslStreamPal.Unix.cs (17)
81
token.Status = new SecurityStatusPal(
SecurityStatusPalErrorCode
.InternalError, ex);
115
return new SecurityStatusPal(
SecurityStatusPalErrorCode
.InternalError, ex);
122
Interop.Ssl.SslErrorCode.SSL_ERROR_RENEGOTIATE => new SecurityStatusPal(
SecurityStatusPalErrorCode
.Renegotiate),
123
Interop.Ssl.SslErrorCode.SSL_ERROR_ZERO_RETURN => new SecurityStatusPal(
SecurityStatusPalErrorCode
.ContextExpired),
124
Interop.Ssl.SslErrorCode.SSL_ERROR_WANT_X509_LOOKUP => new SecurityStatusPal(
SecurityStatusPalErrorCode
.CredentialsNeeded),
126
Interop.Ssl.SslErrorCode.SSL_ERROR_WANT_READ => new SecurityStatusPal(
SecurityStatusPalErrorCode
.OK),
127
_ => new SecurityStatusPal(
SecurityStatusPalErrorCode
.InternalError, new Interop.OpenSsl.SslException((int)errorCode))
160
if (status.ErrorCode !=
SecurityStatusPalErrorCode
.OK)
201
SecurityStatusPalErrorCode
errorCode = Interop.OpenSsl.DoSslHandshake((SafeSslHandle)context, inputBuffer, out consumed, ref token);
203
if (errorCode ==
SecurityStatusPalErrorCode
.CredentialsNeeded)
214
token.Status = new SecurityStatusPal(
SecurityStatusPalErrorCode
.CredentialsNeeded);
236
token.Status = new SecurityStatusPal(
SecurityStatusPalErrorCode
.InternalError, exc);
251
return new SecurityStatusPal(
SecurityStatusPalErrorCode
.OK);
268
return new SecurityStatusPal(
SecurityStatusPalErrorCode
.OK);
274
return new SecurityStatusPal(
SecurityStatusPalErrorCode
.OK);
279
return new SecurityStatusPal(
SecurityStatusPalErrorCode
.InternalError, Interop.Crypto.CreateOpenSslCryptographicException());
283
return new SecurityStatusPal(
SecurityStatusPalErrorCode
.InternalError, new Interop.OpenSsl.SslException((int)code));
System\Net\SecurityStatusPal.cs (2)
8
public readonly
SecurityStatusPalErrorCode
ErrorCode;
11
public SecurityStatusPal(
SecurityStatusPalErrorCode
errorCode, Exception? exception = null)