Chilkat: SmtpCmdResp: 354 输入消息,以 "." 结尾



我尝试使用ChilkatAppendMail方法将发送的邮件存储在Sent邮箱

$oIMAP.AppendMail($sMailbox_name, $oEmail)

大多数情况下它工作得很好。但是在一些终端客户端配置中,我得到:

--sendCmdToSmtp
--sendRcptTo
sendCmdToSmtp:
SmtpCmdSent: DATA<CRLF>
--sendCmdToSmtp
readSmtpResponse:
SmtpCmdResp: 250 OK
--readSmtpResponse
readRcptTo:
readSmtpResponse:
SmtpCmdResp: 250 Accepted
--readSmtpResponse
recipient: *****@destination.pl
--readRcptTo
readRcptTo:
readSmtpResponse:
SmtpCmdResp: 250 Accepted
--readSmtpResponse
recipient: *****@sender.pl
--readRcptTo
readSmtpResponse:
SmtpCmdResp: 354 Enter message, ending with "." on a line by itself
--readSmtpResponse
--sendWithPipelining
sendCmdToSmtp:
SmtpCmdSent: <CRLF>.<CRLF>
--sendCmdToSmtp
readSmtpResponse:
SmtpCmdResp: 250 OK id=1nypCX-0005r9-EO
--readSmtpResponse
--sendSmtpEmail
--sendMimeInner
--sendEmailInner
Success.
--SendEmail
--ChilkatLog

我的问题是为什么会出现354 Enter message, ending with "." on a line by itself?

我已经读过了:输入邮件,以"."结尾

:https://serverfault.com/questions/509464/error - -不发送消息服务器-说- 354

我读到:Whoever wrote the webmail program needs to go back and read RFC 5321 again and then fix the bug.

所以我想知道是不是Chilkat组件有问题?或者我需要更改代码中的某些内容?

我猜您同时拥有MailMan对象(对于SMTP)和IMAP对象的实例。你打电话给邮差。SendEmail发送邮件,它工作得很好。然后调用一个Imap方法将发送的电子邮件复制(追加)到" sent "文件夹在邮件服务器。Imap呼叫失败,但随后您错误地显示了邮递员。LastErrorText而不是imap.LastErrorText.

最新更新