# Force request matching by modifying dumpfile with inline script

**URL:** <https://discourse.mitmproxy.org/t/force-request-matching-by-modifying-dumpfile-with-inline-script/69>\
**Category:** help\
**Created:** [July 7, 2016, 1:49am UTC](https://discourse.mitmproxy.org/t/force-request-matching-by-modifying-dumpfile-with-inline-script/69 "2016-07-07T01:49:25Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ntulele](https://avatars.discourse-cdn.com/v4/letter/n/9fc348/32.png) [@ntulele](https://discourse.mitmproxy.org/u/ntulele)\
**Post date:** [July 7, 2016, 1:49am UTC](https://discourse.mitmproxy.org/t/force-request-matching-by-modifying-dumpfile-with-inline-script/69/1 "2016-07-07T01:49:25Z")

</div>

I’m trying to overcome request matching failures during server response replay. The failures are caused by a timestamp in a request URL parameter.  
My intended solution is to:

1. Remove the timestamps from the flow.request.path for relevant requests in the saved mitmdump file that I’m using for playback, using an inline script
2. Remove the timestamps on-the-fly from incoming requests, using an inline script

So, my questions are:

- Does this seem like a good solution? Is there a better one that I’m overlooking?

- Is there an example script similar to what I need for #1? I’ve looked through the examples and don’t see quite how to alter the flow.request.path for certain responses in a dump file, and save that altered dump file for later server-playback.

Thanks!!

---

<div class="post-metadata">

**Author:** ![mhils](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mitmproxy.org/mhils/32/7_2.png) [@mhils](https://discourse.mitmproxy.org/u/mhils)\
**Post date:** [July 7, 2016, 2:04am UTC](https://discourse.mitmproxy.org/t/force-request-matching-by-modifying-dumpfile-with-inline-script/69/2 "2016-07-07T02:04:17Z")

</div>

Hi @ntulele,

Generally speaking, that sounds like a reasonable solution. However, if the timestamp is just a regular request parameter, you can probably just use `--replay-ignore-param`?

> [@ntulele](#):
>
> I’ve looked through the examples and don’t see quite how to alter the flow.request.path for certain responses in a dump file, and save that altered dump file for later server-playback.

`mitdump -r existing-dumpfile -s transfoming-script -w new-dumpfile` should do the job.

Cheers,  
Max

---

<div class="post-metadata">

**Author:** ![ntulele](https://avatars.discourse-cdn.com/v4/letter/n/9fc348/32.png) [@ntulele](https://discourse.mitmproxy.org/u/ntulele)\
**Post date:** [July 7, 2016, 7:20am UTC](https://discourse.mitmproxy.org/t/force-request-matching-by-modifying-dumpfile-with-inline-script/69/3 "2016-07-07T07:20:29Z")

</div>

–replay-ignore-param worked, thank you for the speedy reply!

Sorry for overlooking/misunderstanding that option in the documentation.
