зеркало из https://github.com/mozilla/gecko-dev.git
d1694a0fd4
This patch ultimately overrides the user-agent which Fennec users send to Google Search pages, choosing a phone- or tablet-specific UA as appropriate. It involves adding four new metadata keys to the webcompat addon's metadata for user-agent overrides: blocks, permanentPref, experiment, telemetryKey: - "blocks" specifies URLs for which any requests should be aborted. This allows us to block the Google service worker for now, as it has caused "content corrupted" issues in the past with other enhanced search addons (see https://github.com/wisniewskit/google-search-fixer/issues/1). - "permanentPref" specifies an about:config preference, which dictates whether the injection is used. Users may set this to `false` to disable the injection outright, and permanently; `true` or `undefined` values allow the injection to function normally. - "experiment" specifies the name of the experiment this feature is optionally gated behind. Only a Fennec-specific implementation is provided in this patch. The implementation simply queries Switchboard to determine if the experiment is active. - "telemetryKey" specifies which telemetry key should be flipped to "true" when this injection runs. We will use this to note whether enhanced search has actually been enabled for this profile. Only a Fennec-specific implementation is given in this patch, which actually just sets a Fennec Shared Preference, which Fennec's core telemetry ping later reads in Java to know what the ping should contain. Differential Revision: https://phabricator.services.mozilla.com/D41074 --HG-- extra : moz-landing-system : lando |
||
---|---|---|
.. | ||
formautofill | ||
fxmonitor | ||
pdfjs | ||
report-site-issue | ||
screenshots | ||
webcompat | ||
moz.build |