Skip to content
Permalink
Branch: master
Find file Copy path
1 contributor

Users who have contributed to this file

14 lines (9 sloc) 313 Bytes
import re
from mitmproxy import ctx
def websocket_message(flow):
# get the latest message
message = flow.messages[-1]
# simply print the content of the message
ctx.log.info(message.content)
# manipulate the message content
message.content = re.sub(r'^Hello', 'HAPPY', message.content)
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.