#151 JShelter FPD Wrappers not applying correctly (custom version of JShelter 0.20)
Opened by noxx483. Modified

Summary

I am using a custom version of JShelter (which I edited myself) in Selenium-driven Chrome For Testing. I edited JShelter FPD to always track callers by default and to automatically download callers report. JS Shields are also edited to be disabled by default. The edits (as well as scripts for testing and reproducing the issue) are available at my github.
The issue is that in version 0.20, the downloaded report is empty - no callers are listed. In 0.19, the issue also exists, but only for ~10% of visited pages. In 0.20, none of the tested pages (which worked with 0.19) work. I used the same custom code in both versions. The issue can be fixed by manually clicking the "Track calling scripts" in the FPD Report menu. After the page reloads, the report is automatically filled and downloaded correctly.

Setup

Pages affected: All tested pages
Custom JShelter Version: 0.20

Relevant pop-up information:

  1. Is Fingerprint Detector active? ON
  2. What fingerprint likelihood does Fingerprint Detector report? None
  3. Did Fingerprint Detector produce any notifications, if so, what was the notification? No

OS: Windows 11
Browser: Selenium-driven Chrome For Testing
Other extensions that might affect JShelter behaviour: None

How to reproduce

(run the script provided in the github link OR:)

  1. Run Selenium-driven Google Chrome with the custom JShelter added as an extension
  2. Enable developer mode and update the extension
  3. Visit the desired page (e.g. https://novinky.cz)
  4. Wait a few seconds for the FPD report to automatically download

Expected result

FPD report filled with tracked callers, as with version 0.19.
Example of FPD obtained with custom edited version of 0.19:
{"fpd_access_logs":{"1332887290":{"Navigator.prototype.userAgent":{"get":{"args":{"":452},"total":452,"callers":{"Error: FPDCallerTracker\n at Navigator.replacementPD.......

Actual result

FPD report is empty {"fpd_access_logs":{"1610246551":{}}}

Reproducibility

I tried to manually load the same custom version of JShelter 0.20 in Brave Browser 1.76.82 and it work as intended - correctly downloads the report filled with callers.
I did not try other browsers in Selenium since I would like to use JShelter specifically in Selenium-driven Google Chrome for testing.

Workarounds

I am able to get it to work inn Selenium by clicking the "Track calling scripts" button in the FPD Report submenu. After I click it, the page reloads and the report succesfully downloads filled with the observed callers.

Have you tried other steps to solve the issue?

  1. I made the exact same changes in version 0.19 and it works there, ~90% of the time.
  2. I tested it in regular browser, Brave, and it works as intended. The issue seems to be present only in Selenium Chrome-for-testing

fpd_report_empty.png


Hello,

Unfortunately, I think that I cannot replicate the behaviour in my setup (Chromium in Linux). My steps to reproduce:

  • Clone the repository
  • Import unpacked extensions from jshelter_0_20_custom_fpd directory
  • Visit https://coveryourtracks.eff.org/
  • Click Test your browser
  • During testing, I see the notification that fingerprinting attempt was blocked
  • JShelter badge icon shows 5 in red backgroud
  • The popup shows very high number of APIs misusable for fingerprinting
  • FPD report window shows many APIs that were called by the page, not empty window

When visiting novinky.cz (note that I have some tracker blockers active):
* Continue the session started above
* Visit novinky.cz
* JShelter badge shows 1 in green background
* JShelter popup shows None for the number of APIs misusable for fingerprinting (this seems more like a bad way to present the information, i.e. different issue)
* FPD report shows quite a few APIs accessed by the page (the exported JSON has about 250kB)

I will check in Windows and Chrome/Edge

I observed the same behaviour in Windows 11 Education with only JShelter installed (no other extension), browsers tested:
* Microsoft Edge Version 134.0.3124.85 (Official build) (64-bit)
* Chrome Version 135.0.7049.85 (Official Build) (64-bit)

I saw just minor difference like FPD reporting low number of misusable APIs.

Hello,

I also tested it in Windows with Brave and Edge, it works there (i.e. downloaded report is correctly populated).

The issue seems to be present only in Selenium-simulated browser (I tried Chrome-For-Testing), which means it might actually not be a fault in JShelter but in Selenium, or Chrome-For-Testing. Or even in my machine. However, it seems to work even with Selenium on rare occasions.

To reproduce the issue, either run the script on my github or do the following steps:

  1. Create default Selenium Chromedriver.

  2. chrome_options = ChromeOptions.Options()

  3. service = ChromeService.Service()
  4. driver = webdriver.Chrome(service=service, options=chrome_options)

I also tried adding the arguments specified in the script on my github. I tried running it using the same arguments as version 0.19, which seems to work in Selenium.

  1. Either enable developer mode manually in chrome://extensions and load unpacked JShelter from the jshelter_0_20_custom_fpd directory, or load it automatically using the provided script.
  2. Visit the desired page (tested on novinky.cz)
  3. Wait for the report to download
  4. FPD report is empty

As mentioned, sometimes, the report is correctly populated. But when I re-launch it, it is empty again.

0.20.2 updated NSCL, is there a change regarding this issue?

0.20.2 updated NSCL, is there a change regarding this issue?

I updated my repository with JShelter chrome build of 0.20.2, tested in Selenium with chromedrivers 134 and 136 and still no change, FPD report remains empty.

Metadata