autodiscovery.py 文件源码

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

项目:peas 作者: mwrlabs 项目源码 文件源码
def __init__(self, email_address):
        impl = getDOMImplementation()
        newdoc = impl.createDocument(None, "Autodiscover", None)        
        top_element = newdoc.documentElement
        top_element.setAttribute("xmlns", "http://schemas.microsoft.com/exchange/autodiscover/mobilesync/requestschema/2006")
        req_elem = newdoc.createElement('Request')
        top_element.appendChild(req_elem)
        email_elem = newdoc.createElement('EMailAddress')
        req_elem.appendChild(email_elem)
        email_elem.appendChild(newdoc.createTextNode(email_address))
        resp_schema = newdoc.createElement('AcceptableResponseSchema')
        req_elem.appendChild(resp_schema)
        resp_schema.appendChild(newdoc.createTextNode("http://schemas.microsoft.com/exchange/autodiscover/mobilesync/responseschema/2006"))
        self.body = newdoc.toxml("utf-8")
        self.length = len(self.body)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号