测试脚本: # -*- coding: utf-8 -*- import socket,select,base64,os,re,time,datetime class mail: def __init__(self): self.errmsg = '' def send(self, buf): try: byteswritten = 0 while byteswritten < len(buf): byteswritten += self.__sockfd.send(buf[byteswritt…