forked from mirrors/gecko-dev
Bug 1838415 - Introduce RFPTarget::FontVisibilityBaseSystem + LangPack. r=tjr
Differential Revision: https://phabricator.services.mozilla.com/D181235
This commit is contained in:
parent
b374d67adf
commit
14d55c325c
3 changed files with 9 additions and 8 deletions
|
|
@ -764,8 +764,12 @@ bool nsPresContext::UpdateFontVisibility() {
|
||||||
// Read the relevant pref depending on RFP/trackingProtection state
|
// Read the relevant pref depending on RFP/trackingProtection state
|
||||||
// to determine the visibility level to use.
|
// to determine the visibility level to use.
|
||||||
int32_t level;
|
int32_t level;
|
||||||
if (mDocument->ShouldResistFingerprinting(RFPTarget::Unknown)) {
|
if (mDocument->ShouldResistFingerprinting(
|
||||||
level = StaticPrefs::layout_css_font_visibility_resistFingerprinting();
|
RFPTarget::FontVisibilityBaseSystem)) {
|
||||||
|
level = int32_t(FontVisibility::Base);
|
||||||
|
} else if (mDocument->ShouldResistFingerprinting(
|
||||||
|
RFPTarget::FontVisibilityLangPack)) {
|
||||||
|
level = int32_t(FontVisibility::LangPack);
|
||||||
} else if (StaticPrefs::privacy_trackingprotection_enabled() ||
|
} else if (StaticPrefs::privacy_trackingprotection_enabled() ||
|
||||||
(isPrivate &&
|
(isPrivate &&
|
||||||
StaticPrefs::privacy_trackingprotection_pbmode_enabled())) {
|
StaticPrefs::privacy_trackingprotection_pbmode_enabled())) {
|
||||||
|
|
|
||||||
|
|
@ -8562,12 +8562,6 @@
|
||||||
value: 3
|
value: 3
|
||||||
mirror: always
|
mirror: always
|
||||||
|
|
||||||
# font-visibility setting when Resist Fingerprinting is enabled
|
|
||||||
- name: layout.css.font-visibility.resistFingerprinting
|
|
||||||
type: int32_t
|
|
||||||
value: 1
|
|
||||||
mirror: always
|
|
||||||
|
|
||||||
# Max font-visibility setting for Private Browsing contexts
|
# Max font-visibility setting for Private Browsing contexts
|
||||||
# (The actual value used in a private-browsing context will be the lesser of
|
# (The actual value used in a private-browsing context will be the lesser of
|
||||||
# the appropriate standard/trackingprotection/RFP value from above, and the
|
# the appropriate standard/trackingprotection/RFP value from above, and the
|
||||||
|
|
|
||||||
|
|
@ -62,6 +62,9 @@ ITEM_VALUE(AudioSampleRate, 1llu << 38)
|
||||||
ITEM_VALUE(NavigatorConnection, 1llu << 39)
|
ITEM_VALUE(NavigatorConnection, 1llu << 39)
|
||||||
ITEM_VALUE(WindowDevicePixelRatio, 1llu << 40)
|
ITEM_VALUE(WindowDevicePixelRatio, 1llu << 40)
|
||||||
ITEM_VALUE(MouseEventScreenPoint, 1llu << 41)
|
ITEM_VALUE(MouseEventScreenPoint, 1llu << 41)
|
||||||
|
// Visibility level of font families available to CSS font-matching
|
||||||
|
ITEM_VALUE(FontVisibilityBaseSystem, 1llu << 42)
|
||||||
|
ITEM_VALUE(FontVisibilityLangPack, 1llu << 43)
|
||||||
|
|
||||||
// !!! Don't forget to update kDefaultFingerintingProtections in nsRFPService.cpp
|
// !!! Don't forget to update kDefaultFingerintingProtections in nsRFPService.cpp
|
||||||
// if necessary.
|
// if necessary.
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue