add websocket.timestamp_end

This commit is contained in:
Maximilian Hils 2021-03-16 14:52:01 +01:00
parent f236ee42ed
commit ac9852122f
4 changed files with 8 additions and 1 deletions

View file

@ -21,7 +21,7 @@ def websocket_message(flow):
async def inject_async(flow: http.HTTPFlow):
msg = "hello from mitmproxy! "
while flow.server_conn.connected:
while flow.websocket.timestamp_end is None:
ctx.master.commands.call("inject", [flow], False, msg)
await asyncio.sleep(1)
msg = msg[1:] + msg[:1]