test_client.py 文件源码

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

项目:txacme 作者: twisted 项目源码 文件源码
def _create_responder(self):
        action = start_action(action_type=u'integration:create_responder')
        with action.context():
            responder = TLSSNI01Responder()
            host_map = responder.wrap_host_map({})
            site = Site(Resource())
            endpoint = TLSEndpoint(
                endpoint=serverFromString(reactor, self.ENDPOINT),
                contextFactory=SNIMap(host_map))
            return (
                DeferredContext(endpoint.listen(site))
                .addCallback(lambda port: self.addCleanup(port.stopListening))
                .addCallback(lambda _: responder)
                .addActionFinish())
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号