Lurker News
Hi HN

I needed a way to monitor network calls made by chrome extensions so I made a small extension.
You can install it by dropping the zip or crx into the extensions page. It'll be on the chrome store whenever/if it gets through the review.
Hopefully it's useful to others.
https://github.com/dnakov/little-rat
https://twitter.com/dnak0v

Comments (101) 23 threads

Earlier comments
Daviey1 reply#
Thanks for sharing, would you mind explaining how it works and if there are any general concerns you have with Chrome not sandboxing between extensions? ie, what else is shared between extensions and what risks do you feel are here.

Thanks

lapcat1 reply#
The key code is here: https://github.com/dnakov/little-rat/blob/f0b9b6be39af9fe7f4...

  chrome.declarativeNetRequest.onRuleMatchedDebug.addListener((e) => {
    if (e.request.initiator?.startsWith('chrome-extension://')) {
Given that the extension is using a "Debug" API, it seems unlikely that the Chrome Web Store will approve. "Only available for unpacked extensions with the declarativeNetRequestFeedback permission as this is intended to be used for debugging purposes only." https://developer.chrome.com/docs/extensions/reference/decla...
npace121 reply#
Yeah, that's correct. The extension loads a rules_1.json file that just "allow"s all traffic originating from third-party scripts through, then logs just the URL of each request coming from a chrome extension. There's probably a way to do this with chrome.webRequest, I'll experiment with that, but generally that one is more expensive in terms of performance.
gorhill1 reply#
> There's probably a way to do this with chrome.webRequest

Network requests initiated by other extensions in their own context are not visible to other extensions through the webRequest API.

Continue this thread — 1 reply

_V_1 reply#
FYI: That CRX in Releases did not work for me - it did install correctly, it showed up in the toolbar but opened an empty popup (no extensions were listed)...

The upnacked zip worked just fine though!
Nice extension, thanks!
(Vivaldi 6.2.3096.3 on Linux)

_V_1 reply#
Also it seems that the "mute" button is somewhat broken or something - I have ~10 extensions and when I click "mute" on some extension, it will toggle mute on the second to the last.

Repeated clicking results in loop of 1) muting second to the last extension 2) muting the extension I'm actually clicking 3) unmuting second to the last and 4) unmuting the one I'm clicking :-D
It is quite hard to describe, I may create a video and upload it somewhere later.

npace121 reply#
Thanks for the feedback, I'll check it out, I haven't tried it in Vivaldi yet.
_V_1 reply#
Hope it helps!

I was clicking around for a bit and noticed one more thing: it does not display "Anti Anti Debug" extension - but that extension suddenly appears when I toggle any mute button.
Maybe that extension is doing something funny? It is too late for me to try now but I will keep digging around tomorrow.

Continue this thread — 1 reply

mickelsen1 reply#
Thank you so much! This is so useful, now I don't have to audit extensions manually.
chinmayag32#
that's a good use case.

Load more comments