Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Farble navigator.deviceMemory instead of blocking it #12348

Closed
pilgrim-brave opened this issue Oct 27, 2020 · 2 comments · Fixed by brave/brave-core#6964
Closed

Farble navigator.deviceMemory instead of blocking it #12348

pilgrim-brave opened this issue Oct 27, 2020 · 2 comments · Fixed by brave/brave-core#6964

Comments

@pilgrim-brave
Copy link

pilgrim-brave commented Oct 27, 2020

Currently we block navigator.deviceMemory unconditionally. Instead, proposal:

  • If shields is off globally or anti-fingerprinting is off for a site, return the true value
  • if anti-fingerprinting is default, and true value is at least 0.5, return a valid value between 0.5 and the true value (see https://developer.mozilla.org/en-US/docs/Web/API/Navigator/deviceMemory for valid values)
    • if true value is 0.25, return true value
  • if anti-fingerprinting is maximum, return any valid value

Choice of value is determined by domain key and session key, as with other farbled values.

@pilgrim-brave
Copy link
Author

Test plan:

  1. Visit https://dev-pages.bravesoftware.com/farbling.html and set Fingerprinting to "Allow all" in the Brave Shields panel.
  2. Visit https://dev-pages.brave.software/farbling.html and set Fingerprinting to "Allow all" in the Brave Shields panel.
  3. Click 'Generate fingerprints"
  4. In the 'Device Memory' row, you should see four identical hash values. Note this value.
  5. Visit https://dev-pages.bravesoftware.com/farbling.html and set Fingerprinting to "Block (standard)" in the Brave Shields panel.
  6. Visit https://dev-pages.brave.software/farbling.html and set Fingerprinting to "Block (standard)" in the Brave Shields panel.
  7. Click 'Generate fingerprints"
  8. In the 'Device Memory' row, you should see four identical hash values. This value should be different from the value in step 4.
  9. Visit https://dev-pages.bravesoftware.com/farbling.html and set Fingerprinting to "Block (strict)" in the Brave Shields panel.
  10. Visit https://dev-pages.brave.software/farbling.html and set Fingerprinting to "Block (strict)" in the Brave Shields panel.
  11. Click 'Generate fingerprints"
  12. In the 'Device Memory' row, you should see four identical hash values. This value should be different from the value in step 4. (Do not compare it to the value in step 8.)

@GeetaSarvadnya
Copy link

Verification passed on

Brave | 1.18.69 Chromium: 87.0.4280.88 (Official Build) (64-bit)
-- | --
Revision | 89e2380a3e36c3464b5dd1302349b1382549290d-refs/branch-heads/4280@{#1761}
OS | Windows 10 OS Version 2004 (Build 19041.630)

Fingerprinting to "Allow all" - Device Memory

  • Verified that the 'Device Memory' row has four identical hash values when Fingerprinting is set to "Allow all"
https://dev-pages.bravesoftware.com/farbling.html https://dev-pages.brave.software/farbling.html
image image

Fingerprinting to "Block (standard)" - Device Memory

  • Verified that the 'Device Memory' row has four identical hash values, these values are different from the above values.
https://dev-pages.bravesoftware.com/farbling.html https://dev-pages.brave.software/farbling.html
image image

Fingerprinting to "Block (strict)" - Device Memory

  • Verified that the 'Device Memory' row has four identical hash values in each frame, these values are different from the test Fingerprinting to "Allow all" - **Device Memory**
https://dev-pages.bravesoftware.com/farbling.html https://dev-pages.brave.software/farbling.html
image image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants