Pending Review
Last Updated: 26 Dec 2018 03:30 by Eric
a
Created on: 25 Dec 2018 06:24
Type: Bug Report
1
执行“bpu xxx”请求断点后,AutoTamperRequestBefore(Session oSession)方法里oSession.oFlags.ContainsKey("x-breakrequest")=false

执行“bpu xxx”请求断点后,AutoTamperRequestBefore(Session oSession)方法里oSession.oFlags.ContainsKey("x-breakrequest")=false。

但是执行“bpa xxx”响应断点后,AutoTamperResponseBefore(Session oSession)方法里oSession.oFlags.ContainsKey("x-breakresponse")=true。

1 comment
Eric
Posted on: 26 Dec 2018 03:30

think the complaint here is that the bpu rule sets the x-breakrequest flag inside the OnBeforeRequest event, while the bpa rule sets the x-breakresponse flag inside the OnPeekAtResponseHeaders event. The result is that extensions that try to examine these flags inside the AutoTamperRe[quest|sponse] event handlers see differing behaviors.

You can fix this yourself if you'd like; just click Rules > Customize Rules and move the lines

        if ((null!=bpRequestURI) && oSession.uriContains(bpRequestURI)) {
                oSession["x-breakrequest"]="uri";
            }

            if ((null!=bpMethod) && (oSession.HTTPMethodIs(bpMethod))) {
                oSession["x-breakrequest"]="method";
            }

...from their current location into the OnPeekAtRequestHeaders event.