lists.torproject.org
Sign In Sign Up
Manage this list Sign In Sign Up

Keyboard Shortcuts

Thread View

  • j: Next unread message
  • k: Previous unread message
  • j a: Jump to all threads
  • j l: Jump to MailingList overview

tbb-commits

Thread Start a new thread
Download
Threads by month
  • ----- 2025 -----
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2024 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2023 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2022 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2021 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2020 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2019 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2018 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2017 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2016 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2015 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2014 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
tbb-commits@lists.torproject.org

  • 18606 discussions
[Git][tpo/applications/tor-browser][tor-browser-115.11.0esr-13.5-1] 4 commits: fixup! Bug 42397: Change RFP-spoofed TZ to Atlantic/Reykjavik.
by Pier Angelo Vendrame (@pierov) 03 Jun '24

03 Jun '24
Pier Angelo Vendrame pushed to branch tor-browser-115.11.0esr-13.5-1 at The Tor Project / Applications / Tor Browser Commits: 83e6ff81 by Pier Angelo Vendrame at 2024-06-03T10:06:52+02:00 fixup! Bug 42397: Change RFP-spoofed TZ to Atlantic/Reykjavik. Revert &quot;Bug 42397: Change RFP-spoofed TZ to Atlantic/Reykjavik.&quot; This reverts commit 6d9095b1fcfd0a89f9871301e1d9f0f561ff50be. - - - - - 499e612d by hackademix at 2024-06-03T10:10:13+02:00 Bug 1835987 - Change RFP-spoofed TZ to Atlantic/Reykjavik. r=tjr Atlantic/Reykjavik stays on UTC during all the year, but it is less likely to be blocked than plan UTC. Differential Revision: https://phabricator.services.mozilla.com/D212131 - - - - - 02196ae8 by Pier Angelo Vendrame at 2024-06-03T10:11:43+02:00 fixup! Bug 41966: Allow removing locales from the locale alternatives list. Revert &quot;Bug 41966: Allow removing locales from the locale alternatives list.&quot; This reverts commit bba294a4b4a78c8b2fa2cb31e4cb4aa0c86d058e. - - - - - 385c5834 by Henry Wilkes at 2024-06-03T10:12:13+02:00 Bug 1851618 - Allow removing packaged locales from requestedLocales. r=settings-reviewers,eemeli,Gijs We open up the UI to allow the user to remove locales from their requestedLocales list, except for the default locale. Differential Revision: https://phabricator.services.mozilla.com/D209930 - - - - - 4 changed files: - browser/components/preferences/dialogs/browserLanguages.js - browser/components/preferences/tests/browser_browser_languages_subdialog.js - browser/components/resistfingerprinting/test/browser/browser_timezone.js - js/src/vm/DateTime.cpp Changes: ===================================== browser/components/preferences/dialogs/browserLanguages.js ===================================== @@ -327,8 +327,7 @@ class SortedItemSelectList { * @prop {string} id - A unique ID. * @prop {string} label - The localized display name. * @prop {string} value - The BCP 47 locale identifier or the word "search". - * @prop {boolean} canRemove - Locales that are part of the packaged locales cannot be - * removed. + * @prop {boolean} canRemove - The default locale cannot be removed. * @prop {boolean} installed - Whether or not the locale is installed. */ @@ -338,7 +337,6 @@ class SortedItemSelectList { */ async function getLocaleDisplayInfo(localeCodes) { let availableLocales = new Set(await LangPackMatcher.getAvailableLocales()); - let packagedLocales = new Set(Services.locale.packagedLocales); let localeNames = Services.intl.getLocaleDisplayNames( undefined, localeCodes, @@ -349,7 +347,7 @@ async function getLocaleDisplayInfo(localeCodes) { id: "locale-" + code, label: localeNames[i], value: code, - canRemove: code !== Services.locale.defaultLocale, + canRemove: code != Services.locale.defaultLocale, installed: availableLocales.has(code), }; }); ===================================== browser/components/preferences/tests/browser_browser_languages_subdialog.js ===================================== @@ -142,18 +142,23 @@ async function createDictionaryBrowseResults() { return dir; } -function assertLocaleOrder(list, locales) { +function assertLocaleOrder(list, locales, selectedLocale) { is( list.itemCount, locales.split(",").length, - "The right number of locales are selected" + "The right number of locales are in the list" ); is( Array.from(list.children) .map(child => child.value) .join(","), locales, - "The selected locales are in order" + "The listed locales are in order" + ); + is( + list.selectedItem.value, + selectedLocale, + "The selected item locale matches" ); } @@ -219,6 +224,11 @@ async function selectLocale(localeCode, available, selected, dialogDoc) { await added; } +// Select a locale from the list of already added locales. +function selectAddedLocale(localeCode, selected) { + selected.selectedItem = selected.querySelector(`[value="${localeCode}"]`); +} + async function openDialog(doc, search = false) { let dialogLoaded = promiseLoadSubDialog(BROWSER_LANGUAGES_URL); if (search) { @@ -283,7 +293,7 @@ add_task(async function testDisabledBrowserLanguages() { // pl is not selected since it's disabled. is(pl.userDisabled, true, "pl is disabled"); is(pl.version, "1.0", "pl is the old 1.0 version"); - assertLocaleOrder(selected, "en-US,he"); + assertLocaleOrder(selected, "en-US,he", "en-US"); // Wait for the children menu to be populated. await BrowserTestUtils.waitForCondition( @@ -313,7 +323,7 @@ add_task(async function testDisabledBrowserLanguages() { // Add pl. await selectLocale("pl", available, selected, dialogDoc); - assertLocaleOrder(selected, "pl,en-US,he"); + assertLocaleOrder(selected, "pl,en-US,he", "pl"); // Find pl again since it's been upgraded. pl = await AddonManager.getAddonByID(langpackId("pl")); @@ -371,12 +381,12 @@ add_task(async function testReorderingBrowserLanguages() { let firstDialogId = getDialogId(dialogDoc); // The initial order is set by the pref, filtered by available. - assertLocaleOrder(selected, "en-US,pl,he"); + assertLocaleOrder(selected, "en-US,pl,he", "en-US"); // Moving pl down changes the order. - selected.selectedItem = selected.querySelector("[value='pl']"); + selectAddedLocale("pl", selected); dialogDoc.getElementById("down").doCommand(); - assertLocaleOrder(selected, "en-US,he,pl"); + assertLocaleOrder(selected, "en-US,he,pl", "pl"); // Accepting the change shows the confirm message bar. let dialogClosed = BrowserTestUtils.waitForEvent(dialog, "dialogclosing"); @@ -404,13 +414,13 @@ add_task(async function testReorderingBrowserLanguages() { selected = newDialog.selected; // The initial order comes from the previous settings. - assertLocaleOrder(selected, "en-US,he,pl"); + assertLocaleOrder(selected, "en-US,he,pl", "en-US"); // Select pl in the list. - selected.selectedItem = selected.querySelector("[value='pl']"); + selectAddedLocale("pl", selected); // Move pl back up. dialogDoc.getElementById("up").doCommand(); - assertLocaleOrder(selected, "en-US,pl,he"); + assertLocaleOrder(selected, "en-US,pl,he", "pl"); // Accepting the change hides the confirm message bar. dialogClosed = BrowserTestUtils.waitForEvent(dialog, "dialogclosing"); @@ -485,25 +495,42 @@ add_task(async function testAddAndRemoveSelectedLanguages() { } ); // The initial order is set by the pref. - assertLocaleOrder(selected, "en-US"); + assertLocaleOrder(selected, "en-US", "en-US"); assertAvailableLocales(available, ["fr", "pl", "he"]); + let removeButton = dialogDoc.getElementById("remove"); + // Cannot remove the default locale. + is(removeButton.disabled, true, "Remove en-US should be disabled"); + // Add pl and fr to selected. await selectLocale("pl", available, selected, dialogDoc); await selectLocale("fr", available, selected, dialogDoc); - assertLocaleOrder(selected, "fr,pl,en-US"); + assertLocaleOrder(selected, "fr,pl,en-US", "fr"); assertAvailableLocales(available, ["he"]); + // Can remove the added locale again. + is(removeButton.disabled, false, "Remove fr should be not be disabled"); + + selectAddedLocale("en-US", selected); + // Cannot remove the default locale, even after adding more. + is(removeButton.disabled, true, "Remove en-us should still be disabled"); + // Remove pl and fr from selected. - dialogDoc.getElementById("remove").doCommand(); - dialogDoc.getElementById("remove").doCommand(); - assertLocaleOrder(selected, "en-US"); + selectAddedLocale("fr", selected); + is(removeButton.disabled, false, "Remove fr should be not be disabled"); + removeButton.doCommand(); + // Selection moves to pl. + assertLocaleOrder(selected, "pl,en-US", "pl"); + is(removeButton.disabled, false, "Remove pl should be not be disabled"); + removeButton.doCommand(); + assertLocaleOrder(selected, "en-US", "en-US"); assertAvailableLocales(available, ["fr", "pl", "he"]); + is(removeButton.disabled, true, "Remove en-us should be disabled at end"); // Add he to selected. await selectLocale("he", available, selected, dialogDoc); - assertLocaleOrder(selected, "he,en-US"); + assertLocaleOrder(selected, "he,en-US", "he"); assertAvailableLocales(available, ["pl", "fr"]); // Accepting the change shows the confirm message bar. @@ -603,7 +630,7 @@ add_task(async function testInstallFromAMO() { } // The initial order is set by the pref. - assertLocaleOrder(selected, "en-US"); + assertLocaleOrder(selected, "en-US", "en-US"); assertAvailableLocales(available, ["fr", "he", "pl"]); is( Services.locale.availableLocales.join(","), @@ -633,7 +660,7 @@ add_task(async function testInstallFromAMO() { ); // Verify the list is correct. - assertLocaleOrder(selected, "pl,en-US"); + assertLocaleOrder(selected, "pl,en-US", "pl"); assertAvailableLocales(available, ["fr", "he"]); is( Services.locale.availableLocales.sort().join(","), @@ -658,7 +685,7 @@ add_task(async function testInstallFromAMO() { // Move pl down the list, which prevents an error since it isn't valid. dialogDoc.getElementById("down").doCommand(); - assertLocaleOrder(selected, "en-US,pl"); + assertLocaleOrder(selected, "en-US,pl", "pl"); // Test that disabling the langpack removes it from the list. let dialogClosed = BrowserTestUtils.waitForEvent(dialog, "dialogclosing"); @@ -683,7 +710,7 @@ add_task(async function testInstallFromAMO() { target => available.itemCount > 1 ); } - assertLocaleOrder(selected, "en-US"); + assertLocaleOrder(selected, "en-US", "en-US"); assertAvailableLocales(available, ["fr", "he", "pl"]); // Uninstall the langpack and dictionary. ===================================== browser/components/resistfingerprinting/test/browser/browser_timezone.js ===================================== @@ -18,13 +18,13 @@ async function verifySpoofed() { function test() { let date = new Date(); const TZ_NAME = "Atlantic/Reykjavik"; - const TZ_SUFFIX = "(Greenwich Mean Time)"; + const TZ_SUFFIX = "Greenwich Mean Time"; ok( - date.toString().endsWith(TZ_SUFFIX), + date.toString().endsWith(`(${TZ_SUFFIX})`), `The date toString() is in ${TZ_NAME} timezone.` ); ok( - date.toTimeString().endsWith(TZ_SUFFIX), + date.toTimeString().endsWith(`(${TZ_SUFFIX})`), `The date toTimeString() is in ${TZ_NAME} timezone.` ); let dateTimeFormat = Intl.DateTimeFormat("en-US", { ===================================== js/src/vm/DateTime.cpp ===================================== @@ -484,11 +484,12 @@ bool js::DateTimeInfo::internalTimeZoneDisplayName(char16_t* buf, size_t buflen, mozilla::intl::TimeZone* js::DateTimeInfo::timeZone() { if (!timeZone_) { - // For resist finger printing mode we always use the Atlantic/Reykjavik time zone - // as a "real world" UTC equivalent. + // For resist finger printing mode we always use the Atlantic/Reykjavik time + // zone as a "real world" UTC equivalent. mozilla::Maybe<mozilla::Span<const char16_t>> timeZoneOverride; if (shouldResistFingerprinting_) { - timeZoneOverride = mozilla::Some(mozilla::MakeStringSpan(u"Atlantic/Reykjavik")); + timeZoneOverride = + mozilla::Some(mozilla::MakeStringSpan(u"Atlantic/Reykjavik")); } auto timeZone = mozilla::intl::TimeZone::TryCreate(timeZoneOverride); View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser/-/compare/2c4138… -- This project does not include diff previews in email notifications. View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser/-/compare/2c4138… You're receiving this email because of your account on gitlab.torproject.org.
1 0
0 0
[Git][tpo/applications/mullvad-browser][mullvad-browser-115.11.0esr-13.5-1] fixup! Bug 41916: Letterboxing preferences UI
by ma1 (@ma1) 03 Jun '24

