告诉我谁知道。几天来,我一直在努力尝试连接到端口 110 上的 pop.mail.ru 服务器。发送 USER 时,我从服务器收到错误消息:
-ERR POP3 is available only with SSL or TLS connection enabled
网上所有的例子都没有设计成使用SSL或者TLS加密,怎么和这个加密联系起来呢?有文章吗?感谢你的回答。
编码:
mailclient = new TcpClient("pop.mail.ru", 110);
NetworkStream ns = mailclient.GetStream();
StreamReader sr = new StreamReader(ns);
StreamWriter sw = new StreamWriter(ns);
sw.WriteLine("USER " + "***@mail.ru");
sw.Flush();
必须与一起使用
SslStream,TcpClient然后用于SslStream读取数据,而不是TcpClient.就像是:
取自这里