第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號(hào)安全,請(qǐng)及時(shí)綁定郵箱和手機(jī)立即綁定
已解決430363個(gè)問(wèn)題,去搜搜看,總會(huì)有你想問(wèn)的

如何使用.NET Framework通過(guò)SSL SMTP發(fā)送電子郵件?

如何使用.NET Framework通過(guò)SSL SMTP發(fā)送電子郵件?

holdtom 2019-08-27 18:13:49
如何使用.NET Framework通過(guò)SSL SMTP發(fā)送電子郵件?有沒(méi)有辦法讓.NET Framework通過(guò)端口465上的SSL SMTP服務(wù)器發(fā)送電子郵件?通常的方式:System.Net.Mail.SmtpClient _SmtpServer = new System.Net.Mail.SmtpClient("tempurl.org");_SmtpServer.Port = 465;_SmtpServer.EnableSsl = true;_SmtpServer.Credentials = new System.Net.NetworkCredential("username", "password");_SmtpServer.Timeout = 5000;_SmtpServer.UseDefaultCredentials = false;MailMessage mail = new MailMessage();mail.From = new MailAddress(from);mail.To.Add(to);mail.CC.Add(cc);mail.Subject = subject;mail.Body = content;mail.IsBodyHtml = useHtml;_SmtpServer.Send(mail);超時(shí):System.Net Verbose: 0 : [1024] SmtpClient::.ctor(host=ssl0.ovh.net, port=465)System.Net Information: 0 : [1024] Associating SmtpClient#64923656 with SmtpTransport#44624228System.Net Verbose: 0 : [1024] Exiting SmtpClient::.ctor()  -> SmtpClient#64923656System.Net Information: 0 : [1024] Associating MailMessage#17654054 with Message#52727599System.Net Verbose: 0 : [1024] SmtpClient#64923656::Send(MailMessage#17654054)System.Net Information: 0 : [1024] SmtpClient#64923656::Send(DeliveryMethod=Network)System.Net Information: 0 : [1024] Associating SmtpClient#64923656 with MailMessage#17654054System.Net Information: 0 : [1024] Associating SmtpTransport#44624228 with SmtpConnection#14347911System.Net Information: 0 : [1024] Associating SmtpConnection#14347911 with ServicePoint#51393439System.Net.Sockets Verbose: 0 : [1024] Socket#26756241::Socket(InterNetwork#2)System.Net.Sockets Verbose: 0 : [1024] Exiting Socket#26756241::Socket() System.Net.Sockets Verbose: 0 : [1024] Socket#23264094::Socket(InterNetworkV6#23)我搜索了一下,發(fā)現(xiàn)System.Net.Mail支持端口587上的連接(顯式SSL的默認(rèn)端口,未加密,然后發(fā)出STARTDLS,然后切換到加密連接:RFC 2228),但不支持隱式SSL(整個(gè)連接)被包裹在SSL層中)...
查看完整描述

3 回答

  • 3 回答
  • 0 關(guān)注
  • 1531 瀏覽

添加回答

舉報(bào)

0/150
提交
取消
微信客服

購(gòu)課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動(dòng)學(xué)習(xí)伙伴

公眾號(hào)

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號(hào)