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

Idle Detection API is back and there is no way to turn it off globally #20490

Closed
Kiyos opened this issue Jan 13, 2022 · 5 comments
Closed

Idle Detection API is back and there is no way to turn it off globally #20490

Kiyos opened this issue Jan 13, 2022 · 5 comments

Comments

@Kiyos
Copy link

Kiyos commented Jan 13, 2022

Description

One of the privacy-breaking features of latest Chromium — Idle Detection API — has appeared in Brave 1.34.80. Older release versions did not have this as per team’s official position. But something went wrong. Sites now can request the permission to know when the user is actively using the device and there is no way to either deny it for all sites by default, or to turn it off completely (which could be even better) via UI.

Steps to Reproduce

  1. Visit the Idle Detection API test page at https://reillyeon.github.io/scraps/idle.html
  2. Observe that the usual red banner at the top of the page (“the Idle Detection API is unavailable”) is now absent
  3. Click the “Request Permission” button
  4. Observe the “reillyeon.github.io wants to Know when you're actively using the device” popup
  5. Click Allow or Deny, then click on the ”View site information” button in the address bar
  6. Observe the new “Your device use” permission with the chosen setting, which is also reflected in the log on the test page
  7. Go to Site and Shields Settings (brave://settings/content), expand Additional permissions
  8. Observe that “Your device use” setting isn’t there
  9. Go to Flags (brave://flags/), search for “idle”
  10. Observe that nothing is found

Actual result:

Step 2:
brave_no_banner

Step 4:
brave_idle_detection_on_a_site

Step 6:
brave_idle_detection_on_a_site_off

Step 8:
brave_no_idle_detection_in_settings

Step 10:
brave_no_idle_detection_in_flags

Expected result:

The “Idle Detection API is unavailable” banner on the test page is visible and there are no permission prompts.

Reproduces how often:

Easily reproduced.

Brave version (brave://version info)

Brave | 1.34.80 Chromium: 97.0.4692.71 (Official Build) (64-bit)
Revision | adefa7837d02a07a604c1e6eff0b3a09422ab88d-refs/branch-heads/4692@{#1247}
OS | Windows 7 Service Pack 1 (Build 7601.24544)

Version/Channel Information:

  • Can you reproduce this issue with the current release?
    Brave is up to date for my OS, so — yes.
  • Can you reproduce this issue with the beta channel?
    Version 1.35.82 — yes.
  • Can you reproduce this issue with the nightly channel?
    Version 1.36.35 — yes.

Other Additional Information:

  • Does the issue resolve itself when disabling Brave Shields?
    No.
  • Does the issue resolve itself when disabling Brave Rewards?
    No.
  • Is the issue reproducible on the latest version of Chrome?
    No.

Miscellaneous Information:

Related issues: #18409, #18417
I sure hope that this feature has made its way back into the codebase by mistake.

@UjCbFwtBayFM
Copy link

Tried reproducing using 1.36.37. Launching Brave in normal mode and trying to request permission using the Idle Detection API test page fails 100% of the time.
2022-01-14-001346-brave
No default setting visible at brave://settings/content.

Launching Brave using --enable-features=IdleDetection has the mentioned test tool work correctly, with no "Unavailable API" banner. Default permission setting displays correctly in brave://settings/content.
2022-01-14-001839-brave
Setting Block as default does not show permission prompt and tool reports it has been denied.
2022-01-14-002524-brave
Setting Allow to ask as default has the permission prompt display correctly, which if overridden is visible on site-specific settings page.
x6oqVSX3YN
2022-01-14-002725-brave

@Kiyos
Copy link
Author

Kiyos commented Jan 17, 2022

There was a strange development today. The red “The Idle Detection API appears not to be supported in your browser” banner on the test page is showing again, as it should. And when I click the Request Permission button, the log says that “IdleDetector is not defined”, again, as it should:
idle_not_enabled_again
It is very strange indeed, because nothing has changed in my browser. Its version is still 1.34.80, there were no new addons installed, etc.
Either it’s a transient issue (which is bad for debugging, I know), or a remote config has been applied.

@Kiyos
Copy link
Author

Kiyos commented Jan 25, 2022

Smol update:
Version 1.34.81 Chromium: 97.0.4692.99 (Official Build) (64-bit) — the issue cannot be reproduced.

@kjozwiak
Copy link
Member

kjozwiak commented Apr 1, 2022

@Kiyos sounds like we can close this one off? Have run into the above since originally reporting it? I tried reproducing it on a clean profile using the following build:

Brave | 1.37.109 Chromium: 100.0.4896.60 (Official Build) (64-bit)
-- | --
Revision | 6a5d10861ce8de5fce22564658033b43cb7de047-refs/branch-heads/4896@{#875}
OS | Windows 11 Version 21H2 (Build 22000.593)

image

@Kiyos
Copy link
Author

Kiyos commented Apr 30, 2022

I guess we can close this for now, yes. However, I still monitor the situation every day because of its weirdness, and will reopen the issue if needed.

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

No branches or pull requests

4 participants