1

Task: Collect http requests within content scripts of other extensions

Description: I am aware that we can attach debugger using chrome debugger api with an extension background page. However, official documentation haven't clearly mentioned if we can also collect requests made in content scripts of extensions?

Note: This question can be a followup of this question.

Community
  • 1
  • 1
CryptoKitty
  • 654
  • 4
  • 20
  • I have implemented method and able to get the http requests attached to extensions. However, I am not sure these http requests include only the one made from background or also from content scripts as well. – CryptoKitty Jun 27 '15 at 14:36
  • include code in the question. seems like since you already implemented it its a matter of just trying it. what results you get? – Zig Mandel Jun 27 '15 at 15:23

2 Answers2

1

Ok I have done some testing and find out that debugger is attached to only background page. Which means that only http requests from background will be recorded.

CryptoKitty
  • 654
  • 4
  • 20
0

You can, but you'll have to attach to the page itself in which the content script lives, because that's where those requests originate.

Xan
  • 74,770
  • 16
  • 179
  • 206
  • but in that case is there anyway of differentiating requests triggered by page and the ones by context scripts of other extension? – CryptoKitty Jun 30 '15 at 19:24