add fingerprinting configuration
This commit is contained in:
+6
@@ -144,6 +144,9 @@ class GeckoEngineSettingsApiImpl : GeckoEngineSettingsApi {
|
||||
components.core.engineSettings.dohDefaultProviderUrl = settings.dohSettings.dohDefaultProviderUrl
|
||||
components.core.engineSettings.dohExceptionsList = settings.dohSettings.dohExceptionsList
|
||||
}
|
||||
if(settings.fingerprintingProtectionOverrides != null) {
|
||||
components.core.engineSettings.fingerprintingProtectionOverrides = settings.fingerprintingProtectionOverrides
|
||||
}
|
||||
}
|
||||
|
||||
override fun updateRuntimeSettings(settings: GeckoEngineSettings) {
|
||||
@@ -227,6 +230,9 @@ class GeckoEngineSettingsApiImpl : GeckoEngineSettingsApi {
|
||||
components.core.engine.settings.dohDefaultProviderUrl = settings.dohSettings.dohDefaultProviderUrl
|
||||
components.core.engine.settings.dohExceptionsList = settings.dohSettings.dohExceptionsList
|
||||
}
|
||||
if(settings.fingerprintingProtectionOverrides != null) {
|
||||
components.core.engine.settings.fingerprintingProtectionOverrides = settings.fingerprintingProtectionOverrides
|
||||
}
|
||||
|
||||
if(reloadSession) {
|
||||
components.useCases.sessionUseCases.reload()
|
||||
|
||||
+5
-2
@@ -1677,7 +1677,8 @@ data class GeckoEngineSettings (
|
||||
val userAgent: String? = null,
|
||||
val contentBlocking: ContentBlocking? = null,
|
||||
val enterpriseRootsEnabled: Boolean? = null,
|
||||
val dohSettings: DohSettings? = null
|
||||
val dohSettings: DohSettings? = null,
|
||||
val fingerprintingProtectionOverrides: String? = null
|
||||
)
|
||||
{
|
||||
companion object {
|
||||
@@ -1696,7 +1697,8 @@ data class GeckoEngineSettings (
|
||||
val contentBlocking = pigeonVar_list[11] as ContentBlocking?
|
||||
val enterpriseRootsEnabled = pigeonVar_list[12] as Boolean?
|
||||
val dohSettings = pigeonVar_list[13] as DohSettings?
|
||||
return GeckoEngineSettings(javascriptEnabled, trackingProtectionPolicy, httpsOnlyMode, globalPrivacyControlEnabled, preferredColorScheme, cookieBannerHandlingMode, cookieBannerHandlingModePrivateBrowsing, cookieBannerHandlingGlobalRules, cookieBannerHandlingGlobalRulesSubFrames, webContentIsolationStrategy, userAgent, contentBlocking, enterpriseRootsEnabled, dohSettings)
|
||||
val fingerprintingProtectionOverrides = pigeonVar_list[14] as String?
|
||||
return GeckoEngineSettings(javascriptEnabled, trackingProtectionPolicy, httpsOnlyMode, globalPrivacyControlEnabled, preferredColorScheme, cookieBannerHandlingMode, cookieBannerHandlingModePrivateBrowsing, cookieBannerHandlingGlobalRules, cookieBannerHandlingGlobalRulesSubFrames, webContentIsolationStrategy, userAgent, contentBlocking, enterpriseRootsEnabled, dohSettings, fingerprintingProtectionOverrides)
|
||||
}
|
||||
}
|
||||
fun toList(): List<Any?> {
|
||||
@@ -1715,6 +1717,7 @@ data class GeckoEngineSettings (
|
||||
contentBlocking,
|
||||
enterpriseRootsEnabled,
|
||||
dohSettings,
|
||||
fingerprintingProtectionOverrides,
|
||||
)
|
||||
}
|
||||
override fun equals(other: Any?): Boolean {
|
||||
|
||||
@@ -94,4 +94,10 @@ class GeckoEngineSettingsService {
|
||||
Future<void> dohSettings(DohSettings state) {
|
||||
return _api.updateRuntimeSettings(GeckoEngineSettings(dohSettings: state));
|
||||
}
|
||||
|
||||
Future<void> fingerprintingProtectionOverrides(String? state) {
|
||||
return _api.updateRuntimeSettings(
|
||||
GeckoEngineSettings(fingerprintingProtectionOverrides: state),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2043,6 +2043,7 @@ class GeckoEngineSettings {
|
||||
this.contentBlocking,
|
||||
this.enterpriseRootsEnabled,
|
||||
this.dohSettings,
|
||||
this.fingerprintingProtectionOverrides,
|
||||
});
|
||||
|
||||
bool? javascriptEnabled;
|
||||
@@ -2073,6 +2074,8 @@ class GeckoEngineSettings {
|
||||
|
||||
DohSettings? dohSettings;
|
||||
|
||||
String? fingerprintingProtectionOverrides;
|
||||
|
||||
List<Object?> _toList() {
|
||||
return <Object?>[
|
||||
javascriptEnabled,
|
||||
@@ -2089,6 +2092,7 @@ class GeckoEngineSettings {
|
||||
contentBlocking,
|
||||
enterpriseRootsEnabled,
|
||||
dohSettings,
|
||||
fingerprintingProtectionOverrides,
|
||||
];
|
||||
}
|
||||
|
||||
@@ -2112,6 +2116,7 @@ class GeckoEngineSettings {
|
||||
contentBlocking: result[11] as ContentBlocking?,
|
||||
enterpriseRootsEnabled: result[12] as bool?,
|
||||
dohSettings: result[13] as DohSettings?,
|
||||
fingerprintingProtectionOverrides: result[14] as String?,
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -666,6 +666,7 @@ class GeckoEngineSettings {
|
||||
final ContentBlocking? contentBlocking;
|
||||
final bool? enterpriseRootsEnabled;
|
||||
final DohSettings? dohSettings;
|
||||
final String? fingerprintingProtectionOverrides;
|
||||
|
||||
GeckoEngineSettings(
|
||||
this.javascriptEnabled,
|
||||
@@ -682,6 +683,7 @@ class GeckoEngineSettings {
|
||||
this.contentBlocking,
|
||||
this.enterpriseRootsEnabled,
|
||||
this.dohSettings,
|
||||
this.fingerprintingProtectionOverrides,
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user