⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 httpauth.py

📁 属性sosuo算法
💻 PY
字号:
import itertoolsfrom dl_daemon import commandimport eventlooprequestIdGenerator = itertools.count()waitingHTTPAuthCallbacks = {}def handleHTTPAuthResponse(id, authHeader):    callback = waitingHTTPAuthCallbacks.pop(id)    callback(authHeader)def findHTTPAuth(callback, host, path):    id = requestIdGenerator.next()    waitingHTTPAuthCallbacks[id] = callback    from dl_daemon import daemon    c = command.FindHTTPAuthCommand(daemon.lastDaemon, id, host, path)    c.send()def askForHTTPAuth(callback, host, path, authScheme):    id = requestIdGenerator.next()    waitingHTTPAuthCallbacks[id] = callback    from dl_daemon import daemon    c = command.AskForHTTPAuthCommand(daemon.lastDaemon, id, host, path,            authScheme)    c.send()

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -