aboutsummaryrefslogtreecommitdiffstats
path: root/test/scripts/tcp_stream_modify.py
diff options
context:
space:
mode:
authorSandor Nemes <snemes@users.noreply.github.com>2016-01-17 21:24:47 +0100
committerSandor Nemes <snemes@users.noreply.github.com>2016-01-17 21:24:47 +0100
commit192f0339674d1b276a0866eddcebb9c93036ae2b (patch)
treebbf4faa75bb330d7d013e17d54f6e5b33ffcbb78 /test/scripts/tcp_stream_modify.py
parent2753af0ec72e542d5a4dc3e5e200bd1638b2b095 (diff)
parent0f54f2990c0a32960ec5c82c620f79c68ad5f4b6 (diff)
downloadmitmproxy-192f0339674d1b276a0866eddcebb9c93036ae2b.tar.gz
mitmproxy-192f0339674d1b276a0866eddcebb9c93036ae2b.tar.bz2
mitmproxy-192f0339674d1b276a0866eddcebb9c93036ae2b.zip
Merge branch 'master' into master
Diffstat (limited to 'test/scripts/tcp_stream_modify.py')
-rw-r--r--test/scripts/tcp_stream_modify.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/test/scripts/tcp_stream_modify.py b/test/scripts/tcp_stream_modify.py
new file mode 100644
index 00000000..9870dddf
--- /dev/null
+++ b/test/scripts/tcp_stream_modify.py
@@ -0,0 +1,3 @@
+def tcp_message(ctx,tm):
+ if tm.sender == tm.server_conn:
+ tm.message = tm.message.replace("foo", "bar")