Fiddler blocking HTTP request modification data

Source: Internet
Author: User

1. Intercept HTTP requestsUsing Fiddler for HTTP Breakpoint debugging is one of the powerful and practical tools of Fiddler. By setting breakpoints, Fiddler can: ① modify HTTP request header information. For example, modify the Ua,cookie,referer information of the request header, through "Forge" the corresponding information to achieve the corresponding purpose (debugging, simulation of user real request, etc.). ② constructs the request data, breaks through the restriction of the form, submits the data arbitrarily. Avoid page JS and form restrictions affecting debugging. ③ Intercept response data and modify the response entity.There are two ways of setting breakpoints:①fiddler the menu bar->rules->automatic breakpoints-> Select a breakpoint, the breakpoint set in this way will be valid for all subsequent HTTP requests. There are two breakpoint locations:1) before response. That is, after the request is sent, but before the Fiddler agent Relays, the requested data can be modified. 2) after response. That is, after the server is appropriate, but before fiddler the response to the client. You can then modify the result of the response. 3) How to eliminate the command? Click Rules->automatic breakpoint->disabled② command line setting breakpoints1) Bpu interrupt at the start of the request 2) Bpafter interrupt when the response arrives 3) BPS Interrupt HTTP response status for all session responses of the specified character 4) bpv/bpm interrupt Specifies the request method for all session response Example one: command-line input: BPM www.baidu.cm (intercept www.baidu.com request) unblock: input command: bpu Example II: Command line input: Bpuafter www.baidu.cm (intercept www.baidu.cm return value) unblock: input command: Bpuafter2. Modify the DataThere are two ways to modify the HTTP request after blocking it, one is temporary modification, that is, the result is only valid for the second request, and the other is permanent modification, which can be implemented by the Urlreplace command.① Temporary Modification requestThat is, execute inspectors->webforms in fiddler, modify the request variable parameter after executing run to completion, the server returns the new request result② Permanent Modification Request1) command line set modify rule, modify request: Urlreplace old Request value new request value Fiddler command line input: Urlreplace pageid=103 pageid=105 where PageID is request parameter, enter command and return, new request set success , unless the request is released, the request value is not changed, the release request command Urlreplace2) script modifies the rule and opens the script as follows: Fiddler execute rules->customize rulesExample one: Intercept a koala client request, modify the request dataPre-conditions: Mobile phone set up the agent (preferably do not test WiFi, testing WiFi modified DNS, tampering with complex content) Step one: Intercept the live Discovery page request, fiddler command line execution: BPUhttp://api.kaolafm.com/api/v4/pagecontent/list?pageid=103Step two: Mobile phone start Koala, click on the Live tab, not open the Live List page fiddler View request does not have any return value step three: Webfroms Modify the parameter value temporarily modify the request, Return discovery page data: Fiddler execution:inspectors-> WebForms, change PageID value from 103 to 105, execute run to completion, interface returns host list page data step four: command line settings modify data rule, change data permanently fiddler command line execution: Urlreplace pageid= 103 pageid=105 Step Five: Client click on the Live tab, open the Host Discovery page Step six: Unblock, execute: urlreplace, and then execute: Bpu Step seven: Customers click the Live tab to open the Live Discovery page normallyThe interface request process is as follows:Example two: interception of a request with a status code of 302Step one: PC Browser opens:www.kaollafm.comStep two: Fiddler command line execution: BPS 302 step three: again in PC browser open:www.kaolafm.comStep four: Unblock, command line execution: bpsThe interface request process is as follows:Data Source:https://wenku.baidu.com/view/ff185ff7cfc789eb172dc8f3.html

Fiddler blocking HTTP request modification data

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.