03 Jun '24
ma1 pushed to branch mullvad-browser-115.11.0esr-13.5-1 at The Tor Project / Applications / Mullvad Browser Commits: 1b8016ae by hackademix at 2024-06-03T10:09:33+02:00 fixup! Bug 41916: Letterboxing preferences UI Import gLetterboxingPrefs for the linter. - - - - - 1 changed file: - browser/components/preferences/main.js Changes: ===================================== browser/components/preferences/main.js ===================================== @@ -3,6 +3,7 @@ * You can obtain one at http://mozilla.org/MPL/2.0/. */ /* import-globals-from extensionControlled.js */ +/* import-globals-from letterboxing.js */ /* import-globals-from preferences.js */ /* import-globals-from /toolkit/mozapps/preferences/fontbuilder.js */ /* import-globals-from /browser/base/content/aboutDialog-appUpdater.js */ View it on GitLab: https://gitlab.torproject.org/tpo/applications/mullvad-browser/-/commit/1b8… -- This project does not include diff previews in email notifications. View it on GitLab: https://gitlab.torproject.org/tpo/applications/mullvad-browser/-/commit/1b8… You're receiving this email because of your account on gitlab.torproject.org.
1 0
0 0
[Git][tpo/applications/tor-browser][base-browser-115.11.0esr-13.5-1] fixup! Bug 41916: Letterboxing preferences UI
by ma1 (@ma1) 03 Jun '24

