Windows launch-on-login can silently re-enable itself on later startups for existing users (first-run enable gate is not durable)
Categories
(Firefox :: Shell Integration, defect)
Tracking
()
People
(Reporter: drubino, Assigned: iholmes)
References
Details
Attachments
(1 file)
Symptom / reports
Windows users report that "Open Firefox when your computer starts" (launch-on-login) turns itself back ON after they disable it -- not just once
on a new install, but repeatedly on subsequent startups. Reddit: https://www.reddit.com/r/firefox/comments/1ubmddw/comment/ot1b7m5/
Root cause (code analysis)
The default-enable of launch-on-login is gated solely on nsIToolkitProfileService.isFirstRun, which is recomputed every startup, and can be true on more than the genuine first run:
- By design: new install path / different install hash (side-by-side installs, moved/portable install, install-dir layout change).
- Gap: installs.ini not persisting the install Default (roaming / OneDrive-redirected AppData, locked-down/enterprise profiles, AV)
- Gap: Launching exclusively via -P / --profile, which never establishes the install default (the -P/--profile arms of SelectStartupProfile return without setting it or clearing mIsFirstRun).
Meanwhile, there is no durable "default already applied" marker for launch on login. Any time isFirstRun re-evaluates true for an established user launch-on-login is re-enabled, silently overriding the user's choice.
Telemetry evidence
BigQuery, firefox_desktop.metrics, 1% sample, Windows, release, last 21 days, using os.environment.launch_on_login_state cross-referenced with
launch_on_login.user_toggle: 91% of disable to enable transitions currently are happening without a user toggle, which is about 5,000 clients a week.
Proposed fix
Add "launch-on-login default already applied" and set it when:
- The default is actually applied
- The profile starts up and isFirstStartup evaluates to false
- The user uses Firefox preferences to change the setting from enabled to disabled
And then check this pref before enabling launch on login if ever isFirstRun evaluates to true again.
| Assignee | ||
Comment 1•2 days ago
|
||
isFirstRun can be reset and return a false positive in certain scenarios which causes the launch
on login preference to be reenabled even after the user disables it.
This change sets a preference flag so we can tell if we've already enabled it once, so we don't
revert user changes.
Updated•2 days ago
|
Description
•