Skip to content

MB 328: Refactor the search engine patch.

Merge Info

Related Issues

Backporting

Timeline

  • Immediate: patchset needed as soon as possible
  • Next Minor Stable Release: patchset that needs to be verified in nightly before backport
  • Eventually: patchset that needs to be verified in alpha before backport
  • No Backport (preferred): patchset for the next major stable

(Optional) Justification

  • Emergency security update: patchset fixes CVEs, 0-days, etc
  • Critical bug-fix: patchset fixes a bug in core-functionality
  • Consistency: patchset which would make development easier if it were in both the alpha and release branches; developer tools, build system changes, etc
  • Sponsor required: patchset required for sponsor
  • Localization: typos and other localization changes that should be also in the release branch
  • Other: please explain

Merging

  • Merge to mullvad-browser - !fixups to mullvad-browser-specific commits, new features, security backports
  • Merge to base-browser -!fixups to base-browser-specific commits, new features to be shared with tor-browser
    • NOTE: if your changeset includes patches to both base-browser and mullvad-browser please clearly label in the change description which commits should be cherry-picked to base-browser after merging

Issue Tracking

Review

Request Reviewer

  • Request review from an applications developer depending on modified system:
    • NOTE: if the MR modifies multiple areas, please /cc all the relevant reviewers (since gitlab only allows 1 reviewer)
    • accessibility : henry
    • android : clairehurst, dan
    • build system : boklm
    • extensions : ma1
    • firefox internals (XUL/JS/XPCOM) : jwilde, ma1
    • fonts : pierov
    • frontend (implementation) : henry
    • frontend (review) : donuts, richard
    • localization : henry, pierov
    • macOS : clairehurst, dan
    • nightly builds : boklm
    • rebases/release-prep : dan, ma1, pierov, richard
    • security : jwilde, ma1
    • signing : boklm, richard
    • updater : pierov
    • windows : jwilde, richard
    • misc/other : pierov, richard

Change Description

Upstream switched to a completely different search engine configuration between ESR 115 and ESR 128 (see also tor-browser#42891 (closed)).

I had caught this during the rebases, and provided an already updated configuration for the search engines.

However, after working on this also on Tor Browser, I decided to take another path, and refactored MB to be similar to what we did on TBB (tor-browser!1162 (merged)).

In particular, I took MB's configuration and moved it to a JSON file. Also, I added the orderHint property that initially I didn't add, otherwise the engines were sorted alphabetically.

Then, I added another JSON file to declare the icons.

Finally, I restored the unused search engine webextensions, because removing them would require some migration code to remove them also from the databases. Some alpha users might be in an in-between state, but it isn't too late for release users. Upstream also kept them and planned to remove them in the future.

How Tested

Built a local dev build and checked:

  • all search engines are still present
  • all search engines have icons
  • search engines are in the same order as declared (but actually thanks to the orderHint propety)
  • we don't have any errors related to the search engines in the console

Merge request reports

Loading