03 Jun '24
ma1 pushed to branch base-browser-115.11.0esr-13.5-1 at The Tor Project / Applications / Tor Browser Commits: 9054cfca by hackademix at 2024-06-03T10:07:55+02:00 fixup! Bug 41916: Letterboxing preferences UI Import gLetterboxingPrefs for the linter. - - - - - 1 changed file: - browser/components/preferences/main.js Changes: ===================================== browser/components/preferences/main.js ===================================== @@ -3,6 +3,7 @@ * You can obtain one at http://mozilla.org/MPL/2.0/. */ /* import-globals-from extensionControlled.js */ +/* import-globals-from letterboxing.js */ /* import-globals-from preferences.js */ /* import-globals-from /toolkit/mozapps/preferences/fontbuilder.js */ /* import-globals-from /browser/base/content/aboutDialog-appUpdater.js */ View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser/-/commit/9054cfc… -- This project does not include diff previews in email notifications. View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser/-/commit/9054cfc… You're receiving this email because of your account on gitlab.torproject.org.
1 0
0 0
[Git][tpo/applications/tor-browser][tor-browser-115.11.0esr-13.5-1] fixup! Bug 41916: Letterboxing preferences UI
by ma1 (@ma1) 03 Jun '24

03 Jun '24
ma1 pushed to branch tor-browser-115.11.0esr-13.5-1 at The Tor Project / Applications / Tor Browser Commits: 2c413893 by hackademix at 2024-06-03T10:01:17+02:00 fixup! Bug 41916: Letterboxing preferences UI Import gLetterboxingPrefs for the linter. - - - - - 1 changed file: - browser/components/preferences/main.js Changes: ===================================== browser/components/preferences/main.js ===================================== @@ -3,6 +3,7 @@ * You can obtain one at http://mozilla.org/MPL/2.0/. */ /* import-globals-from extensionControlled.js */ +/* import-globals-from letterboxing.js */ /* import-globals-from preferences.js */ /* import-globals-from /toolkit/mozapps/preferences/fontbuilder.js */ /* import-globals-from /browser/base/content/aboutDialog-appUpdater.js */ View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser/-/commit/2c41389… -- This project does not include diff previews in email notifications. View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser/-/commit/2c41389… You're receiving this email because of your account on gitlab.torproject.org.
1 0
0 0
[Git][tpo/applications/tor-browser-build][main] Bug 41153: Update README for Ubuntu 24.04 unprivileged user namespace changes
by boklm (@boklm) 01 Jun '24

01 Jun '24
boklm pushed to branch main at The Tor Project / Applications / tor-browser-build Commits: bd033876 by NoisyCoil at 2024-06-01T10:49:06+02:00 Bug 41153: Update README for Ubuntu 24.04 unprivileged user namespace changes - - - - - 1 changed file: - README Changes: ===================================== README ===================================== @@ -78,12 +78,18 @@ The build system is based on rbm, which is included as a git submodule in the rbm/ directory. You can fetch the rbm git submodule by running 'make submodule-update'. -The build uses user_namespaces(7), which are disabled by default on Debian. -To enable them you can use the following command as root: +The build uses user_namespaces(7), which are disabled by default on Debian +and on Ubuntu v24.04 and later. To enable them on Debian you can use the +following command as root: # sysctl -w kernel.unprivileged_userns_clone=1 -You can enable them permanently by adding the setting to /etc/sysctl.d/ +To enable them on Ubuntu v24.04 and later, you can use the following command +as root: + + # sysctl -w kernel.apparmor_restrict_unprivileged_userns=0 + +You can enable them permanently by adding the settings to /etc/sysctl.d/ The user you use to build needs to have a range of subordinate uids and gids in /etc/subuid and /etc/subgid. Most of the time they are added by View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser-build/-/commit/b… -- This project does not include diff previews in email notifications. View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser-build/-/commit/b… You're receiving this email because of your account on gitlab.torproject.org.
1 0
0 0
[Git][tpo/applications/tor-browser][tor-browser-115.11.0esr-13.5-1] fixup! Bug 41600: Add a tor circuit display panel.
by richard (@richard) 30 May '24

30 May '24
richard pushed to branch tor-browser-115.11.0esr-13.5-1 at The Tor Project / Applications / Tor Browser Commits: c3e505ef by Henry Wilkes at 2024-05-30T16:38:58+01:00 fixup! Bug 41600: Add a tor circuit display panel. Bug 41859: Increase ip address font size to make them more legible on windows OS. - - - - - 1 changed file: - browser/components/torcircuit/content/torCircuitPanel.css Changes: ===================================== browser/components/torcircuit/content/torCircuitPanel.css ===================================== @@ -165,11 +165,16 @@ } .tor-circuit-addresses { - font-size: smaller; + font-size: 0.9em; font-family: monospace; margin-inline-start: 0.75em; } +.tor-circuit-ip-address { + /* Override the rule for <code>, which is -moz-fixed. */ + font-family: inherit; +} + /* Footer buttons */ .tor-circuit-button label { margin: 0; View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser/-/commit/c3e505e… -- This project does not include diff previews in email notifications. View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser/-/commit/c3e505e… You're receiving this email because of your account on gitlab.torproject.org.
1 0
0 0
[Git][tpo/applications/mullvad-browser][mullvad-browser-115.11.0esr-13.5-1] Bug 290: Add default bookmarks in alpha channel for testing
by richard (@richard) 30 May '24

30 May '24
richard pushed to branch mullvad-browser-115.11.0esr-13.5-1 at The Tor Project / Applications / Mullvad Browser Commits: 80396457 by Dan Ballard at 2024-05-30T12:28:35+00:00 Bug 290: Add default bookmarks in alpha channel for testing - - - - - 1 changed file: - browser/base/content/default-bookmarks.html Changes: ===================================== browser/base/content/default-bookmarks.html ===================================== @@ -15,7 +15,18 @@ <h1>Bookmarks</h1> <dl><p> - <dt><a href="https://mullvad.net/" icon="@mullvad_icon@">Mullvad VPN</a></dt> + <dt><a href="https://mullvad.net/" icon="@mullvad_icon@">Mullvad VPN</a></dt> +#if MOZ_UPDATE_CHANNEL != release + <dt><h3>QA</h3></dt> + <dl><p> + <dt><a href="https://mullvad.net/check">connection check</a></dt> + <dt><a href="https://webrtc.github.io/samples/src/content/getusermedia/gum/">webcam | webRTC</a></dt> + <dt><a href="https://webrtc.github.io/samples/src/content/getusermedia/audio/">audio | webRTC</a></dt> + <dt><a href="https://webrtc.github.io/samples/src/content/getusermedia/getdisplaymedia/">screenshare | webRTC</a></dt> + <dt><a href="https://youtube.com/">youtube</a></dt> + <dt><a href="https://theguardian.com/">the guardian</a></dt> + </dl><p> +#endif </dl><p> </body> </html> View it on GitLab: https://gitlab.torproject.org/tpo/applications/mullvad-browser/-/commit/803… -- This project does not include diff previews in email notifications. View it on GitLab: https://gitlab.torproject.org/tpo/applications/mullvad-browser/-/commit/803… You're receiving this email because of your account on gitlab.torproject.org.
1 0
0 0
[Git][tpo/applications/mullvad-browser][mullvad-browser-115.11.0esr-13.5-1] 5 commits: fixup! Bug 40175: Add origin attributes to about:reader top-level requests
by richard (@richard) 30 May '24

30 May '24
richard pushed to branch mullvad-browser-115.11.0esr-13.5-1 at The Tor Project / Applications / Mullvad Browser Commits: f34bff1e by Pier Angelo Vendrame at 2024-05-30T11:44:22+00:00 fixup! Bug 40175: Add origin attributes to about:reader top-level requests Revert &quot;Bug 40175: Add origin attributes to about:reader top-level requests&quot; This reverts commit 2718a926fd331a0df2ad8cc90c6c9633f3630243. - - - - - 7684ec07 by Pier Angelo Vendrame at 2024-05-30T11:44:22+00:00 fixup! Bug 41116: Normalize system fonts. Revert &quot;fixup! Bug 41116: Normalize system fonts.&quot; This reverts commit 2c1a8f5261873f3c2435b9de1f83c07d5933748e. - - - - - aff5ec0f by Pier Angelo Vendrame at 2024-05-30T11:44:22+00:00 fixup! Bug 41116: Normalize system fonts. Revert &quot;Bug 41116: Normalize system fonts.&quot; This reverts commit df3f350e810ebe79c0823a124e6a555baf812f55. - - - - - 6ebf41c3 by Pier Angelo Vendrame at 2024-05-30T11:44:23+00:00 Bug 1787790: Normalize system fonts with RFP on. r=emilio System fonts can leak any user customization of system fonts, or user&#39;s locale (e.g., en-US and ja Windows have different system fonts). Also, Linux distributions/desktop environments set default fonts in different ways. Customization can be detected either with font metrics, the font allowed list is not enabled or the font is included in it, or with getComputedStyle, that leaks the name of the font that Firefox tries to apply. This patch try to prevent these leaks by using a generic &quot;sans-serif&quot; for all system fonts, except on macOS, where it uses &quot;-apple-system&quot;, and on Android, where these fonts always use Roboto. Differential Revision: https://phabricator.services.mozilla.com/D163576 - - - - - 1b026291 by cypherpunks1 at 2024-05-30T11:44:23+00:00 Bug 1892046 - Add origin attributes to about:reader requests. r=reader-mode-reviewers,cmkm Differential Revision: https://phabricator.services.mozilla.com/D207759 - - - - - 5 changed files: - gfx/thebes/gfxPlatformFontList.cpp - layout/base/nsLayoutUtils.cpp - layout/reftests/font-matching/reftest.list - + layout/reftests/font-matching/system-font-rfp-ref.html - + layout/reftests/font-matching/system-font-rfp.html Changes: ===================================== gfx/thebes/gfxPlatformFontList.cpp ===================================== @@ -1973,19 +1973,17 @@ static void GetSystemUIFontFamilies(const nsPresContext* aPresContext, nsFont systemFont; gfxFontStyle fontStyle; nsAutoString systemFontName; - if (aPresContext && aPresContext->Document() - ? aPresContext->Document()->ShouldResistFingerprinting( - RFPTarget::Unknown) - : nsContentUtils::ShouldResistFingerprinting( - "aPresContext not available", RFPTarget::Unknown)) { -#ifdef XP_MACOSX + if (aPresContext ? aPresContext->Document()->ShouldResistFingerprinting( + RFPTarget::Unknown) + : nsContentUtils::ShouldResistFingerprinting( + "aPresContext not available", RFPTarget::Unknown)) { +#if defined(XP_MACOSX) || defined(MOZ_WIDGET_UIKIT) *aFamilies.AppendElement() = "-apple-system"_ns; return; #elif !defined(MOZ_WIDGET_ANDROID) *aFamilies.AppendElement() = "sans-serif"_ns; return; #endif - // Android uses already fixed fonts. } if (!LookAndFeel::GetFont(StyleSystemFont::Menu, systemFontName, fontStyle)) { return; ===================================== layout/base/nsLayoutUtils.cpp ===================================== @@ -9680,7 +9680,7 @@ already_AddRefed<nsFontMetrics> nsLayoutUtils::GetMetricsFor( static void GetSpoofedSystemFontForRFP(LookAndFeel::FontID aFontID, gfxFontStyle& aStyle, nsAString& aName) { -#if defined(XP_MACOSX) +#if defined(XP_MACOSX) || defined(MOZ_WIDGET_UIKIT) aName = u"-apple-system"_ns; // Values taken from a macOS 10.15 system. switch (aFontID) { @@ -9690,7 +9690,8 @@ static void GetSpoofedSystemFontForRFP(LookAndFeel::FontID aFontID, break; case LookAndFeel::FontID::SmallCaption: aStyle.weight = gfxFontStyle::FontWeight::BOLD; - // fall-through + // fall-through for font-size + [[fallthrough]]; case LookAndFeel::FontID::MessageBox: case LookAndFeel::FontID::StatusBar: aStyle.size = 11; @@ -9704,14 +9705,13 @@ static void GetSpoofedSystemFontForRFP(LookAndFeel::FontID aFontID, // languages, so we fallback to sans-serif to fall back to the user's // default sans-serif. Size is 12px for all system fonts (tried in an en-US // system). - // Several Android systems reported Roboto 12px, so similar to what Windows - // does. aName = u"sans-serif"_ns; aStyle.size = 12; #elif defined(MOZ_WIDGET_ANDROID) + // Keep consistency with nsLookAndFeel::NativeGetFont. aName = u"Roboto"_ns; aStyle.size = 12; -#else +#elif defined(MOZ_WIDGET_GTK) // On Linux, there is not a default. For example, GNOME on Debian uses // Cantarell, 14.667px. Ubuntu Mate uses the Ubuntu font, but also 14.667px. // Fedora with KDE uses Noto Sans, 13.3333px, but it uses Noto Sans on @@ -9721,6 +9721,8 @@ static void GetSpoofedSystemFontForRFP(LookAndFeel::FontID aFontID, // UI font-size. aName = u"sans-serif"_ns; aStyle.size = 15; +#else +# error "Unknown platform" #endif } ===================================== layout/reftests/font-matching/reftest.list ===================================== @@ -195,3 +195,6 @@ pref(ui.font.menu,"serif") test-pref(ui.font.menu.weight,"800") != system-font-p # Reset default prefs. defaults + +# Bug 1787790 - Normalize system fonts when using RFP +test-pref(privacy.resistFingerprinting,true) == system-font-rfp.html system-font-rfp-ref.html ===================================== layout/reftests/font-matching/system-font-rfp-ref.html ===================================== @@ -0,0 +1,44 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<style> +body { + font-family: -apple-system, sans-serif; + font-size: 12px; +} + +.android { + font-family: Roboto; +} + +.linux { + font-size: 15px; +} + +.mac { + .caption, .menu { + font-size: 13px; + } + .message-box, .status-bar { + font-size: 11px; + } + .small-caption { + font-size: 11px; + font-weight: 700; + } +} +</style> +<div class="caption">Caption</div> +<div class="icon">Icon</div> +<div class="menu">Menu</div> +<div class="message-box">Message box</div> +<div class="small-caption">Small caption</div> +<div class="status-bar">Status bar</div> +<script> +if (navigator.platform.startsWith("Mac")) { + document.querySelector("body").className = "mac"; +} else if (navigator.userAgent.includes("Android")) { + document.querySelector("body").className = "android"; +} else if (navigator.platform.startsWith("Linux")) { + document.querySelector("body").className = "linux"; +} +</script> ===================================== layout/reftests/font-matching/system-font-rfp.html ===================================== @@ -0,0 +1,8 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<div style="font: caption">Caption</div> +<div style="font: icon">Icon</div> +<div style="font: menu">Menu</div> +<div style="font: message-box">Message box</div> +<div style="font: small-caption">Small caption</div> +<div style="font: status-bar">Status bar</div> View it on GitLab: https://gitlab.torproject.org/tpo/applications/mullvad-browser/-/compare/2c… -- This project does not include diff previews in email notifications. View it on GitLab: https://gitlab.torproject.org/tpo/applications/mullvad-browser/-/compare/2c… You're receiving this email because of your account on gitlab.torproject.org.
1 0
0 0
[Git][tpo/applications/tor-browser][base-browser-115.11.0esr-13.5-1] 5 commits: fixup! Bug 40175: Add origin attributes to about:reader top-level requests
by richard (@richard) 30 May '24

30 May '24
richard pushed to branch base-browser-115.11.0esr-13.5-1 at The Tor Project / Applications / Tor Browser Commits: 62fcc276 by Pier Angelo Vendrame at 2024-05-30T11:43:20+00:00 fixup! Bug 40175: Add origin attributes to about:reader top-level requests Revert &quot;Bug 40175: Add origin attributes to about:reader top-level requests&quot; This reverts commit 2718a926fd331a0df2ad8cc90c6c9633f3630243. - - - - - 2058592a by Pier Angelo Vendrame at 2024-05-30T11:43:21+00:00 fixup! Bug 41116: Normalize system fonts. Revert &quot;fixup! Bug 41116: Normalize system fonts.&quot; This reverts commit 2c1a8f5261873f3c2435b9de1f83c07d5933748e. - - - - - d7d0c5a8 by Pier Angelo Vendrame at 2024-05-30T11:43:21+00:00 fixup! Bug 41116: Normalize system fonts. Revert &quot;Bug 41116: Normalize system fonts.&quot; This reverts commit df3f350e810ebe79c0823a124e6a555baf812f55. - - - - - f6b799f0 by Pier Angelo Vendrame at 2024-05-30T11:43:21+00:00 Bug 1787790: Normalize system fonts with RFP on. r=emilio System fonts can leak any user customization of system fonts, or user&#39;s locale (e.g., en-US and ja Windows have different system fonts). Also, Linux distributions/desktop environments set default fonts in different ways. Customization can be detected either with font metrics, the font allowed list is not enabled or the font is included in it, or with getComputedStyle, that leaks the name of the font that Firefox tries to apply. This patch try to prevent these leaks by using a generic &quot;sans-serif&quot; for all system fonts, except on macOS, where it uses &quot;-apple-system&quot;, and on Android, where these fonts always use Roboto. Differential Revision: https://phabricator.services.mozilla.com/D163576 - - - - - 5658183f by cypherpunks1 at 2024-05-30T11:43:22+00:00 Bug 1892046 - Add origin attributes to about:reader requests. r=reader-mode-reviewers,cmkm Differential Revision: https://phabricator.services.mozilla.com/D207759 - - - - - 5 changed files: - gfx/thebes/gfxPlatformFontList.cpp - layout/base/nsLayoutUtils.cpp - layout/reftests/font-matching/reftest.list - + layout/reftests/font-matching/system-font-rfp-ref.html - + layout/reftests/font-matching/system-font-rfp.html Changes: ===================================== gfx/thebes/gfxPlatformFontList.cpp ===================================== @@ -1973,19 +1973,17 @@ static void GetSystemUIFontFamilies(const nsPresContext* aPresContext, nsFont systemFont; gfxFontStyle fontStyle; nsAutoString systemFontName; - if (aPresContext && aPresContext->Document() - ? aPresContext->Document()->ShouldResistFingerprinting( - RFPTarget::Unknown) - : nsContentUtils::ShouldResistFingerprinting( - "aPresContext not available", RFPTarget::Unknown)) { -#ifdef XP_MACOSX + if (aPresContext ? aPresContext->Document()->ShouldResistFingerprinting( + RFPTarget::Unknown) + : nsContentUtils::ShouldResistFingerprinting( + "aPresContext not available", RFPTarget::Unknown)) { +#if defined(XP_MACOSX) || defined(MOZ_WIDGET_UIKIT) *aFamilies.AppendElement() = "-apple-system"_ns; return; #elif !defined(MOZ_WIDGET_ANDROID) *aFamilies.AppendElement() = "sans-serif"_ns; return; #endif - // Android uses already fixed fonts. } if (!LookAndFeel::GetFont(StyleSystemFont::Menu, systemFontName, fontStyle)) { return; ===================================== layout/base/nsLayoutUtils.cpp ===================================== @@ -9680,7 +9680,7 @@ already_AddRefed<nsFontMetrics> nsLayoutUtils::GetMetricsFor( static void GetSpoofedSystemFontForRFP(LookAndFeel::FontID aFontID, gfxFontStyle& aStyle, nsAString& aName) { -#if defined(XP_MACOSX) +#if defined(XP_MACOSX) || defined(MOZ_WIDGET_UIKIT) aName = u"-apple-system"_ns; // Values taken from a macOS 10.15 system. switch (aFontID) { @@ -9690,7 +9690,8 @@ static void GetSpoofedSystemFontForRFP(LookAndFeel::FontID aFontID, break; case LookAndFeel::FontID::SmallCaption: aStyle.weight = gfxFontStyle::FontWeight::BOLD; - // fall-through + // fall-through for font-size + [[fallthrough]]; case LookAndFeel::FontID::MessageBox: case LookAndFeel::FontID::StatusBar: aStyle.size = 11; @@ -9704,14 +9705,13 @@ static void GetSpoofedSystemFontForRFP(LookAndFeel::FontID aFontID, // languages, so we fallback to sans-serif to fall back to the user's // default sans-serif. Size is 12px for all system fonts (tried in an en-US // system). - // Several Android systems reported Roboto 12px, so similar to what Windows - // does. aName = u"sans-serif"_ns; aStyle.size = 12; #elif defined(MOZ_WIDGET_ANDROID) + // Keep consistency with nsLookAndFeel::NativeGetFont. aName = u"Roboto"_ns; aStyle.size = 12; -#else +#elif defined(MOZ_WIDGET_GTK) // On Linux, there is not a default. For example, GNOME on Debian uses // Cantarell, 14.667px. Ubuntu Mate uses the Ubuntu font, but also 14.667px. // Fedora with KDE uses Noto Sans, 13.3333px, but it uses Noto Sans on @@ -9721,6 +9721,8 @@ static void GetSpoofedSystemFontForRFP(LookAndFeel::FontID aFontID, // UI font-size. aName = u"sans-serif"_ns; aStyle.size = 15; +#else +# error "Unknown platform" #endif } ===================================== layout/reftests/font-matching/reftest.list ===================================== @@ -195,3 +195,6 @@ pref(ui.font.menu,"serif") test-pref(ui.font.menu.weight,"800") != system-font-p # Reset default prefs. defaults + +# Bug 1787790 - Normalize system fonts when using RFP +test-pref(privacy.resistFingerprinting,true) == system-font-rfp.html system-font-rfp-ref.html ===================================== layout/reftests/font-matching/system-font-rfp-ref.html ===================================== @@ -0,0 +1,44 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<style> +body { + font-family: -apple-system, sans-serif; + font-size: 12px; +} + +.android { + font-family: Roboto; +} + +.linux { + font-size: 15px; +} + +.mac { + .caption, .menu { + font-size: 13px; + } + .message-box, .status-bar { + font-size: 11px; + } + .small-caption { + font-size: 11px; + font-weight: 700; + } +} +</style> +<div class="caption">Caption</div> +<div class="icon">Icon</div> +<div class="menu">Menu</div> +<div class="message-box">Message box</div> +<div class="small-caption">Small caption</div> +<div class="status-bar">Status bar</div> +<script> +if (navigator.platform.startsWith("Mac")) { + document.querySelector("body").className = "mac"; +} else if (navigator.userAgent.includes("Android")) { + document.querySelector("body").className = "android"; +} else if (navigator.platform.startsWith("Linux")) { + document.querySelector("body").className = "linux"; +} +</script> ===================================== layout/reftests/font-matching/system-font-rfp.html ===================================== @@ -0,0 +1,8 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<div style="font: caption">Caption</div> +<div style="font: icon">Icon</div> +<div style="font: menu">Menu</div> +<div style="font: message-box">Message box</div> +<div style="font: small-caption">Small caption</div> +<div style="font: status-bar">Status bar</div> View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser/-/compare/d4e035… -- This project does not include diff previews in email notifications. View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser/-/compare/d4e035… You're receiving this email because of your account on gitlab.torproject.org.
1 0
0 0
[Git][tpo/applications/tor-browser][tor-browser-115.11.0esr-13.5-1] 5 commits: fixup! Bug 40175: Add origin attributes to about:reader top-level requests
by richard (@richard) 30 May '24

30 May '24
richard pushed to branch tor-browser-115.11.0esr-13.5-1 at The Tor Project / Applications / Tor Browser Commits: b4fbb624 by Pier Angelo Vendrame at 2024-05-30T08:49:54+02:00 fixup! Bug 40175: Add origin attributes to about:reader top-level requests Revert &quot;Bug 40175: Add origin attributes to about:reader top-level requests&quot; This reverts commit 2718a926fd331a0df2ad8cc90c6c9633f3630243. - - - - - 73f0f817 by Pier Angelo Vendrame at 2024-05-30T08:50:18+02:00 fixup! Bug 41116: Normalize system fonts. Revert &quot;fixup! Bug 41116: Normalize system fonts.&quot; This reverts commit 2c1a8f5261873f3c2435b9de1f83c07d5933748e. - - - - - 3841a1fd by Pier Angelo Vendrame at 2024-05-30T08:50:37+02:00 fixup! Bug 41116: Normalize system fonts. Revert &quot;Bug 41116: Normalize system fonts.&quot; This reverts commit df3f350e810ebe79c0823a124e6a555baf812f55. - - - - - 09bd48db by Pier Angelo Vendrame at 2024-05-30T08:56:02+02:00 Bug 1787790: Normalize system fonts with RFP on. r=emilio System fonts can leak any user customization of system fonts, or user&#39;s locale (e.g., en-US and ja Windows have different system fonts). Also, Linux distributions/desktop environments set default fonts in different ways. Customization can be detected either with font metrics, the font allowed list is not enabled or the font is included in it, or with getComputedStyle, that leaks the name of the font that Firefox tries to apply. This patch try to prevent these leaks by using a generic &quot;sans-serif&quot; for all system fonts, except on macOS, where it uses &quot;-apple-system&quot;, and on Android, where these fonts always use Roboto. Differential Revision: https://phabricator.services.mozilla.com/D163576 - - - - - fa069b8b by cypherpunks1 at 2024-05-30T08:56:03+02:00 Bug 1892046 - Add origin attributes to about:reader requests. r=reader-mode-reviewers,cmkm Differential Revision: https://phabricator.services.mozilla.com/D207759 - - - - - 5 changed files: - gfx/thebes/gfxPlatformFontList.cpp - layout/base/nsLayoutUtils.cpp - layout/reftests/font-matching/reftest.list - + layout/reftests/font-matching/system-font-rfp-ref.html - + layout/reftests/font-matching/system-font-rfp.html Changes: ===================================== gfx/thebes/gfxPlatformFontList.cpp ===================================== @@ -1973,19 +1973,17 @@ static void GetSystemUIFontFamilies(const nsPresContext* aPresContext, nsFont systemFont; gfxFontStyle fontStyle; nsAutoString systemFontName; - if (aPresContext && aPresContext->Document() - ? aPresContext->Document()->ShouldResistFingerprinting( - RFPTarget::Unknown) - : nsContentUtils::ShouldResistFingerprinting( - "aPresContext not available", RFPTarget::Unknown)) { -#ifdef XP_MACOSX + if (aPresContext ? aPresContext->Document()->ShouldResistFingerprinting( + RFPTarget::Unknown) + : nsContentUtils::ShouldResistFingerprinting( + "aPresContext not available", RFPTarget::Unknown)) { +#if defined(XP_MACOSX) || defined(MOZ_WIDGET_UIKIT) *aFamilies.AppendElement() = "-apple-system"_ns; return; #elif !defined(MOZ_WIDGET_ANDROID) *aFamilies.AppendElement() = "sans-serif"_ns; return; #endif - // Android uses already fixed fonts. } if (!LookAndFeel::GetFont(StyleSystemFont::Menu, systemFontName, fontStyle)) { return; ===================================== layout/base/nsLayoutUtils.cpp ===================================== @@ -9680,7 +9680,7 @@ already_AddRefed<nsFontMetrics> nsLayoutUtils::GetMetricsFor( static void GetSpoofedSystemFontForRFP(LookAndFeel::FontID aFontID, gfxFontStyle& aStyle, nsAString& aName) { -#if defined(XP_MACOSX) +#if defined(XP_MACOSX) || defined(MOZ_WIDGET_UIKIT) aName = u"-apple-system"_ns; // Values taken from a macOS 10.15 system. switch (aFontID) { @@ -9690,7 +9690,8 @@ static void GetSpoofedSystemFontForRFP(LookAndFeel::FontID aFontID, break; case LookAndFeel::FontID::SmallCaption: aStyle.weight = gfxFontStyle::FontWeight::BOLD; - // fall-through + // fall-through for font-size + [[fallthrough]]; case LookAndFeel::FontID::MessageBox: case LookAndFeel::FontID::StatusBar: aStyle.size = 11; @@ -9704,14 +9705,13 @@ static void GetSpoofedSystemFontForRFP(LookAndFeel::FontID aFontID, // languages, so we fallback to sans-serif to fall back to the user's // default sans-serif. Size is 12px for all system fonts (tried in an en-US // system). - // Several Android systems reported Roboto 12px, so similar to what Windows - // does. aName = u"sans-serif"_ns; aStyle.size = 12; #elif defined(MOZ_WIDGET_ANDROID) + // Keep consistency with nsLookAndFeel::NativeGetFont. aName = u"Roboto"_ns; aStyle.size = 12; -#else +#elif defined(MOZ_WIDGET_GTK) // On Linux, there is not a default. For example, GNOME on Debian uses // Cantarell, 14.667px. Ubuntu Mate uses the Ubuntu font, but also 14.667px. // Fedora with KDE uses Noto Sans, 13.3333px, but it uses Noto Sans on @@ -9721,6 +9721,8 @@ static void GetSpoofedSystemFontForRFP(LookAndFeel::FontID aFontID, // UI font-size. aName = u"sans-serif"_ns; aStyle.size = 15; +#else +# error "Unknown platform" #endif } ===================================== layout/reftests/font-matching/reftest.list ===================================== @@ -195,3 +195,6 @@ pref(ui.font.menu,"serif") test-pref(ui.font.menu.weight,"800") != system-font-p # Reset default prefs. defaults + +# Bug 1787790 - Normalize system fonts when using RFP +test-pref(privacy.resistFingerprinting,true) == system-font-rfp.html system-font-rfp-ref.html ===================================== layout/reftests/font-matching/system-font-rfp-ref.html ===================================== @@ -0,0 +1,44 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<style> +body { + font-family: -apple-system, sans-serif; + font-size: 12px; +} + +.android { + font-family: Roboto; +} + +.linux { + font-size: 15px; +} + +.mac { + .caption, .menu { + font-size: 13px; + } + .message-box, .status-bar { + font-size: 11px; + } + .small-caption { + font-size: 11px; + font-weight: 700; + } +} +</style> +<div class="caption">Caption</div> +<div class="icon">Icon</div> +<div class="menu">Menu</div> +<div class="message-box">Message box</div> +<div class="small-caption">Small caption</div> +<div class="status-bar">Status bar</div> +<script> +if (navigator.platform.startsWith("Mac")) { + document.querySelector("body").className = "mac"; +} else if (navigator.userAgent.includes("Android")) { + document.querySelector("body").className = "android"; +} else if (navigator.platform.startsWith("Linux")) { + document.querySelector("body").className = "linux"; +} +</script> ===================================== layout/reftests/font-matching/system-font-rfp.html ===================================== @@ -0,0 +1,8 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<div style="font: caption">Caption</div> +<div style="font: icon">Icon</div> +<div style="font: menu">Menu</div> +<div style="font: message-box">Message box</div> +<div style="font: small-caption">Small caption</div> +<div style="font: status-bar">Status bar</div> View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser/-/compare/46c671… -- This project does not include diff previews in email notifications. View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser/-/compare/46c671… You're receiving this email because of your account on gitlab.torproject.org.
1 0
0 0
  • ← Newer
  • 1
  • ...
  • 227
  • 228
  • 229
  • 230
  • 231
  • 232
  • 233
  • ...
  • 1861
  • Older →

HyperKitty Powered by HyperKitty version 1.3.12.