Hi
We have he same Problem. Any solution yet
The Code works fine when sending mail direct to the Exchange 2003. If we send to a Product called XWALL (http://www.lakecomm.com/) it fails...
Our trace (Failed with .NET 2.0 SMTP):
(Note: i blanked out the base64 Username/PW Part with (***BLANKED_OUT_BASE64***))
06-10-11 14:13:06 0005: > 220 mail.ourserver.com ESMTP XWall v3.38
06-10-11 14:13:06 0005: < EHLO ourproxy
06-10-11 14:13:06 0005: > 250-mail.ourserver.com
06-10-11 14:13:06 0005: > 250-ENHANCEDSTATUSCODES
06-10-11 14:13:06 0005: > 250-ETRN
06-10-11 14:13:06 0005: > 250-DSN
06-10-11 14:13:06 0005: > 250-PIPELINING
06-10-11 14:13:06 0005: > 250-8BITMIME
06-10-11 14:13:06 0005: > 250-PRIORITY
06-10-11 14:13:06 0005: > 250-CHUNKING
06-10-11 14:13:06 0005: > 250-SIZE
06-10-11 14:13:06 0005: > 250-AUTH=LOGIN
06-10-11 14:13:06 0005: > 250-AUTH PLAIN LOGIN CRAM-MD5
06-10-11 14:13:06 0005: > 250-XBDATA
06-10-11 14:13:06 0005: > 250 XXWALL30
06-10-11 14:13:06 0005: < AUTH login b(***BLANKED_OUT_BASE64***)=
06-10-11 14:13:06 0005: > 334 V(***BLANKED_OUT_BASE64***)6
06-10-11 14:13:06 0005: < N(***BLANKED_OUT_BASE64***)=
06-10-11 14:13:06 0005: > 334 U(***BLANKED_OUT_BASE64***)6
06-10-11 14:13:06 0005: > 535 5.7.0 authentication of 77xJt$345sq failed, access denied
Correct Trace (BY 3th Part SMTP Client):
---------------------------------------------------------------
06-10-11 14:39:42 0008: < AUTH login
06-10-11 14:39:42 0008: > 334 V(***BLANKED_OUT_BASE64***)6
06-10-11 14:39:50 0008: < b(***BLANKED_OUT_BASE64***)==
06-10-11 14:39:50 0008: > 334 U(***BLANKED_OUT_BASE64***)6
06-10-11 14:39:58 0008: < N(***BLANKED_OUT_BASE64***)=
06-10-11 14:39:58 0008: > 235 2.7.0 user successfully authenticated
vb.net Code:
Public Sub Send()
Dim vMail As New MailMessage
Try
btnSend.Enabled =
False
txtOut.Text =
"Sending mail..." & vbCrLf
System.Windows.Forms.Application.DoEvents()
If chkPlaintext.Checked Then
vMail.IsBodyHtml =
False 'Text
Else
vMail.IsBodyHtml =
True 'html
End If
If Len(txtEncoding.Text) > 0 Then
Dim voE As System.Text.Encoding
voE = System.Text.Encoding.GetEncoding(txtEncoding.Text)
If voE Is Nothing Then
voE = System.Text.Encoding.Default
End If
vMail.BodyEncoding = voE
End If
If chkPlaintext.Checked Then
vMail.Body = txtBody.Text
Else
vMail.Body = gsFormatHTML_SMTP(txtBody.Text)
End If
vMail.Subject = txtSubject.Text
vMail.Priority = MailPriority.High
vMail.Sender =
New MailAddress(txtSender.Text)
vMail.From =
New MailAddress(txtSender.Text)
vMail.To.Add(txtTo.Text)
Err.Clear()
Dim voSMTP As New SmtpClient
voSMTP.Host = txtServer.Text
voSMTP.Port = txtPort.Text
voSMTP.Timeout = txtTimeout.Text * 1000
voSMTP.DeliveryMethod = SmtpDeliveryMethod.Network
If Len(txtAuthenticationUser.Text) > 0 Then
voSMTP.UseDefaultCredentials =
False
Dim voC As New System.Net.NetworkCredential
voC.UserName = txtAuthenticationUser.Text
voC.Password = txtAuthenticationPW.Text
voC.Domain = txtDomain.Text
voSMTP.Credentials = voC
Else
voSMTP.UseDefaultCredentials =
True
voSMTP.Credentials = System.Net.CredentialCache.DefaultCredentials()
End If
voSMTP.EnableSsl = chkEnableSSL.Checked
voSMTP.Send(vMail)
Catch ex As Exception
If TypeOf ex Is System.Net.Mail.SmtpException Then
Dim voE As SmtpException = ex
txtOut.Text =
"!!!Couldn't send mail!!! (SmtpException)" & vbCrLf & "Error-Message: " & voE.Message & vbCrLf & "Server StatusCode: " & voE.StatusCode & vbCrLf & "Source: " & voE.Source & vbCrLf & vbCrLf & "StackTrace: " & vbCrLf & voE.StackTrace
ElseIf TypeOf ex Is System.Net.Mail.SmtpFailedRecipientException Then
Dim voE As SmtpFailedRecipientException = ex
txtOut.Text =
"!!!Couldn't send mail!!! (FailedRecipient)" & vbCrLf & "Error-Message: " & voE.Message & vbCrLf & "Failed Recipients: " & voE.FailedRecipient & vbCrLf & "Source: " & voE.Source & vbCrLf & vbCrLf & "StackTrace: " & vbCrLf & voE.StackTrace
ElseIf TypeOf ex Is System.Net.Mail.SmtpFailedRecipientsException Then
Dim voE As SmtpFailedRecipientsException = ex
txtOut.Text =
"!!!Couldn't send mail!!! (FailedRecipients)" & vbCrLf & "Error-Message: " & voE.Message & vbCrLf & "Failed Recipients: " & voE.FailedRecipient & vbCrLf & "Source: " & voE.Source & vbCrLf & vbCrLf & "StackTrace: " & vbCrLf & voE.StackTrace
Else
txtOut.Text =
"!!!Couldn't send mail!!!" & vbCrLf & "Error-Message: " & ex.Message & vbCrLf & "Source: " & ex.Source & vbCrLf & vbCrLf & "StackTrace: " & vbCrLf & ex.StackTrace
End If
btnSend.Enabled =
True
Exit Sub
End Try
txtOut.Text =
"Mail sucessfully sent."
btnSend.Enabled =
True
End Sub
Thanx