1 Star 0 Fork 0

redaus / mitm_addon

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
demo.py 484 Bytes
一键复制 编辑 原始数据 按行查看 历史
Your Name 提交于 2021-12-09 11:01 . inital
# coding:utf-8
"""Add an HTTP header to each response."""
class AddHeader:
def __init__(self):
self.num = 0
def response(self, flow):
self.num = self.num + 1
flow.response.headers["count"] = str(self.num)
_names = list(flow.response.headers)
_values = [flow.response.headers[x] for x in _names]
_data = {_names[i]: _values[i] for i in range(len(_names))}
print(_data)
addons = [
AddHeader()
]
1
https://gitee.com/actanble/mitm_addon.git
git@gitee.com:actanble/mitm_addon.git
actanble
mitm_addon
mitm_addon
master

搜索帮助