简体   繁体   English

chrome WebRequest API可以监控http请求吗?

[英]Can chrome WebRequest API monitor the http request?

I want to monitor all the http request send from my chrome browser, and collect all the http request to another server. 我想监视从我的chrome浏览器发送的所有http请求,并将所有http请求收集到另一台服务器。

I have read This question and These examples , but I don't know how to get the content of the request. 我已经阅读了这个问题这些示例 ,但是我不知道如何获取请求的内容。

For example, when I browse google.com in my chrome browser with this chrome extension, this extension will send the following the another server which will collect it: 例如,当我使用此chrome扩展程序在chrome浏览器中浏览google.com时,此扩展程序将向以下另一台服务器发送信息,以收集该信息:

GET http://www.google.com/ HTTP/1.1
Accept: text/html, application/xhtml+xml, */*
Accept-Language: zh-CN
User-Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; InfoPath.2)
Accept-Encoding: gzip, deflate
Proxy-Connection: Keep-Alive
Host: www.google.com
Pragma: no-cache
Cookie: blabla...

I can not find how to get the content of all the requests from here , is that possible? 我找不到从这里获取所有请求内容的方法,这可能吗?

Sorry, it's not possible at the moment. 抱歉,目前无法执行。 All you can get is headers. 您所能获得的只是标题。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Chrome扩展程序chrome.webRequest API-请求标题中未包含一些http请求标题 - Chrome extension chrome.webRequest API - Some http request headers not coming in request headers Chrome扩展程序:使用chrome.webRequest修改与cURL请求的`--data` arg等效的HTTP请求 - Chrome Extensions: use chrome.webRequest to modify HTTP request equivalent of the `--data` arg of a cURL request 使用Google Chrome webRequest API进行简单转发 - Simple forwarding using Google Chrome webRequest API Google Chrome webRequest API和swf文件 - Google Chrome webRequest API and swf file Chrome.webRequest API - requestBody始终未定义 - Chrome.webRequest API - requestBody always undefined Chrome或FireFox可以强制执行https请求而不是http请求吗? - Can Chrome or FireFox force https request instead of http request? 是否可以使用扩展程序监控 Chrome 中的 HTTP 流量? - Is it possible to monitor HTTP Traffic in Chrome using an extension? Java API / Google Chrome请求之间的HTTP请求区别? - HTTP request differences between Java API/Google Chrome requests? 使用chrome.webRequest.onBeforeRequest进行同步XHR请求 - Making synchoronous XHR request with chrome.webRequest.onBeforeRequest chrome.webRequest.onBeforeRequest.addListener 背景 Ajax 请求? - chrome.webRequest.onBeforeRequest.addListener background Ajax request?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM