imaprelayclient.py 文件源码

python
阅读 18 收藏 0 点赞 0 评论 0

项目:PiBunny 作者: tholum 项目源码 文件源码
def __init__(self, target):
        # Target comes as protocol://target:port
        self.target = target
        proto, host, port = target.split(':')
        host = host[2:]
        if int(port) == 993 or proto.upper() == 'IMAPS':
            self.session = imaplib.IMAP4_SSL(host,int(port))
        else:
            #assume non-ssl IMAP
            self.session = imaplib.IMAP4(host,port)
        if 'AUTH=NTLM' not in self.session.capabilities:
            logging.error('IMAP server does not support NTLM authentication!')
            return False
        self.authtag = self.session._new_tag()
        self.lastresult = None
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号