Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ AuthenticateContinue()

bool System.Net.Mail.SmtpConnection.ConnectAndHandshakeAsyncResult.AuthenticateContinue ( )
inlineprivate

Definition at line 439 of file SmtpConnection.cs.

440 {
441 while (true)
442 {
444 if (authorization == null)
445 {
446 throw new SmtpException(System.SR.SmtpAuthenticationFailed);
447 }
448 IAsyncResult asyncResult = AuthCommand.BeginSend(_connection, authorization.Message, s_authenticateContinueCallback, this);
449 if (!asyncResult.CompletedSynchronously)
450 {
451 return false;
452 }
453 LineInfo lineInfo = AuthCommand.EndSend(asyncResult);
454 if (lineInfo.StatusCode == (SmtpStatusCode)235)
455 {
457 _connection._isConnected = true;
459 return false;
460 }
461 if (lineInfo.StatusCode != (SmtpStatusCode)334)
462 {
463 break;
464 }
465 _authResponse = lineInfo.Line;
466 }
467 return true;
468 }
readonly ISmtpAuthenticationModule[] _authenticationModules
static string SmtpAuthenticationFailed
Definition SR.cs:136
Definition SR.cs:7
void CloseContext(object sessionCookie)
Authorization Authenticate(string challenge, NetworkCredential credentials, object sessionCookie, string spn, ChannelBinding channelBindingToken)

References System.Net.Mail.SmtpConnection._authenticationModules, System.Net.Mail.SmtpConnection.ConnectAndHandshakeAsyncResult._authResponse, System.Net.Mail.SmtpConnection._client, System.Net.Mail.SmtpConnection.ConnectAndHandshakeAsyncResult._connection, System.Net.Mail.SmtpConnection.ConnectAndHandshakeAsyncResult._currentModule, System.asyncResult, System.Net.Mail.ISmtpAuthenticationModule.Authenticate(), System.Net.Mail.AuthCommand.BeginSend(), System.Net.Mail.ISmtpAuthenticationModule.CloseContext(), System.Net.Mail.AuthCommand.EndSend(), System.Net.LazyAsyncResult.InvokeCallback(), System.Net.Mail.LineInfo.Line, System.Net.Authorization.Message, System.Net.Mail.SmtpConnection.ConnectAndHandshakeAsyncResult.s_authenticateContinueCallback, System.SR.SmtpAuthenticationFailed, System.Net.Mail.LineInfo.StatusCode, and System.Net.Mail.SmtpClient.TargetName.

Referenced by System.Net.Mail.SmtpConnection.ConnectAndHandshakeAsyncResult.Authenticate(), System.Net.Mail.SmtpConnection.ConnectAndHandshakeAsyncResult.AuthenticateCallback(), and System.Net.Mail.SmtpConnection.ConnectAndHandshakeAsyncResult.AuthenticateContinueCallback().