[AUTO][FILECONTROL] - version 145.0.7632.46 (#2681)

[AUTO][FILECONTROL] - version 145.0.7632.46
This commit is contained in:
uazo
2026-02-11 12:46:06 +00:00
committed by GitHub
174 changed files with 4347 additions and 5104 deletions
+1 -1
View File
@@ -1 +1 @@
144.0.7559.97
145.0.7632.46
@@ -323,10 +323,13 @@ AwContentBrowserClient::CreateBrowserMainParts(bool /* is_integration_test */) {
return std::make_unique<AwBrowserMainParts>(this);
}
bool IsAnyStartupTaskExperimentEnabled() {
bool AwContentBrowserClient::IsAnyStartupTaskExperimentEnabled() {
return AwBrowserMainParts::isWebViewStartupTasksExperimentEnabled() ||
AwBrowserMainParts::isWebViewStartupTasksExperimentEnabledP2() ||
AwBrowserMainParts::isStartupTaskYieldToNativeExperimentEnabled();
AwBrowserMainParts::isStartupTaskYieldToNativeExperimentEnabled() ||
startup_tasks_logic_enabled_for_testing_ ||
startup_tasks_logic_p2_enabled_for_testing_ ||
startup_tasks_yield_to_native_experiment_enabled_for_testing_;
}
void AwContentBrowserClient::PostAfterStartupTask(
@@ -356,7 +359,8 @@ void AwContentBrowserClient::OnStartupComplete() {
DCHECK(!startup_info_.startup_complete);
startup_info_.startup_complete = true;
if (AwBrowserMainParts::isStartupTaskYieldToNativeExperimentEnabled()) {
if (AwBrowserMainParts::isStartupTaskYieldToNativeExperimentEnabled() ||
startup_tasks_yield_to_native_experiment_enabled_for_testing_) {
YieldToLooperChecker::GetInstance().SetStartupRunning(false);
}
@@ -383,7 +387,8 @@ void AwContentBrowserClient::OnUiTaskRunnerReady(
startup_info_.enable_native_task_execution_callback =
std::move(enable_native_task_execution_callback);
if (AwBrowserMainParts::isStartupTaskYieldToNativeExperimentEnabled()) {
if (AwBrowserMainParts::isStartupTaskYieldToNativeExperimentEnabled() ||
startup_tasks_yield_to_native_experiment_enabled_for_testing_) {
YieldToLooperChecker::GetInstance().SetStartupRunning(true);
}
}
@@ -13,11 +13,11 @@
#include "base/metrics/persistent_histogram_allocator.h"
#include "base/path_service.h"
#include "components/history/core/browser/features.h"
#include "components/input/features.h"
#include "components/metrics/persistent_histograms.h"
#include "components/payments/content/android/payment_feature_map.h"
#include "components/permissions/features.h"
#include "components/safe_browsing/core/common/features.h"
#include "components/translate/core/common/translate_util.h"
#include "components/variations/feature_overrides.h"
#include "components/viz/common/features.h"
#include "content/public/common/content_features.h"
@@ -32,6 +32,7 @@
#include "third_party/blink/public/common/features_generated.h"
#include "ui/android/ui_android_features.h"
#include "ui/base/ui_base_features.h"
#include "ui/events/features.h"
#include "ui/gl/gl_features.h"
#include "ui/gl/gl_switches.h"
@@ -65,10 +66,10 @@ void AwFieldTrials::RegisterFeatureOverrides(base::FeatureList* feature_list) {
aw_feature_overrides.DisableFeature(
blink::features::kAboutBlankPageRespectsDarkModeOnUserAction);
// TODO(crbug.com/433304196): Remove this once webview experiment has
// TODO(crbug.com/444669046): Remove this once webview experiment has
// concluded.
aw_feature_overrides.DisableFeature(
blink::features::kAsyncTouchMovesImmediatelyAfterScroll);
input::features::kUpdateScrollPredictorInputMapping);
// Disable enforcing `noopener` on Blob URL navigations on WebView.
aw_feature_overrides.DisableFeature(
@@ -81,6 +82,10 @@ void AwFieldTrials::RegisterFeatureOverrides(base::FeatureList* feature_list) {
// HDR does not support webview yet. See crbug.com/1493153 for an explanation.
aw_feature_overrides.DisableFeature(ui::kAndroidHDR);
// TODO(crbug.com/450845471): Remove this once webview experiment has
// concluded.
aw_feature_overrides.DisableFeature(ui::kCompensateGestureDetectorTimeouts);
// Disable launch_handler on WebView.
aw_feature_overrides.DisableFeature(::features::kAndroidWebAppLaunchHandler);
@@ -194,12 +199,6 @@ void AwFieldTrials::RegisterFeatureOverrides(base::FeatureList* feature_list) {
// Disable Web Serial API on WebView.
aw_feature_overrides.DisableFeature(blink::features::kWebSerialAPI);
// Disable TFLite based language detection on webview until webview supports
// ML model delivery via Optimization Guide component.
// TODO(crbug.com/40819484): Enable the feature on Webview.
aw_feature_overrides.DisableFeature(
::translate::kTFLiteLanguageDetectionEnabled);
// Disable key pinning enforcement on webview.
aw_feature_overrides.DisableFeature(
net::features::kStaticKeyPinningEnforcement);
@@ -207,6 +206,9 @@ void AwFieldTrials::RegisterFeatureOverrides(base::FeatureList* feature_list) {
// FedCM is not yet supported on WebView.
aw_feature_overrides.DisableFeature(::features::kFedCm);
// Email Verification Protocol is not yet supported on WebView.
aw_feature_overrides.DisableFeature(::features::kEmailVerificationProtocol);
// Disable Digital Credentials API on WebView.
aw_feature_overrides.DisableFeature(
::features::kWebIdentityDigitalCredentials);
@@ -288,26 +290,31 @@ void AwFieldTrials::RegisterFeatureOverrides(base::FeatureList* feature_list) {
aw_feature_overrides.DisableFeature(
features::kAAudioPerStreamDeviceSelection);
// WebView exposes text autosizing to apps via setLayoutAlgorithm(), so
// we keep text autosizing support in WebView for now. Further WebView
// work will take place in https://crbug.com/391990606.
aw_feature_overrides.DisableFeature(blink::features::kForceOffTextAutosizing);
// Local Network Access restrictions should not be enforced in WebView.
// The LNA permission is auto-granted in WebView, but the permission
// policy currently blocks iframes from using it. crbug.com/442879527
aw_feature_overrides.DisableFeature(
network::features::kLocalNetworkAccessChecks);
aw_feature_overrides.DisableFeature(
network::features::kLocalNetworkAccessChecksSplitPermissions);
// Disable background media for WebView, until we have consensus on long-term
// behavior crbug.com/453706851
aw_feature_overrides.DisableFeature(
features::kAndroidEnableBackgroundMediaLargeFormFactors);
// Disable ExtendedReportingRemovePrefDependency for WebView, because WebView
// doesn't support ESB
aw_feature_overrides.DisableFeature(
safe_browsing::kExtendedReportingRemovePrefDependency);
// SystemTracing is enabled by default only in WebView for now.
aw_feature_overrides.EnableFeature(features::kEnablePerfettoSystemTracing);
// Deemed that performance benefit is not worth the stability cost.
// See crbug.com/1309151.
aw_feature_overrides.DisableFeature(::features::kGpuShaderDiskCache);
// Don't pass the data about browser window position on screen to WebView.
aw_feature_overrides.DisableFeature(ui::kAndroidUseCorrectWindowBounds);
}
@@ -229,6 +229,9 @@ by a child template that "extends" this file.
android:allowAudioPlaybackCapture="false"
android:appComponentFactory="org.chromium.chrome.browser.base.SplitCompatAppComponentFactory"
android:enableOnBackInvokedCallback="true"
{% if javaless_renderers is defined %}
android:zygotePreloadNativeLib="lib{{ library_name }}.so"
{% endif %}
{% block extra_application_attributes %}{% endblock %}>
{% if channel in ['canary', 'dev', 'default'] %}
@@ -292,6 +295,13 @@ by a child template that "extends" this file.
<data android:mimeType="text/plain"/>
<data android:mimeType="application/xhtml+xml"/>
</intent-filter>
<!-- PDF viewing support. -->
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<data android:mimeType="application/pdf" />
<data android:scheme="content" />
</intent-filter>
<!-- MHTML support, used for snapshots -->
<intent-filter>
<action android:name="android.intent.action.VIEW" />
@@ -544,6 +554,9 @@ by a child template that "extends" this file.
android:theme="@style/Theme.Chromium.TabbedMode"
android:exported="true"
android:launchMode="singleTask"
{% if is_desktop_android == "true" %}
android:persistableMode="persistAcrossReboots"
{% endif %}
{# We can only use blocks once in Jinja, for future substitutions we use
self.supports_video_persistence(). #}
{% block supports_video_persistence %}
@@ -1158,9 +1171,6 @@ by a child template that "extends" this file.
<receiver android:name="org.chromium.chrome.browser.offlinepages.AutoFetchNotifier$InProgressCancelReceiver"
android:exported="false"/>
<receiver android:name="org.chromium.chrome.browser.safety_hub.UnsubscribedNotificationsNotificationManager$NotificationReceiver"
android:exported="false"/>
<service android:name="org.chromium.chrome.browser.media.MediaCaptureNotificationService"
{% if is_desktop_android == "true" and enable_screen_capture == "true" %}
android:foregroundServiceType="camera|microphone|mediaProjection|mediaPlayback"
@@ -1296,21 +1306,22 @@ by a child template that "extends" this file.
{% if javaless_renderers is defined %}
<!-- Restricting to just 2 native-only services, one for zygote and one for non-zygote. -->
{% for i in range(2) %}
<!-- For now, the name of a native-only service must be prefixed with "NativeService". This is
only for the prototype, and once it actually lands in the Android tree, there will be a
better mechanism than this. -->
<service android:name="org.chromium.content.app.NativeServiceSandboxedProcessService{{ i }}"
<service android:name="org.chromium.content.app.NativeOnlySandboxedProcessService{{ i }}"
android:nativeService="true"
android:process=":sandboxed_process{{ i }}"
android:permission="{{ manifest_package }}.permission.CHILD_SERVICE"
android:isolatedProcess="true"
android:useAppZygote="true"
android:exported="{{sandboxed_service_exported|default(false)}}"
{% if (sandboxed_service_exported|default(false)) == 'true' %}
android:externalService="true"
tools:ignore="ExportedService"
android:visibleToInstantApps="true"
{% endif %} >
<meta-data android:name="android.app.lib_name" android:value="{{ library_name }}"/>
<meta-data android:name="android.app.func_name" android:value="NativeChildProcessService_onCreate"/>
<property android:name="android.app.PROPERTY_NATIVE_SERVICE_LIBRARY_NAME"
android:value="lib{{ library_name }}.so" />
<property android:name="android.app.PROPERTY_NATIVE_SERVICE_FUNCTION_NAME"
android:value="NativeChildProcessService_onCreate" />
</service>
{% endfor %}
{% endif %}
@@ -1860,7 +1860,7 @@ public class CustomTabIntentDataProvider extends BrowserServicesIntentDataProvid
if (displayMode instanceof TrustedWebActivityDisplayMode.BrowserMode) {
return !isDisplayOverride;
}
if (WebAppHeaderUtils.isMinimalUiFlagEnabled()
if (WebAppHeaderUtils.isMinimalUiEnabled()
&& displayMode instanceof TrustedWebActivityDisplayMode.MinimalUiMode) {
return true;
}
@@ -1905,7 +1905,7 @@ public class CustomTabIntentDataProvider extends BrowserServicesIntentDataProvid
boolean shouldUseMinimalUi =
displayMode instanceof TrustedWebActivityDisplayMode.MinimalUiMode
|| displayMode instanceof TrustedWebActivityDisplayMode.BrowserMode;
if (WebAppHeaderUtils.isMinimalUiFlagEnabled() && shouldUseMinimalUi) {
if (WebAppHeaderUtils.isMinimalUiEnabled() && shouldUseMinimalUi) {
return DisplayMode.MINIMAL_UI;
}
File diff suppressed because it is too large Load Diff
@@ -313,37 +313,6 @@ bool ChromeBrowsingDataRemoverDelegate::MayRemoveDownloadHistory() {
return profile_->GetPrefs()->GetBoolean(prefs::kAllowDeletingBrowserHistory);
}
std::vector<std::string>
ChromeBrowsingDataRemoverDelegate::GetDomainsForDeferredCookieDeletion(
content::StoragePartition* storage_partition,
uint64_t remove_mask) {
#if BUILDFLAG(IS_ANDROID)
// On Android the identity model isn't based on Gaia cookies, so they can be
// wiped immediately without influencing the wiping of account-scoped data.
return {};
#else
// The Google/Gaia cookies we care about live in the default StoragePartition.
if (!storage_partition->GetConfig().is_default() ||
(remove_mask & constants::DEFERRED_COOKIE_DELETION_DATA_TYPES) == 0) {
return {};
}
// Return Google and Gaia domains, so Google signout is deferred until
// account-scoped data is deleted.
auto urls = {GaiaUrls::GetInstance()->google_url(),
GaiaUrls::GetInstance()->gaia_url()};
std::set<std::string> domains;
for (const GURL& url : urls) {
std::string domain = GetDomainAndRegistry(
url, net::registry_controlled_domains::INCLUDE_PRIVATE_REGISTRIES);
if (domain.empty())
domain = url.GetHost();
domains.insert(domain);
}
return {domains.begin(), domains.end()};
#endif
}
void ChromeBrowsingDataRemoverDelegate::RemoveEmbedderData(
const base::Time& delete_begin,
const base::Time& delete_end,
@@ -959,8 +928,6 @@ void ChromeBrowsingDataRemoverDelegate::RemoveEmbedderData(
if (password_store) {
// No sync completion callback is needed for profile passwords, since the
// login token is persisted and can be used after cookie deletion.
// TODO:(crbug.com/1167715) - Test that associated compromised credentials
// are removed.
password_store->RemoveLoginsCreatedBetween(
FROM_HERE, delete_begin_, delete_end_,
CreateTaskCompletionCallback(
@@ -467,17 +467,6 @@ void PopulateChromeFrameBinders(
map->Add<optimization_guide::mojom::ModelBroker>(&BindModelBroker);
if (!base::FeatureList::IsEnabled(blink::features::kLanguageDetectionAPI)) {
// When the feature is enabled, the driver is bound by
// browser_interface_binders.cc to make it available to JS execution
// contexts. When the feature is disabled, we bind it here for Chrome's
// page-translation feature.
//
// TODO(https://crbug.com/354069716): Remove this when the flag is removed.
map->Add<language_detection::mojom::ContentLanguageDetectionDriver>(
&translate::BindContentLanguageDetectionDriver);
}
map->Add<blink::mojom::CredentialManager>(&BindCredentialManager);
map->Add<chrome::mojom::OpenSearchDescriptionDocumentHandler>(
@@ -19,7 +19,6 @@
#include "base/byte_count.h"
#include "base/check_deref.h"
#include "base/command_line.h"
#include "base/containers/contains.h"
#include "base/containers/fixed_flat_map.h"
#include "base/containers/fixed_flat_set.h"
#include "base/dcheck_is_on.h"
@@ -71,7 +70,6 @@
#include "chrome/browser/chrome_content_browser_client_navigation_throttles.h"
#include "chrome/browser/chrome_content_browser_client_parts.h"
#include "chrome/browser/content_settings/cookie_settings_factory.h"
#include "chrome/browser/content_settings/generated_javascript_optimizer_pref.h"
#include "chrome/browser/content_settings/host_content_settings_map_factory.h"
#include "chrome/browser/custom_handlers/protocol_handler_registry_factory.h"
#include "chrome/browser/data_saver/data_saver.h"
@@ -124,7 +122,6 @@
#include "chrome/browser/predictors/loading_predictor.h"
#include "chrome/browser/predictors/loading_predictor_factory.h"
#include "chrome/browser/preloading/prefetch/no_state_prefetch/chrome_no_state_prefetch_contents_delegate.h"
#include "chrome/browser/preloading/prefetch/no_state_prefetch/chrome_speculation_host_delegate.h"
#include "chrome/browser/preloading/prefetch/no_state_prefetch/no_state_prefetch_manager_factory.h"
#include "chrome/browser/preloading/prefetch/prefetch_service/chrome_prefetch_service_delegate.h"
#include "chrome/browser/preloading/prefetch/search_prefetch/field_trial_settings.h"
@@ -135,7 +132,6 @@
#include "chrome/browser/preloading/prerender/prerender_web_contents_delegate.h"
#include "chrome/browser/preloading/search_preload/search_preload_features.h"
#include "chrome/browser/privacy_sandbox/privacy_sandbox_settings_factory.h"
#include "chrome/browser/privacy_sandbox/tracking_protection_settings_factory.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/profiles/profile_io_data.h"
#include "chrome/browser/profiles/profile_manager.h"
@@ -217,6 +213,7 @@
#include "components/browsing_topics/browsing_topics_service.h"
#include "components/captive_portal/core/buildflags.h"
#include "components/content_settings/browser/page_specific_content_settings.h"
#include "components/content_settings/browser/ui/javascript_optimizer_setting.h"
#include "components/content_settings/core/browser/content_settings_utils.h"
#include "components/content_settings/core/browser/cookie_settings.h"
#include "components/content_settings/core/browser/host_content_settings_map.h"
@@ -260,6 +257,7 @@
#include "components/no_state_prefetch/browser/no_state_prefetch_manager.h"
#include "components/no_state_prefetch/common/no_state_prefetch_final_status.h"
#include "components/no_state_prefetch/common/no_state_prefetch_url_loader_throttle.h"
#include "components/on_device_translation/buildflags/buildflags.h"
#include "components/page_load_metrics/browser/metrics_web_contents_observer.h"
#include "components/password_manager/core/browser/features/password_features.h"
#include "components/password_manager/core/browser/password_manager_metrics_util.h"
@@ -279,10 +277,10 @@
#include "components/privacy_sandbox/privacy_sandbox_features.h"
#include "components/privacy_sandbox/privacy_sandbox_prefs.h"
#include "components/privacy_sandbox/privacy_sandbox_settings.h"
#include "components/privacy_sandbox/tracking_protection_settings.h"
#include "components/safe_browsing/content/browser/async_check_tracker.h"
#include "components/safe_browsing/content/browser/browser_url_loader_throttle.h"
#include "components/safe_browsing/content/browser/password_protection/password_protection_commit_deferring_condition.h"
#include "components/safe_browsing/content/browser/ui_manager.h"
#include "components/safe_browsing/core/browser/hashprefix_realtime/hash_realtime_service.h"
#include "components/safe_browsing/core/browser/realtime/policy_engine.h"
#include "components/safe_browsing/core/browser/realtime/url_lookup_service.h"
@@ -293,7 +291,6 @@
#include "components/safe_browsing/core/common/safe_browsing_prefs.h"
#include "components/search_engines/template_url_service.h"
#include "components/security_state/core/security_state.h"
#include "components/services/on_device_translation/buildflags/buildflags.h"
#include "components/site_isolation/features.h"
#include "components/site_isolation/pref_names.h"
#include "components/site_isolation/preloaded_isolated_origins.h"
@@ -512,6 +509,7 @@
#include "chrome/browser/actor/actor_keyed_service_factory.h"
#include "chrome/browser/contextual_tasks/contextual_tasks_ui_service.h"
#include "chrome/browser/contextual_tasks/contextual_tasks_ui_service_factory.h"
#include "chrome/browser/contextual_tasks/contextual_tasks_url_loader_factory_interceptor.h"
#include "chrome/browser/devtools/chrome_devtools_manager_delegate.h"
#include "chrome/browser/devtools/devtools_window.h"
#include "chrome/browser/digital_credentials/digital_identity_provider_desktop.h"
@@ -714,7 +712,7 @@
#if BUILDFLAG(ENABLE_ON_DEVICE_TRANSLATION)
#include "chrome/browser/on_device_translation/component_manager.h"
#include "chrome/browser/on_device_translation/pref_names.h"
#include "components/on_device_translation/pref_names.h"
#endif // BUILDFLAG(ENABLE_ON_DEVICE_TRANSLATION)
#if BUILDFLAG(ENABLE_REQUEST_HEADER_INTEGRITY)
@@ -767,9 +765,6 @@ constexpr char kSecurePaymentConfirmationKeychainAccessGroup[] =
// ShouldEnableStrictSiteIsolation().
bool g_disable_advanced_protection_caching_for_tests = false;
BASE_FEATURE(kSkipPagehideInCommitForDSENavigation,
base::FEATURE_DISABLED_BY_DEFAULT);
// Warm up the ServiceWorker registration for DSE.
BASE_FEATURE(kPrewarmServiceWorkerRegistrationForDSE,
base::FEATURE_DISABLED_BY_DEFAULT);
@@ -963,7 +958,7 @@ bool IsExtensionIdAllowedToUseIsolatedContext(std::string_view extension_id) {
"bbobefdodiifgmhhdijgpelmkdaebfpn", // Controlled Frame Service
// Worker Test
});
return base::Contains(kAllowedIsolatedContextExtensionIds, extension_id);
return kAllowedIsolatedContextExtensionIds.contains(extension_id);
}
#endif // BUILDFLAG(ENABLE_EXTENSIONS_CORE)
@@ -1308,6 +1303,12 @@ ProfileSelections GetHumanProfileSelections() {
.Build();
}
bool IsPrewarmUrl(const GURL& url, const url::Origin& dse_origin) {
const GURL prewarm_url = GURL(features::kPrewarmUrl.Get());
return prewarm_url.is_valid() && url == prewarm_url &&
dse_origin.IsSameOriginWith(prewarm_url);
}
bool IsDefaultSearchEngine(Profile* profile, const GURL& url) {
auto* template_url_service =
TemplateURLServiceFactory::GetForProfile(profile);
@@ -1328,12 +1329,8 @@ bool IsDefaultSearchEngine(Profile* profile, const GURL& url) {
}
if (base::FeatureList::IsEnabled(features::kConsiderDSEWarmUpPageAsSRP)) {
const GURL prewarm_url = GURL(features::kPrewarmUrl.Get());
if (prewarm_url.is_valid() && url == prewarm_url &&
template_url_service->GetDefaultSearchProviderOrigin().IsSameOriginWith(
prewarm_url)) {
return true;
}
return IsPrewarmUrl(url,
template_url_service->GetDefaultSearchProviderOrigin());
}
return false;
@@ -1470,10 +1467,6 @@ void ChromeContentBrowserClient::RegisterProfilePrefs(
registry->RegisterBooleanPref(prefs::kIPv6ReachabilityOverrideEnabled, false);
registry->RegisterDictionaryPref(
enterprise::content::kCopyPreventionSettings);
registry->RegisterIntegerPref(
prefs::kUserAgentReduction,
static_cast<int>(
embedder_support::UserAgentReductionEnterprisePolicyState::kDefault));
registry->RegisterBooleanPref(prefs::kOriginAgentClusterDefaultEnabled, true);
registry->RegisterBooleanPref(
@@ -2461,6 +2454,15 @@ void ChromeContentBrowserClient::WillComputeSiteForNavigation(
}
}
bool ChromeContentBrowserClient::IsAndroidAdvancedProtectionEnabled() {
#if BUILDFLAG(IS_ANDROID)
return safe_browsing::AdvancedProtectionStatusManagerAndroid::
QueryIsUnderAdvancedProtection();
#else
return false;
#endif
}
bool ChromeContentBrowserClient::ShouldEnableStrictSiteIsolation() {
if (base::FeatureList::IsEnabled(features::kSitePerProcess)) {
return true;
@@ -3244,7 +3246,7 @@ void ChromeContentBrowserClient::GuestPermissionRequestHelper(
base::OnceCallback<void(bool)> callback,
bool allow) {
DCHECK_CURRENTLY_ON(BrowserThread::UI);
std::map<int, int> process_map;
std::map<content::ChildProcessId, int> process_map;
bool has_web_view_guest = false;
// Record access to file system for potential display in UI.
for (const auto& it : render_frames) {
@@ -3252,9 +3254,12 @@ void ChromeContentBrowserClient::GuestPermissionRequestHelper(
continue;
}
process_map.insert(std::pair<int, int>(it.child_id, it.frame_routing_id));
process_map.insert(std::pair<content::ChildProcessId, int>(
it.child_id, it.frame_routing_id));
if (extensions::WebViewRendererState::GetInstance()->IsGuest(it.child_id)) {
// TODO(crbug.com/379869738) Remove GetUnsafeValue.
if (extensions::WebViewRendererState::GetInstance()->IsGuest(
it.child_id.GetUnsafeValue())) {
has_web_view_guest = true;
}
}
@@ -3263,7 +3268,8 @@ void ChromeContentBrowserClient::GuestPermissionRequestHelper(
return;
}
DCHECK_EQ(1U, process_map.size());
std::map<int, int>::const_iterator it = process_map.begin();
std::map<content::ChildProcessId, int>::const_iterator it =
process_map.begin();
extensions::WebViewPermissionHelper* web_view_permission_helper =
extensions::WebViewPermissionHelper::FromRenderFrameHostId(
@@ -3507,18 +3513,16 @@ bool ChromeContentBrowserClient::IsAttributionReportingOperationAllowed(
case AttributionReportingOperation::kOsSourceTransitionalDebugReporting:
DCHECK(source_origin);
DCHECK(reporting_origin);
DCHECK(can_bypass);
return privacy_sandbox_settings
->IsAttributionReportingTransitionalDebuggingAllowed(
*source_origin, *reporting_origin, *can_bypass);
*source_origin, *reporting_origin);
case AttributionReportingOperation::kTriggerTransitionalDebugReporting:
case AttributionReportingOperation::kOsTriggerTransitionalDebugReporting:
DCHECK(destination_origin);
DCHECK(reporting_origin);
DCHECK(can_bypass);
return privacy_sandbox_settings
->IsAttributionReportingTransitionalDebuggingAllowed(
*destination_origin, *reporting_origin, *can_bypass);
*destination_origin, *reporting_origin);
case AttributionReportingOperation::kAny:
return privacy_sandbox_settings->IsAttributionReportingEverAllowed();
}
@@ -3624,31 +3628,6 @@ bool ChromeContentBrowserClient::IsPrivateAggregationDebugModeAllowed(
top_frame_origin, reporting_origin);
}
bool ChromeContentBrowserClient::IsCookieDeprecationLabelAllowed(
content::BrowserContext* browser_context) {
Profile* profile = Profile::FromBrowserContext(browser_context);
auto* privacy_sandbox_settings =
PrivacySandboxSettingsFactory::GetForProfile(profile);
if (!privacy_sandbox_settings) {
return false;
}
return privacy_sandbox_settings->IsCookieDeprecationLabelAllowed();
}
bool ChromeContentBrowserClient::IsCookieDeprecationLabelAllowedForContext(
content::BrowserContext* browser_context,
const url::Origin& top_frame_origin,
const url::Origin& context_origin) {
Profile* profile = Profile::FromBrowserContext(browser_context);
auto* privacy_sandbox_settings =
PrivacySandboxSettingsFactory::GetForProfile(profile);
DCHECK(privacy_sandbox_settings);
return privacy_sandbox_settings->IsCookieDeprecationLabelAllowedForContext(
top_frame_origin, context_origin);
}
bool ChromeContentBrowserClient::IsFullCookieAccessAllowed(
content::BrowserContext* browser_context,
content::WebContents* web_contents,
@@ -3691,7 +3670,21 @@ bool ChromeContentBrowserClient::IsServiceWorkerSyntheticResponseAllowed(
return false;
}
return IsDefaultSearchEngine(profile, url);
if (!IsDefaultSearchEngine(profile, url)) {
return false;
}
// Prewarm page can be treated as a DSE. As we don't want to enable synthetic
// response on the prewarm page, manually exclude it.
auto* template_url_service =
TemplateURLServiceFactory::GetForProfile(profile);
CHECK(template_url_service);
if (IsPrewarmUrl(url,
template_url_service->GetDefaultSearchProviderOrigin())) {
return false;
}
return true;
}
void ChromeContentBrowserClient::GrantCookieAccessDueToHeuristic(
@@ -5044,8 +5037,7 @@ void ChromeContentBrowserClient::GetAdditionalFileSystemBackends(
for (auto& part : extra_parts_) {
part->GetAdditionalFileSystemBackends(
browser_context, storage_partition_path,
GetQuarantineConnectionCallback(), additional_backends);
browser_context, storage_partition_path, additional_backends);
}
}
@@ -6393,11 +6385,19 @@ void ChromeContentBrowserClient::WillCreateURLLoaderFactory(
#if BUILDFLAG(IS_MAC)
if (base::FeatureList::IsEnabled(enterprise_auth::kOktaSSO)) {
// WARNING: This factory blocks certain requests from going out via the
// final network bound factory.
enterprise_auth::ProxyingURLLoaderFactory::MaybeProxyRequest(
request_initiator, factory_builder);
request_initiator, type, factory_builder);
}
#endif
#if !BUILDFLAG(IS_ANDROID)
if (base::FeatureList::IsEnabled(contextual_tasks::kContextualTasks)) {
contextual_tasks::MaybeInterceptURLLoaderFactory(frame, factory_builder);
}
#endif // !BUILDFLAG(IS_ANDROID)
// WARNING: This must be the last interceptor in the chain as the proxying
// URLLoaderFactory installed by this needs to be the one actually sending
// packets over the network (to effectively target `bound_network`).
@@ -6607,7 +6607,7 @@ void ChromeContentBrowserClient::ConfigureNetworkContextParams(
cert_verifier_creation_params);
} else {
// Set default params.
network_context_params->user_agent = GetUserAgentBasedOnPolicy(context);
network_context_params->user_agent = GetUserAgent();
network_context_params->accept_language = GetApplicationLocale();
}
}
@@ -7010,22 +7010,6 @@ bool ChromeContentBrowserClient::HandleWebUI(
}
#endif // BUILDFLAG(CHROME_ROOT_STORE_CERT_MANAGEMENT_UI)
#if !BUILDFLAG(IS_ANDROID)
// Redirect from deprecated trackingProtection subpage to cookies.
if (url->SchemeIs(content::kChromeUIScheme) &&
url->GetHost() == chrome::kChromeUISettingsHost &&
url->GetPath() == chrome::kTrackingProtectionSubPagePath) {
GURL::Replacements replacements;
replacements.SetPathStr(chrome::kCookiesSubPagePath);
*url = url->ReplaceComponents(replacements);
base::UmaHistogramBoolean("Settings.Cookies.TrackingProtectionRedirect",
true);
} else if (url->GetPath() == chrome::kCookiesSubPagePath) {
base::UmaHistogramBoolean("Settings.Cookies.TrackingProtectionRedirect",
false);
}
#endif
if (IsDisabledInternalWebUI(*url)) {
GURL::Replacements replacements;
std::string query("host=" + url->spec());
@@ -7245,11 +7229,10 @@ bool ChromeContentBrowserClient::CanAcceptUntrustedExchangesIfNeeded() {
void ChromeContentBrowserClient::OnNetworkServiceDataUseUpdate(
content::GlobalRenderFrameHostId render_frame_host_id,
int32_t network_traffic_annotation_id_hash,
int64_t recv_bytes,
int64_t sent_bytes) {
base::ByteSize recv_bytes,
base::ByteSize sent_bytes) {
task_manager::TaskManagerInterface::UpdateAccumulatedStatsNetworkForRoute(
render_frame_host_id, base::ByteCount(recv_bytes),
base::ByteCount(sent_bytes));
render_frame_host_id, recv_bytes, sent_bytes);
}
base::FilePath
@@ -7313,15 +7296,6 @@ std::string ChromeContentBrowserClient::GetUserAgent() {
return embedder_support::GetUserAgent();
}
std::string ChromeContentBrowserClient::GetUserAgentBasedOnPolicy(
content::BrowserContext* context) {
const PrefService* prefs = Profile::FromBrowserContext(context)->GetPrefs();
embedder_support::UserAgentReductionEnterprisePolicyState
user_agent_reduction =
embedder_support::GetUserAgentReductionFromPrefs(prefs);
return embedder_support::GetUserAgent(user_agent_reduction);
}
blink::UserAgentMetadata ChromeContentBrowserClient::GetUserAgentMetadata() {
DCHECK_CURRENTLY_ON(BrowserThread::UI);
return embedder_support::GetUserAgentMetadata();
@@ -7506,20 +7480,13 @@ void ChromeContentBrowserClient::GetMediaDeviceIDSalt(
url::Origin top_frame_origin = rfh->GetMainFrame()->GetLastCommittedOrigin();
content::BrowserContext* browser_context = rfh->GetBrowserContext();
// Persistent MediaDevice IDs are allowed if cookies are allowed or if the
// user is in the default state in 3PCD.
// Persistent MediaDevice IDs are allowed iff cookies are allowed.
scoped_refptr<content_settings::CookieSettings> cookie_settings =
CookieSettingsFactory::GetForProfile(
Profile::FromBrowserContext(browser_context));
privacy_sandbox::TrackingProtectionSettings* tracking_protection =
TrackingProtectionSettingsFactory::GetForProfile(
Profile::FromBrowserContext(browser_context));
bool allowed =
cookie_settings->IsFullCookieAccessAllowed(
url, site_for_cookies, top_frame_origin,
net::CookieSettingOverrides(), storage_key.ToCookiePartitionKey()) ||
(tracking_protection->IsTrackingProtection3pcdEnabled() &&
!tracking_protection->AreAllThirdPartyCookiesBlocked());
bool allowed = cookie_settings->IsFullCookieAccessAllowed(
url, site_for_cookies, top_frame_origin, net::CookieSettingOverrides(),
storage_key.ToCookiePartitionKey());
ChromeBrowsingDataModelDelegate::BrowsingDataAccessed(
rfh, storage_key,
ChromeBrowsingDataModelDelegate::StorageType::kMediaDeviceSalt, !allowed);
@@ -7734,11 +7701,6 @@ ChromeContentBrowserClient::ShouldOverridePrivateNetworkRequestPolicy(
#endif
Profile* profile = Profile::FromBrowserContext(browser_context);
if (profile->GetPrefs()->GetBoolean(
prefs::kManagedLocalNetworkAccessRestrictionsEnabled)) {
return content::ContentBrowserClient::PrivateNetworkRequestPolicyOverride::
kBlockInsteadOfWarn;
}
if (profile->GetPrefs()->GetBoolean(
prefs::kManagedLocalNetworkAccessRestrictionsTemporaryOptOut)) {
@@ -8057,12 +8019,6 @@ ChromeContentBrowserClient::CreateAnchorElementPreconnectDelegate(
return std::make_unique<AnchorElementPreloader>(render_frame_host);
}
std::unique_ptr<content::SpeculationHostDelegate>
ChromeContentBrowserClient::CreateSpeculationHostDelegate(
content::RenderFrameHost& render_frame_host) {
return std::make_unique<ChromeSpeculationHostDelegate>(render_frame_host);
}
std::unique_ptr<content::PrefetchServiceDelegate>
ChromeContentBrowserClient::CreatePrefetchServiceDelegate(
content::BrowserContext* browser_context) {
@@ -8296,38 +8252,6 @@ bool ChromeContentBrowserClient::IsThirdPartyStoragePartitioningAllowed(
CONTENT_SETTING_ALLOW;
}
bool ChromeContentBrowserClient::
IsUnpartitionedStorageAccessAllowedByUserPreference(
content::BrowserContext* browser_context,
const GURL& url,
const net::SiteForCookies& site_for_cookies,
const url::Origin& top_frame_origin) {
content_settings::CookieSettings* cookie_settings =
CookieSettingsFactory::GetForProfile(
Profile::FromBrowserContext(browser_context))
.get();
if (!cookie_settings) {
// If there are no cookies settings then nothing is limiting storage access.
return true;
}
net::SchemefulSite top_frame_site(top_frame_origin);
std::optional<net::CookiePartitionKey> cookie_partition_key =
net::CookiePartitionKey::FromStorageKeyComponents(
top_frame_site,
net::CookiePartitionKey::BoolToAncestorChainBit(
!site_for_cookies.IsFirstParty(url)),
/*nonce=*/std::nullopt);
// Cookie settings overrides are not relevant for this check.
net::CookieSettingOverrides empty_overrides;
return cookie_settings->IsFullCookieAccessAllowed(
url, site_for_cookies, top_frame_origin, empty_overrides,
cookie_partition_key);
}
bool ChromeContentBrowserClient::AreDeprecatedAutomaticBeaconCredentialsAllowed(
content::BrowserContext* browser_context,
const GURL& destination_url,
@@ -8365,7 +8289,7 @@ bool ChromeContentBrowserClient::
#if BUILDFLAG(IS_MAC)
std::string ChromeContentBrowserClient::GetChildProcessSuffix(int child_flags) {
if (child_flags ==
base::to_underlying(ChildProcessHostFlags::kChildProcessHelperAlerts)) {
std::to_underlying(ChildProcessHostFlags::kChildProcessHelperAlerts)) {
return chrome::kMacHelperSuffixAlerts;
}
NOTREACHED() << "Unsupported child process flags!";
@@ -8645,7 +8569,8 @@ void ChromeContentBrowserClient::BindTranslationManager(
const url::Origin& origin,
mojo::PendingReceiver<blink::mojom::TranslationManager> receiver) {
on_device_translation::TranslationManagerImpl::Bind(
host, browser_context, context_user_data, origin, std::move(receiver));
host, browser_context, context_user_data, origin,
g_browser_process->component_updater(), std::move(receiver));
}
#endif
@@ -8759,7 +8684,8 @@ void ChromeContentBrowserClient::AddExtraPartForTesting(
bool ChromeContentBrowserClient::ShouldDispatchPagehideDuringCommit(
content::BrowserContext* browser_context,
const GURL& destination_url) {
if (!base::FeatureList::IsEnabled(kSkipPagehideInCommitForDSENavigation)) {
if (!base::FeatureList::IsEnabled(
features::kSkipPagehideInCommitForDSENavigation)) {
return true;
}
auto* template_url_service = TemplateURLServiceFactory::GetForProfile(
@@ -8959,3 +8885,9 @@ ChromeContentBrowserClient::GetOverrideValueForStaticStorageQuota(
return std::nullopt;
}
}
std::string ChromeContentBrowserClient::GetDnsTxtResolverUrlPrefix() {
static constexpr char kGoogleDnsResolverUrl[] =
"https://dns.google/resolve?type=txt&do=1&name=";
return kGoogleDnsResolverUrl;
}
@@ -19,7 +19,6 @@
#include "chrome/browser/policy/chrome_policy_blocklist_service_factory.h"
#include "chrome/browser/policy/policy_util.h"
#include "chrome/browser/preloading/prefetch/no_state_prefetch/chrome_no_state_prefetch_contents_delegate.h"
#include "chrome/browser/preloading/prefetch/no_state_prefetch/no_state_prefetch_navigation_throttle.h"
#include "chrome/browser/privacy_sandbox/privacy_sandbox_settings_factory.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/ssl/chrome_security_blocking_page_factory.h"
@@ -495,8 +494,6 @@ void CreateAndAddChromeThrottlesForNavigation(
payments::PaymentHandlerNavigationThrottle::MaybeCreateAndAdd(registry);
prerender::NoStatePrefetchNavigationThrottle::MaybeCreateAndAdd(registry);
#if !BUILDFLAG(IS_ANDROID)
ReadAnythingSidePanelNavigationThrottle::CreateAndAdd(registry);
@@ -11,6 +11,7 @@ import org.chromium.base.MutableFlagWithSafeDefault;
import org.chromium.base.MutableIntParamWithSafeDefault;
import org.chromium.base.MutableParamWithSafeDefault;
import org.chromium.base.SysUtils;
import org.chromium.base.TimeUtils;
import org.chromium.build.BuildConfig;
import org.chromium.build.annotations.NullMarked;
import org.chromium.components.cached_flags.BooleanCachedFeatureParam;
@@ -166,8 +167,6 @@ public abstract class ChromeFeatureList {
"AdaptiveButtonInTopToolbarPageSummary";
public static final String ANDROID_ANIMATED_PROGRESS_BAR_IN_BROWSER =
"AndroidAnimatedProgressBarInBrowser";
public static final String ANDROID_ANIMATED_PROGRESS_BAR_IN_VIZ =
"AndroidAnimatedProgressBarInViz";
public static final String ANDROID_APPEARANCE_SETTINGS = "AndroidAppearanceSettings";
public static final String ANDROID_APP_INTEGRATION_MODULE = "AndroidAppIntegrationModule";
public static final String ANDROID_APP_INTEGRATION_MULTI_DATA_SOURCE =
@@ -177,7 +176,6 @@ public abstract class ChromeFeatureList {
public static final String ANDROID_AUTO_MINTED_TWA = "AndroidAutoMintedTWA";
public static final String ANDROID_BOOKMARK_BAR = "AndroidBookmarkBar";
public static final String ANDROID_BOOKMARK_BAR_FAST_FOLLOW = "AndroidBookmarkBarFastFollow";
public static final String ANDROID_BOTTOM_TOOLBAR = "AndroidBottomToolbar";
public static final String ANDROID_BOTTOM_TOOLBAR_V2 = "AndroidBottomToolbarV2";
public static final String ANDROID_COMPOSEPLATE = "AndroidComposeplate";
public static final String ANDROID_COMPOSEPLATE_LFF = "AndroidComposeplateLFF";
@@ -188,40 +186,26 @@ public abstract class ChromeFeatureList {
public static final String ANDROID_ELEGANT_TEXT_HEIGHT = "AndroidElegantTextHeight";
public static final String ANDROID_FIRST_RUN_LAUNCH_BOUNDS = "AndroidFirstRunLaunchBounds";
public static final String ANDROID_LOGO_VIEW_REFACTOR = "AndroidLogoViewRefactor";
public static final String ANDROID_MINIMAL_UI_LARGE_SCREEN = "AndroidMinimalUiLargeScreen";
public static final String ANDROID_NEW_MEDIA_PICKER = "AndroidNewMediaPicker";
public static final String ANDROID_NO_VISIBLE_HINT_FOR_DIFFERENT_TLD =
"AndroidNoVisibleHintForDifferentTLD";
public static final String ANDROID_OMNIBOX_FOCUSED_NEW_TAB_PAGE =
"AndroidOmniboxFocusedNewTabPage";
public static final String ANDROID_OPEN_INCOGNITO_AS_WINDOW = "AndroidOpenIncognitoAsWindow";
public static final String ANDROID_OPEN_PDF_INLINE_BACKPORT = "AndroidOpenPdfInlineBackport";
public static final String ANDROID_PB_DISABLE_PULSE_ANIMATION =
"AndroidPbDisablePulseAnimation";
public static final String ANDROID_PB_DISABLE_SMOOTH_ANIMATION =
"AndroidPbDisableSmoothAnimation";
public static final String ANDROID_PDF_ASSIST_CONTENT = "AndroidPdfAssistContent";
public static final String ANDROID_PINNED_TABS = "AndroidPinnedTabs";
public static final String ANDROID_PINNED_TABS_TABLET_TAB_STRIP =
"AndroidPinnedTabsTabletTabStrip";
public static final String ANDROID_PROGRESS_BAR_VISUAL_UPDATE =
"AndroidProgressBarVisualUpdate";
public static final String ANDROID_SETTINGS_CONTAINMENT = "AndroidSettingsContainment";
public static final String ANDROID_SHOW_RESTORE_TABS_PROMO_ON_FRE_BYPASSED_KILL_SWITCH =
"AndroidShowRestoreTabsPromoOnFREBypassedKillSwitch";
public static final String ANDROID_SETUP_LIST = "AndroidSetupList";
public static final String ANDROID_SURFACE_COLOR_UPDATE = "AndroidSurfaceColorUpdate";
public static final String ANDROID_TAB_DECLUTTER_ARCHIVE_ALL_BUT_ACTIVE =
"AndroidTabDeclutterArchiveAllButActiveTab";
public static final String ANDROID_TAB_DECLUTTER_ARCHIVE_TAB_GROUPS =
"AndroidTabDeclutterArchiveTabGroups";
public static final String ANDROID_TAB_DECLUTTER_DEDUPE_TAB_IDS_KILL_SWITCH =
"AndroidTabDeclutterDedupeTabIdsKillSwitch";
public static final String ANDROID_TAB_DECLUTTER_PERFORMANCE_IMPROVEMENTS =
"AndroidTabDeclutterPerformanceImprovements";
public static final String ANDROID_TAB_DECLUTTER_RESCUE_KILLSWITCH =
"AndroidTabDeclutterRescueKillswitch";
public static final String ANDROID_TAB_GROUPS_COLOR_UPDATE_GM3 =
"AndroidTabGroupsColorUpdateGM3";
public static final String ANDROID_TAB_HIGHLIGHTING = "AndroidTabHighlighting";
public static final String ANDROID_TAB_SKIP_SAVE_TABS_TASK_KILLSWITCH =
"AndroidTabSkipSaveTabsTaskKillswitch";
@@ -280,6 +264,8 @@ public abstract class ChromeFeatureList {
"AutofillEnableLoyaltyCardsFilling";
public static final String AUTOFILL_ENABLE_NEW_CARD_BENEFITS_TOGGLE_TEXT =
"AutofillEnableNewCardBenefitsToggleText";
public static final String AUTOFILL_ENABLE_NEW_FOP_DISPLAY_ANDROID =
"AutofillEnableNewFopDisplayAndroid";
public static final String AUTOFILL_ENABLE_SECURITY_TOUCH_EVENT_FILTERING_ANDROID =
"AutofillEnableSecurityTouchEventFilteringAndroid";
public static final String AUTOFILL_ENABLE_SEPARATE_PIX_PREFERENCE_ITEM =
@@ -287,6 +273,7 @@ public abstract class ChromeFeatureList {
public static final String AUTOFILL_ENABLE_SERVER_IBAN = "AutofillEnableServerIban";
public static final String AUTOFILL_ENABLE_SUPPORT_FOR_HOME_AND_WORK =
"AutofillEnableSupportForHomeAndWork";
public static final String AUTOFILL_ENABLE_WALLET_BRANDING = "AutofillEnableWalletBranding";
public static final String AUTOFILL_RETRY_IMAGE_FETCH_ON_FAILURE =
"AutofillRetryImageFetchOnFailure";
public static final String AUTOFILL_SYNC_EWALLET_ACCOUNTS = "AutofillSyncEwalletAccounts";
@@ -294,21 +281,24 @@ public abstract class ChromeFeatureList {
"AutofillThirdPartyModeContentProvider";
public static final String AUTOMOTIVE_BACK_BUTTON_BAR_STREAMLINE =
"AutomotiveBackButtonBarStreamline";
public static final String AUTO_DOC_PIP_PERMISSION_PROMPT_ANDROID =
"AutoDocPiPPermissionPromptAndroid";
public static final String AUTO_PICTURE_IN_PICTURE_ANDROID = "AutoPictureInPictureAndroid";
public static final String AUTO_REVOKE_SUSPICIOUS_NOTIFICATION =
"AutoRevokeSuspiciousNotification";
public static final String AVOID_DOUBLE_MULTIWINDOW_CHANGES = "AvoidDoubleMultiwindowChanges";
public static final String AVOID_RELAYOUT_DURING_FOCUS_ANIMATION =
"AvoidRelayoutDuringFocusAnimation";
public static final String BACKGROUND_THREAD_POOL_FIELD_TRIAL =
"BackgroundThreadPoolFieldTrial";
public static final String BACK_FORWARD_CACHE = "BackForwardCache";
public static final String BCIV_BOTTOM_CONTROLS = "AndroidBcivBottomControls";
public static final String BLOCK_INTENTS_WHILE_LOCKED = "BlockIntentsWhileLocked";
public static final String BOARDING_PASS_DETECTOR = "BoardingPassDetector";
public static final String BOOKMARK_PANE_ANDROID = "BookmarkPaneAndroid";
public static final String BROWSER_CONTROLS_DEBUGGING = "BrowserControlsDebugging";
public static final String BROWSER_CONTROLS_EARLY_RESIZE = "BrowserControlsEarlyResize";
public static final String BROWSER_CONTROLS_IN_VIZ = "AndroidBrowserControlsInViz";
public static final String BROWSER_CONTROLS_PERSISTS_ON_CVH = "BrowserControlsPersistsOnCvh";
public static final String BROWSER_CONTROLS_RENDER_DRIVEN_SHOW_CONSTRAINT =
"BrowserControlsRenderDrivenShowConstraint";
public static final String BROWSING_DATA_MODEL = "BrowsingDataModel";
@@ -388,7 +378,6 @@ public abstract class ChromeFeatureList {
public static final String CONTROLS_VISIBILITY_FROM_NAVIGATIONS =
"ControlsVisibilityFromNavigations";
public static final String CORMORANT = "Cormorant";
public static final String CPA_SPEC_UPDATE = "CpaSpecUpdate";
public static final String CROSS_DEVICE_TAB_PANE_ANDROID = "CrossDeviceTabPaneAndroid";
public static final String DARKEN_WEBSITES_CHECKBOX_IN_THEMES_SETTING =
"DarkenWebsitesCheckboxInThemesSetting";
@@ -399,6 +388,7 @@ public abstract class ChromeFeatureList {
public static final String DATA_SHARING_NON_PRODUCTION_ENVIRONMENT =
"DataSharingNonProductionEnvironment";
public static final String DEFAULT_BROWSER_PROMO_ANDROID2 = "DefaultBrowserPromoAndroid2";
public static final String DESKTOP_ANDROID_LINK_CAPTURING = "DesktopAndroidLinkCapturing";
public static final String DESKTOP_UA_ON_CONNECTED_DISPLAY = "DesktopUAOnConnectedDisplay";
public static final String DETAILED_LANGUAGE_SETTINGS = "DetailedLanguageSettings";
public static final String DEVICE_AUTHENTICATOR_ANDROIDX = "DeviceAuthenticatorAndroidx";
@@ -432,7 +422,9 @@ public abstract class ChromeFeatureList {
"EnableFullscreenToAnyScreenAndroid";
public static final String ENABLE_SAVE_PACKAGE_FOR_OFF_THE_RECORD =
"EnableSavePackageForOffTheRecord";
public static final String ENABLE_SWIPE_TO_SWITCH_PANE = "EnableSwipeToSwitchPane";
public static final String ENABLE_X_AXIS_ACTIVITY_TRANSITION = "EnableXAxisActivityTransition";
public static final String ESC_CANCEL_DRAG = "EscCancelDrag";
public static final String FACILITATED_PAYMENTS_ENABLE_A2A_PAYMENT =
"FacilitatedPaymentsEnableA2APayment";
public static final String FEED_AUDIO_OVERVIEWS = "FeedAudioOverviews";
@@ -442,10 +434,7 @@ public abstract class ChromeFeatureList {
public static final String FEED_IMAGE_MEMORY_CACHE_SIZE_PERCENTAGE =
"FeedImageMemoryCacheSizePercentage";
public static final String FEED_LOADING_PLACEHOLDER = "FeedLoadingPlaceholder";
public static final String FEED_SHOW_SIGN_IN_COMMAND = "FeedShowSignInCommand";
public static final String FILLING_PASSWORDS_FROM_ANY_ORIGIN = "FillingPasswordsFromAnyOrigin";
public static final String FINGERPRINTING_PROTECTION_UX = "FingerprintingProtectionUx";
public static final String FLOATING_SNACKBAR = "FloatingSnackbar";
public static final String FLUID_RESIZE = "FluidResize";
public static final String FORCE_LIST_TAB_SWITCHER = "ForceListTabSwitcher";
public static final String FORCE_TRANSLUCENT_NOTIFICATION_TRAMPOLINE =
@@ -464,18 +453,15 @@ public abstract class ChromeFeatureList {
public static final String HEADLESS_TAB_MODEL = "HeadlessTabModel";
public static final String HISTORY_JOURNEYS = "Journeys";
public static final String HISTORY_PANE_ANDROID = "HistoryPaneAndroid";
public static final String HOMEPAGE_IS_NEW_TAB_PAGE_POLICY_ANDROID =
"HomepageIsNewTabPagePolicyAndroid";
public static final String HOME_MODULE_PREF_REFACTOR = "HomeModulePrefRefactor";
public static final String HTTPS_FIRST_BALANCED_MODE = "HttpsFirstBalancedMode";
public static final String HUB_BACK_BUTTON = "HubBackButton";
public static final String HUB_SLIDE_ANIMATION = "HubSlideAnimation";
public static final String INCOGNITO_NTP_SMALL_ICON = "IncognitoNtpSmallIcon";
public static final String INCOGNITO_SCREENSHOT = "IncognitoScreenshot";
public static final String INCOGNITO_THEME_OVERLAY_TESTING = "IncognitoThemeOverlayTesting";
public static final String INSTANCE_SWITCHER_V2 = "InstanceSwitcherV2";
public static final String IP_PROTECTION_UX = "IpProtectionUx";
public static final String KEYBOARD_ESC_BACK_NAVIGATION = "KeyboardEscBackNavigation";
public static final String LAUNCH_CAUSE_SCREEN_OFF_FIX = "LaunchCauseScreenOffFix";
public static final String LENS_ON_QUICK_ACTION_SEARCH_WIDGET = "LensOnQuickActionSearchWidget";
public static final String LINK_HOVER_STATUS_BAR = "LinkHoverStatusBar";
public static final String LOADING_PREDICTOR_LIMIT_PRECONNECT_SOCKET_COUNT =
@@ -483,6 +469,8 @@ public abstract class ChromeFeatureList {
public static final String LOAD_ALL_TABS_AT_STARTUP = "LoadAllTabsAtStartup";
public static final String LOAD_NATIVE_EARLY = "LoadNativeEarly";
public static final String LOCAL_NETWORK_ACCESS = "LocalNetworkAccessChecks";
public static final String LOCAL_NETWORK_ACCESS_SPLIT_PERMISSIONS =
"LocalNetworkAccessChecksSplitPermissions";
public static final String LOCK_BACK_PRESS_HANDLER_AT_START = "LockBackPressHandlerAtStart";
public static final String LOCK_TOP_CONTROLS_ON_LARGE_TABLETS = "LockTopControlsOnLargeTablets";
public static final String LOCK_TOP_CONTROLS_ON_LARGE_TABLETS_V2 =
@@ -495,9 +483,10 @@ public abstract class ChromeFeatureList {
public static final String MAYLAUNCHURL_USES_SEPARATE_STORAGE_PARTITION =
"MayLaunchUrlUsesSeparateStoragePartition";
public static final String MEDIA_INDICATORS_ANDROID = "MediaIndicatorsAndroid";
public static final String MINI_ORIGIN_BAR = "MiniOriginBar";
public static final String MOST_VISITED_TILES_CUSTOMIZATION = "MostVisitedTilesCustomization";
public static final String MOST_VISITED_TILES_RESELECT = "MostVisitedTilesReselect";
public static final String MOVE_TO_FRONT_IN_LAUNCH_INTENT_DISPATCHER =
"MoveToFrontInLaunchIntentDispatcher";
public static final String MULTI_INSTANCE_APPLICATION_STATUS_CLEANUP =
"MultiInstanceApplicationStatusCleanup";
public static final String MVC_UPDATE_VIEW_WHEN_MODEL_CHANGED = "MvcUpdateViewWhenModelChanged";
@@ -528,6 +517,7 @@ public abstract class ChromeFeatureList {
"PermissionDedicatedCpssSettingAndroid";
public static final String PERMISSION_SITE_SETTING_RADIO_BUTTON =
"PermissionSiteSettingsRadioButton";
public static final String PERSIST_ACROSS_REBOOTS = "PersistAcrossReboots";
public static final String PLUS_ADDRESSES_ENABLED = "PlusAddressesEnabled";
public static final String PLUS_ADDRESS_ANDROID_OPEN_GMS_CORE_MANAGEMENT_PAGE =
"PlusAddressAndroidOpenGmsCoreManagementPage";
@@ -553,6 +543,7 @@ public abstract class ChromeFeatureList {
// supervised_user::UseLocalSupervision() instead. Exposed only for testing.
public static final String PROPAGATE_DEVICE_CONTENT_FILTERS_TO_SUPERVISED_USER =
"PropagateDeviceContentFiltersToSupervisedUser";
public static final String PROTECT_RECENTLY_VISIBLE_TAB = "ProtectRecentlyVisibleTab";
public static final String PUSH_MESSAGING_DISALLOW_SENDER_IDS =
"PushMessagingDisallowSenderIDs";
public static final String PWA_RESTORE_UI = "PwaRestoreUi";
@@ -592,7 +583,6 @@ public abstract class ChromeFeatureList {
public static final String ROBUST_WINDOW_MANAGEMENT = "RobustWindowManagement";
public static final String ROBUST_WINDOW_MANAGEMENT_EXPERIMENTAL =
"RobustWindowManagementExperimental";
public static final String ROLL_BACK_MODE_B = "RollBackModeB";
public static final String SAFETY_HUB = "SafetyHub";
public static final String SAFETY_HUB_DISRUPTIVE_NOTIFICATION_REVOCATION =
"SafetyHubDisruptiveNotificationRevocation";
@@ -627,9 +617,10 @@ public abstract class ChromeFeatureList {
public static final String SETTINGS_SINGLE_ACTIVITY = "SettingsSingleActivity";
public static final String SHARED_DATA_TYPES_KILL_SWITCH = "SharedDataTypesKillSwitch";
public static final String SHARE_CUSTOM_ACTIONS_IN_CCT = "ShareCustomActionsInCCT";
public static final String SHOW_BLOCKED_SENSITIVE_DOWNLOAD = "ShowBlockedSensitiveDownload";
public static final String SHOW_CLOSE_ALL_INCOGNITO_TABS_BUTTON =
"ShowCloseAllIncognitoTabsButton";
public static final String SHOW_HOME_BUTTON_POLICY_ANDROID = "ShowHomeButtonPolicyAndroid";
public static final String SHOW_DOWNLOAD_SCANNING_STATE = "ShowDownloadScanningState";
public static final String SHOW_NEW_TAB_ANIMATIONS = "ShowNewTabAnimations";
public static final String SHOW_TAB_LIST_ANIMATIONS = "ShowTabListAnimations";
public static final String SHOW_WARNINGS_FOR_SUSPICIOUS_NOTIFICATIONS =
@@ -650,24 +641,16 @@ public abstract class ChromeFeatureList {
public static final String SYNC_ENABLE_NEW_SYNC_DASHBOARD_URL = "SyncEnableNewSyncDashboardUrl";
public static final String SYNC_ENABLE_PASSWORDS_SYNC_ERROR_MESSAGE_ALTERNATIVE =
"SyncEnablePasswordsSyncErrorMessageAlternative";
public static final String TABLET_TAB_STRIP_ANIMATION = "TabletTabStripAnimation";
public static final String TAB_ARCHIVAL_DRAG_DROP_ANDROID = "TabArchivalDragDropAndroid";
public static final String TAB_BOTTOM_SHEET = "TabBottomSheet";
public static final String TAB_CLOSURE_METHOD_REFACTOR = "TabClosureMethodRefactor";
public static final String TAB_COLLECTION_ANDROID = "TabCollectionAndroid";
public static final String TAB_FREEZING_USES_DISCARD = "TabFreezingUsesDiscard";
public static final String TAB_GROUP_ANDROID_VISUAL_DATA_CLEANUP =
"TabGroupAndroidVisualDataCleanup";
public static final String TAB_GROUP_ENTRY_POINTS_ANDROID = "TabGroupEntryPointsAndroid";
public static final String TAB_GROUP_PARITY_BOTTOM_SHEET_ANDROID =
"TabGroupParityBottomSheetAndroid";
public static final String TAB_MODEL_INIT_FIXES = "TabModelInitFixes";
public static final String TAB_STORAGE_SQLITE_PROTOTYPE = "TabStorageSqlitePrototype";
public static final String TAB_STRIP_AUTO_SELECT_ON_CLOSE_CHANGE =
"TabStripAutoSelectOnCloseChange";
public static final String TAB_STRIP_CLOSE_REFACTOR_ANDROID = "TabStripCloseRefactorAndroid";
public static final String TAB_STRIP_DENSITY_CHANGE_ANDROID = "TabStripDensityChangeAndroid";
public static final String TAB_STRIP_GROUP_DRAG_DROP_ANDROID = "TabStripGroupDragDropAndroid";
public static final String TAB_STRIP_INCOGNITO_MIGRATION = "TabStripIncognitoMigration";
public static final String TAB_STRIP_MOUSE_CLOSE_RESIZE_DELAY = "TabStripMouseCloseResizeDelay";
public static final String TAB_SWITCHER_DRAG_DROP_ANDROID = "TabSwitcherDragDropAndroid";
public static final String TAB_SWITCHER_GROUP_SUGGESTIONS_ANDROID =
"TabSwitcherGroupSuggestionsAndroid";
@@ -678,8 +661,6 @@ public abstract class ChromeFeatureList {
public static final String TASK_MANAGER_CLANK = "TaskManagerClank";
public static final String TEST_DEFAULT_DISABLED = "TestDefaultDisabled";
public static final String TEST_DEFAULT_ENABLED = "TestDefaultEnabled";
public static final String THIRD_PARTY_DISABLE_CHROME_AUTOFILL_SETTINGS_SCREEN =
"ThirdPartyDisableChromeAutofillSettingsScreen";
public static final String TINKER_TANK_BOTTOM_SHEET = "TinkerTankBottomSheet";
public static final String TOOLBAR_PHONE_ANIMATION_REFACTOR = "ToolbarPhoneAnimationRefactor";
public static final String TOOLBAR_SCROLL_ABLATION = "AndroidToolbarScrollAblation";
@@ -689,13 +670,13 @@ public abstract class ChromeFeatureList {
public static final String TOP_CONTROLS_REFACTOR = "TopControlsRefactor";
public static final String TOP_CONTROLS_REFACTOR_V2 = "TopControlsRefactorV2";
public static final String TOUCH_TO_SEARCH_CALLOUT = "TouchToSearchCallout";
public static final String TRACKING_PROTECTION_3PCD = "TrackingProtection3pcd";
public static final String TRANSLATE_MESSAGE_UI = "TranslateMessageUI";
public static final String TRANSLATE_TFLITE = "TFLiteLanguageDetectionEnabled";
public static final String TRUSTED_WEB_ACTIVITY_CONTACTS_DELEGATION =
"TrustedWebActivityContactsDelegation";
public static final String UMA_SESSION_CORRECTNESS_FIXES = "UmaSessionCorrectnessFixes";
public static final String UNO_PHASE_2_FOLLOW_UP = "UnoPhase2FollowUp";
public static final String UNPARCEL_INTENT_FILE_DESCRIPTORS = "UnparcelIntentFileDescriptors";
public static final String UPDATE_COMPOSTIROR_FOR_SURFACE_CONTROL =
"UpdateCompositorForSurfaceControl";
public static final String USE_ACTIVITY_MANAGER_FOR_TAB_ACTIVATION =
@@ -728,24 +709,17 @@ public abstract class ChromeFeatureList {
newCachedFlag(ACCOUNT_FOR_SUPPRESSED_KEYBOARD_INSETS, /* defaultValue= */ true);
public static final CachedFlag sAndroidAnimatedProgressBarInBrowser =
newCachedFlag(ANDROID_ANIMATED_PROGRESS_BAR_IN_BROWSER, true);
public static final CachedFlag sAndroidAnimatedProgressBarInViz =
newCachedFlag(ANDROID_ANIMATED_PROGRESS_BAR_IN_VIZ, false);
public static final CachedFlag sAndroidAppIntegrationModule =
newCachedFlag(ANDROID_APP_INTEGRATION_MODULE, true);
public static final CachedFlag sAndroidAppIntegrationMultiDataSource =
newCachedFlag(ANDROID_APP_INTEGRATION_MULTI_DATA_SOURCE, true);
public static final CachedFlag sAndroidAutoMintedTwa =
newCachedFlag(ANDROID_AUTO_MINTED_TWA, false);
public static final CachedFlag sAndroidBottomToolbar =
newCachedFlag(ANDROID_BOTTOM_TOOLBAR, true, true);
public static final CachedFlag sAndroidBottomToolbarV2 =
newCachedFlag(ANDROID_BOTTOM_TOOLBAR_V2, false, true);
public static final CachedFlag sAndroidComposeplate = newCachedFlag(ANDROID_COMPOSEPLATE, true);
public static final CachedFlag sAndroidComposeplateLFF =
newCachedFlag(
ANDROID_COMPOSEPLATE_LFF,
/* defaultValue= */ false,
/* defaultValueInTests= */ true);
newCachedFlag(ANDROID_COMPOSEPLATE_LFF, /* defaultValue= */ true);
public static final CachedFlag sAndroidDataImporterService =
newCachedFlag(ANDROID_DATA_IMPORTER_SERVICE, true);
public static final CachedFlag sAndroidDesktopDensity =
@@ -754,12 +728,10 @@ public abstract class ChromeFeatureList {
newCachedFlag(ANDROID_ELEGANT_TEXT_HEIGHT, true);
public static final CachedFlag sAndroidLogoViewRefactor =
newCachedFlag(ANDROID_LOGO_VIEW_REFACTOR, /* defaultValue= */ true);
public static final CachedFlag sAndroidMinimalUiLargeScreen =
newCachedFlag(ANDROID_MINIMAL_UI_LARGE_SCREEN, true);
public static final CachedFlag sAndroidNewMediaPicker =
newCachedFlag(ANDROID_NEW_MEDIA_PICKER, false);
public static final CachedFlag sAndroidOpenIncognitoAsWindow =
newCachedFlag(ANDROID_OPEN_INCOGNITO_AS_WINDOW, BuildConfig.IS_DESKTOP_ANDROID);
newCachedFlag(ANDROID_OPEN_INCOGNITO_AS_WINDOW, BuildConfig.IS_DESKTOP_ANDROID, true);
public static final CachedFlag sAndroidProgressBarVisualUpdate =
newCachedFlag(
ANDROID_PROGRESS_BAR_VISUAL_UPDATE,
@@ -770,6 +742,11 @@ public abstract class ChromeFeatureList {
ANDROID_SETTINGS_CONTAINMENT,
/* defaultValue= */ false,
/* defaultValueInTests= */ true);
public static final CachedFlag sAndroidSetupList =
newCachedFlag(
ANDROID_SETUP_LIST,
/* defaultValue= */ false,
/* defaultValueInTests= */ false);
public static final CachedFlag sAndroidSurfaceColorUpdate =
newCachedFlag(
ANDROID_SURFACE_COLOR_UPDATE,
@@ -777,8 +754,6 @@ public abstract class ChromeFeatureList {
/* defaultValueInTests= */ false);
public static final CachedFlag sAndroidTabDeclutterDedupeTabIdsKillSwitch =
newCachedFlag(ANDROID_TAB_DECLUTTER_DEDUPE_TAB_IDS_KILL_SWITCH, true);
public static final CachedFlag sAndroidTabGroupsColorUpdateGm3 =
newCachedFlag(ANDROID_TAB_GROUPS_COLOR_UPDATE_GM3, true);
public static final CachedFlag sAndroidTabSkipSaveTabsKillswitch =
newCachedFlag(ANDROID_TAB_SKIP_SAVE_TABS_TASK_KILLSWITCH, true, true);
public static final CachedFlag sAndroidThemeModule = newCachedFlag(ANDROID_THEME_MODULE, true);
@@ -889,12 +864,11 @@ public abstract class ChromeFeatureList {
public static final CachedFlag sClankStartupLatencyInjection =
newCachedFlag(CLANK_STARTUP_LATENCY_INJECTION, false);
public static final CachedFlag sClearIntentWhenRecreated =
newCachedFlag(CLEAR_INTENT_WHEN_RECREATED, /* defaultValue= */ true);
newCachedFlag(CLEAR_INTENT_WHEN_RECREATED, /* defaultValue= */ false);
public static final CachedFlag sCommandLineOnNonRooted =
newCachedFlag(COMMAND_LINE_ON_NON_ROOTED, false);
public static final CachedFlag sContextMenuPictureInPictureAndroid =
newCachedFlag(CONTEXT_MENU_PICTURE_IN_PICTURE_ANDROID, false);
public static final CachedFlag sCpaSpecUpdate = newCachedFlag(CPA_SPEC_UPDATE, true);
public static final CachedFlag sCpaTabGroupingButton =
newCachedFlag(
CONTEXTUAL_PAGE_ACTION_TAB_GROUPING,
@@ -902,13 +876,13 @@ public abstract class ChromeFeatureList {
/* defaultValueInTests= */ true);
public static final CachedFlag sCrossDeviceTabPaneAndroid =
newCachedFlag(CROSS_DEVICE_TAB_PANE_ANDROID, false);
public static final CachedFlag sDesktopAndroidLinkCapturing =
newCachedFlag(DESKTOP_ANDROID_LINK_CAPTURING, false);
public static final CachedFlag sDesktopUAOnConnectedDisplay =
newCachedFlag(
DESKTOP_UA_ON_CONNECTED_DISPLAY,
/* defaultValue= */ false,
/* defaultValueInTests= */ true);
public static final CachedFlag sDisplayEdgeToEdgeFullscreen =
newCachedFlag(DISPLAY_EDGE_TO_EDGE_FULLSCREEN, false, true);
public static final CachedFlag sDocumentPictureInPictureAPI =
newCachedFlag(DOCUMENT_PICTURE_IN_PICTURE_API, false, /* defaultValueInTests= */ false);
public static final CachedFlag sDrawChromePagesEdgeToEdge =
@@ -933,7 +907,6 @@ public abstract class ChromeFeatureList {
newCachedFlag(ENABLE_FULLSCREEN_TO_ANY_SCREEN_ANDROID, false, true);
public static final CachedFlag sEnableXAxisActivityTransition =
newCachedFlag(ENABLE_X_AXIS_ACTIVITY_TRANSITION, false);
public static final CachedFlag sFloatingSnackbar = newCachedFlag(FLOATING_SNACKBAR, true);
public static final CachedFlag sFluidResize =
newCachedFlag(FLUID_RESIZE, /* defaultValue= */ false, /* defaultValueInTests= */ true);
public static final CachedFlag sForceTranslucentNotificationTrampoline =
@@ -954,31 +927,38 @@ public abstract class ChromeFeatureList {
HISTORY_PANE_ANDROID,
/* defaultValue= */ false,
/* defaultValueInTests= */ true);
public static final CachedFlag sHomepageIsNewTabPagePolicyAndroid =
newCachedFlag(HOMEPAGE_IS_NEW_TAB_PAGE_POLICY_ANDROID, true);
public static final CachedFlag sIncognitoThemeOverlayTesting =
newCachedFlag(INCOGNITO_THEME_OVERLAY_TESTING, false);
public static final CachedFlag sKeyboardEscBackNavigation =
newCachedFlag(KEYBOARD_ESC_BACK_NAVIGATION, true);
public static final CachedFlag sLaunchCauseScreenOffFix =
newCachedFlag(
LAUNCH_CAUSE_SCREEN_OFF_FIX,
/* defaultValue= */ false,
/* defaultValueInTests= */ true);
public static final CachedFlag sLoadAllTabsAtStartup =
newCachedFlag(
LOAD_ALL_TABS_AT_STARTUP,
/* defaultValue= */ false,
/* defaultValueInTests= */ true);
// For the LoadNativeEarly CachedFlag, its defaultValue is false so that we do not load native
// library early and initialize feature list early on the first run to not break the first run
// Finch support, its defaultValueInTests is true so that we test this new behaviour in CQ bots.
public static final CachedFlag sLoadNativeEarly =
newCachedFlag(
LOAD_NATIVE_EARLY, /* defaultValue= */ false, /* defaultValueInTests= */ true);
public static final CachedFlag sLockBackPressHandlerAtStart =
newCachedFlag(LOCK_BACK_PRESS_HANDLER_AT_START, true);
public static final CachedFlag sLockTopControlsOnLargeTabletsV2 =
newCachedFlag(LOCK_TOP_CONTROLS_ON_LARGE_TABLETS_V2, false);
newCachedFlag(
LOCK_TOP_CONTROLS_ON_LARGE_TABLETS_V2,
/* defaultValue= */ false);
public static final CachedFlag sMagicStackAndroid = newCachedFlag(MAGIC_STACK_ANDROID, true);
public static final CachedFlag sMaliciousApkDownloadCheck =
newCachedFlag(
MALICIOUS_APK_DOWNLOAD_CHECK,
/* defaultValue= */ false,
/* defaultValueInTests= */ true);
public static final CachedFlag sMiniOriginBar = newCachedFlag(MINI_ORIGIN_BAR, true, true);
public static final CachedFlag sMostVisitedTilesCustomization =
newCachedFlag(
MOST_VISITED_TILES_CUSTOMIZATION,
@@ -986,6 +966,11 @@ public abstract class ChromeFeatureList {
/* defaultValueInTests= */ true);
public static final CachedFlag sMostVisitedTilesReselect =
newCachedFlag(MOST_VISITED_TILES_RESELECT, false);
public static final CachedFlag sMoveToFrontInLaunchIntentDispatcher =
newCachedFlag(
MOVE_TO_FRONT_IN_LAUNCH_INTENT_DISPATCHER,
/* defaultValue= */ false,
/* defaultValueInTests= */ true);
public static final CachedFlag sMultiInstanceApplicationStatusCleanup =
newCachedFlag(MULTI_INSTANCE_APPLICATION_STATUS_CLEANUP, false);
public static final CachedFlag sMvcUpdateViewWhenModelChanged =
@@ -1007,11 +992,15 @@ public abstract class ChromeFeatureList {
newCachedFlag(NOTIFICATION_TRAMPOLINE, false);
public static final CachedFlag sPCctMinimumHeight = newCachedFlag(PCCT_MINIMUM_HEIGHT, true);
public static final CachedFlag sPaintPreviewDemo = newCachedFlag(PAINT_PREVIEW_DEMO, false);
public static final CachedFlag sPersistAcrossReboots =
newCachedFlag(PERSIST_ACROSS_REBOOTS, false);
public static final CachedFlag sPostGetMyMemoryStateToBackground =
newCachedFlag(POST_GET_MEMORY_PRESSURE_TO_BACKGROUND, true);
public static final CachedFlag sPowerSavingModeBroadcastReceiverInBackground =
newCachedFlag(POWER_SAVING_MODE_BROADCAST_RECEIVER_IN_BACKGROUND, true);
public static final CachedFlag sPriceChangeModule = newCachedFlag(PRICE_CHANGE_MODULE, true);
public static final CachedFlag sProtectRecentlyVisibleTab =
newCachedFlag(PROTECT_RECENTLY_VISIBLE_TAB, false);
public static final CachedFlag sReportNotificationContentDetectionData =
newCachedFlag(
REPORT_NOTIFICATION_CONTENT_DETECTION_DATA,
@@ -1041,18 +1030,12 @@ public abstract class ChromeFeatureList {
SETTINGS_SINGLE_ACTIVITY,
/* defaultValue= */ false,
/* defaultValueInTests= */ true);
public static final CachedFlag sShowHomeButtonPolicyAndroid =
newCachedFlag(SHOW_HOME_BUTTON_POLICY_ANDROID, true);
public static final CachedFlag sSmallerTabStripTitleLimit =
newCachedFlag(SMALLER_TAB_STRIP_TITLE_LIMIT, true);
public static final CachedFlag sStartSurfaceReturnTime =
newCachedFlag(START_SURFACE_RETURN_TIME, true);
public static final CachedFlag sTabClosureMethodRefactor =
newCachedFlag(TAB_CLOSURE_METHOD_REFACTOR, false);
public static final CachedFlag sTabCollectionAndroid =
newCachedFlag(TAB_COLLECTION_ANDROID, true);
public static final CachedFlag sTabGroupAndroidVisualDataCleanup =
newCachedFlag(TAB_GROUP_ANDROID_VISUAL_DATA_CLEANUP, true);
public static final CachedFlag sTabModelInitFixes =
newCachedFlag(
TAB_MODEL_INIT_FIXES,
@@ -1066,11 +1049,9 @@ public abstract class ChromeFeatureList {
public static final CachedFlag sTabStripDensityChangeAndroid =
newCachedFlag(TAB_STRIP_DENSITY_CHANGE_ANDROID, true);
public static final CachedFlag sTabStripIncognitoMigration =
newCachedFlag(TAB_STRIP_INCOGNITO_MIGRATION, BuildConfig.IS_DESKTOP_ANDROID);
newCachedFlag(TAB_STRIP_INCOGNITO_MIGRATION, BuildConfig.IS_DESKTOP_ANDROID, true);
public static final CachedFlag sTabWindowManagerReportIndicesMismatch =
newCachedFlag(TAB_WINDOW_MANAGER_REPORT_INDICES_MISMATCH, true);
public static final CachedFlag sTabletTabStripAnimation =
newCachedFlag(TABLET_TAB_STRIP_ANIMATION, true);
public static final CachedFlag sTestDefaultDisabled =
newCachedFlag(TEST_DEFAULT_DISABLED, false);
public static final CachedFlag sTestDefaultEnabled = newCachedFlag(TEST_DEFAULT_ENABLED, true);
@@ -1100,12 +1081,17 @@ public abstract class ChromeFeatureList {
/* defaultValue= */ false,
/* defaultValueInTests= */ true);
public static final CachedFlag sTopControlsRefactorV2 =
newCachedFlag(TOP_CONTROLS_REFACTOR_V2, /* defaultValue= */ false);
newCachedFlag(
TOP_CONTROLS_REFACTOR_V2,
/* defaultValue= */ false,
/* defaultValueInTests= */ true);
public static final CachedFlag sTouchToSearchCallout =
newCachedFlag(
TOUCH_TO_SEARCH_CALLOUT,
/* defaultValue= */ false,
/* defaultValueInTests= */ true);
public static final CachedFlag sUnparcelIntentFileDescriptors =
newCachedFlag(UNPARCEL_INTENT_FILE_DESCRIPTORS, /* defaultValue= */ true);
public static final CachedFlag sUseActivityManagerForTabActivation =
newCachedFlag(USE_ACTIVITY_MANAGER_FOR_TAB_ACTIVATION, true);
public static final CachedFlag sUseChimeAndroidSdk =
@@ -1123,11 +1109,9 @@ public abstract class ChromeFeatureList {
// keep-sorted start
sAccountForSuppressedKeyboardInsets,
sAndroidAnimatedProgressBarInBrowser,
sAndroidAnimatedProgressBarInViz,
sAndroidAppIntegrationModule,
sAndroidAppIntegrationMultiDataSource,
sAndroidAutoMintedTwa,
sAndroidBottomToolbar,
sAndroidBottomToolbarV2,
sAndroidComposeplate,
sAndroidComposeplateLFF,
@@ -1135,14 +1119,13 @@ public abstract class ChromeFeatureList {
sAndroidDesktopDensity,
sAndroidElegantTextHeight,
sAndroidLogoViewRefactor,
sAndroidMinimalUiLargeScreen,
sAndroidNewMediaPicker,
sAndroidOpenIncognitoAsWindow,
sAndroidProgressBarVisualUpdate,
sAndroidSettingsContainment,
sAndroidSetupList,
sAndroidSurfaceColorUpdate,
sAndroidTabDeclutterDedupeTabIdsKillSwitch,
sAndroidTabGroupsColorUpdateGm3,
sAndroidTabSkipSaveTabsKillswitch,
sAndroidThemeModule,
sAndroidThemeResourceProvider,
@@ -1195,11 +1178,10 @@ public abstract class ChromeFeatureList {
sClearIntentWhenRecreated,
sCommandLineOnNonRooted,
sContextMenuPictureInPictureAndroid,
sCpaSpecUpdate,
sCpaTabGroupingButton,
sCrossDeviceTabPaneAndroid,
sDesktopAndroidLinkCapturing,
sDesktopUAOnConnectedDisplay,
sDisplayEdgeToEdgeFullscreen,
sDocumentPictureInPictureAPI,
sDrawChromePagesEdgeToEdge,
sEdgeToEdgeBottomChin,
@@ -1212,7 +1194,6 @@ public abstract class ChromeFeatureList {
sEnableExclusiveAccessManager,
sEnableFullscreenToAnyScreenAndroid,
sEnableXAxisActivityTransition,
sFloatingSnackbar,
sFluidResize,
sForceTranslucentNotificationTrampoline,
sFullscreenInsetsApiMigration,
@@ -1220,18 +1201,18 @@ public abstract class ChromeFeatureList {
sGridTabSwitcherSurfaceColorUpdate,
sGridTabSwitcherUpdate,
sHistoryPaneAndroid,
sHomepageIsNewTabPagePolicyAndroid,
sIncognitoThemeOverlayTesting,
sKeyboardEscBackNavigation,
sLaunchCauseScreenOffFix,
sLoadAllTabsAtStartup,
sLoadNativeEarly,
sLockBackPressHandlerAtStart,
sLockTopControlsOnLargeTabletsV2,
sMagicStackAndroid,
sMaliciousApkDownloadCheck,
sMiniOriginBar,
sMostVisitedTilesCustomization,
sMostVisitedTilesReselect,
sMoveToFrontInLaunchIntentDispatcher,
sMultiInstanceApplicationStatusCleanup,
sMvcUpdateViewWhenModelChanged,
sNavBarColorAnimation,
@@ -1242,9 +1223,11 @@ public abstract class ChromeFeatureList {
sNotificationTrampoline,
sPCctMinimumHeight,
sPaintPreviewDemo,
sPersistAcrossReboots,
sPostGetMyMemoryStateToBackground,
sPowerSavingModeBroadcastReceiverInBackground,
sPriceChangeModule,
sProtectRecentlyVisibleTab,
sReportNotificationContentDetectionData,
sRightEdgeGoesForwardGestureNav,
sSafetyHubWeakAndReusedPasswords,
@@ -1255,18 +1238,14 @@ public abstract class ChromeFeatureList {
sSearchInSettings,
sSettingsMultiColumn,
sSettingsSingleActivity,
sShowHomeButtonPolicyAndroid,
sSmallerTabStripTitleLimit,
sStartSurfaceReturnTime,
sTabClosureMethodRefactor,
sTabCollectionAndroid,
sTabGroupAndroidVisualDataCleanup,
sTabModelInitFixes,
sTabStorageSqlitePrototype,
sTabStripDensityChangeAndroid,
sTabStripIncognitoMigration,
sTabWindowManagerReportIndicesMismatch,
sTabletTabStripAnimation,
sToolbarPhoneAnimationRefactor,
sToolbarSnapshotRefactor,
sToolbarStaleCaptureBugFix,
@@ -1274,6 +1253,7 @@ public abstract class ChromeFeatureList {
sTopControlsRefactor,
sTopControlsRefactorV2,
sTouchToSearchCallout,
sUnparcelIntentFileDescriptors,
sUseActivityManagerForTabActivation,
sUseChimeAndroidSdk,
sUseInitialNetworkStateAtStartup,
@@ -1311,28 +1291,16 @@ public abstract class ChromeFeatureList {
newMutableFlagWithSafeDefault(ANDROID_PINNED_TABS, false);
public static final MutableFlagWithSafeDefault sAndroidPinnedTabsTabletTabStrip =
newMutableFlagWithSafeDefault(ANDROID_PINNED_TABS_TABLET_TAB_STRIP, false);
public static final MutableFlagWithSafeDefault
sAndroidShowRestoreTabsPromoOnFreBypassedKillSwitch =
newMutableFlagWithSafeDefault(
ANDROID_SHOW_RESTORE_TABS_PROMO_ON_FRE_BYPASSED_KILL_SWITCH, true);
public static final MutableFlagWithSafeDefault sAndroidTabDeclutterArchiveAllButActiveTab =
newMutableFlagWithSafeDefault(ANDROID_TAB_DECLUTTER_ARCHIVE_ALL_BUT_ACTIVE, false);
public static final MutableFlagWithSafeDefault sAndroidTabDeclutterArchiveTabGroups =
newMutableFlagWithSafeDefault(ANDROID_TAB_DECLUTTER_ARCHIVE_TAB_GROUPS, true);
public static final MutableFlagWithSafeDefault sAndroidTabDeclutterPerformanceImprovements =
newMutableFlagWithSafeDefault(ANDROID_TAB_DECLUTTER_PERFORMANCE_IMPROVEMENTS, true);
public static final MutableFlagWithSafeDefault sAndroidTabDeclutterRescueKillSwitch =
newMutableFlagWithSafeDefault(ANDROID_TAB_DECLUTTER_RESCUE_KILLSWITCH, true);
public static final MutableFlagWithSafeDefault sAndroidTabHighlighting =
newMutableFlagWithSafeDefault(ANDROID_TAB_HIGHLIGHTING, false);
public static final MutableFlagWithSafeDefault sAndroidTipsNotifications =
newMutableFlagWithSafeDefault(ANDROID_TIPS_NOTIFICATIONS, false);
public static final MutableFlagWithSafeDefault sBcivBottomControls =
newMutableFlagWithSafeDefault(BCIV_BOTTOM_CONTROLS, true);
public static final MutableFlagWithSafeDefault sBrowserControlsEarlyResize =
newMutableFlagWithSafeDefault(BROWSER_CONTROLS_EARLY_RESIZE, false);
public static final MutableFlagWithSafeDefault sBrowserControlsInViz =
newMutableFlagWithSafeDefault(BROWSER_CONTROLS_IN_VIZ, true);
public static final MutableFlagWithSafeDefault sBrowserControlsPersistsOnCvh =
newMutableFlagWithSafeDefault(BROWSER_CONTROLS_PERSISTS_ON_CVH, true);
// Default to false. The logic behind the flag is not relevant when native is not initialized.
public static final MutableFlagWithSafeDefault sBrowserControlsRenderDrivenShowConstraint =
newMutableFlagWithSafeDefault(BROWSER_CONTROLS_RENDER_DRIVEN_SHOW_CONSTRAINT, false);
@@ -1344,10 +1312,12 @@ public abstract class ChromeFeatureList {
// value pre-native to false as it is safer if the feature needs to be killed via Finch config.
public static final MutableFlagWithSafeDefault sEmptyTabListAnimationKillSwitch =
newMutableFlagWithSafeDefault(EMPTY_TAB_LIST_ANIMATION_KILL_SWITCH, false);
public static final MutableFlagWithSafeDefault sEnableSwipeToSwitchPane =
newMutableFlagWithSafeDefault(ENABLE_SWIPE_TO_SWITCH_PANE, false);
public static final MutableFlagWithSafeDefault sEscCancelDrag =
newMutableFlagWithSafeDefault(ESC_CANCEL_DRAG, false);
public static final MutableFlagWithSafeDefault sHubBackButton =
newMutableFlagWithSafeDefault(HUB_BACK_BUTTON, false);
public static final MutableFlagWithSafeDefault sHubSlideAnimation =
newMutableFlagWithSafeDefault(HUB_SLIDE_ANIMATION, true);
public static final MutableFlagWithSafeDefault sIncognitoNtpSmallIcon =
newMutableFlagWithSafeDefault(INCOGNITO_NTP_SMALL_ICON, false);
public static final MutableFlagWithSafeDefault sIncognitoScreenshot =
@@ -1362,6 +1332,8 @@ public abstract class ChromeFeatureList {
newMutableFlagWithSafeDefault(OMNIBOX_AUTOFOCUS_ON_INCOGNITO_NTP, false);
public static final MutableFlagWithSafeDefault sReadAloudTapToSeek =
newMutableFlagWithSafeDefault(READALOUD_TAP_TO_SEEK, false);
public static final MutableFlagWithSafeDefault sRecentlyClosedTabsAndWindows =
newMutableFlagWithSafeDefault(RECENTLY_CLOSED_TABS_AND_WINDOWS, false);
public static final MutableFlagWithSafeDefault sRecordIncognitoNtpTimeToFirstNavigationMetric =
newMutableFlagWithSafeDefault(
RECORD_INCOGNITO_NTP_TIME_TO_FIRST_NAVIGATION_METRIC, true);
@@ -1375,14 +1347,10 @@ public abstract class ChromeFeatureList {
newMutableFlagWithSafeDefault(SHOW_TAB_LIST_ANIMATIONS, false);
public static final MutableFlagWithSafeDefault sSuppressToolbarCapturesAtGestureEnd =
newMutableFlagWithSafeDefault(SUPPRESS_TOOLBAR_CAPTURES_AT_GESTURE_END, false);
public static final MutableFlagWithSafeDefault sTabArchivalDragDropAndroid =
newMutableFlagWithSafeDefault(TAB_ARCHIVAL_DRAG_DROP_ANDROID, true);
public static final MutableFlagWithSafeDefault sTabBottomSheet =
newMutableFlagWithSafeDefault(TAB_BOTTOM_SHEET, false);
public static final MutableFlagWithSafeDefault sTabFreezingUsesDiscard =
newMutableFlagWithSafeDefault(TAB_FREEZING_USES_DISCARD, false);
public static final MutableFlagWithSafeDefault sTabGroupEntryPointsAndroid =
newMutableFlagWithSafeDefault(TAB_GROUP_ENTRY_POINTS_ANDROID, true);
public static final MutableFlagWithSafeDefault sTabGroupParityBottomSheetAndroid =
newMutableFlagWithSafeDefault(TAB_GROUP_PARITY_BOTTOM_SHEET_ANDROID, true);
public static final MutableFlagWithSafeDefault sTabSwitcherGroupSuggestionsAndroid =
newMutableFlagWithSafeDefault(TAB_SWITCHER_GROUP_SUGGESTIONS_ANDROID, false);
public static final MutableFlagWithSafeDefault sTabSwitcherGroupSuggestionsTestModeAndroid =
@@ -1407,6 +1375,9 @@ public abstract class ChromeFeatureList {
newBooleanCachedFeatureParam(CCT_ADAPTIVE_BUTTON, "contextual_only", false);
public static final IntCachedFeatureParam sCctAdaptiveButtonDefaultVariant =
newIntCachedFeatureParam(CCT_ADAPTIVE_BUTTON, "default_variant", 0);
public static final BooleanCachedFeatureParam sLockTopControlsForceAdjustHeightOnStartup =
newBooleanCachedFeatureParam(
LOCK_TOP_CONTROLS_ON_LARGE_TABLETS_V2, "adjust_tab_strip_on_startup", true);
public static final IntCachedFeatureParam sLowMemoryDeviceThresholdMb =
newIntCachedFeatureParam(
LOW_END_MEMORY_EXPERIMENT,
@@ -1442,8 +1413,6 @@ public abstract class ChromeFeatureList {
public static final BooleanCachedFeatureParam sAndroidComposeplateV2Enabled =
newBooleanCachedFeatureParam(ANDROID_COMPOSEPLATE, "v2_enabled", true);
public static final BooleanCachedFeatureParam sAndroidBottomToolbarDefaultToTop =
newBooleanCachedFeatureParam(ANDROID_BOTTOM_TOOLBAR, "default_to_top", true);
public static final BooleanCachedFeatureParam
sAndroidBottomToolbarV2ForceBottomForFocusedOmnibox =
@@ -1584,6 +1553,17 @@ public abstract class ChromeFeatureList {
public static final BooleanCachedFeatureParam sNewTabPageCustomizationV2ShowColorPicker =
newBooleanCachedFeatureParam(NEW_TAB_PAGE_CUSTOMIZATION_V2, "show_color_picker", false);
public static final BooleanCachedFeatureParam sNewTabPageCustomizationV2ShowLogoAndSearchBox =
newBooleanCachedFeatureParam(
NEW_TAB_PAGE_CUSTOMIZATION_V2, "show_logo_and_search_box", false);
/** The time duration limit to refresh NTP's background. */
public static final IntCachedFeatureParam sNewTabPageCustomizationV2DailyRefreshThresholdMs =
newIntCachedFeatureParam(
NEW_TAB_PAGE_CUSTOMIZATION_V2,
"daily_refresh_threshold_ms",
(int) TimeUtils.MILLISECONDS_PER_DAY); // 1 day in milliseconds.
/**
* Param for the OEMs that need an exception for min versions. Its value should be a comma
* separated list of integers, and its index should match {@link #sEdgeToEdgeBottomChinOemList}.
@@ -1630,6 +1610,9 @@ public abstract class ChromeFeatureList {
public static final IntCachedFeatureParam sEdgeToEdgeTabletMinWidthThreshold =
newIntCachedFeatureParam(EDGE_TO_EDGE_TABLET, "e2e_tablet_width_threshold", -1);
public static final BooleanCachedFeatureParam sInitFeatureListEarly =
newBooleanCachedFeatureParam(LOAD_NATIVE_EARLY, "init_feature_list_early", true);
public static final BooleanCachedFeatureParam sTabGroupListContainment =
newBooleanCachedFeatureParam(
GRID_TAB_SWITCHER_SURFACE_COLOR_UPDATE, "tab_group_list_containment", true);
@@ -1707,6 +1690,9 @@ public abstract class ChromeFeatureList {
"activity_creation_timestamp_diff_threshold_ms",
1000);
public static final IntCachedFeatureParam sTopControlsRefactorNarrowWidthTransitionThreshold =
newIntCachedFeatureParam(TOP_CONTROLS_REFACTOR, "min_width_transition_threshold", 0);
/** Always register to push notification service. */
public static final BooleanCachedFeatureParam sUseChimeAndroidSdkAlwaysRegister =
newBooleanCachedFeatureParam(USE_CHIME_ANDROID_SDK, "always_register", false);
@@ -1738,7 +1724,6 @@ public abstract class ChromeFeatureList {
sAndroidAppIntegrationMultiDataSourceSkipDeviceCheck,
sAndroidAppIntegrationMultiDataSourceSkipSchemaCheck,
sAndroidBookmarkBarShowBookmarkBar,
sAndroidBottomToolbarDefaultToTop,
sAndroidBottomToolbarV2ForceBottomForFocusedOmnibox,
sAndroidBottomToolbarV2ReverseOrderSuggestionsList,
sAndroidComposeplateHideIncognitoButton,
@@ -1777,6 +1762,8 @@ public abstract class ChromeFeatureList {
sEdgeToEdgeUseBackupNavbarInsetsOemList,
sEdgeToEdgeUseBackupNavbarInsetsOemMinVersions,
sEdgeToEdgeUseBackupNavbarInsetsUseGestures,
sInitFeatureListEarly,
sLockTopControlsForceAdjustHeightOnStartup,
sLowMemoryDeviceThresholdMb,
sMagicStackAndroidShowAllModules,
sMaliciousApkDownloadCheckTelemetryOnly,
@@ -1786,7 +1773,9 @@ public abstract class ChromeFeatureList {
sMostVisitedTilesReselectLaxSchemeHost,
sNavBarColorAnimationDisableBottomChinColorAnimation,
sNavBarColorAnimationDisableEdgeToEdgeLayoutColorAnimation,
sNewTabPageCustomizationV2DailyRefreshThresholdMs,
sNewTabPageCustomizationV2ShowColorPicker,
sNewTabPageCustomizationV2ShowLogoAndSearchBox,
sNotificationTrampolineImmediateJobDurationMs,
sNotificationTrampolineLongJobDurationMs,
sNotificationTrampolineNormalJobDurationMs,
@@ -1802,6 +1791,7 @@ public abstract class ChromeFeatureList {
sTabGroupListContainment,
sTabStorageSqlitePrototypeAuthoritativeReadSource,
sTabWindowManagerReportIndicesMismatchTimeDiffThresholdMs,
sTopControlsRefactorNarrowWidthTransitionThreshold,
sTouchToSearchCalloutIph,
sTouchToSearchCalloutSnippetAsSubtitle,
sUseChimeAndroidSdkAlwaysRegister,
@@ -16,13 +16,11 @@
#include "build/android_buildflags.h"
#include "build/branding_buildflags.h"
#include "build/build_config.h"
#include "build/chromecast_buildflags.h"
#include "chrome/browser/about_flags.h"
#include "chrome/browser/accessibility/accessibility_labels_service.h"
#include "chrome/browser/accessibility/invert_bubble_prefs.h"
#include "chrome/browser/accessibility/page_colors_controller.h"
#include "chrome/browser/accessibility/prefers_default_scrollbar_styles_prefs.h"
#include "chrome/browser/actor/ui/actor_ui_state_manager_prefs.h"
#include "chrome/browser/browser_process_impl.h"
#include "chrome/browser/chrome_content_browser_client.h"
#include "chrome/browser/component_updater/component_updater_prefs.h"
@@ -38,8 +36,6 @@
#include "chrome/browser/media/media_engagement_service.h"
#include "chrome/browser/media/media_storage_id_salt.h"
#include "chrome/browser/media/prefs/capture_device_ranking.h"
#include "chrome/browser/media/router/discovery/access_code/access_code_cast_feature.h"
#include "chrome/browser/media/router/media_router_feature.h"
#include "chrome/browser/media/webrtc/capture_policy_utils.h"
#include "chrome/browser/media/webrtc/media_capture_devices_dispatcher.h"
#include "chrome/browser/media/webrtc/permission_bubble_media_access_handler.h"
@@ -81,13 +77,11 @@
#include "chrome/browser/subscription_eligibility/subscription_eligibility_prefs.h"
#include "chrome/browser/tracing/chrome_tracing_delegate.h"
#include "chrome/browser/ui/browser_ui_prefs.h"
#include "chrome/browser/ui/hats/hats_service_desktop.h"
#include "chrome/browser/ui/network_profile_bubble.h"
#include "chrome/browser/ui/performance_controls/performance_controls_metrics.h"
#include "chrome/browser/ui/prefs/prefs_tab_helper.h"
#include "chrome/browser/ui/safety_hub/safety_hub_prefs.h"
#include "chrome/browser/ui/search_engines/keyword_editor_controller.h"
#include "chrome/browser/ui/send_tab_to_self/send_tab_to_self_bubble.h"
#include "chrome/browser/ui/toolbar/chrome_labs/chrome_labs_prefs.h"
#include "chrome/browser/ui/toolbar/chrome_location_bar_model_delegate.h"
#include "chrome/browser/ui/toolbar/toolbar_pref_names.h"
@@ -143,6 +137,7 @@
#include "components/omnibox/browser/document_provider.h"
#include "components/omnibox/browser/omnibox_prefs.h"
#include "components/omnibox/browser/zero_suggest_provider.h"
#include "components/on_device_translation/buildflags/buildflags.h"
#include "components/optimization_guide/core/model_execution/model_execution_prefs.h"
#include "components/optimization_guide/core/optimization_guide_prefs.h"
#include "components/page_info/core/merchant_trust_service.h"
@@ -163,7 +158,6 @@
#include "components/prefs/pref_registry_simple.h"
#include "components/prefs/pref_service.h"
#include "components/privacy_sandbox/privacy_sandbox_prefs.h"
#include "components/privacy_sandbox/tpcd_pref_names.h"
#include "components/proxy_config/pref_proxy_config_tracker_impl.h"
#include "components/regional_capabilities/regional_capabilities_prefs.h"
#include "components/safe_browsing/buildflags.h"
@@ -176,7 +170,6 @@
#include "components/security_interstitials/content/stateful_ssl_host_state_delegate.h"
#include "components/segmentation_platform/embedder/default_model/device_switcher_result_dispatcher.h"
#include "components/segmentation_platform/public/segmentation_platform_service.h"
#include "components/services/on_device_translation/buildflags/buildflags.h"
#include "components/sessions/core/session_id_generator.h"
#include "components/sharing_message/sharing_sync_preference.h"
#include "components/signin/core/browser/active_primary_accounts_metrics_recorder.h"
@@ -184,11 +177,12 @@
#include "components/signin/public/base/signin_prefs.h"
#include "components/signin/public/identity_manager/identity_manager.h"
#include "components/site_engagement/content/site_engagement_service.h"
#include "components/subresource_filter/content/shared/browser/ruleset_service.h"
#include "components/subresource_filter/content/browser/ruleset_service.h"
#include "components/subresource_filter/core/common/constants.h"
#include "components/supervised_user/core/browser/supervised_user_preferences.h"
#include "components/supervised_user/core/common/pref_names.h"
#include "components/sync/base/pref_names.h"
#include "components/sync/service/device_statistics_tracker.h"
#include "components/sync/service/glue/sync_transport_data_prefs.h"
#include "components/sync/service/sync_prefs.h"
#include "components/sync_device_info/device_info_prefs.h"
@@ -230,30 +224,10 @@
#if BUILDFLAG(ENABLE_EXTENSIONS)
#include "chrome/browser/accessibility/animation_policy_prefs.h"
#include "chrome/browser/apps/platform_apps/shortcut_manager.h"
#include "chrome/browser/extensions/api/tabs/tabs_api.h"
#include "chrome/browser/extensions/preinstalled_apps.h"
#include "chrome/browser/ui/extensions/extension_settings_overridden_dialog.h"
#include "chrome/browser/ui/extensions/settings_api_bubble_helpers.h"
#include "chrome/browser/ui/webui/extensions/extensions_ui.h"
#include "extensions/browser/api/audio/audio_api.h"
#if BUILDFLAG(IS_CHROMEOS)
#include "chrome/browser/ash/device_name/device_name_store.h"
#include "chrome/browser/ash/extensions/extensions_permissions_tracker.h"
#include "chrome/browser/ash/kerberos/kerberos_credentials_manager.h"
#include "chrome/browser/ash/net/system_proxy_manager.h"
#include "chrome/browser/ash/performance/doze_mode_power_status_scheduler.h"
#include "chrome/browser/ash/platform_keys/key_permissions/key_permissions_manager_impl.h"
#include "chrome/browser/ash/policy/networking/euicc_status_uploader.h"
#include "chrome/browser/ash/policy/remote_commands/crd/crd_admin_session_controller.h"
#include "chrome/browser/ash/settings/hardware_data_usage_controller.h"
#include "chrome/browser/ash/settings/stats_reporting_controller.h"
#include "chrome/browser/ash/system_web_apps/apps/media_app/media_app_guest_ui_config.h"
#include "chrome/browser/component_updater/metadata_table_chromeos.h"
#include "chrome/browser/ui/ash/projector/projector_app_client_impl.h"
#include "chrome/browser/ui/webui/ash/edu_coexistence/edu_coexistence_login_handler.h"
#include "chrome/browser/ui/webui/signin/ash/inline_login_handler_impl.h"
#include "chromeos/ash/components/carrier_lock/carrier_lock_manager.h"
#endif // BUILDFLAG(IS_CHROMEOS)
#endif // BUILDFLAG(ENABLE_EXTENSIONS)
#if BUILDFLAG(ENABLE_PDF)
@@ -275,17 +249,20 @@
#include "chrome/browser/readaloud/android/prefs.h"
#include "chrome/browser/ssl/known_interception_disclosure_infobar_delegate.h"
#include "components/cdm/browser/media_drm_storage_impl.h" // nogncheck crbug.com/1125897
#include "components/feed/core/common/pref_names.h" // nogncheck
#include "components/feed/core/shared_prefs/pref_names.h" // nogncheck
#include "components/feed/core/v2/ios_shared_prefs.h" // nogncheck
#include "components/feed/core/common/pref_names.h" // nogncheck
#include "components/feed/core/shared_prefs/pref_names.h" // nogncheck
#include "components/feed/core/v2/ios_shared_prefs.h" // nogncheck
#include "components/ntp_tiles/popular_sites_impl.h"
#include "components/permissions/contexts/geolocation_permission_context_android.h"
#include "components/webapps/browser/android/install_prompt_prefs.h"
#else // BUILDFLAG(IS_ANDROID)
#include "chrome/browser/actor/ui/actor_ui_state_manager_prefs.h"
#include "chrome/browser/contextual_cueing/contextual_cueing_prefs.h"
#include "chrome/browser/gcm/gcm_product_util.h"
#include "chrome/browser/hid/hid_policy_allowed_devices.h"
#include "chrome/browser/intranet_redirect_detector.h"
#include "chrome/browser/media/router/discovery/access_code/access_code_cast_feature.h"
#include "chrome/browser/media/router/media_router_feature.h"
#include "chrome/browser/media/unified_autoplay_config.h"
#include "chrome/browser/nearby_sharing/common/nearby_share_prefs.h"
#include "chrome/browser/new_tab_page/modules/file_suggestion/drive_service.h"
@@ -304,6 +281,9 @@
#include "chrome/browser/task_manager/task_manager_interface.h"
#include "chrome/browser/themes/theme_syncable_service.h"
#include "chrome/browser/ui/commerce/commerce_ui_tab_helper.h"
#include "chrome/browser/ui/hats/hats_service_desktop.h"
#include "chrome/browser/ui/read_anything/read_anything_prefs.h"
#include "chrome/browser/ui/send_tab_to_self/send_tab_to_self_bubble.h"
#include "chrome/browser/ui/startup/startup_browser_creator.h"
#include "chrome/browser/ui/tabs/organization/prefs.h"
#include "chrome/browser/ui/tabs/pinned_tab_codec.h"
@@ -319,7 +299,6 @@
#include "chrome/browser/ui/webui/new_tab_page/new_tab_page_ui.h"
#include "chrome/browser/ui/webui/new_tab_page/ntp_pref_names.h"
#include "chrome/browser/ui/webui/settings/settings_ui.h"
#include "chrome/browser/ui/webui/side_panel/read_anything/read_anything_prefs.h"
#include "chrome/browser/ui/webui/tab_search/tab_search_prefs.h"
#include "chrome/browser/upgrade_detector/upgrade_detector.h"
#include "chrome/browser/user_education/browser_user_education_storage_service.h"
@@ -372,6 +351,7 @@
#include "chrome/browser/ash/cryptauth/client_app_metadata_provider_service.h"
#include "chrome/browser/ash/cryptauth/cryptauth_device_id_provider.h"
#include "chrome/browser/ash/customization/customization_document.h"
#include "chrome/browser/ash/extensions/extensions_permissions_tracker.h"
#include "chrome/browser/ash/file_manager/file_manager_pref_names.h"
#include "chrome/browser/ash/file_manager/file_tasks.h"
#include "chrome/browser/ash/file_system_provider/registry.h"
@@ -380,6 +360,7 @@
#include "chrome/browser/ash/guest_os/guest_id.h"
#include "chrome/browser/ash/guest_os/guest_os_pref_names.h"
#include "chrome/browser/ash/guest_os/guest_os_terminal.h"
#include "chrome/browser/ash/kerberos/kerberos_credentials_manager.h"
#include "chrome/browser/ash/login/quick_unlock/fingerprint_storage.h"
#include "chrome/browser/ash/login/quick_unlock/pin_storage_prefs.h"
#include "chrome/browser/ash/login/quick_unlock/quick_unlock_utils.h"
@@ -400,6 +381,9 @@
#include "chrome/browser/ash/net/ash_proxy_monitor.h"
#include "chrome/browser/ash/net/network_throttling_observer.h"
#include "chrome/browser/ash/net/secure_dns_manager.h"
#include "chrome/browser/ash/net/system_proxy_manager.h"
#include "chrome/browser/ash/performance/doze_mode_power_status_scheduler.h"
#include "chrome/browser/ash/platform_keys/key_permissions/key_permissions_manager_impl.h"
#include "chrome/browser/ash/plugin_vm/plugin_vm_pref_names.h"
#include "chrome/browser/ash/policy/core/browser_policy_connector_ash.h"
#include "chrome/browser/ash/policy/core/device_cloud_policy_manager_ash.h"
@@ -408,6 +392,8 @@
#include "chrome/browser/ash/policy/handlers/adb_sideloading_allowance_mode_policy_handler.h"
#include "chrome/browser/ash/policy/handlers/minimum_version_policy_handler.h"
#include "chrome/browser/ash/policy/handlers/tpm_auto_update_mode_policy_handler.h"
#include "chrome/browser/ash/policy/networking/euicc_status_uploader.h"
#include "chrome/browser/ash/policy/remote_commands/crd/crd_admin_session_controller.h"
#include "chrome/browser/ash/policy/reporting/app_install_event_log_manager_wrapper.h"
#include "chrome/browser/ash/policy/reporting/arc_app_install_event_logger.h"
#include "chrome/browser/ash/policy/reporting/metrics_reporting/metric_reporting_prefs.h"
@@ -420,9 +406,12 @@
#include "chrome/browser/ash/printing/enterprise/enterprise_printers_provider.h"
#include "chrome/browser/ash/release_notes/release_notes_storage.h"
#include "chrome/browser/ash/scanning/chrome_scanning_app_delegate.h"
#include "chrome/browser/ash/settings/hardware_data_usage_controller.h"
#include "chrome/browser/ash/settings/stats_reporting_controller.h"
#include "chrome/browser/ash/system/automatic_reboot_manager.h"
#include "chrome/browser/ash/system/input_device_settings.h"
#include "chrome/browser/ash/system_web_apps/apps/help_app/help_app_notification_controller.h"
#include "chrome/browser/ash/system_web_apps/apps/media_app/media_app_guest_ui_config.h"
#include "chrome/browser/ash/wallpaper_handlers/wallpaper_prefs.h"
#include "chrome/browser/chromeos/enterprise/cloud_storage/pref_utils.h"
#include "chrome/browser/chromeos/extensions/echo_private/echo_private_api_util.h"
@@ -430,6 +419,7 @@
#include "chrome/browser/chromeos/policy/dlp/dlp_rules_manager_impl.h"
#include "chrome/browser/chromeos/reporting/metric_reporting_prefs.h"
#include "chrome/browser/chromeos/upload_office_to_cloud/upload_office_to_cloud.h"
#include "chrome/browser/component_updater/metadata_table_chromeos.h"
#include "chrome/browser/device_identity/chromeos/device_oauth2_token_store_chromeos.h"
#include "chrome/browser/extensions/api/document_scan/profile_prefs_registry_util.h"
#include "chrome/browser/extensions/api/enterprise_platform_keys/enterprise_platform_keys_registry_util.h"
@@ -438,15 +428,19 @@
#include "chrome/browser/memory/oom_kills_monitor.h"
#include "chrome/browser/metrics/chromeos_metrics_provider.h"
#include "chrome/browser/policy/annotations/blocklist_handler.h"
#include "chrome/browser/ui/ash/projector/projector_app_client_impl.h"
#include "chrome/browser/ui/ash/shelf/chrome_shelf_prefs.h"
#include "chrome/browser/ui/webui/ash/edu_coexistence/edu_coexistence_login_handler.h"
#include "chrome/browser/ui/webui/ash/login/enable_debugging_screen_handler.h"
#include "chrome/browser/ui/webui/ash/settings/os_settings_ui.h"
#include "chrome/browser/ui/webui/certificates_handler.h"
#include "chrome/browser/ui/webui/settings/reset_settings_handler.h"
#include "chrome/browser/ui/webui/signin/ash/inline_login_handler_impl.h"
#include "chrome/browser/upgrade_detector/upgrade_detector_chromeos.h"
#include "chromeos/ash/components/audio/audio_devices_pref_handler_impl.h"
#include "chromeos/ash/components/boca/babelorca/babel_orca_manager.h"
#include "chromeos/ash/components/boca/on_task/on_task_prefs.h"
#include "chromeos/ash/components/carrier_lock/carrier_lock_manager.h"
#include "chromeos/ash/components/demo_mode/utils/demo_session_utils.h"
#include "chromeos/ash/components/local_search_service/search_metrics_reporter.h"
#include "chromeos/ash/components/network/cellular_esim_profile_handler_impl.h"
@@ -546,7 +540,7 @@
#include "components/enterprise/data_controls/core/browser/prefs.h"
#endif
#if BUILDFLAG(ENABLE_GLIC)
#if BUILDFLAG(ENABLE_GLIC) || BUILDFLAG(ENABLE_GLIC_ANDROID)
#include "chrome/browser/glic/glic_pref_names.h"
#endif
@@ -559,39 +553,6 @@ namespace {
// Please keep the list of deprecated prefs in chronological order. i.e. Add to
// the bottom of the list, not here at the top.
// Deprecated 12/2024.
inline constexpr char kDeleteTimePeriodV2[] =
"browser.clear_data.time_period_v2";
inline constexpr char kDeleteTimePeriodV2Basic[] =
"browser.clear_data.time_period_v2_basic";
#if BUILDFLAG(IS_CHROMEOS)
// Deprecated 12/2024
inline const char kCryptAuthDeviceSyncIsRecoveringFromFailure[] =
"cryptauth.device_sync.is_recovering_from_failure";
inline const char kCryptAuthDeviceSyncLastSyncTimeSeconds[] =
"cryptauth.device_sync.last_device_sync_time_seconds";
inline const char kCryptAuthDeviceSyncReason[] = "cryptauth.device_sync.reason";
inline const char kCryptAuthDeviceSyncUnlockKeys[] =
"cryptauth.device_sync.unlock_keys";
inline const char kCryptAuthEnrollmentIsRecoveringFromFailure[] =
"cryptauth.enrollment.is_recovering_from_failure";
inline const char kCryptAuthEnrollmentLastEnrollmentTimeSeconds[] =
"cryptauth.enrollment.last_enrollment_time_seconds";
inline const char kCryptAuthEnrollmentReason[] = "cryptauth.enrollment.reason";
inline const char kCryptAuthEnrollmentUserPublicKey[] =
"cryptauth.enrollment.user_public_key";
inline const char kCryptAuthEnrollmentUserPrivateKey[] =
"cryptauth.enrollment.user_private_key";
inline const char kLacrosLaunchOnLogin[] = "lacros.launch_on_login";
inline const char kLacrosLaunchSwitch[] = "lacros_launch_switch";
inline const char kLacrosSelection[] = "lacros_selection";
#endif
// Deprecated 12/2024.
inline constexpr char kPageContentCollectionEnabled[] =
"page_content_collection.enabled";
// Deprecated 01/2025.
inline constexpr char kCompactModeEnabled[] = "compact_mode";
@@ -929,15 +890,75 @@ const char kFpfRulesetFormat[] =
const char kFpfRulesetChecksum[] =
"fingerprinting_protection_filter.ruleset_version.checksum";
// Deprecated 12/2025.
const char kPrivacyBudgetGeneration[] = "privacy_budget.generation";
const char kPrivacyBudgetSeenSurfaces[] = "privacy_budget.seen";
const char kPrivacyBudgetSelectedOffsets[] = "privacy_budget.selected";
const char kPrivacyBudgetSelectedBlock[] = "privacy_budget.block_offset";
const char kPrivacyBudgetMetaExperimentActivationSalt[] =
"privacy_budget.meta_experiment_activation_salt";
// Preference key for Enterprise policy UserAgentReduction which is distinct
// from blink::features::kReduceUserAgentMinorVersion.
constexpr char kReduceUserAgentMinorVersion[] = "user_agent_reduction";
// Deprecated 12/2025.
constexpr char kAutofillStatesDataDir[] = "autofill.states_data_dir";
constexpr char kMerchantTrustUiLastInteractionTime[] =
"merchant_trust.ui.last_interaction_time";
constexpr char kMerchantTrustPageInfoLastOpenTime[] =
"merchant_trust.page_info.last_open_time";
// Deprecated 12/2025.
constexpr char kCloudPrintProxyEnabled[] = "cloud_print.enabled";
constexpr char kCloudPrintEmail[] = "cloud_print.email";
// Deprecated 12/2025.
constexpr char kTrackingProtectionEligibleSince[] =
"tracking_protection.tracking_protection_eligible_since";
constexpr char kTrackingProtectionOnboardedSince[] =
"tracking_protection.tracking_protection_onboarded_since";
constexpr char kTrackingProtectionNoticeLastShown[] =
"tracking_protection.tracking_protection_notice_last_shown";
constexpr char kTrackingProtectionOnboardingAckedSince[] =
"tracking_protection.tracking_protection_onboarding_acked_since";
constexpr char kTrackingProtectionOnboardingAcked[] =
"tracking_protection.tracking_protection_onboarding_acked";
constexpr char kTrackingProtectionOnboardingAckAction[] =
"tracking_protection.tracking_protection_onboarding_ack_action";
constexpr char kTrackingProtectionSilentEligibleSince[] =
"tracking_protection.tracking_protection_silent_eligible_since";
constexpr char kTrackingProtectionSilentOnboardedSince[] =
"tracking_protection.tracking_protection_silent_onboarded_since";
constexpr char kAllowAll3pcToggleEnabled[] =
"tracking_protection.allow_all_3pc_toggle_enabled";
constexpr char kTrackingProtectionLevel[] =
"tracking_protection.tracking_protection_level";
constexpr char kIpProtectionEnabled[] =
"tracking_protection.ip_protection_enabled";
constexpr char kIpProtectionInitializedByDogfood[] =
"tracking_protection.ip_protection_initialized_by_dogfood";
constexpr char kUserBypass3pcExceptionsMigrated[] =
"tracking_protection.user_bypass_3pc_exceptions_migrated";
constexpr char kTrackingProtectionSilentOnboardingStatus[] =
"tracking_protection.tracking_protection_silent_onboarding_status";
constexpr char kFingerprintingProtectionEnabled[] =
"tracking_protection.fingerprinting_protection_enabled";
constexpr char kTrackingProtectionOnboardingStatus[] =
"tracking_protection.tracking_protection_onboarding_status";
constexpr char kTPCDExperimentClientState[] = "tpcd_experiment.client_state";
constexpr char kTPCDExperimentClientStateVersion[] =
"tpcd_experiment.client_state_version";
constexpr char kTPCDExperimentProfileState[] = "tpcd_experiment.profile_state";
#if BUILDFLAG(IS_CHROMEOS)
// Deprecated 01/2026.
constexpr char kDeviceName[] = "device_name";
#endif // BUILDFLAG(IS_CHROMEOS)
// Register local state used only for migration (clearing or moving to a new
// key).
void RegisterLocalStatePrefsForMigration(PrefRegistrySimple* registry) {
#if BUILDFLAG(IS_CHROMEOS)
// Deprecated 12/2024.
registry->RegisterIntegerPref(kLacrosLaunchSwitch, 0);
registry->RegisterIntegerPref(kLacrosSelection, 0);
#endif
// Deprecated 02/2025.
registry->RegisterBooleanPref(kUserAgentClientHintsGREASEUpdateEnabled, true);
@@ -1017,6 +1038,45 @@ void RegisterLocalStatePrefsForMigration(PrefRegistrySimple* registry) {
registry->RegisterStringPref(kFpfRulesetContent, std::string());
registry->RegisterIntegerPref(kFpfRulesetFormat, 0);
registry->RegisterUint64Pref(kFpfRulesetChecksum, 0);
// Deprecated 12/2025.
registry->RegisterIntegerPref(kPrivacyBudgetGeneration, 0);
registry->RegisterStringPref(kPrivacyBudgetSeenSurfaces, std::string());
registry->RegisterStringPref(kPrivacyBudgetSelectedOffsets, std::string());
registry->RegisterIntegerPref(kPrivacyBudgetSelectedBlock, -1);
registry->RegisterDoublePref(kPrivacyBudgetMetaExperimentActivationSalt, 0);
// Deprecated 12/2025.
registry->RegisterStringPref(kAutofillStatesDataDir, std::string());
// Deprecated 12/2025.
registry->RegisterBooleanPref(kFingerprintingProtectionEnabled, false);
registry->RegisterBooleanPref(kIpProtectionEnabled, false);
registry->RegisterBooleanPref(kAllowAll3pcToggleEnabled, false);
registry->RegisterBooleanPref(kUserBypass3pcExceptionsMigrated, false);
registry->RegisterIntegerPref(kTrackingProtectionLevel, 0);
registry->RegisterTimePref(kTrackingProtectionSilentOnboardedSince,
base::Time());
registry->RegisterTimePref(kTrackingProtectionSilentEligibleSince,
base::Time());
registry->RegisterTimePref(kTrackingProtectionEligibleSince, base::Time());
registry->RegisterTimePref(kTrackingProtectionOnboardedSince, base::Time());
registry->RegisterTimePref(kTrackingProtectionNoticeLastShown, base::Time());
registry->RegisterTimePref(kTrackingProtectionOnboardingAckedSince,
base::Time());
registry->RegisterBooleanPref(kTrackingProtectionOnboardingAcked, false);
registry->RegisterIntegerPref(kTrackingProtectionOnboardingAckAction, 0);
registry->RegisterBooleanPref(kIpProtectionInitializedByDogfood, false);
registry->RegisterIntegerPref(kTrackingProtectionSilentOnboardingStatus, 0);
registry->RegisterIntegerPref(kTrackingProtectionOnboardingStatus, 0);
registry->RegisterIntegerPref(kTPCDExperimentClientState, 0);
registry->RegisterIntegerPref(kTPCDExperimentClientStateVersion, 0);
registry->RegisterIntegerPref(kTPCDExperimentProfileState, 0);
#if BUILDFLAG(IS_CHROMEOS)
// Deprecated 01/2026.
registry->RegisterStringPref(kDeviceName, "");
#endif // BUILDFLAG(IS_CHROMEOS)
}
// Register prefs used only for migration (clearing or moving to a new key).
@@ -1024,34 +1084,6 @@ void RegisterProfilePrefsForMigration(
user_prefs::PrefRegistrySyncable* registry) {
chrome_browser_net::secure_dns::RegisterProbesSettingBackupPref(registry);
// Deprecated 12/2024.
registry->RegisterIntegerPref(kDeleteTimePeriodV2, -1);
registry->RegisterIntegerPref(kDeleteTimePeriodV2Basic, -1);
#if BUILDFLAG(IS_CHROMEOS)
// Deprecated 12/2024
registry->RegisterDoublePref(kCryptAuthDeviceSyncLastSyncTimeSeconds, 0.0);
registry->RegisterBooleanPref(kCryptAuthDeviceSyncIsRecoveringFromFailure,
false);
registry->RegisterIntegerPref(kCryptAuthDeviceSyncReason,
cryptauth::INVOCATION_REASON_UNKNOWN);
registry->RegisterListPref(kCryptAuthDeviceSyncUnlockKeys);
registry->RegisterBooleanPref(kCryptAuthEnrollmentIsRecoveringFromFailure,
false);
registry->RegisterDoublePref(kCryptAuthEnrollmentLastEnrollmentTimeSeconds,
0.0);
registry->RegisterIntegerPref(kCryptAuthEnrollmentReason,
cryptauth::INVOCATION_REASON_UNKNOWN);
registry->RegisterStringPref(kCryptAuthEnrollmentUserPublicKey,
std::string());
registry->RegisterStringPref(kCryptAuthEnrollmentUserPrivateKey,
std::string());
registry->RegisterBooleanPref(kLacrosLaunchOnLogin, false);
#endif
// Deprecated 12/2024.
registry->RegisterBooleanPref(kPageContentCollectionEnabled, false);
// Deprecated 01/2025.
registry->RegisterBooleanPref(kCompactModeEnabled, false);
@@ -1277,6 +1309,15 @@ void RegisterProfilePrefsForMigration(
// Deprecated 11/2025.
registry->RegisterDictionaryPref(kRefreshHeuristicBreakageException);
// Deprecated 12/2025.
registry->RegisterBooleanPref(kReduceUserAgentMinorVersion, false);
registry->RegisterTimePref(kMerchantTrustUiLastInteractionTime, base::Time());
registry->RegisterTimePref(kMerchantTrustPageInfoLastOpenTime, base::Time());
// Deprecated 12/2025.
registry->RegisterBooleanPref(kCloudPrintProxyEnabled, true);
registry->RegisterStringPref(kCloudPrintEmail, std::string());
}
} // namespace
@@ -1359,7 +1400,6 @@ void RegisterLocalState(PrefRegistrySimple* registry) {
subresource_filter::IndexedRulesetVersion::RegisterPrefs(
registry, subresource_filter::kSafeBrowsingRulesetConfig.filter_tag);
SystemNetworkContextManager::RegisterPrefs(registry);
tpcd::experiment::RegisterLocalStatePrefs(registry);
tpcd::metadata::RegisterLocalStatePrefs(registry);
tracing::RegisterPrefs(registry);
update_client::RegisterPrefs(registry);
@@ -1392,7 +1432,7 @@ void RegisterLocalState(PrefRegistrySimple* registry) {
registry->RegisterIntegerPref(first_run::kTosDialogBehavior, 0);
registry->RegisterBooleanPref(lens::kLensCameraAssistedSearchEnabled, true);
#else // BUILDFLAG(IS_ANDROID)
#else // BUILDFLAG(IS_ANDROID)
gcm::RegisterPrefs(registry);
headless::RegisterPrefs(registry);
IntranetRedirectDetector::RegisterPrefs(registry);
@@ -1435,7 +1475,6 @@ void RegisterLocalState(PrefRegistrySimple* registry) {
ash::bluetooth_config::DeviceNameManagerImpl::RegisterLocalStatePrefs(
registry);
ash::demo_mode::RegisterLocalStatePrefs(registry);
ash::DeviceNameStore::RegisterLocalStatePrefs(registry);
ash::DozeModePowerStatusScheduler::RegisterLocalStatePrefs(registry);
chromeos::DeviceOAuth2TokenStoreChromeOS::RegisterPrefs(registry);
ash::device_settings_cache::RegisterPrefs(registry);
@@ -1562,6 +1601,11 @@ void RegisterLocalState(PrefRegistrySimple* registry) {
true);
#endif // BUILDFLAG(ENABLE_PDF)
#if BUILDFLAG(ENABLE_PDF_SAVE_TO_DRIVE)
registry->RegisterStringPref(
prefs::kRestrictPdfSaveToGoogleDriveAccountsToPattern, "");
#endif // BUILDFLAG(ENABLE_PDF_SAVE_TO_DRIVE)
#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || \
BUILDFLAG(IS_ANDROID)
registry->RegisterBooleanPref(prefs::kChromeForTestingAllowed, true);
@@ -1575,7 +1619,7 @@ void RegisterLocalState(PrefRegistrySimple* registry) {
registry->RegisterIntegerPref(prefs::kChromeDataRegionSetting, 0);
#if BUILDFLAG(ENABLE_GLIC)
#if BUILDFLAG(ENABLE_GLIC) || BUILDFLAG(ENABLE_GLIC_ANDROID)
glic::prefs::RegisterLocalStatePrefs(registry);
#endif
@@ -1621,7 +1665,7 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry,
enterprise_reporting::RegisterProfilePrefs(registry);
dom_distiller::DistilledPagePrefs::RegisterProfilePrefs(registry);
DownloadPrefs::RegisterProfilePrefs(registry);
#if BUILDFLAG(ENABLE_GLIC)
#if BUILDFLAG(ENABLE_GLIC) || BUILDFLAG(ENABLE_GLIC_ANDROID)
glic::prefs::RegisterProfilePrefs(registry);
#endif
permissions::PermissionHatsTriggerHelper::RegisterProfilePrefs(registry);
@@ -1639,7 +1683,6 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry,
media_device_salt::MediaDeviceIDSalt::RegisterProfilePrefs(registry);
MediaEngagementService::RegisterProfilePrefs(registry);
MediaStorageIdSalt::RegisterProfilePrefs(registry);
page_info::MerchantTrustService::RegisterProfilePrefs(registry);
metrics::RegisterDemographicsProfilePrefs(registry);
NotificationDisplayServiceImpl::RegisterProfilePrefs(registry);
NotifierStateTracker::RegisterProfilePrefs(registry);
@@ -1700,11 +1743,11 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry,
supervised_user::RegisterProfilePrefs(registry);
sync_sessions::SessionSyncPrefs::RegisterProfilePrefs(registry);
syncer::DeviceInfoPrefs::RegisterProfilePrefs(registry);
syncer::DeviceStatisticsTracker::RegisterProfilePrefs(registry);
syncer::SyncPrefs::RegisterProfilePrefs(registry);
syncer::SyncTransportDataPrefs::RegisterProfilePrefs(registry);
TemplateURLPrepopulateData::RegisterProfilePrefs(registry);
tab_groups::prefs::RegisterProfilePrefs(registry);
tpcd::experiment::RegisterProfilePrefs(registry);
translate::TranslatePrefs::RegisterProfilePrefs(registry);
visited_url_ranking::GroupSuggestionsServiceImpl::RegisterProfilePrefs(
registry);
@@ -1737,6 +1780,7 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry,
// were nested in either a class or separate namespace with a simple
// Register[Profile]Prefs() name.
extensions::RegisterSettingsOverriddenUiPrefs(registry);
ExtensionSettingsOverriddenDialog::RegisterProfilePrefs(registry);
#endif // BUILDFLAG(ENABLE_EXTENSIONS)
#if BUILDFLAG(ENABLE_PDF)
@@ -1774,7 +1818,7 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry,
usage_stats::UsageStatsBridge::RegisterProfilePrefs(registry);
variations::VariationsService::RegisterProfilePrefs(registry);
webapps::InstallPromptPrefs::RegisterProfilePrefs(registry);
#else // BUILDFLAG(IS_ANDROID)
#else // BUILDFLAG(IS_ANDROID)
bookmarks_webui::RegisterProfilePrefs(registry);
browser_sync::ForeignSessionHandler::RegisterProfilePrefs(registry);
BrowserUserEducationStorageService::RegisterProfilePrefs(registry);
@@ -2013,9 +2057,6 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry,
user_prefs::PrefRegistrySyncable::SYNCABLE_PREF);
#endif // !BUILDFLAG(IS_ANDROID)
registry->RegisterBooleanPref(
prefs::kManagedLocalNetworkAccessRestrictionsEnabled, false);
registry->RegisterBooleanPref(
prefs::kManagedLocalNetworkAccessRestrictionsTemporaryOptOut, false);
@@ -2049,8 +2090,8 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry,
// TODO(crbug.com/442891187): Move these to appropriate manager files when
// the policies logic is implemented.
registry->RegisterListPref(policy::policy_prefs::kIncognitoModeBlocklist);
registry->RegisterListPref(policy::policy_prefs::kIncognitoModeAllowlist);
registry->RegisterListPref(policy::policy_prefs::kIncognitoModeUrlBlocklist);
registry->RegisterListPref(policy::policy_prefs::kIncognitoModeUrlAllowlist);
registry->RegisterBooleanPref(
ntp_tiles::prefs::kTabResumptionHomeModuleEnabled, true);
@@ -2120,12 +2161,6 @@ void MigrateObsoleteLocalStatePrefs(PrefService* local_state) {
// BEGIN_MIGRATE_OBSOLETE_LOCAL_STATE_PREFS
// Please don't delete the preceding line. It is used by PRESUBMIT.py.
// Added 12/2024
#if BUILDFLAG(IS_CHROMEOS)
local_state->ClearPref(kLacrosLaunchSwitch);
local_state->ClearPref(kLacrosSelection);
#endif
// Added 02/2025.
local_state->ClearPref(kUserAgentClientHintsGREASEUpdateEnabled);
@@ -2208,6 +2243,42 @@ void MigrateObsoleteLocalStatePrefs(PrefService* local_state) {
local_state->ClearPref(kFpfRulesetFormat);
local_state->ClearPref(kFpfRulesetChecksum);
// Added 12/2025
local_state->ClearPref(kPrivacyBudgetGeneration);
local_state->ClearPref(kPrivacyBudgetSeenSurfaces);
local_state->ClearPref(kPrivacyBudgetSelectedOffsets);
local_state->ClearPref(kPrivacyBudgetSelectedBlock);
local_state->ClearPref(kPrivacyBudgetMetaExperimentActivationSalt);
// Added 12/2025
local_state->ClearPref(kAutofillStatesDataDir);
// Added 12/2025
local_state->ClearPref(kFingerprintingProtectionEnabled);
local_state->ClearPref(kIpProtectionEnabled);
local_state->ClearPref(kAllowAll3pcToggleEnabled);
local_state->ClearPref(kUserBypass3pcExceptionsMigrated);
local_state->ClearPref(kTrackingProtectionLevel);
local_state->ClearPref(kTrackingProtectionSilentOnboardedSince);
local_state->ClearPref(kTrackingProtectionSilentEligibleSince);
local_state->ClearPref(kTrackingProtectionEligibleSince);
local_state->ClearPref(kTrackingProtectionOnboardedSince);
local_state->ClearPref(kTrackingProtectionNoticeLastShown);
local_state->ClearPref(kTrackingProtectionOnboardingAckedSince);
local_state->ClearPref(kTrackingProtectionOnboardingAcked);
local_state->ClearPref(kTrackingProtectionOnboardingAckAction);
local_state->ClearPref(kIpProtectionInitializedByDogfood);
local_state->ClearPref(kTrackingProtectionSilentOnboardingStatus);
local_state->ClearPref(kTrackingProtectionOnboardingStatus);
local_state->ClearPref(kTPCDExperimentClientState);
local_state->ClearPref(kTPCDExperimentClientStateVersion);
local_state->ClearPref(kTPCDExperimentProfileState);
#if BUILDFLAG(IS_CHROMEOS)
// Added 01/2026.
local_state->ClearPref(kDeviceName);
#endif // BUILDFLAG(IS_CHROMEOS)
// Please don't delete the following line. It is used by PRESUBMIT.py.
// END_MIGRATE_OBSOLETE_LOCAL_STATE_PREFS
@@ -2269,27 +2340,6 @@ void MigrateObsoleteProfilePrefs(PrefService* profile_prefs,
MigrateDefaultBrowserLastDeclinedPref(profile_prefs);
#endif
// Added 12/2024.
profile_prefs->ClearPref(kDeleteTimePeriodV2);
profile_prefs->ClearPref(kDeleteTimePeriodV2Basic);
#if BUILDFLAG(IS_CHROMEOS)
// Deprecated 12/2024
profile_prefs->ClearPref(kCryptAuthDeviceSyncLastSyncTimeSeconds);
profile_prefs->ClearPref(kCryptAuthDeviceSyncIsRecoveringFromFailure);
profile_prefs->ClearPref(kCryptAuthDeviceSyncReason);
profile_prefs->ClearPref(kCryptAuthDeviceSyncUnlockKeys);
profile_prefs->ClearPref(kCryptAuthEnrollmentIsRecoveringFromFailure);
profile_prefs->ClearPref(kCryptAuthEnrollmentLastEnrollmentTimeSeconds);
profile_prefs->ClearPref(kCryptAuthEnrollmentReason);
profile_prefs->ClearPref(kCryptAuthEnrollmentUserPublicKey);
profile_prefs->ClearPref(kCryptAuthEnrollmentUserPrivateKey);
profile_prefs->ClearPref(kLacrosLaunchOnLogin);
#endif
// Added 12/2024.
profile_prefs->ClearPref(kPageContentCollectionEnabled);
#if !BUILDFLAG(IS_ANDROID)
// Added 01/2025.
password_manager::features_util::MigrateDefaultProfileStorePref(
@@ -2504,6 +2554,15 @@ void MigrateObsoleteProfilePrefs(PrefService* profile_prefs,
// Added 11/2025.
profile_prefs->ClearPref(kRefreshHeuristicBreakageException);
// Added 12/2025.
profile_prefs->ClearPref(kReduceUserAgentMinorVersion);
profile_prefs->ClearPref(kMerchantTrustUiLastInteractionTime);
profile_prefs->ClearPref(kMerchantTrustPageInfoLastOpenTime);
// Added 12/2025.
profile_prefs->ClearPref(kCloudPrintProxyEnabled);
profile_prefs->ClearPref(kCloudPrintEmail);
// Please don't delete the following line. It is used by PRESUBMIT.py.
// END_MIGRATE_OBSOLETE_PROFILE_PREFS
@@ -40,7 +40,6 @@
#include "chrome/browser/media/media_engagement_service.h"
#include "chrome/browser/metrics/desktop_session_duration/desktop_session_duration_observer.h"
#include "chrome/browser/navigation_predictor/navigation_predictor_preconnect_client.h"
#include "chrome/browser/net/http_auth_cache_status.h"
#include "chrome/browser/net/net_error_tab_helper.h"
#include "chrome/browser/optimization_guide/optimization_guide_keyed_service.h"
#include "chrome/browser/optimization_guide/optimization_guide_keyed_service_factory.h"
@@ -76,7 +75,6 @@
#include "chrome/browser/sync/sessions/sync_sessions_web_contents_router_factory.h"
#include "chrome/browser/tab_contents/navigation_metrics_recorder.h"
#include "chrome/browser/task_manager/web_contents_tags.h"
#include "chrome/browser/tpcd/heuristics/opener_heuristic_service.h"
#include "chrome/browser/tpcd/http_error_observer/http_error_tab_helper.h"
#include "chrome/browser/tpcd/metadata/devtools_observer.h"
#include "chrome/browser/translate/chrome_translate_client.h"
@@ -103,9 +101,6 @@
#include "chrome/common/chrome_features.h"
#include "chrome/common/chrome_isolated_world_ids.h"
#include "chrome/common/chrome_switches.h"
#include "components/autofill/content/browser/content_autofill_client.h"
#include "components/autofill/content/browser/content_autofill_driver_factory.h"
#include "components/autofill/core/browser/foundations/browser_autofill_manager.h"
#include "components/blocked_content/popup_blocker_tab_helper.h"
#include "components/blocked_content/popup_opener_tab_helper.h"
#include "components/breadcrumbs/core/breadcrumbs_status.h"
@@ -139,6 +134,7 @@
#include "components/permissions/permission_request_manager.h"
#include "components/safe_browsing/content/browser/async_check_tracker.h"
#include "components/safe_browsing/content/browser/safe_browsing_navigation_observer.h"
#include "components/safe_browsing/content/browser/ui_manager.h"
#include "components/safe_browsing/core/common/features.h"
#include "components/search/ntp_features.h"
#include "components/site_engagement/content/site_engagement_helper.h"
@@ -172,6 +168,7 @@
#include "chrome/browser/fast_checkout/fast_checkout_tab_helper.h"
#include "chrome/browser/flags/android/chrome_feature_list.h"
#include "chrome/browser/loader/from_gws_navigation_and_keep_alive_request_tab_helper.h"
#include "chrome/browser/net/http_auth_cache_status.h"
#include "chrome/browser/plugins/plugin_observer_android.h"
#include "chrome/browser/ui/android/context_menu_helper.h"
#include "chrome/browser/ui/javascript_dialogs/javascript_tab_modal_dialog_manager_delegate_android.h"
@@ -234,7 +231,6 @@
#if BUILDFLAG(ENABLE_EXTENSIONS)
#include "chrome/browser/extensions/app_tab_helper.h"
#include "chrome/browser/extensions/navigation_extension_enabler.h"
#include "chrome/browser/ui/extensions/extension_side_panel_utils.h"
#include "chrome/browser/web_applications/isolated_web_apps/window_management/window_management_content_setting_observer.h"
#include "chrome/browser/web_applications/policy/pre_redirection_url_observer.h"
@@ -245,6 +241,7 @@
#if BUILDFLAG(ENABLE_EXTENSIONS_CORE)
#include "chrome/browser/extensions/api/web_navigation/web_navigation_tab_observer.h"
#include "chrome/browser/extensions/navigation_extension_enabler.h"
#include "chrome/browser/extensions/tab_helper.h"
#include "extensions/browser/view_type_utils.h"
#endif
@@ -265,9 +262,6 @@
#if BUILDFLAG(ENABLE_COMPOSE)
#include "chrome/browser/compose/chrome_compose_client.h"
#include "chrome/browser/compose/compose_enabling.h"
#include "components/compose/buildflags.h"
#include "components/compose/core/browser/compose_features.h"
#endif
#if BUILDFLAG(ENABLE_RLZ)
@@ -467,7 +461,6 @@ void TabHelpers::AttachTabHelpers(WebContents* web_contents) {
MixedContentSettingsTabHelper::CreateForWebContents(web_contents);
NavigationMetricsRecorder::CreateForWebContents(web_contents);
NavigationPredictorPreconnectClient::CreateForWebContents(web_contents);
OpenerHeuristicService::Get(web_contents->GetBrowserContext());
if (optimization_guide::features::IsOptimizationHintsEnabled()) {
OptimizationGuideWebContentsObserver::CreateForWebContents(web_contents);
}
@@ -511,9 +504,7 @@ void TabHelpers::AttachTabHelpers(WebContents* web_contents) {
#if BUILDFLAG(IS_ANDROID)
nullptr;
#else
base::FeatureList::IsEnabled(features::kSideBySide)
? tabs::TabInterface::MaybeGetFromContents(web_contents)
: nullptr;
tabs::TabInterface::MaybeGetFromContents(web_contents);
#endif // BUILDFLAG(IS_ANDROID)
permissions::PermissionRequestManager::CreateForWebContents(
web_contents, desktop_tab_interface);
@@ -688,11 +679,7 @@ void TabHelpers::AttachTabHelpers(WebContents* web_contents) {
}
UMABrowsingActivityObserver::TabHelper::CreateForWebContents(web_contents);
web_modal::WebContentsModalDialogManager::CreateForWebContents(web_contents);
if (OmniboxFieldTrial::IsZeroSuggestPrefetchingEnabled() ||
omnibox_feature_configs::ContextualSearch::Get()
.IsEnabledWithPrefetch()) {
ZeroSuggestPrefetchTabHelper::CreateForWebContents(web_contents);
}
ZeroSuggestPrefetchTabHelper::CreateForWebContents(web_contents);
#endif // BUILDFLAG(IS_ANDROID)
#if BUILDFLAG(ENABLE_COMPOSE)
@@ -733,11 +720,7 @@ void TabHelpers::AttachTabHelpers(WebContents* web_contents) {
features::kHappinessTrackingSurveysForDesktopDemo) ||
base::FeatureList::IsEnabled(features::kTrustSafetySentimentSurvey) ||
base::FeatureList::IsEnabled(features::kTrustSafetySentimentSurveyV2) ||
PerformanceControlsHatsServiceFactory::IsAnySurveyFeatureEnabled() ||
base::FeatureList::IsEnabled(
page_info::kMerchantTrustEvaluationControlSurvey) ||
base::FeatureList::IsEnabled(
page_info::kMerchantTrustEvaluationExperimentSurvey)) {
PerformanceControlsHatsServiceFactory::IsAnySurveyFeatureEnabled()) {
HatsHelper::CreateForWebContents(web_contents);
}
SharedHighlightingPromo::CreateForWebContents(web_contents);
@@ -772,13 +755,13 @@ void TabHelpers::AttachTabHelpers(WebContents* web_contents) {
#if BUILDFLAG(ENABLE_EXTENSIONS)
extensions::AppTabHelper::CreateForWebContents(web_contents);
extensions::NavigationExtensionEnabler::CreateForWebContents(web_contents);
web_app::WindowManagementContentSettingObserver::CreateForWebContents(
web_contents);
#endif
#if BUILDFLAG(ENABLE_EXTENSIONS_CORE)
// These helpers are used on Win/Mac/Linux and also desktop Android.
extensions::NavigationExtensionEnabler::CreateForWebContents(web_contents);
extensions::WebNavigationTabObserver::CreateForWebContents(web_contents);
extensions::TabHelper::CreateForWebContents(web_contents);
#endif
@@ -473,7 +473,7 @@ namespace autofillPrivate {
callback GetAutofillAiOptInStatusCallback = void(boolean optedIn);
callback SetAutofillAiOptInStatusCallback = void(boolean success);
callback GetWalletablePassDetectionOptInStatusCallback = void(boolean optedIn);
callback SetWalletablePassDetectionOptInStatusCallback = void();
callback SetWalletablePassDetectionOptInStatusCallback = void(boolean success);
callback GetPayOverTimeIssuerListCallback = void(PayOverTimeIssuerEntry[] entries);
interface Functions {
@@ -265,9 +265,10 @@ namespace certificateProvider {
// It's the extension's responsibility to try again later if another flow is
// in progress.
// |details|: Contains the details about the requested dialog.
// |callback|: Is called when the dialog is resolved with the user input, or
// when the dialog request finishes unsuccessfully (e.g. the dialog was
// canceled by the user or was not allowed to be shown).
// |callback|: Returns a Promise which resolves when the PIN is provided by
// the user. Rejects with an error if the dialog request finishes
// unsuccessfully (e.g. the dialog was canceled by the user or was not
// allowed to be shown).
static void requestPin(
RequestPinDetails details,
RequestPinCallback callback);
@@ -275,8 +276,8 @@ namespace certificateProvider {
// Stops the pin request started by the $(ref:requestPin) function.
// |details|: Contains the details about the reason for stopping the
// request flow.
// |callback|: To be used by Chrome to send to the extension the status from
// their request to close PIN dialog for user.
// |callback|: Returns a Promise which resolves when the request to close
// the PIN dialog is complete.
static void stopPinRequest(
StopPinRequestDetails details,
StopPinRequestCallback callback);
@@ -288,7 +289,7 @@ namespace certificateProvider {
// $(ref:onCertificatesUpdateRequested) every time this event is
// received.</p>
// |details|: The certificates to set. Invalid certificates will be ignored.
// |callback|: Called upon completion.
// |callback|: Returns a Promise which resolves upon completion.
static void setCertificates(
SetCertificatesDetails details,
optional SetCertificatesCallback callback);
@@ -549,7 +549,7 @@ namespace documentScan {
// with a $(ref:ScanResults) object. If a callback is passed to
// this function, the returned data is passed to it instead.
// |options| : An object containing scan parameters.
// |callback| : Called with the result and data from the scan.
// |callback| : Returns a Promise which resolves with the scan results.
static void scan(
ScanOptions options,
ScanCallback callback);
@@ -559,7 +559,8 @@ namespace documentScan {
// is passed to this function, returned data is passed to it instead.
// |filter| : A $(ref:DeviceFilter) indicating which types of scanners
// should be returned.
// |callback| : Called with the result and list of scanners.
// |callback| : Returns a Promise which resolves with the result and list of
// scanners.
static void getScannerList(
DeviceFilter filter, GetScannerListCallback callback);
@@ -568,7 +569,7 @@ namespace documentScan {
// is passed to this function, returned data is passed to it instead.
// |scannerId| : The ID of a scanner to be opened. This value is one
// returned from a previous call to $(ref:getScannerList).
// |callback| : Called with the result.
// |callback| : Returns a Promise which resolves with the result.
static void openScanner(
DOMString scannerId, OpenScannerCallback callback);
@@ -578,7 +579,7 @@ namespace documentScan {
// is passed to this function, returned data is passed to it instead.
// |scannerHandle| : The handle of an open scanner returned from a call
// to $(ref:openScanner).
// |callback| : Called with the result.
// |callback| : Returns a Promise which resolves with the result.
static void getOptionGroups(
DOMString scannerHandle, GetOptionGroupsCallback callback);
@@ -589,7 +590,7 @@ namespace documentScan {
// used for further operations.
// |scannerHandle| : Specifies the handle of an open scanner that was
// previously returned from a call to $(ref:openScanner).
// |callback| : Called with the result.
// |callback| : Returns a Promise which resolves with the result.
static void closeScanner(
DOMString scannerHandle, CloseScannerCallback callback);
@@ -602,7 +603,7 @@ namespace documentScan {
// should be a value previously returned from a call to $(ref:openScanner).
// |options| : A list of <code>OptionSetting</code> objects to be applied to
// the scanner.
// |callback| : Called with the result.
// |callback| : Returns a Promise which resolves with the result.
static void setOptions(
DOMString scannerHandle, OptionSetting[] options,
SetOptionsCallback callback);
@@ -618,7 +619,7 @@ namespace documentScan {
// be used for the scan. The <code>StartScanOptions.format</code> property
// must match one of the entries returned in the scanner's
// <code>ScannerInfo</code>.
// |callback| : Called with the result.
// |callback| : Returns a Promise which resolves with the result.
static void startScan(
DOMString scannerHandle, StartScanOptions options,
StartScanCallback callback);
@@ -628,7 +629,7 @@ namespace documentScan {
// is passed to it instead.
// |job| : The handle of an active scan job previously returned from a
// call to $(ref:startScan).
// |callback| : Called with the result.
// |callback| : Returns a Promise which resolves with the result.
static void cancelScan(
DOMString job, CancelScanCallback callback);
@@ -647,7 +648,7 @@ namespace documentScan {
//
// |job| : Active job handle previously returned from
// $(ref:startScan).
// |callback| : Called with the result.
// |callback| : Returns a Promise which resolves with the result.
static void readScanData(
DOMString job, ReadScanDataCallback callback);
};
@@ -467,7 +467,8 @@ namespace downloads {
// a descriptive string. The error strings are not guaranteed to remain
// backwards compatible between releases. Extensions must not parse it.
// |options|: What to download and how.
// |callback|: Called with the id of the new $(ref:DownloadItem).
// |callback|: Returns a Promise which resolves with the id of the new
// $(ref:DownloadItem).
static void download(
DownloadOptions options,
optional DownloadCallback callback);
@@ -486,7 +487,8 @@ namespace downloads {
// paused state. Otherwise $(ref:runtime.lastError) contains an error message.
// The request will fail if the download is not active.
// |downloadId|: The id of the download to pause.
// |callback|: Called when the pause request is completed.
// |callback|: Returns a Promise which resolves when the pause request is
// completed.
static void pause(
long downloadId,
optional NullCallback callback);
@@ -495,7 +497,8 @@ namespace downloads {
// in progress and unpaused. Otherwise $(ref:runtime.lastError) contains an
// error message. The request will fail if the download is not active.
// |downloadId|: The id of the download to resume.
// |callback|: Called when the resume request is completed.
// |callback|: Returns a Promise which resolves when the resume request is
// completed.
static void resume(
long downloadId,
optional NullCallback callback);
@@ -503,7 +506,8 @@ namespace downloads {
// Cancel a download. When <code>callback</code> is run, the download is
// cancelled, completed, interrupted or doesn't exist anymore.
// |downloadId|: The id of the download to cancel.
// |callback|: Called when the cancel request is completed.
// |callback|: Returns a Promise which resolves when the cancel request is
// completed.
static void cancel(
long downloadId,
optional NullCallback callback);
@@ -518,7 +522,8 @@ namespace downloads {
// registered file types and visual theme. If a file icon cannot be
// determined, $(ref:runtime.lastError) will contain an error message.
// |downloadId|: The identifier for the download.
// |callback|: A URL to an image that represents the download.
// |callback|: Returns a Promise which resolves with a URL to an image that
// represents the download.
static void getFileIcon(
long downloadId,
optional GetFileIconOptions options,
@@ -564,7 +569,8 @@ namespace downloads {
// temporary file is renamed to the target filename, the |state| changes to
// 'complete', and $(ref:onChanged) fires.
// |downloadId|: The identifier for the $(ref:DownloadItem).
// |callback|: Called when the danger prompt dialog closes.
// |callback|: Returns a Promise which resolves when the danger prompt
// dialog closes.
static void acceptDanger(
long downloadId,
optional NullCallback callback);
@@ -586,7 +592,8 @@ namespace downloads {
// $(ref:runtime.lastError). Requires the <code>"downloads.ui"</code>
// permission in addition to the <code>"downloads"</code> permission.
// |options|: Encapsulate a change to the download UI.
// |callback|: Called when the UI update is completed.
// |callback|: Returns a Promise which resolves when the UI update is
// completed.
static void setUiOptions(
UiOptions options,
optional NullCallback callback);
@@ -23,8 +23,8 @@ namespace enterprise.deviceAttributes {
// that is generated by the server and identifies the cloud record of the
// device for querying in the cloud directory API.
// If the current user is not affiliated, returns an empty string.
// |callback| : Called with the device identifier of the directory API when
// received.
// |callback| : Returns a Promise which resolves with the device identifier
// of the directory API.
void getDirectoryDeviceId(
GetDirectoryDeviceIdCallback callback);
@@ -33,27 +33,31 @@ namespace enterprise.deviceAttributes {
// for device-wide certificates). This API may not be used for tracking
// devices without the consent of the device's administrator.
// If the current user is not affiliated, returns an empty string.
// |callback| : Called with the serial number of the device.
// |callback| : Returns a Promise which resolves with the serial number of
// the device.
void getDeviceSerialNumber(
GetDeviceSerialNumberCallback callback);
// Fetches the administrator-annotated Asset Id.
// If the current user is not affiliated or no Asset Id has been set by the
// administrator, returns an empty string.
// |callback| : Called with the Asset ID of the device.
// |callback| : Returns a Promise which resolves with the Asset ID of the
// device.
void getDeviceAssetId(GetDeviceAssetIdCallback callback);
// Fetches the administrator-annotated Location.
// If the current user is not affiliated or no Annotated Location has been
// set by the administrator, returns an empty string.
// |callback| : Called with the Annotated Location of the device.
// |callback| : Returns a Promise which resolves with the Annotated
// Location of the device.
void getDeviceAnnotatedLocation(
GetDeviceAnnotatedLocationCallback callback);
// Fetches the device's hostname as set by DeviceHostnameTemplate policy.
// If the current user is not affiliated or no hostname has been set by the
// enterprise policy, returns an empty string.
// |callback| : Called with hostname of the device.
// |callback| : Returns a Promise which resolves with the hostname of the
// device.
void getDeviceHostname(
GetDeviceHostnameCallback callback);
};
@@ -17,7 +17,8 @@ namespace enterprise.hardwarePlatform {
interface Functions {
// Obtains the manufacturer and model for the hardware platform and, if
// the extension is authorized, returns it via |callback|.
// |callback|: Called with the hardware platform info.
// |callback|: Returns a Promise which resolves with the hardware platform
// info.
static void getHardwarePlatformInfo(
HardwarePlatformInfoCallback callback);
};
@@ -26,8 +26,8 @@ namespace enterprise.kioskInput {
// $(ref:runtime.lastError) will be set with a failure reason.
// |options|: Object containing the fields defined in
// $(ref:SetCurrentInputMethodOptions).
// |callback|: Called when the input method is changed or if
// there is an error.
// |callback|: Returns a Promise which resolves when the input method is
// changed, or rejects if there is an error.
static void setCurrentInputMethod(
SetCurrentInputMethodOptions options,
SetCurrentInputMethodCallback callback);
@@ -26,8 +26,8 @@ namespace enterprise.networkingAttributes {
// Retrieves the network details of the device's default network.
// If the user is not affiliated or the device is not connected to a
// network, $(ref:runtime.lastError) will be set with a failure reason.
// |callback| : Called with the device's default network's
// $(ref:NetworkDetails).
// |callback| : Returns a Promise which resolves with the device's default
// network's $(ref:NetworkDetails).
void getNetworkDetails(
GetNetworkDetailsCallback callback);
};
@@ -115,7 +115,8 @@ namespace enterprise.platformKeys {
// token. Can be used to check for the existence and expiration of client
// certificates that are usable for a certain authentication.
// |tokenId|: The id of a Token returned by <code>getTokens</code>.
// |callback|: Called back with the list of the available certificates.
// |callback|: Returns a Promise which resolves with the list of the
// available certificates.
static void getCertificates(DOMString tokenId,
GetCertificatesCallback callback);
@@ -126,7 +127,8 @@ namespace enterprise.platformKeys {
// system and browser for authentication.
// |tokenId|: The id of a Token returned by <code>getTokens</code>.
// |certificate|: The DER encoding of a X.509 certificate.
// |callback|: Called back when this operation is finished.
// |callback|: Returns a Promise which resolves when this operation is
// finished.
static void importCertificate(DOMString tokenId,
ArrayBuffer certificate,
optional DoneCallback callback);
@@ -137,7 +139,8 @@ namespace enterprise.platformKeys {
// choice. Should be used to free storage in the certificate store.
// |tokenId|: The id of a Token returned by <code>getTokens</code>.
// |certificate|: The DER encoding of a X.509 certificate.
// |callback|: Called back when this operation is finished.
// |callback|: Returns a Promise which resolves when this operation is
// finished.
static void removeCertificate(DOMString tokenId,
ArrayBuffer certificate,
optional DoneCallback callback);
@@ -167,7 +170,7 @@ namespace enterprise.platformKeys {
// <code>"user"</code> token and is not accessible by any other API.
// |options|: Object containing the fields defined in
// $(ref:ChallengeKeyOptions).
// |callback|: Called back with the challenge response.
// |callback|: Returns a Promise which resolves with the challenge response.
static void challengeKey(ChallengeKeyOptions options,
ChallengeCallback callback);
@@ -199,7 +202,7 @@ namespace enterprise.platformKeys {
// signing key. This key is 2048-bit RSA. Subsequent calls
// to this function will then generate a new Enterprise
// Machine Key.
// |callback|: Called back with the challenge response.
// |callback|: Returns a Promise which resolves with the challenge response.
[deprecated="Use $(ref:challengeKey) instead."]
static void challengeMachineKey(ArrayBuffer challenge,
optional boolean registerKey,
@@ -232,7 +235,7 @@ namespace enterprise.platformKeys {
// with a certificate and used like any other signing key.
// This key is 2048-bit RSA. Subsequent calls to this
// function will then generate a new Enterprise User Key.
// |callback|: Called back with the challenge response.
// |callback|: Returns a Promise which resolves with the challenge response.
[deprecated="Use $(ref:challengeKey) instead."]
static void challengeUserKey(ArrayBuffer challenge,
boolean registerKey,
@@ -100,13 +100,6 @@ enum FormatFileSystemType { vfat, exfat, ntfs };
// File transfer progress state.
enum TransferState { in_progress, queued, completed, failed };
// The response when starting installing a Linux package.
enum InstallLinuxPackageStatus {
started,
failed,
install_already_active
};
// Specifies type of event that is raised.
enum FileWatchEventType { changed, error };
@@ -997,17 +990,6 @@ dictionary FileSystemProviderAction {
DOMString? title;
};
// Information about a Linux package in response to GetLinuxPackageInfo.
dictionary LinuxPackageInfo {
DOMString name;
DOMString version;
// A one-line summary of the project. Almost always present.
DOMString? summary;
// A longer description of the project. Almost always present.
DOMString? description;
};
// Payload data for crostini event.
dictionary CrostiniEvent {
// Is the event raised for enable, disable, share, or unshare.
@@ -1510,12 +1492,6 @@ callback GetVolumeRootCallback =
callback GetCrostiniSharedPathsCallback =
void(CrostiniSharedPathResponse response);
// |linux_package_info| Package info for the queried package.
callback GetLinuxPackageInfoCallback =
void(LinuxPackageInfo linux_package_info);
callback InstallLinuxPackageCallback = void(InstallLinuxPackageStatus status);
// |apps| List of Android picker apps.
callback GetAndroidPickerAppsCallback = void(AndroidApp[] apps);
@@ -1931,16 +1907,6 @@ interface Functions {
DOMString vmName,
GetCrostiniSharedPathsCallback callback);
// Requests information about a Linux package. |entry| is a .deb file.
[nocompile, doesNotSupportPromises]
static void getLinuxPackageInfo([instanceOf=Entry] object entry,
GetLinuxPackageInfoCallback callback);
// Starts installation of a Linux package.
[nocompile, doesNotSupportPromises]
static void installLinuxPackage([instanceOf=Entry] object entry,
InstallLinuxPackageCallback callback);
// Imports a Crostini Image File (.tini). This overrides the existing Linux
// apps and files.
[nocompile]
@@ -61,10 +61,6 @@ namespace fileManagerPrivateInternal {
callback GetRecentFilesCallback = void(EntryDescription[] entries);
callback GetCrostiniSharedPathsCallback =
void(CrostiniSharedPathResponse response);
callback GetLinuxPackageInfoCallback =
void(fileManagerPrivate.LinuxPackageInfo linux_package_info);
callback InstallLinuxPackageCallback =
void(fileManagerPrivate.InstallLinuxPackageStatus status);
callback GetThumbnailCallback = void(DOMString ThumbnailDataUrl);
callback BooleanCallback = void(boolean result);
callback GetVolumeRootCallback = void(EntryDescription rootDir);
@@ -158,12 +154,6 @@ namespace fileManagerPrivateInternal {
boolean observeFirstForSession,
DOMString vmName,
GetCrostiniSharedPathsCallback callback);
static void getLinuxPackageInfo(
DOMString url,
GetLinuxPackageInfoCallback callback);
static void installLinuxPackage(
DOMString url,
InstallLinuxPackageCallback callback);
static void importCrostiniImage(DOMString url);
static void toggleAddedToHoldingSpace(
DOMString[] urls, boolean add,
@@ -154,8 +154,8 @@ namespace identity {
// the callback.
//
// |details| : Token options.
// |callback| : Called with an OAuth2 access token as specified by the
// manifest, or undefined if there was an error. The
// |callback| : Returns a Promise which resolves with an OAuth2 access token
// as specified by the manifest, or rejects if there was an error. The
// <code>grantedScopes</code> parameter is populated since Chrome 87. When
// available, this parameter contains the list of granted scopes
// corresponding with the returned token.
@@ -174,9 +174,10 @@ namespace identity {
// only applies to the primary account for the profile.
//
// |details|: Profile options.
// |callback|: Called with the <code>ProfileUserInfo</code> of the primary
// Chrome account, of an empty <code>ProfileUserInfo</code> if the account
// with given <code>details</code> doesn't exist.
// |callback|: Returns a Promise which resolves with the
// <code>ProfileUserInfo</code> of the primary Chrome account, or an empty
// <code>ProfileUserInfo</code> if the account with given
// <code>details</code> doesn't exist.
static void getProfileUserInfo(
optional ProfileDetails details,
GetProfileUserInfoCallback callback);
@@ -189,7 +190,8 @@ namespace identity {
// <code>getAuthToken</code>.
//
// |details| : Token information.
// |callback| : Called when the token has been removed from the cache.
// |callback| : Returns a Promise which resolves when the token has been
// removed from the cache.
static void removeCachedAuthToken(
InvalidTokenDetails details,
optional InvalidateAuthTokenCallback callback);
@@ -201,7 +203,8 @@ namespace identity {
// <li>De-authorizes the user from all auth flows</li>
// </ul>
//
// |callback| : Called when the state has been cleared.
// |callback| : Returns a Promise which resolves when the state has been
// cleared.
static void clearAllCachedAuthTokens(
ClearAllCachedAuthTokensCallback callback);
@@ -222,7 +225,8 @@ namespace identity {
// when your app is first launched.
//
// |details| : WebAuth flow options.
// |callback| : Called with the URL redirected back to your application.
// |callback| : Returns a Promise which resolves with the URL redirected
// back to your application.
static void launchWebAuthFlow(
WebAuthFlowDetails details,
LaunchWebAuthFlowCallback callback);
@@ -153,10 +153,9 @@ namespace notifications {
//
// The <code>notificationId</code> parameter is required before Chrome 42.
// |options|: Contents of the notification.
// |callback|: Returns the notification id (either supplied or generated)
// that represents the created notification.
//
// The callback is required before Chrome 42.
// |callback|: Returns a Promise which resolves with the notification id
// (either supplied or generated) that represents the created
// notification.
static void create(
optional DOMString notificationId,
NotificationOptions options,
@@ -166,9 +165,8 @@ namespace notifications {
// |notificationId|: The id of the notification to be updated. This is
// returned by $(ref:notifications.create) method.
// |options|: Contents of the notification to update to.
// |callback|: Called to indicate whether a matching notification existed.
//
// The callback is required before Chrome 42.
// |callback|: Returns a Promise which resolves to indicate whether a
// matching notification existed.
static void update(
DOMString notificationId,
NotificationOptions options,
@@ -177,20 +175,21 @@ namespace notifications {
// Clears the specified notification.
// |notificationId|: The id of the notification to be cleared. This is
// returned by $(ref:notifications.create) method.
// |callback|: Called to indicate whether a matching notification existed.
//
// The callback is required before Chrome 42.
// |callback|: Returns a Promise which resolves to indicate whether a
// matching notification existed.
static void clear(
DOMString notificationId,
optional ClearCallback callback);
// Retrieves all the notifications of this app or extension.
// |callback|: Returns the set of notification_ids currently in the system.
// |callback|: Returns a Promise which resolves with the set of
// notification_ids currently in the system.
static void getAll(GetAllCallback callback);
// Retrieves whether the user has enabled notifications from this app
// or extension.
// |callback|: Returns the current permission level.
// |callback|: Returns a Promise which resolves with the current permission
// level.
static void getPermissionLevel(
PermissionLevelCallback callback);
};
@@ -190,9 +190,9 @@ namespace scripting {
// the script evaluates to a promise, the browser will wait for the promise to
// settle and return the resulting value.
// |injection|: The details of the script which to inject.
// |callback|: Invoked upon completion of the injection. The resulting
// array contains the result of execution for each frame where the
// injection succeeded.
// |callback|: Returns a Promise which resolves upon completion of the
// injection. The resulting array contains the result of execution for each
// frame where the injection succeeded.
static void executeScript(
ScriptInjection injection,
optional ScriptInjectionCallback callback);
@@ -200,7 +200,8 @@ namespace scripting {
// Inserts a CSS stylesheet into a target context.
// If multiple frames are specified, unsuccessful injections are ignored.
// |injection|: The details of the styles to insert.
// |callback|: Invoked upon completion of the insertion.
// |callback|: Returns a Promise which resolves upon completion of the
// insertion.
static void insertCSS(
CSSInjection injection,
optional CSSInjectionCallback callback);
@@ -211,7 +212,8 @@ namespace scripting {
// <code>css</code>, <code>files</code>, and <code>origin</code> properties
// must exactly match the stylesheet inserted through $(ref:insertCSS).
// Attempting to remove a non-existent stylesheet is a no-op.
// |callback|: A callback to be invoked upon the completion of the removal.
// |callback|: Returns a Promise which resolves upon the completion of the
// removal.
static void removeCSS(
CSSInjection injection,
optional CSSInjectionCallback callback);
@@ -220,8 +222,8 @@ namespace scripting {
// |scripts|: Contains a list of scripts to be registered. If there are
// errors during script parsing/file validation, or if the IDs specified
// already exist, then no scripts are registered.
// |callback|: A callback to be invoked once scripts have been fully
// registered or if an error has occurred.
// |callback|: Returns a Promise which resolves once scripts have been
// fully registered or rejects if an error has occurred.
static void registerContentScripts(
RegisteredContentScript[] scripts,
optional RegisterContentScriptsCallback callback);
@@ -238,8 +240,8 @@ namespace scripting {
// |filter|: If specified, only unregisters dynamic content scripts which
// match the filter. Otherwise, all of the extension's dynamic content
// scripts are unregistered.
// |callback|: A callback to be invoked once scripts have been unregistered
// or if an error has occurred.
// |callback|: Returns a Promise which resolves once scripts have been
// unregistered or rejects if an error has occurred.
static void unregisterContentScripts(
optional ContentScriptFilter filter,
optional UnregisterContentScriptsCallback callback);
@@ -250,8 +252,8 @@ namespace scripting {
// there are errors during script parsing/file validation, or if the IDs
// specified do not correspond to a fully registered script, then no scripts
// are updated.
// |callback|: A callback to be invoked once scripts have been updated or
// if an error has occurred.
// |callback|: Returns a Promise which resolves once scripts have been
// updated or rejects if an error has occurred.
static void updateContentScripts(
RegisteredContentScript[] scripts,
optional RegisterContentScriptsCallback callback);
@@ -11,7 +11,7 @@ namespace sidePanel {
};
dictionary ManifestKeys {
SidePanel side_panel;
SidePanel? side_panel;
};
// Defines the possible alignment for the side panel in the browser UI.
@@ -132,14 +132,16 @@ namespace sidePanel {
interface Functions {
// Configures the side panel.
// |options|: The configuration options to apply to the panel.
// |callback|: Invoked when the options have been set.
// |callback|: Returns a Promise which resolves when the options have been
// set.
static void setOptions(
PanelOptions options,
optional VoidCallback callback);
// Returns the active panel configuration.
// |options|: Specifies the context to return the configuration for.
// |callback|: Called with the active panel configuration.
// |callback|: Returns a Promise which resolves with the active panel
// configuration.
static void getOptions(
GetPanelOptions options,
PanelOptionsCallback callback);
@@ -147,32 +149,36 @@ namespace sidePanel {
// Configures the extension's side panel behavior. This is an upsert
// operation.
// |behavior|: The new behavior to be set.
// |callback|: Called when the new behavior has been set.
// |callback|: Returns a Promise which resolves when the new behavior has
// been set.
static void setPanelBehavior(
PanelBehavior behavior,
optional VoidCallback callback);
// Returns the extension's current side panel behavior.
// |callback|: Called with the extension's side panel behavior.
// |callback|: Returns a Promise which resolves with the extension's side
// panel behavior.
static void getPanelBehavior(
PanelBehaviorCallback callback);
// Opens the side panel for the extension.
// This may only be called in response to a user action.
// |options|: Specifies the context in which to open the side panel.
// |callback|: Called when the side panel has been opened.
// |callback|: Returns a Promise which resolves when the side panel has been
// opened.
static void open(
OpenOptions options,
VoidCallback callback);
// Returns the side panel's current layout.
// |callback|: Called with a $(ref:PanelLayout) containing the side value.
// |callback|: Returns a Promise which resolves with a $(ref:PanelLayout).
static void getLayout(PanelLayoutCallback callback);
// Closes the extension's side panel.
// This is a no-op if the panel is already closed.
// |options|: Specifies the context in which to close the side panel.
// |callback|: Called when the side panel has been closed.
// |callback|: Returns a Promise which resolves when the side panel has been
// closed.
[nodoc] static void close(
CloseOptions options,
VoidCallback callback);
@@ -18,7 +18,8 @@ namespace systemLog {
interface Functions {
// Adds a new log record.
// |options|: The logging options.
// |callback|: A callback to invoke once the log has been added.
// |callback|: Returns a Promise which resolves once the log has been
// added.
static void add(
MessageOptions options,
optional VoidCallback callback);
@@ -100,7 +100,8 @@ namespace tabCapture {
// This allows extensions to inform the user that there is an existing
// tab capture that would prevent a new tab capture from succeeding (or
// to prevent redundant requests for the same tab).
// |callback| : Callback invoked with CaptureInfo[] for captured tabs.
// |callback| : Returns a Promise which resolves with CaptureInfo[] for
// captured tabs.
static void getCapturedTabs(
GetCapturedTabsCallback callback);
@@ -109,8 +110,8 @@ namespace tabCapture {
// stream ID, instead of a media stream, to the consumer tab.
//
// |GetMediaStreamOptions| : Options for the media stream id to retrieve.
// |callback| : Callback to invoke with the result. If successful, the
// result is an opaque string that can be passed to the
// |callback| : Returns a Promise which resolves with the result. If
// successful, the result is an opaque string that can be passed to the
// <code>getUserMedia()</code> API to generate a media stream that
// corresponds to the target tab. The created <code>streamId</code> can
// only be used once and expires after a few seconds if it is not used.
@@ -121,16 +121,16 @@ namespace vpnProvider {
// Creates a new VPN configuration that persists across multiple login
// sessions of the user.
// |name|: The name of the VPN configuration.
// |callback|: Called when the configuration is created or if there is an
// error.
// |callback|: Returns a Promise which resolves when the configuration is
// created or rejects if there is an error.
static void createConfig(
DOMString name,
CreateConfigCompleteCallback callback);
// Destroys a VPN configuration created by the extension.
// |id|: ID of the VPN configuration to destroy.
// |callback|: Called when the configuration is destroyed or if there is an
// error.
// |callback|: Returns a Promise which resolves when the configuration is
// destroyed or rejects if there is an error.
static void destroyConfig(
DOMString id,
optional CallCompleteCallback callback);
@@ -139,7 +139,8 @@ namespace vpnProvider {
// immediately after <code>"connected"</code> is received from the platform.
// This will succeed only when the VPN session is owned by the extension.
// |parameters|: The parameters for the VPN session.
// |callback|: Called when the parameters are set or if there is an error.
// |callback|: Returns a Promise which resolves when the parameters are set
// or rejects if there is an error.
static void setParameters(
Parameters parameters,
CallCompleteCallback callback);
@@ -147,7 +148,8 @@ namespace vpnProvider {
// Sends an IP packet through the tunnel created for the VPN session.
// This will succeed only when the VPN session is owned by the extension.
// |data|: The IP packet to be sent to the platform.
// |callback|: Called when the packet is sent or if there is an error.
// |callback|: Returns a Promise which resolves when the packet is sent or
// rejects if there is an error.
static void sendPacket(
ArrayBuffer data,
optional CallCompleteCallback callback);
@@ -155,8 +157,8 @@ namespace vpnProvider {
// Notifies the VPN session state to the platform.
// This will succeed only when the VPN session is owned by the extension.
// |state|: The VPN session state of the VPN client.
// |callback|: Called when the notification is complete or if there is an
// error.
// |callback|: Returns a Promise which resolves when the notification is
// complete or rejects if there is an error.
static void notifyConnectionStateChanged(
VpnConnectionState state,
optional CallCompleteCallback callback);
@@ -814,9 +814,7 @@ bool ChromeContentRendererClient::IsPluginHandledExternally(
// necessary here (see https://crbug.com/965747). For now, returning false
// should take us to CreatePlugin after HTMLPlugInElement which is called
// through HTMLPlugInElement::LoadPlugin code path.
if (plugin_info->status != chrome::mojom::PluginStatus::kAllowed &&
plugin_info->status !=
chrome::mojom::PluginStatus::kPlayImportantContent) {
if (plugin_info->status != chrome::mojom::PluginStatus::kAllowed) {
// We could get here when a MimeHandlerView is loaded inside a <webview>
// which is using permissions API (see WebViewPluginTests).
ChromeExtensionsRendererClient::DidBlockMimeHandlerViewForDisallowedPlugin(
@@ -1000,8 +998,7 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
case chrome::mojom::PluginStatus::kNotFound: {
NOTREACHED();
}
case chrome::mojom::PluginStatus::kAllowed:
case chrome::mojom::PluginStatus::kPlayImportantContent: {
case chrome::mojom::PluginStatus::kAllowed: {
if (info.path.value() == ChromeContentClient::kPDFExtensionPluginPath) {
// Report PDF load metrics. Since the PDF plugin is comprised of an
// extension that loads a second plugin, avoid double counting by
@@ -179,7 +179,7 @@ ExtensionInstallSources:
type: array
ListOfPermissions:
items:
pattern: ^[a-z][a-zA-Z0-9.]*$
pattern: ^[a-z][a-zA-Z0-9._]*$
type: string
type: array
ListOfUrlPatterns:
@@ -1390,8 +1390,8 @@ policies:
1389: AutoSignOutEnabled
1390: ExtensionInstallCloudPolicyChecksEnabled
1391: DevToolsGoogleDeveloperProgramProfileAvailability
1392: IncognitoModeBlocklist
1393: IncognitoModeAllowlist
1392: IncognitoModeUrlBlocklist
1393: IncognitoModeUrlAllowlist
1394: PreferSlowKexAlgorithms
1395: ExtensionForceInstallWithNonMalwareViolationsEnabled
1396: CacheEncryptionEnabled
@@ -1416,6 +1416,13 @@ policies:
1415: DeviceLoginScreenPreferSlowCiphers
1416: SearchContentSharingSettings
1417: StaticStorageQuotaEnabled
1418: SaaSReportDomainUrlsForBrowser
1419: SaaSReportDomainUrlsForProfile
1420: GeminiActOnWebAllowedForURLs
1421: GeminiActOnWebBlockedForURLs
1422: WebAppInstallByUserEnabled
1423: ''
1424: RestrictPdfSaveToGoogleDriveAccountsToPattern
atomic_groups:
1: Homepage
@@ -0,0 +1,39 @@
caption: Specifies a list of SaaS domains that will be reported for managed browser
desc: |-
This policy controls <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> reporting of SaaS domain visits and content transfers for a managed browser.
When the policy is set, the URLs matching SaaS domains will be used to generate report and uploaded. Unmatched URLs will be ignored.
When the policy is not set or set to an empty list, no report will be generated.
The matching patterns use a similar format to those for the '<ph name="URL_BLOCKLIST_POLICY_NAME">URLBlocklist</ph>' policy, which are documented at https://support.google.com/chrome/a?p=url_blocklist_filter_format. With a few exceptions below:
* URL host must match the hostname or be a subdomain of the hostname of one of the domains from the SaaS sites list.
* URL path must start with the path from the matched SaaS sites list entry.
* The URL scheme, port, query are disregarded during the matching process.
This policy value is populated by the cloud policy infrastructure and admins can't set it directly.
example_value:
- google.com
- example.com/path
default: []
features:
dynamic_refresh: true
per_profile: false
cloud_only: true
future_on:
- chrome.*
owners:
- janzarzycki@google.com
- igorruvinov@chromium.org
- file://components/enterprise/browser/reporting/OWNERS
schema:
items:
type: string
type: array
tags:
- admin-sharing
- google-sharing
type: list
@@ -0,0 +1,42 @@
caption: Specifies a list of SaaS domains that will be reported for managed profile
desc: |-
This policy controls <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> reporting of SaaS domain visits and content transfers for a managed profile.
When the policy is set, the URLs matching SaaS domains will be used to generate report and uploaded. Unmatched URLs will be ignored.
When the policy is not set or set to an empty list, no report will be generated.
The matching patterns use a similar format to those for the '<ph name="URL_BLOCKLIST_POLICY_NAME">URLBlocklist</ph>' policy, which are documented at https://support.google.com/chrome/a?p=url_blocklist_filter_format. With a few exceptions below:
* URL host must match the hostname or be a subdomain of the hostname of one of the domains from the SaaS sites list.
* URL path must start with the path from the matched SaaS sites list entry.
* The URL scheme, port, query are disregarded during the matching process.
This policy can only be set as a cloud user policy.
This policy value is populated by the cloud policy infrastructure and admins can't set it directly.
example_value:
- google.com
- example.com/path
default: []
features:
dynamic_refresh: true
per_profile: true
user_only: true
cloud_only: true
future_on:
- chrome.*
owners:
- janzarzycki@google.com
- igorruvinov@chromium.org
- file://components/enterprise/browser/reporting/OWNERS
schema:
items:
type: string
type: array
tags:
- admin-sharing
- google-sharing
type: list
@@ -26,6 +26,7 @@ features:
per_profile: true
future_on:
- fuchsia
- ios
owners:
- chromeos-commercial-networking-team@google.com
- miersh@google.com
@@ -4,10 +4,6 @@ desc: |-
Setting the policy to Enabled means a default search is performed when a user enters non-URL text in the address bar. To specify the default search provider, set the rest of the default search policies. If you leave those policies empty, the user can choose the default provider. Setting the policy to Disabled means there's no search when the user enters non-URL text in the address bar. The Disabled value is not supported by the <ph name="GOOGLE_ADMIN_CONSOLE_PRODUCT_NAME">Google Admin console</ph>.
If you set the policy, users can't change it in <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph>. If not set, the default search provider is on, and users can set the search provider list.
On <ph name="MS_WIN_NAME">Microsoft® Windows®</ph>, this policy is only available on instances that are joined to a <ph name="MS_AD_NAME">Microsoft® Active Directory®</ph> domain, joined to <ph name="MS_AAD_NAME">Microsoft® Azure® Active Directory®</ph> or enrolled in <ph name="CHROME_ENTERPRISE_CORE_NAME">Chrome Enterprise Core</ph>.
On <ph name="MAC_OS_NAME">macOS</ph>, this policy is only available on instances that are managed via MDM, joined to a domain via MCX or enrolled in <ph name="CHROME_ENTERPRISE_CORE_NAME">Chrome Enterprise Core</ph>.
example_value: true
features:
can_be_recommended: true
@@ -13,6 +13,8 @@ example_value: true
features:
dynamic_refresh: false
per_profile: true
future_on:
- android
items:
- caption: Block installation of external extensions
value: true
@@ -28,6 +28,8 @@ example_value:
features:
dynamic_refresh: true
per_profile: true
future_on:
- android
items:
- caption: Extension
name: extension
@@ -19,15 +19,15 @@ desc: |-
Setting the policy to Disabled or not setting the policy will cause force-installed extensions with non-malware violations to be disabled.
This policy will be available for 3 milestones.
This policy was removed in M145. Starting that version, force-installed extensions with non-malware violations will be disabled in low-trust environments.
owners:
- richche@google.com
- file://extensions/OWNERS
supported_on:
- chrome.mac:142-
- chrome.win:142-
- chrome.mac:142-144
- chrome.win:142-144
features:
dynamic_refresh: true
@@ -46,6 +46,8 @@ items:
default: false
deprecated: true
example_value: false
tags: []
@@ -10,6 +10,8 @@ example_value:
features:
dynamic_refresh: true
per_profile: true
future_on:
- android
label: URL patterns to allow extension, app, and user script installs from
owners:
- dbertoni@chromium.org
@@ -19,6 +19,8 @@ desc: |-
supported_on:
- chrome.*:115-
- chrome_os:115-
future_on:
- android
features:
dynamic_refresh: true
per_profile: true
@@ -11,4 +11,3 @@ Extensions:
- ExtensionManifestV2Availability
- ExtensionUnpublishedAvailability
- ExtensionExtendedBackgroundLifetimeForPortConnectionsToUrls
- ExtensionForceInstallWithNonMalwareViolationsEnabled
@@ -1,8 +1,8 @@
caption: Enable First-Party Sets.
default: true
# TODO(b/313073098): Deprecate policy.
deprecated: true
desc: |-
This policy is provided as a way to opt-out of the First-Party Sets feature.
This policy is provided as a way to opt-out of the First-Party Sets feature (which was later renamed <ph name="RELATED_WEBSITE_SETS_FEATURE_NAME">Related Website Sets</ph> feature).
When this policy is unset or set to Enabled, the First-Party Sets feature is enabled.
@@ -11,8 +11,8 @@ desc: |-
It controls whether Chrome supports First-Party Sets related integrations.
This is the equivalent of the <ph name="RELATED_WEBSITE_SETS_ENABLED_POLICY_NAME">RelatedWebsiteSetsEnabled</ph> policy.
Either policy may be used, but this one will be deprecated soon so the <ph name="RELATED_WEBSITE_SETS_ENABLED_POLICY_NAME">RelatedWebsiteSetsEnabled</ph> policy is preferred.
They both have the same effect on the browser's behavior.
Either policy may be used with the same effect on the browser's behavior.
Both these policies are deprecated following <ph name="RELATED_WEBSITE_SETS_FEATURE_NAME">Related Website Sets</ph> feature deprecation in <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> version 144.
example_value: false
features:
dynamic_refresh: true
@@ -1,8 +1,8 @@
caption: Override First-Party Sets.
default: {}
# TODO(b/313073098): Deprecate policy.
deprecated: true
desc: |-
This policy provides a way to override the list of sets the browser uses for First-Party Sets features.
This policy provides a way to override the list of sets the browser uses for First-Party Sets features (which was later renamed <ph name="RELATED_WEBSITE_SETS_FEATURE_NAME">Related Website Sets</ph> feature).
Each set in the browser's list of First-Party Sets must meet the requirements of a First-Party Set.
A First-Party Set must contain a primary site and one or more member sites.
@@ -38,8 +38,8 @@ desc: |-
On <ph name="MAC_OS_NAME">macOS</ph>, this policy is only available on instances that are managed via MDM, joined to a domain via MCX or enrolled in <ph name="CHROME_ENTERPRISE_CORE_NAME">Chrome Enterprise Core</ph>.
This is the equivalent of the <ph name="RELATED_WEBSITE_SETS_OVERRIDES_POLICY_NAME">RelatedWebsiteSetsOverrides</ph> policy.
Either policy may be used, but this one will be deprecated soon so the <ph name="RELATED_WEBSITE_SETS_OVERRIDES_POLICY_NAME">RelatedWebsiteSetsOverrides</ph> policy is preferred.
They both have the same effect on the browser's behavior.
Either policy may be used with the same effect on the browser's behavior.
Both these policies are deprecated following <ph name="RELATED_WEBSITE_SETS_FEATURE_NAME">Related Website Sets</ph> feature deprecation in <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> version 144.
example_value:
additions:
- associatedSites:
@@ -0,0 +1,33 @@
caption: Allow Gemini app integrations to directly act on specified sites
desc: |-
Allows to set a list of URL patterns that specify on which sites Gemini app integrations can directly act on web pages.
URLs matching neither the allowlist or the blocklist use <ph name="GEMINI_ACT_ON_WEB_SETTINGS_POLICY_NAME">GeminiActOnWebSettings</ph>.
URLs matching both the allowlist and the blocklist are allowed.
For detailed information on valid url patterns, please see https://support.google.com/chrome/a?p=url_blocklist_filter_format.
owners:
- liuwilliam@chromium.org
- mcnee@chromium.org
- file://chrome/browser/glic/OWNERS
example_value:
- example.com
- https://ssl.server.com
- hosting.com/good_path
- https://server:8080/path
- .exact.hostname.com
future_on:
- chrome.*
- chrome_os
- android
features:
dynamic_refresh: true
per_profile: true
type: list
schema:
items:
type: string
type: array
tags: []
@@ -0,0 +1,33 @@
caption: Block Gemini app integrations to directly act on specified sites
desc: |-
Allows to set a list of URL patterns that specify on which sites Gemini app integrations cannot directly act on web pages.
URLs matching neither the allowlist or the blocklist use <ph name="GEMINI_ACT_ON_WEB_SETTINGS_POLICY_NAME">GeminiActOnWebSettings</ph>.
URLs matching both the allowlist and the blocklist are allowed.
For detailed information on valid url patterns, please see https://support.google.com/chrome/a?p=url_blocklist_filter_format.
owners:
- liuwilliam@chromium.org
- mcnee@chromium.org
- file://chrome/browser/glic/OWNERS
example_value:
- example.com
- https://ssl.server.com
- hosting.com/bad_path
- https://server:8080/path
- .exact.hostname.com
future_on:
- chrome.*
- chrome_os
- android
features:
dynamic_refresh: true
per_profile: true
type: list
schema:
items:
type: string
type: array
tags: []
@@ -16,6 +16,8 @@ owners:
- liuwilliam@chromium.org
- file://chrome/browser/glic/OWNERS
example_value: 0
future_on:
- android
features:
dynamic_refresh: true
per_profile: true
@@ -1,7 +1,7 @@
caption: Enable content sharing with <ph name="GOOGLE_AI_MODE_PRODUCT_NAME">Google AI Mode</ph> integrations
caption: Enable content sharing with <ph name="GOOGLE_AI_MODE_PRODUCT_NAME">Google AI Mode</ph> and <ph name="GOOGLE_LENS_PRODUCT_NAME">Lens</ph> integrations
desc: |-
This policy controls sharing of page and file content with <ph name="GOOGLE_AI_MODE_PRODUCT_NAME">Google AI Mode</ph> through <ph name="PRODUCT_NAME">Google Chrome</ph> side panel or tabs.
This policy controls sharing of page and file content with <ph name="GOOGLE_AI_MODE_PRODUCT_NAME">Google AI Mode</ph> and <ph name="GOOGLE_LENS_PRODUCT_NAME">Lens</ph> through <ph name="PRODUCT_NAME">Google Chrome</ph> side panel or tabs.
Note that this policy doesn't affect <ph name="GOOGLE_AI_MODE_PRODUCT_NAME">Google AI Mode</ph> on the web. It only controls how users can share information with it when using <ph name="PRODUCT_NAME">Google Chrome</ph>.
@@ -15,6 +15,8 @@ desc: |-
This policy also doesn't control <ph name="GOOGLE_GEMINI_PRODUCT_NAME">Google Gemini</ph> integration which can be disabled by <ph name="GEMINI_SETTINGS_POLICY_NAME">GeminiSettings</ph>.
If this policy is unset, its behavior is determined by the <ph name="GEN_AI_DEFAULT_SETTINGS_POLICY_NAME">GenAiDefaultSettings</ph> policy.
For more information on data handling for generative AI features, please see https://support.google.com/chrome/a?p=generative_ai_settings.
default: 0
example_value: 1
@@ -21,14 +21,12 @@ desc: |-
See https://wicg.github.io/local-network-access/ for <ph
name="LOCAL_NETWORK_ACCESS">Local Network Access</ph> restrictions.
This policy is deprecated because <ph name="LOCAL_NETWORK_ACCESS">Local Network Access</ph>
has launched by default. The policy will be removed in a future release.
default: false
supported_on:
- chrome.*:138-
- chrome_os:138-
- android:139-
- chrome.*:138-144
- chrome_os:138-144
- android:139-144
features:
dynamic_refresh: true
@@ -19,16 +19,12 @@ desc: |-
See https://wicg.github.io/local-network-access/ for <ph
name="LOCAL_NETWORK_ACCESS">Local Network Access</ph> restrictions.
This enterprise policy is temporary, and will be removed after M146.
This enterprise policy is temporary, and will be removed after M152.
Long term, the policy <ph
name="LOCAL_NETWORK_ACCESS_ALLOWED_FOR_URLS_POLICY_NAME">LocalNetworkAccessAllowedForUrls</ph>
can be used to allowlist URL patterns that should be automatically granted
the <ph name="LOCAL_NETWORK_ACCESS">Local Network Access</ph> permission.
Note that if the policy <ph
name="LOCAL_NETWORK_ACCESS_RESTRICTIONS_ENABLED_POLICY_NAME">LocalNetworkAccessRestrictionsEnabled</ph>
is enabled, it will take precedence over this policy.
default: false
supported_on:
@@ -6,7 +6,7 @@ desc: |-
If the policy is set to "Enable browser sign-in," then the user is allowed to sign in to the browser. On all platforms except <ph name="IOS_NAME">iOS</ph>, the user is automatically signed in to the browser when signed in to Google web services like Gmail. Being signed in to the browser means the user's account information will be kept by the browser. However, it does not mean that <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> Sync will be turned on by default; the user must separately opt-in to use this feature. Enabling this policy will prevent the user from turning off the setting that allows browser sign-in. To control the availability of <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> Sync, use the <ph name="SYNC_POLICY_NAME">SyncDisabled</ph> policy.
If the policy is set to "Force browser sign-in" the user is presented with an account selection dialog and has to choose and sign in to an account to use the browser. This ensures that for managed accounts the policies associated with the account are applied and enforced. The default value of <ph name="GUEST_MODE_POLICY_NAME">BrowserGuestModeEnabled</ph> will be set to disabled. Note that existing unsigned profiles will be locked and inaccessible after enabling this policy. For more information, see help center article: https://support.google.com/chrome/a/answer/7572556 . This option is not supported on <ph name="LINUX_OS_NAME">Linux</ph> nor <ph name="ANDROID_NAME">Android</ph>, where it will fall back to "Enable browser sign-in" if used.
If the policy is set to "Force browser sign-in" the user is presented with an account selection dialog and has to choose and sign in to an account to use the browser. This ensures that for managed accounts the policies associated with the account are applied and enforced. The default value of <ph name="GUEST_MODE_POLICY_NAME">BrowserGuestModeEnabled</ph> will be set to disabled. Note that existing unsigned profiles will be locked and inaccessible after enabling this policy. For more information, see help center article: https://support.google.com/chrome/?p=force_browser_signin . This option is not supported on <ph name="PRODUCT_OS_NAME">$2<ex>Google ChromeOS</ex></ph> nor <ph name="ANDROID_NAME">Android</ph>, where it will fall back to "Enable browser sign-in" if used.
If this policy is not set then the user can decide if they want to enable browser sign-in in the <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> settings and use it as they see fit.
example_value: 2
@@ -28,6 +28,7 @@ items:
- chrome.win:70-
- chrome.mac:70-
- ios:97-
- chrome.linux:145-
value: 2
owners:
- file://components/policy/OWNERS
@@ -15,7 +15,11 @@ desc: |-
As of <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> version 128, this setting will not control developer mode on extensions page if <ph name="EXTENSION_DEVELOPER_MODE_SETTINGS_POLICY_NAME">ExtensionDeveloperModeSettings</ph> policy is set.
If you want to restrict Developer Tools access based on the page URL, use the <ph name="DEVELOPER_TOOLS_AVAILABILITY_BLOCKLIST_POLICY_NAME">DeveloperToolsAvailabilityBlocklist</ph> and <ph name="DEVELOPER_TOOLS_AVAILABILITY_ALLOWLIST_POLICY_NAME">DeveloperToolsAvailabilityAllowlist</ph> policies.
The availability of Developer Tools is determined in the following order of precedence:
1. If a URL matches a pattern in the <ph name="DEVELOPER_TOOLS_AVAILABILITY_ALLOWLIST_POLICY_NAME">DeveloperToolsAvailabilityAllowlist</ph> policy, Developer Tools are allowed.
2. If the <ph name="DEVELOPER_TOOLS_AVAILABILITY_ALLOWLIST_POLICY_NAME">DeveloperToolsAvailabilityAllowlist</ph> is set and the <ph name="DEVELOPER_TOOLS_AVAILABILITY_BLOCKLIST_POLICY_NAME">DeveloperToolsAvailabilityBlocklist</ph> is not, any URL not on the allowlist is blocked.
3. If a URL matches a pattern in the <ph name="DEVELOPER_TOOLS_AVAILABILITY_BLOCKLIST_POLICY_NAME">DeveloperToolsAvailabilityBlocklist</ph> policy, Developer Tools are blocked.
4. If a URL is not covered by the allowlist or blocklist, this policy (<ph name="DEVELOPER_TOOLS_AVAILABILITY_POLICY_NAME">DeveloperToolsAvailability</ph>) is the fallback.
default: 0
example_value: 2
features:
@@ -4,9 +4,13 @@ desc: |-
URL patterns are matched against the URL of the page being inspected. If a match is found, the <ph name="CHROME_DEVTOOLS_NAME">Chrome DevTools</ph> are allowed. This applies even if the URL also matches the <ph name="DEVELOPER_TOOLS_AVAILABILITY_BLOCKLIST_POLICY_NAME">DeveloperToolsAvailabilityBlocklist</ph> policy, even if the <ph name="DEVELOPER_TOOLS_AVAILABILITY_POLICY_NAME">DeveloperToolsAvailability</ph> policy is set to disallow (value 2). For information on the URL format, see https://support.google.com/chrome/a?p=url_blocklist_filter_format.
Leaving the policy unset means this allowlist has no effect. Since <ph name="CHROME_DEVTOOLS_NAME">Chrome DevTools</ph> are available by default, they will only be blocked if specified in the <ph name="DEVELOPER_TOOLS_AVAILABILITY_BLOCKLIST_POLICY_NAME">DeveloperToolsAvailabilityBlocklist</ph> policy.
Leaving the policy unset means this allowlist has no effect.
Unmatched URLs will follow the <ph name="DEVELOPER_TOOLS_AVAILABILITY_POLICY_NAME">DeveloperToolsAvailability</ph> policy.
If this policy is set and <ph name="DEVELOPER_TOOLS_AVAILABILITY_BLOCKLIST_POLICY_NAME">DeveloperToolsAvailabilityBlocklist</ph> is not, any URL not on this list will be blocked.
If both this and the <ph name="DEVELOPER_TOOLS_AVAILABILITY_BLOCKLIST_POLICY_NAME">DeveloperToolsAvailabilityBlocklist</ph> policies are set, this allowlist takes precedence. If a URL matches a pattern on the allowlist, it will be allowed. If it matches a pattern on the blocklist (but not the allowlist), it will be blocked. If a URL matches neither, the <ph name="DEVELOPER_TOOLS_AVAILABILITY_POLICY_NAME">DeveloperToolsAvailability</ph> policy will be used as a fallback.
If neither policy is set, the availability is determined by the <ph name="DEVELOPER_TOOLS_AVAILABILITY_POLICY_NAME">DeveloperToolsAvailability</ph> policy.
This policy also applies to <ph name="CHROME_DEVTOOLS_NAME">Chrome DevTools</ph> opened for extensions and web applications.
@@ -2,9 +2,11 @@ caption: List of URL patterns for which <ph name="CHROME_DEVTOOLS_NAME">Chrome D
desc: |-
URL patterns are matched against the URL of the page being inspected. If a match is found, the <ph name="CHROME_DEVTOOLS_NAME">Chrome DevTools</ph> are blocked. For information on the URL format, see https://support.google.com/chrome/a?p=url_blocklist_filter_format.
The <ph name="DEVELOPER_TOOLS_AVAILABILITY_ALLOWLIST_POLICY_NAME">DeveloperToolsAvailabilityAllowlist</ph> policy takes precedence over <ph name="DEVELOPER_TOOLS_AVAILABILITY_BLOCKLIST_POLICY_NAME">DeveloperToolsAvailabilityBlocklist</ph>.
If the <ph name="DEVELOPER_TOOLS_AVAILABILITY_ALLOWLIST_POLICY_NAME">DeveloperToolsAvailabilityAllowlist</ph> policy is set and this policy is not, any URL not on the allowlist will be blocked.
Unmatched URLs will follow the <ph name="DEVELOPER_TOOLS_AVAILABILITY_POLICY_NAME">DeveloperToolsAvailability</ph> policy.
If both this and the <ph name="DEVELOPER_TOOLS_AVAILABILITY_ALLOWLIST_POLICY_NAME">DeveloperToolsAvailabilityAllowlist</ph> are set, the allowlist takes precedence. If a URL matches a pattern on the allowlist, it will be allowed. If it matches a pattern on this blocklist (but not the allowlist), it will be blocked. If a URL matches neither, the <ph name="DEVELOPER_TOOLS_AVAILABILITY_POLICY_NAME">DeveloperToolsAvailability</ph> policy will be used as a fallback.
If neither policy is set, the availability is determined by the <ph name="DEVELOPER_TOOLS_AVAILABILITY_POLICY_NAME">DeveloperToolsAvailability</ph> policy.
This policy also applies to <ph name="CHROME_DEVTOOLS_NAME">Chrome DevTools</ph> opened for extensions and web applications.
@@ -11,8 +11,6 @@ example_value: false
features:
dynamic_refresh: false
per_profile: false
future_on:
- chrome.linux
items:
- caption: Force the user to sign in before using the browser
value: true
@@ -26,6 +24,7 @@ schema:
supported_on:
- chrome.win:64-
- chrome.mac:66-
- chrome.linux:145-
- android:65-
tags: []
type: main
@@ -2,12 +2,22 @@ caption: Allow HTTPS-Only Mode to be enabled
default: allowed
desc: |-
This policy controls whether users can enable HTTPS-Only Mode (Always Use Secure Connections) in Settings. HTTPS-Only Mode upgrades all navigations to HTTPS.
If this setting is not set or set to allowed, users will be allowed to enable HTTPS-Only Mode.
If this setting is set to disallowed, users will not be allowed to enable HTTPS-Only Mode.
If this setting is set to force_enabled, HTTPS-Only Mode will be enabled in Strict mode and users will not be able to disable it.
If this setting is set to force_balanced_enabled, HTTPS-Only Mode will be enabled in Balanced mode and users will not be able to disable it.
force_enabled is supported from M112 onwards, force_balanced_enabled is supported from M129 onwards.
If you set this policy to a value that is not supported by the version of Chrome that receives the policy, Chrome will default to the allowed setting.
If this setting is not set or set to "allowed", users will be allowed to enable HTTPS-Only Mode.
If this setting is set to "disallowed", HTTPS-Only Mode will be disabled.
If this setting is set to "force_enabled", HTTPS-Only Mode will be enabled in Strict mode.
If this setting is set to "force_balanced_enabled", HTTPS-Only Mode will be enabled in Balanced mode.
"force_enabled" is supported from M112 onwards, "force_balanced_enabled" is supported from M129 onwards.
"force_enabled" and "force_balanced_enabled" can be recommended to users too.
HTTPS-Only Mode will be set Strict or Balanced initially but users are allowed to
change it.
If you set this policy to a value that is not supported by the version of Chrome that receives the policy, Chrome will default to the allowed setting.
The separate <ph name="HTTP_ALLOWLIST_POLICY_NAME">HttpAllowlist</ph> policy
can be used to exempt specific hostnames or hostname patterns from being
@@ -17,17 +27,18 @@ example_value: disallowed
features:
dynamic_refresh: true
per_profile: true
can_be_recommended: true
items:
- caption: Do not restrict users' HTTPS-Only Mode setting
name: allowed
value: allowed
- caption: Do not allow users to enable any HTTPS-Only Mode
- caption: Disable HTTPS-Only Mode
name: disallowed
value: disallowed
- caption: Force enable HTTPS-Only Mode in Strict mode
- caption: Enable HTTPS-Only Mode in Strict mode
name: force_enabled
value: force_enabled
- caption: Force enable HTTPS-Only Mode in Balanced Mode
- caption: Enable HTTPS-Only Mode in Balanced Mode
name: force_balanced_enabled
value: force_balanced_enabled
owners:
@@ -1,34 +0,0 @@
caption: Allow access to a list of URLs in Incognito mode.
desc: |-
Setting the policy provides access to the listed URLs in Incognito mode, as exceptions to <ph name="INCOGNITO_MODE_BLOCKLIST_POLICY_NAME">IncognitoModeBlocklist</ph>. For example, setting <ph name="INCOGNITO_MODE_BLOCKLIST_POLICY_NAME">IncognitoModeBlocklist</ph> to * will block all requests in Incognito mode, and you can use this policy to allow access to a limited list of URLs. Use it to open exceptions to certain schemes, subdomains of other domains, ports, or specific paths, using the format specified at ( https://support.google.com/chrome/a?p=url_blocklist_filter_format ). The <ph name="INCOGNITO_MODE_ALLOWLIST_POLICY_NAME">IncognitoModeAllowlist</ph> policy takes precedence over <ph name="INCOGNITO_MODE_BLOCKLIST_POLICY_NAME">IncognitoModeBlocklist</ph>. This policy is limited to 1,000 entries.
Leaving the policy unset allows no exceptions to <ph name="INCOGNITO_MODE_BLOCKLIST_POLICY_NAME">IncognitoModeBlocklist</ph>.
This policy only affects Incognito mode. To allow URLs for all user profiles, please use the <ph name="URL_ALLOWLIST_POLICY_NAME">URLAllowlist</ph> policy.
example_value:
- example.com
- https://ssl.server.com
- hosting.com/bad_path
- https://server:8080/path
- .exact.hostname.com
- file://*
- custom_scheme:*
- '*'
future_on:
- chrome.*
- chrome_os
- ios
- android
owners:
- file://components/policy/OWNERS
- mwalachowski@google.com
features:
dynamic_refresh: true
per_profile: true
schema:
items:
type: string
type: array
tags:
- filtering
type: list
@@ -12,7 +12,7 @@ desc: |-
default: 0
example_value: 1
features:
dynamic_refresh: true
dynamic_refresh: false
per_profile: true
future_on:
- fuchsia
@@ -0,0 +1,34 @@
caption: Allow access to a list of URLs in Incognito mode.
desc: |-
Setting the policy provides access to the listed URLs in Incognito mode, as exceptions to <ph name="INCOGNITO_MODE_URL_BLOCKLIST_POLICY_NAME">IncognitoModeUrlBlocklist</ph>. For example, setting <ph name="INCOGNITO_MODE_URL_BLOCKLIST_POLICY_NAME">IncognitoModeUrlBlocklist</ph> to * will block all requests in Incognito mode, and you can use this policy to allow access to a limited list of URLs. Use it to open exceptions to certain schemes, subdomains of other domains, ports, or specific paths, using the format specified at ( https://support.google.com/chrome/a?p=url_blocklist_filter_format ). The <ph name="INCOGNITO_MODE_URL_ALLOWLIST_POLICY_NAME">IncognitoModeUrlAllowlist</ph> policy takes precedence over <ph name="INCOGNITO_MODE_URL_BLOCKLIST_POLICY_NAME">IncognitoModeUrlBlocklist</ph>. This policy is limited to 1,000 entries.
Leaving the policy unset allows no exceptions to <ph name="INCOGNITO_MODE_URL_BLOCKLIST_POLICY_NAME">IncognitoModeUrlBlocklist</ph>.
This policy only affects Incognito mode. To allow URLs for all user profiles, please use the <ph name="URL_ALLOWLIST_POLICY_NAME">URLAllowlist</ph> policy.
example_value:
- example.com
- https://ssl.server.com
- hosting.com/bad_path
- https://server:8080/path
- .exact.hostname.com
- file://*
- custom_scheme:*
- '*'
future_on:
- chrome.*
- chrome_os
- ios
- android
owners:
- file://components/policy/OWNERS
- mwalachowski@google.com
features:
dynamic_refresh: true
per_profile: true
schema:
items:
type: string
type: array
tags:
- filtering
type: list
@@ -1,6 +1,6 @@
caption: Block access to a list of URLs in Incognito mode.
desc: |-
Setting the <ph name="INCOGNITO_MODE_BLOCKLIST_POLICY_NAME">IncognitoModeBlocklist</ph> policy stops web pages with prohibited URLs from loading in Incognito mode. Administrators can specify the list of URL patterns to be blocked. If left unset, no URLs are blocked in the Incognito mode. Up to 1,000 exceptions can be defined in <ph name="INCOGNITO_MODE_ALLOWLIST_POLICY_NAME">IncognitoModeAllowlist</ph>. See how to format a URL pattern ( https://support.google.com/chrome/a?p=url_blocklist_filter_format ).
Setting the <ph name="INCOGNITO_MODE_URL_BLOCKLIST_POLICY_NAME">IncognitoModeUrlBlocklist</ph> policy stops web pages with prohibited URLs from loading in Incognito mode. Administrators can specify the list of URL patterns to be blocked. If left unset, no URLs are blocked in the Incognito mode. Up to 1,000 exceptions can be defined in <ph name="INCOGNITO_MODE_URL_ALLOWLIST_POLICY_NAME">IncognitoModeUrlAllowlist</ph>. See how to format a URL pattern ( https://support.google.com/chrome/a?p=url_blocklist_filter_format ).
This policy only affects Incognito mode. To block URLs for all user profiles, please use the <ph name="URL_BLOCKLIST_POLICY_NAME">URLBlocklist</ph> policy.
example_value:
@@ -6,6 +6,8 @@ desc: Leaving the policy unset or setting it to Enabled allows users to view and
search box on the New Tab page. Setting the policy to Disabled means users
will not see the <ph name="GOOGLE_LENS_PRODUCT_NAME">Google Lens</ph> button
in the search box on the New Tab page.
Starting in <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> 147, this policy will be deprecated. IT Admins can use <ph name="SEARCH_CONTENT_SHARING_SETTINGS_POLICY_NAME">SearchContentSharingSettings</ph> to control this feature going forward.
example_value: true
features:
dynamic_refresh: true
@@ -9,6 +9,8 @@ desc: |-
When policy is set to 1 - Do not allow, the feature will not be available.
Starting in <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> 140, if the policy is unset, its behavior is determined by the <ph name="GEN_AI_DEFAULT_SETTINGS_POLICY_NAME">GenAiDefaultSettings</ph> policy.
Starting in <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> 147, this policy will be deprecated. IT Admins can use <ph name="SEARCH_CONTENT_SHARING_SETTINGS_POLICY_NAME">SearchContentSharingSettings</ph> to control this feature going forward.
default: 0
example_value: 1
features:
@@ -7,6 +7,8 @@ desc: Leaving the policy unset or setting it to Enabled allows users to view and
<ph name="GOOGLE_LENS_PRODUCT_NAME">Google Lens</ph> region search menu item in
the context menu when <ph name="GOOGLE_LENS_PRODUCT_NAME">Google Lens</ph> region
search is supported.
Starting in <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> 147, this policy will be deprecated. IT Admins can use <ph name="SEARCH_CONTENT_SHARING_SETTINGS_POLICY_NAME">SearchContentSharingSettings</ph> to control this feature going forward.
example_value: true
features:
dynamic_refresh: true
@@ -1,6 +1,7 @@
caption: Add restrictions on managed accounts
default: none
desc: |2-
desc: |-
This policy is deprecated. Please use <ph name="POLICY_VALUE_PROFILE_SEPARATION_SETTINGS_NAME">ProfileSeparationSettings</ph> instead.
Default behavior (Policy unset)
When an account is added in the content area a small dialog may appear asking the user to create a new profile. This dialog is dismissable.
@@ -22,6 +23,7 @@ desc: |2-
<ph name="MANAGED_ACCOUNTS_SIGNIN_RESTRICTION_POLICY_NAME">ManagedAccountsSigninRestriction</ph> = <ph name="POLICY_VALUE_PRIMARY_ACCOUNT_STRICT_KEEP_EXISTING_DATA">'primary_account_strict_keep_existing_data'</ph>
This is the same behavior as <ph name="POLICY_VALUE_PRIMARY_ACCOUNT_KEEP_EXISTING_DATA">'primary_account_keep_existing_data'</ph> except the newly created profile is not allowed to have secondary accounts.
deprecated: true
example_value: primary_account
features:
dynamic_refresh: false
@@ -11,6 +11,8 @@ desc: |-
supported_on:
- chrome.*:136-
- android:143-
future_on:
- ios
features:
dynamic_refresh: true
per_profile: false
@@ -12,6 +12,8 @@ supported_on:
- chrome.mac:126-
- chrome.linux:128-
- android:143-
future_on:
- ios
features:
dynamic_refresh: true
per_profile: true
@@ -0,0 +1,21 @@
caption: Restrict eligible Google accounts for saving PDF files to Google Drive from the
<ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> PDF Viewer
desc: |-
Contains a regular expression to determine eligible Google accounts for saving PDF files to Google Drive from the <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> PDF Viewer.
An error is displayed if a user tries to upload a PDF file to Google Drive using an account that does not match this pattern.
If this policy is left not set or blank, then the user can use any Google account to save PDF files to Google Drive.
example_value: .*@example\.com
features:
dynamic_refresh: false
per_profile: false
owners:
- file://components/policy/OWNERS
- faizur@chromium.org
schema:
type: string
supported_on:
- chrome.*:145-
tags: []
type: string
@@ -3,7 +3,7 @@ default: null
desc: |-
When enabled, the storage quota APIs will return a static value equal to usage + min(10 GiB, disk rounded up to the nearest 1 GiB).
When disabled, the storage quota APIs will generally return a dynamic value proportional to the total space available on the device, regardless of usage.
If unset, the predictable reported storage quota feature launch or flags will determine behavior.
If unset, the storage quota APIs will use the default Chrome behavior.
Sites with unlimited storage permissions are unaffected by this setting. Enforced quota is also unaffected.
example_value: true
features:
@@ -35,9 +35,9 @@ schema:
- 2
type: integer
supported_on:
- chrome_os:98-
- chrome.*:98-
- android:98-
- chrome_os:98-144
- chrome.*:98-144
- android:98-144
tags:
- website-sharing
type: int-enum
@@ -0,0 +1,29 @@
caption: Enable User Web App Install From Browser
desc: |-
This policy controls whether users can install web apps through the browser.
If you enable or dont configure this policy, users can install web apps through the browser.
If you disable this policy, users cant install web apps through the browser and the "apps" data type will be excluded from synchronization for <ph name="CHROME_SYNC_NAME">Chrome Sync</ph>.
This policy doesn't support dynamic refresh. Any changes, whether enabling, disabling or unsetting, become effective only after the browser is restarted.
This policy doesn't affect the '<ph name="WEB_APP_INSTALL_FORCE_LIST_POLICY_NAME">WebAppInstallForceList</ph>' policy.
default: true
example_value: false
features:
dynamic_refresh: false
per_profile: true
owners:
- file://chrome/browser/web_applications/OWNERS
- ishikapatel@microsoft.com
- liahiscock@microsoft.com
supported_on:
- chrome.*:145-
- chrome_os:145-
type: main
schema:
type: boolean
items:
- caption: Users can install web apps through the browser.
value: true
- caption: Users cant install web apps through the browser.
value: false
tags: []
@@ -4,6 +4,7 @@ desc: |-
Setting the policy to Disabled means users can't turn on the proxy, and the machine can't share its printers with <ph name="CLOUD_PRINT_NAME">Google Cloud Print</ph>.
default: true
deprecated: true
example_value: true
features:
dynamic_refresh: true
@@ -21,6 +22,6 @@ owners:
schema:
type: boolean
supported_on:
- chrome.*:17-
- chrome.*:17-144
tags: []
type: main
@@ -1,4 +1,6 @@
# This policy is deprecated and should be removed in M146 (crbug.com/454935785).
caption: Choose whether the <ph name="PRIVACY_SANDBOX_NAME">Privacy Sandbox</ph> Fingerprinting Protection feature is to be enabled in Incognito mode.
deprecated: true
default: null
desc: |-
A policy to control whether the <ph name="PRIVACY_SANDBOX_NAME">Privacy Sandbox</ph> Fingerprinting Protection setting is to be enabled in Incognito mode or disabled for your users.
@@ -11,9 +13,9 @@ features:
dynamic_refresh: true
per_profile: true
supported_on:
- android:140-
- chrome.*:140-
- chrome_os:140-
- android:140-145
- chrome.*:140-145
- chrome_os:140-145
items:
- caption: Enable the <ph name="PRIVACY_SANDBOX_NAME">Privacy Sandbox</ph> Fingerprinting Protection feature in Incognito mode.
value: true
@@ -25,6 +27,7 @@ owners:
- aabeshouse@google.com
- johnykim@google.com
- rizvis@google.com
- thesalsa@google.com
- file://components/privacy_sandbox/OWNERS
schema:
type: boolean
@@ -1,6 +1,7 @@
caption: Choose whether the <ph name="PRIVACY_SANDBOX_NAME">Privacy Sandbox</ph> IP Protection feature should be enabled.
default: null
desc: |- # TODO(b/416726104): Move the considerations and other details to a help center article.
deprecated: true
desc: |-
A policy to control whether the <ph name="PRIVACY_SANDBOX_NAME">Privacy Sandbox</ph> <ph name="IP_PROTECTION_NAME">IP Protection</ph> feature should be enabled.
<ph name="IP_PROTECTION_NAME">IP Protection</ph> is a feature that limits availability of a user's original IP address for certain third-party network requests made while browsing in Incognito mode, enhancing protections against cross-site tracking during Incognito browsing sessions.
@@ -28,9 +29,9 @@ features:
dynamic_refresh: true
per_profile: true
supported_on:
- android:138-
- chrome.*:138-
- chrome_os:138-
- android:138-143
- chrome.*:138-143
- chrome_os:138-143
items:
- caption: Disable the <ph name="IP_PROTECTION_NAME">IP Protection</ph> feature.
value: false
@@ -4,15 +4,13 @@ desc:
When this policy is set to 1, the <ph name="PROXY_OVERRIDE_RULES_POLICY_NAME">ProxyOverrideRules</ph> policy will be applied at the user scope, even that user is unaffiliated.
When this policy is set to 2, the <ph name="PROXY_OVERRIDE_RULES_POLICY_NAME">ProxyOverrideRules</ph> policy will never be applied when its source is a user.
example_value: 1
default: 0
features:
dynamic_refresh: true
per_profile: false
future_on:
- chrome.*
supported_on:
- chrome.*:145-
owners:
- seblalancette@chromium.org
- domfc@chromium.org
@@ -21,7 +19,6 @@ schema:
enum:
- 0
- 1
- 2
type: integer
tags:
- system-security
@@ -3,10 +3,6 @@ desc: |-
Setting the policy sets the URL for users to change their password after seeing a warning in the browser. The password protection service sends users to the URL (HTTP and HTTPS protocols only) you designate through this policy. For <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> to correctly capture the salted hash of the new password on this change password page, make sure your change password page follows these guidelines ( https://www.chromium.org/developers/design-documents/create-amazing-password-forms ).
Turning the policy off or leaving it unset means the service sends users to https://myaccount.google.com to change their password.
On <ph name="MS_WIN_NAME">Microsoft® Windows®</ph>, this policy is only available on instances that are joined to a <ph name="MS_AD_NAME">Microsoft® Active Directory®</ph> domain, joined to <ph name="MS_AAD_NAME">Microsoft® Azure® Active Directory®</ph> or enrolled in <ph name="CHROME_ENTERPRISE_CORE_NAME">Chrome Enterprise Core</ph>.
On <ph name="MAC_OS_NAME">macOS</ph>, this policy is only available on instances that are managed via MDM, joined to a domain via MCX or enrolled in <ph name="CHROME_ENTERPRISE_CORE_NAME">Chrome Enterprise Core</ph>.
example_value: https://mydomain.com/change_password.html
features:
dynamic_refresh: true
@@ -4,10 +4,6 @@ desc: |-
Setting the policy sets the list of enterprise login URLs (HTTP and HTTPS protocols only). Password protection service will capture salted hashes of passwords on these URLs and use them for password reuse detection. For <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> to correctly capture password salted hashes, ensure your sign-in pages follow these guidelines ( https://www.chromium.org/developers/design-documents/create-amazing-password-forms ).
Turning this setting off or leaving it unset means the password protection service only captures the password salted hashes on https://accounts.google.com.
On <ph name="MS_WIN_NAME">Microsoft® Windows®</ph>, this policy is only available on instances that are joined to a <ph name="MS_AD_NAME">Microsoft® Active Directory®</ph> domain, joined to <ph name="MS_AAD_NAME">Microsoft® Azure® Active Directory®</ph> or enrolled in <ph name="CHROME_ENTERPRISE_CORE_NAME">Chrome Enterprise Core</ph>.
On <ph name="MAC_OS_NAME">macOS</ph>, this policy is only available on instances that are managed via MDM, joined to a domain via MCX or enrolled in <ph name="CHROME_ENTERPRISE_CORE_NAME">Chrome Enterprise Core</ph>.
example_value:
- https://mydomain.com/login.html
- https://login.mydomain.com
@@ -5,10 +5,6 @@ desc: |-
Leaving the policy unset means default Safe Browsing protection applies to all resources.
This policy does not support regular expressions; however, subdomains of a given domain are allowlisted. Fully qualified domain names (FQDNs) are not required.
On <ph name="MS_WIN_NAME">Microsoft® Windows®</ph>, this policy is only available on instances that are joined to a <ph name="MS_AD_NAME">Microsoft® Active Directory®</ph> domain, joined to <ph name="MS_AAD_NAME">Microsoft® Azure® Active Directory®</ph> or enrolled in <ph name="CHROME_ENTERPRISE_CORE_NAME">Chrome Enterprise Core</ph>.
On <ph name="MAC_OS_NAME">macOS</ph>, this policy is only available on instances that are managed via MDM, joined to a domain via MCX or enrolled in <ph name="CHROME_ENTERPRISE_CORE_NAME">Chrome Enterprise Core</ph>.
example_value:
- mydomain.com
- myuniversity.edu
@@ -10,10 +10,6 @@ desc: |-
See more about Safe Browsing ( https://developers.google.com/safe-browsing ).
If the policy <ph name="SAFE_BROWSING_PROTECTION_LEVEL_POLICY_NAME">SafeBrowsingProtectionLevel</ph> is set, the value of the policy <ph name="SAFE_BROWSING_ENABLED_POLICY_NAME">SafeBrowsingEnabled</ph> is ignored.
On <ph name="MS_WIN_NAME">Microsoft® Windows®</ph>, this policy is only available on instances that are joined to a <ph name="MS_AD_NAME">Microsoft® Active Directory®</ph> domain, joined to <ph name="MS_AAD_NAME">Microsoft® Azure® Active Directory®</ph> or enrolled in <ph name="CHROME_ENTERPRISE_CORE_NAME">Chrome Enterprise Core</ph>.
On <ph name="MAC_OS_NAME">macOS</ph>, this policy is only available on instances that are managed via MDM, joined to a domain via MCX or enrolled in <ph name="CHROME_ENTERPRISE_CORE_NAME">Chrome Enterprise Core</ph>.
default: null
example_value: true
features:
@@ -15,12 +15,13 @@ desc: |-
<ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> does not support Single Sign-on using <ph name="EXTENSIBLE_ENTERPRISE_SSO_PRODUCT_NAME">Extensible Enterprise SSO</ph> in Incognito or Guest modes.
<ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> only supports Single Sign-on using <ph name="EXTENSIBLE_ENTERPRISE_SSO_PRODUCT_NAME">Extensible Enterprise SSO</ph> for the following identity providers: Microsoft.
<ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> only supports Single Sign-on using <ph name="EXTENSIBLE_ENTERPRISE_SSO_PRODUCT_NAME">Extensible Enterprise SSO</ph> for the following identity providers: Microsoft, Okta.
This feature is available starting in <ph name="MAC_OS_NAME">macOS</ph> 10.15.
owners:
- ydago@chromium.org
- ssolarewicz@chromium.org
- file://components/policy/OWNERS
supported_on:
@@ -35,6 +36,7 @@ schema:
enum:
- all
- microsoft
- okta
type: string
type: array
items:
@@ -44,6 +46,11 @@ items:
- caption: Microsoft® cloud identity provider
name: microsoft
value: microsoft
- caption: Okta® cloud identity provider
name: okta
value: okta
supported_on:
- chrome.mac:146-
example_value:
- all
tags: []
@@ -40,9 +40,9 @@ schema:
type: string
type: array
# LINT.ThenChange(//chromeos/ash/components/osauth/public/auth_policy_utils.cc:LocalAuthFactorsPolicyMap)
default_for_enterprise_users: []
future_on:
- chrome_os
tags: []
type: string-enum-list
type: string-enum-list
@@ -27,6 +27,7 @@ features:
type: int-enum
# LINT.IfChange
schema:
type: integer
enum:
@@ -34,6 +35,7 @@ schema:
- 2
- 3
- 4
# LINT.ThenChange(//chromeos/ash/services/auth_factor_config/public/mojom/auth_factor_config.mojom:LocalAuthFactorsComplexity)
items:
- caption: No Complexity
@@ -4,10 +4,6 @@ desc: |-
Setting the policy to Enabled makes the New Tab page the user's homepage, ignoring any homepage URL location. Setting the policy to Disabled means that their homepage is never the New Tab page, unless the user's homepage URL is set to chrome://newtab.
If you set the policy, users can't change their homepage type in <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph>. If not set, the user decides whether or not the New Tab page is their homepage.
On <ph name="MS_WIN_NAME">Microsoft® Windows®</ph>, this policy is only available on instances that are joined to a <ph name="MS_AD_NAME">Microsoft® Active Directory®</ph> domain, joined to <ph name="MS_AAD_NAME">Microsoft® Azure® Active Directory®</ph> or enrolled in <ph name="CHROME_ENTERPRISE_CORE_NAME">Chrome Enterprise Core</ph>.
On <ph name="MAC_OS_NAME">macOS</ph>, this policy is only available on instances that are managed via MDM, joined to a domain via MCX or enrolled in <ph name="CHROME_ENTERPRISE_CORE_NAME">Chrome Enterprise Core</ph>.
example_value: true
features:
can_be_recommended: true
@@ -7,10 +7,6 @@ desc: |-
The URL needs a standard scheme, such as http://example.com or https://example.com. When this policy is set, users can't change their homepage URL in <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph>.
Leaving both <ph name="HOMEPAGE_LOCATION_POLICY_NAME">HomepageLocation</ph> and <ph name="HOMEPAGE_IS_NEW_TAB_PAGE_POLICY_NAME">HomepageIsNewTabPage</ph> unset lets users choose their homepage.
On <ph name="MS_WIN_NAME">Microsoft® Windows®</ph>, this policy is only available on instances that are joined to a <ph name="MS_AD_NAME">Microsoft® Active Directory®</ph> domain, joined to <ph name="MS_AAD_NAME">Microsoft® Azure® Active Directory®</ph> or enrolled in <ph name="CHROME_ENTERPRISE_CORE_NAME">Chrome Enterprise Core</ph>.
On <ph name="MAC_OS_NAME">macOS</ph>, this policy is only available on instances that are managed via MDM, joined to a domain via MCX or enrolled in <ph name="CHROME_ENTERPRISE_CORE_NAME">Chrome Enterprise Core</ph>.
example_value: https://www.chromium.org
features:
can_be_recommended: true
@@ -9,10 +9,6 @@ desc: |-
It is a best practice to provide fully canonicalized URL, if the URL is not fully canonicalized <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> will default to https://.
Leaving the policy unset or empty puts the default New Tab page in use.
On <ph name="MS_WIN_NAME">Microsoft® Windows®</ph>, this policy is only available on instances that are joined to a <ph name="MS_AD_NAME">Microsoft® Active Directory®</ph> domain, joined to <ph name="MS_AAD_NAME">Microsoft® Azure® Active Directory®</ph> or enrolled in <ph name="CHROME_ENTERPRISE_CORE_NAME">Chrome Enterprise Core</ph>.
On <ph name="MAC_OS_NAME">macOS</ph>, this policy is only available on instances that are managed via MDM, joined to a domain via MCX or enrolled in <ph name="CHROME_ENTERPRISE_CORE_NAME">Chrome Enterprise Core</ph>.
example_value: https://www.chromium.org
features:
dynamic_refresh: true
@@ -41,6 +41,7 @@
#include "base/no_destructor.h"
#include "base/observer_list.h"
#include "base/process/process.h"
#include "base/strings/strcat.h"
#include "base/strings/string_split.h"
#include "base/strings/string_util.h"
#include "base/strings/stringprintf.h"
@@ -208,7 +209,6 @@
#include "third_party/blink/public/mojom/frame/fullscreen.mojom.h"
#include "third_party/blink/public/mojom/image_downloader/image_downloader.mojom.h"
#include "third_party/blink/public/mojom/input/input_handler.mojom-shared.h"
#include "third_party/blink/public/mojom/mediastream/media_stream.mojom-shared.h"
#include "third_party/blink/public/mojom/mediastream/media_stream.mojom.h"
#include "third_party/blink/public/mojom/page/draggable_region.mojom.h"
#include "third_party/blink/public/mojom/window_features/window_features.mojom.h"
@@ -1953,9 +1953,6 @@ std::vector<RenderFrameHostImpl*> WebContentsImpl::GetOutermostMainFrames() {
// sometimes exceed 1. For example, for WebUIBrowser, when a prerendering code
// path is triggered, a prerender frame tree is generated, but the path to
// activate or discard it does not run before this point.
//
// TODO(webium): Fix prerendering and bfcache for WebUIBrowser, which are not
// yet fully enabled.
DCHECK(
!GetOuterWebContents() || (result.size() == 1) ||
base::FeatureList::IsEnabled(features::kAttachUnownedInnerWebContents));
@@ -1963,6 +1960,37 @@ std::vector<RenderFrameHostImpl*> WebContentsImpl::GetOutermostMainFrames() {
return result;
}
std::vector<RenderFrameHostImpl*>
WebContentsImpl::GetOutermostMainFramesForViewChange() {
// Do nothing if the WebContents is currently being initialized or destroyed.
if (!GetPrimaryMainFrame()) {
return {};
}
std::vector<RenderFrameHostImpl*> result;
result.push_back(GetPrimaryMainFrame());
if (auto* speculative_rfh = GetPrimaryFrameTree()
.root()
->render_manager()
->speculative_frame_host()) {
result.push_back(speculative_rfh);
}
for (FrameTree* prerender_frame_tree :
GetPrerenderHostRegistry()->GetPrerenderFrameTrees()) {
DCHECK(prerender_frame_tree->GetMainFrame());
result.push_back(prerender_frame_tree->GetMainFrame());
}
for (const auto& entry : GetController().GetBackForwardCache().GetEntries()) {
result.push_back(entry->render_frame_host());
}
return result;
}
#if BUILDFLAG(IS_MAC) && BUILDFLAG(USE_EXTERNAL_POPUP_MENU)
void WebContentsImpl::DecrementForbidExternalPopupMenus() {
DCHECK_GE(external_popup_menus_forbid_counter_, 1);
@@ -3252,13 +3280,6 @@ void WebContentsImpl::AttachInnerWebContentsImpl(
inner_web_contents_impl->GetRenderManager();
RenderFrameHostImpl* inner_main_frame =
inner_render_manager->current_frame_host();
RenderViewHostImpl* inner_render_view_host =
inner_main_frame->render_view_host();
RenderFrameHostImpl* inner_speculative_frame =
inner_render_manager->speculative_frame_host();
RenderViewHostImpl* inner_speculative_render_view_host =
inner_speculative_frame ? inner_speculative_frame->render_view_host()
: nullptr;
auto* outer_render_manager =
render_frame_host_impl->frame_tree_node()->render_manager();
@@ -3273,52 +3294,36 @@ void WebContentsImpl::AttachInnerWebContentsImpl(
GetContentClient()->browser()->GetWebContentsViewDelegate(
inner_web_contents_impl),
&inner_web_contents_impl->render_view_host_delegate_view_);
// On platforms where destroying the WebContents' view does not also destroy
// the platform RenderWidgetHostView, we need to destroy it if it exists.
// TODO(mcnee): Should all platforms' WebContentsView destroy the platform
// RWHV?
if (RenderWidgetHostViewBase* prev_rwhv =
inner_render_manager->GetRenderWidgetHostView()) {
if (!prev_rwhv->IsRenderWidgetHostViewChildFrame()) {
prev_rwhv->Destroy();
}
}
// Do the same for speculative render frame host's view.
if (inner_speculative_frame) {
RenderWidgetHostViewBase* prev_speculative_rwhv =
static_cast<RenderWidgetHostViewBase*>(
inner_speculative_frame->GetView());
if (prev_speculative_rwhv &&
!prev_speculative_rwhv->IsRenderWidgetHostViewChildFrame()) {
prev_speculative_rwhv->Destroy();
}
}
// When the WebContents being initialized has not already navigated, the
// browser side Render{View,Frame}Host must be initialized and the
// RenderWidgetHostView created. This is needed because the usual
// initialization happens during the first navigation, but not all guest types
// navigate before attaching. If the browser side is already initialized, the
// calls below will just early return.
inner_render_manager->InitRenderView(
inner_main_frame->GetSiteInstance()->group(), inner_render_view_host,
/*proxy=*/nullptr, /*navigation_metrics_token=*/std::nullopt);
if (!inner_render_manager->GetRenderWidgetHostView()) {
inner_web_contents_impl->CreateRenderWidgetHostViewForRenderManager(
inner_render_view_host);
}
// Do the same for speculative render frame host.
if (inner_speculative_render_view_host) {
inner_render_manager->InitRenderView(
inner_speculative_frame->GetSiteInstance()->group(),
inner_speculative_render_view_host,
/*proxy=*/nullptr, /*navigation_metrics_token=*/std::nullopt);
RenderWidgetHostViewBase* speculative_rwhv =
static_cast<RenderWidgetHostViewBase*>(
inner_speculative_frame->GetView());
if (!speculative_rwhv) {
inner_web_contents_impl->CreateRenderWidgetHostViewForRenderManager(
inner_speculative_render_view_host);
// Update views for all outermost main frames impacted by the view change of
// the inner WebContents, including speculative render frame host and the
// ones in prerender and BFCache.
for (auto* rfh :
inner_web_contents_impl->GetOutermostMainFramesForViewChange()) {
// On platforms where destroying the WebContents' view does not also destroy
// the platform RenderWidgetHostView, we need to destroy it if it exists.
// TODO(mcnee): Should all platforms' WebContentsView destroy the platform
// RWHV?
if (RenderWidgetHostViewBase* prev_rwhv =
static_cast<RenderWidgetHostViewBase*>(rfh->GetView())) {
if (prev_rwhv && !prev_rwhv->IsRenderWidgetHostViewChildFrame()) {
prev_rwhv->Destroy();
}
}
// When the WebContents being initialized has not already navigated, the
// browser side Render{View,Frame}Host must be initialized and the
// RenderWidgetHostView created. This is needed because the usual
// initialization happens during the first navigation, but not all guest
// types navigate before attaching. If the browser side is already
// initialized, the calls below will just early return.
auto* render_manager = rfh->frame_tree_node()->render_manager();
RenderViewHostImpl* rvh = rfh->render_view_host();
render_manager->InitRenderView(rfh->GetSiteInstance()->group(), rvh,
/*proxy=*/nullptr,
/*navigation_metrics_token=*/std::nullopt);
if (!rfh->GetView()) {
inner_web_contents_impl->CreateRenderWidgetHostViewForRenderManager(rvh);
}
}
@@ -3391,21 +3396,24 @@ void WebContentsImpl::DetachUnownedInnerWebContents(
// RenderWidgetHostView are of type RenderWidgetHostViewChildFrame and they
// need to be re-created with appropriate platform views.
// Do this for all outermost main frames including speculative render frame
// host and the ones in prerender and BFCache.
std::vector<RenderViewHostImpl*> list_of_rvh_with_rwhv;
inner_web_contents_impl->GetPrimaryFrameTree().ForEachRenderViewHost(
[&list_of_rvh_with_rwhv](RenderViewHostImpl* rvh) {
if (rvh->GetWidget() && rvh->GetWidget()->GetView()) {
// While in theory only child frame RWHVs should exist at this stage,
// in practice, a race with navigation cleanup could result in a main
// frame RWHV that is pending deletion still existing here.
// This might happen when a WebContents is destroyed immediately
// after it navigates and then attaches to an outer WebContents.
if (rvh->GetWidget()->GetView()->IsRenderWidgetHostViewChildFrame()) {
list_of_rvh_with_rwhv.push_back(rvh);
}
rvh->GetWidget()->GetView()->Destroy();
}
});
for (auto* rfh :
inner_web_contents_impl->GetOutermostMainFramesForViewChange()) {
RenderViewHostImpl* rvh = rfh->render_view_host();
if (rvh->GetWidget() && rvh->GetWidget()->GetView()) {
// While in theory only child frame RWHVs should exist at this stage,
// in practice, a race with navigation cleanup could result in a main
// frame RWHV that is pending deletion still existing here.
// This might happen when a WebContents is destroyed immediately
// after it navigates and then attaches to an outer WebContents.
if (rvh->GetWidget()->GetView()->IsRenderWidgetHostViewChildFrame()) {
list_of_rvh_with_rwhv.push_back(rvh);
}
rvh->GetWidget()->GetView()->Destroy();
}
}
// Destroy WebContentsViewChildFrame.
inner_web_contents_impl->render_view_host_delegate_view_ = nullptr;
@@ -3854,14 +3862,18 @@ const blink::web_pref::WebPreferences WebContentsImpl::ComputeWebPreferences(
prefs.main_frame_resizes_are_orientation_changes = false;
break;
case ui::DEVICE_FORM_FACTOR_TABLET:
// Specific to large tablets (10"), by default they request desktop
// site, but can per-site optionally override it to request mobile
// instead.
case ui::DEVICE_FORM_FACTOR_XR:
// Specific to large tablets (10") and XR devices, by default they
// request desktop site, but can per-site optionally override it to
// request mobile instead.
if (is_request_android_desktop_site) {
apply_desktop_common_settings = true;
}
break;
default:
case ui::DEVICE_FORM_FACTOR_AUTOMOTIVE:
case ui::DEVICE_FORM_FACTOR_TV:
case ui::DEVICE_FORM_FACTOR_FOLDABLE:
case ui::DEVICE_FORM_FACTOR_PHONE:
break;
}
@@ -4299,12 +4311,16 @@ void WebContentsImpl::OnRenderWidgetHostDestroyed(
DCHECK_EQ(1u, num_erased);
}
PrerenderHostId WebContentsImpl::GetPrerenderHostId() {
return PrerenderHostId();
}
void WebContentsImpl::AddWebContentsDestructionObserver(
WebContentsImpl* web_contents) {
OPTIONAL_TRACE_EVENT0(TRACE_DISABLED_BY_DEFAULT("content.verbose"),
"WebContentsImpl::AddWebContentsDestructionObserver");
if (!base::Contains(web_contents_destruction_observers_, web_contents)) {
if (!web_contents_destruction_observers_.contains(web_contents)) {
web_contents_destruction_observers_[web_contents] =
std::make_unique<WebContentsDestructionObserver>(this, web_contents);
}
@@ -4324,8 +4340,8 @@ void WebContentsImpl::AddRenderWidgetHostDestructionObserver(
TRACE_DISABLED_BY_DEFAULT("content.verbose"),
"WebContentsImpl::AddRenderWidgetHostDestructionObserver");
DCHECK(!base::Contains(render_widget_host_destruction_observers_,
render_widget_host));
DCHECK(
!render_widget_host_destruction_observers_.contains(render_widget_host));
render_widget_host_destruction_observers_.insert(
{render_widget_host,
@@ -4356,16 +4372,26 @@ void WebContentsImpl::RemoveObserver(WebContentsObserver* observer) {
std::set<RenderWidgetHostViewBase*>
WebContentsImpl::GetRenderWidgetHostViewsInWebContentsTree() {
std::set<RenderWidgetHostViewBase*> result;
// Views for speculative render frame host could also be frame sink id owner
// and should move frame sink id registration from inner WebContents to outer
// WebContents when WebContents is attached/detached.
GetPrimaryMainFrame()->ForEachRenderFrameHostImplIncludingSpeculative(
[&result](RenderFrameHostImpl* rfh) {
if (auto* view =
static_cast<RenderWidgetHostViewBase*>(rfh->GetView())) {
result.insert(view);
}
});
// Views for speculative render frame host, prerender and BFCache could also
// be frame sink id owner and should move frame sink id registration from
// inner WebContents to outer WebContents when WebContents is
// attached/detached.
auto* speculative_main_frame =
GetPrimaryFrameTree().root()->render_manager()->speculative_frame_host();
for (auto* main_frame : GetOutermostMainFramesForViewChange()) {
if (main_frame == speculative_main_frame) {
// Skip speculative main frame host as it will be handled by
// main_frame->ForEachRenderFrameHostImplIncludingSpeculative.
continue;
}
main_frame->ForEachRenderFrameHostImplIncludingSpeculative(
[&result](RenderFrameHostImpl* rfh) {
if (auto* view =
static_cast<RenderWidgetHostViewBase*>(rfh->GetView())) {
result.insert(view);
}
});
}
return result;
}
@@ -8999,7 +9025,7 @@ void WebContentsImpl::RunFileChooser(
// Do not allow background tab to open file chooser.
return;
}
if (!delegate_->IsContentsActive(this)) {
if (delegate_ && !delegate_->IsContentsActive(this)) {
// Do not allow inactive tabs to open file chooser.
return;
}
@@ -9333,8 +9359,7 @@ void WebContentsImpl::RenderViewTerminated(RenderViewHost* rvh,
// Cancel any visible dialogs so they are not left dangling over the sad tab.
CancelActiveAndPendingDialogs();
audio_stream_monitor_.RenderProcessGone(
rvh_impl->GetProcess()->GetDeprecatedID());
audio_stream_monitor_.RenderProcessGone(rvh_impl->GetProcess()->GetID());
// Reset the loading progress. TODO(avi): What does it mean to have a
// "renderer crash" when there is more than one renderer process serving a
@@ -10209,6 +10234,20 @@ void WebContentsImpl::DidReceiveInputEvent(
WindowOpenDisposition::CURRENT_TAB);
}
HandleUserInteractionForInputEvent(render_widget_host, event);
}
void WebContentsImpl::SimulateUserInteraction(
RenderWidgetHostImpl* render_widget_host,
const blink::WebInputEvent& event) {
CHECK(IsUserInteractionInputType(event.GetType()));
HandleUserInteractionForInputEvent(render_widget_host, event);
}
void WebContentsImpl::HandleUserInteractionForInputEvent(
RenderWidgetHostImpl* render_widget_host,
const blink::WebInputEvent& event) {
if (!IsUserInteractionInputType(event.GetType())) {
return;
}
@@ -12142,13 +12181,13 @@ std::unique_ptr<PrerenderHandle> WebContentsImpl::StartPrerendering(
#endif // BUILDFLAG(IS_ANDROID)
attributes.holdback_status_override = holdback_status_override;
FrameTreeNodeId frame_tree_node_id =
PrerenderHostId prerender_host_id =
GetPrerenderHostRegistry()->CreateAndStartHost(attributes,
preloading_attempt);
if (frame_tree_node_id) {
if (prerender_host_id) {
return std::make_unique<PrerenderHandleImpl>(
GetPrerenderHostRegistry()->GetWeakPtr(), frame_tree_node_id,
GetPrerenderHostRegistry()->GetWeakPtr(), prerender_host_id,
prerendering_url, std::move(no_vary_search_hint));
}
return nullptr;
@@ -12232,8 +12271,14 @@ bool WebContentsImpl::CancelPrerendering(FrameTreeNode* frame_tree_node,
return frame_tree_node->GetParentOrOuterDocumentOrEmbedder()
->CancelPrerendering(PrerenderCancellationReason(final_status));
}
PrerenderHost* prerender_host =
GetPrerenderHostRegistry()->FindNonReservedHostById(
frame_tree_node->frame_tree_node_id());
if (!prerender_host) {
return false;
}
return GetPrerenderHostRegistry()->CancelHost(
frame_tree_node->frame_tree_node_id(), final_status);
prerender_host->prerender_host_id(), final_status);
}
ui::mojom::VirtualKeyboardMode WebContentsImpl::GetVirtualKeyboardMode() const {
@@ -25,7 +25,7 @@
#include "content/public/common/content_features.h"
#include "content/public/common/content_switches.h"
#include "device/base/features.h"
#include "device/fido/features.h"
#include "device/fido/public/features.h"
#include "device/gamepad/public/cpp/gamepad_features.h"
#include "device/vr/buildflags/buildflags.h"
#include "gpu/config/gpu_finch_features.h"
@@ -206,6 +206,8 @@ void SetRuntimeFeaturesFromChromiumFeatures() {
kSetOnlyIfOverridden},
{wf::EnableDocumentPolicyNegotiation,
raw_ref(features::kDocumentPolicyNegotiation)},
{wf::EnableEmailVerificationProtocol,
raw_ref(features::kEmailVerificationProtocol), kDefault},
{wf::EnableEyeDropperAPI, raw_ref(features::kEyeDropper),
kSetOnlyIfOverridden},
{wf::EnableFedCm, raw_ref(features::kFedCm), kSetOnlyIfOverridden},
@@ -357,8 +359,6 @@ void SetRuntimeFeaturesFromChromiumFeatures() {
#endif
{"CompressionDictionaryTransport",
raw_ref(network::features::kCompressionDictionaryTransport)},
{"CookieDeprecationFacilitatedTesting",
raw_ref(features::kCookieDeprecationFacilitatedTesting)},
{"CookieStoreAPIMaxAge",
raw_ref(blink::features::kCookieStoreAPIMaxAge)},
{"DocumentPolicyIncludeJSCallStacksInCrashReports",
@@ -415,7 +415,10 @@ void SetRuntimeFeaturesFromChromiumFeatures() {
{"WebAppLaunchQueue", raw_ref(features::kAndroidWebAppLaunchHandler)},
#endif
{"LocalNetworkAccessPermissionPolicy",
raw_ref(network::features::kLocalNetworkAccessChecks)}};
raw_ref(network::features::kLocalNetworkAccessChecks)},
{"LocalNetworkAccessSplitPermissions",
raw_ref(
network::features::kLocalNetworkAccessChecksSplitPermissions)}};
for (const auto& mapping : runtimeFeatureNameToChromiumFeatureMapping) {
SetRuntimeFeatureFromChromiumFeature(
*mapping.chromium_feature, mapping.option, [&mapping](bool enabled) {
@@ -645,6 +648,17 @@ void ResolveInvalidConfigurations() {
WebRuntimeFeatures::EnablePermissionElement(false);
}
// UserMediaElement cannot be enabled without the support of the
// browser process.
if (!base::FeatureList::IsEnabled(blink::features::kUserMediaElement)) {
LOG_IF(WARNING,
WebRuntimeFeatures::IsUserMediaElementEnabledByRuntimeFlag())
<< "UserMediaElement cannot be enabled in this configuration. Use --"
<< switches::kEnableFeatures << "="
<< blink::features::kUserMediaElement.name << " instead.";
WebRuntimeFeatures::EnableUserMediaElement(false);
}
// CSP Hashes in V1 cannot be enabled without the support of the network
// service.
if (!base::FeatureList::IsEnabled(
@@ -50,7 +50,6 @@
#include "content/public/browser/render_frame_host.h"
#include "content/public/browser/responsiveness_calculator_delegate.h"
#include "content/public/browser/sms_fetcher.h"
#include "content/public/browser/speculation_host_delegate.h"
#include "content/public/browser/tracing_delegate.h"
#include "content/public/browser/url_loader_request_interceptor.h"
#include "content/public/browser/web_authentication_delegate.h"
@@ -725,18 +724,6 @@ bool ContentBrowserClient::IsPrivateAggregationDebugModeAllowed(
return true;
}
bool ContentBrowserClient::IsCookieDeprecationLabelAllowed(
content::BrowserContext* browser_context) {
return false;
}
bool ContentBrowserClient::IsCookieDeprecationLabelAllowedForContext(
content::BrowserContext* browser_context,
const url::Origin& top_frame_origin,
const url::Origin& context_origin) {
return false;
}
bool ContentBrowserClient::IsFullCookieAccessAllowed(
content::BrowserContext* browser_context,
content::WebContents* web_contents,
@@ -1227,7 +1214,7 @@ void ContentBrowserClient::ConfigureNetworkContextParams(
network::mojom::NetworkContextParams* network_context_params,
cert_verifier::mojom::CertVerifierCreationParams*
cert_verifier_creation_params) {
network_context_params->user_agent = GetUserAgentBasedOnPolicy(context);
network_context_params->user_agent = GetUserAgent();
network_context_params->accept_language = "en-us,en";
}
@@ -1413,8 +1400,8 @@ bool ContentBrowserClient::CanAcceptUntrustedExchangesIfNeeded() {
void ContentBrowserClient::OnNetworkServiceDataUseUpdate(
GlobalRenderFrameHostId render_frame_host_id,
int32_t network_traffic_annotation_id_hash,
int64_t recv_bytes,
int64_t sent_bytes) {}
base::ByteSize recv_bytes,
base::ByteSize sent_bytes) {}
base::FilePath ContentBrowserClient::GetSandboxedStorageServiceDataDirectory() {
return base::FilePath();
@@ -1451,11 +1438,6 @@ std::string ContentBrowserClient::GetUserAgent() {
return std::string();
}
std::string ContentBrowserClient::GetUserAgentBasedOnPolicy(
content::BrowserContext* content) {
return GetUserAgent();
}
blink::UserAgentMetadata ContentBrowserClient::GetUserAgentMetadata() {
return blink::UserAgentMetadata();
}
@@ -1642,6 +1624,10 @@ bool ContentBrowserClient::DisallowV8FeatureFlagOverridesForSite(
return false;
}
bool ContentBrowserClient::IsAndroidAdvancedProtectionEnabled() {
return false;
}
ukm::UkmService* ContentBrowserClient::GetUkmService() {
return nullptr;
}
@@ -1693,12 +1679,6 @@ ContentBrowserClient::CreateAnchorElementPreconnectDelegate(
return nullptr;
}
std::unique_ptr<SpeculationHostDelegate>
ContentBrowserClient::CreateSpeculationHostDelegate(
RenderFrameHost& render_frame_host) {
return nullptr;
}
std::unique_ptr<PrefetchServiceDelegate>
ContentBrowserClient::CreatePrefetchServiceDelegate(
BrowserContext* browser_context) {
@@ -1775,14 +1755,6 @@ bool ContentBrowserClient::IsThirdPartyStoragePartitioningAllowed(
return true;
}
bool ContentBrowserClient::IsUnpartitionedStorageAccessAllowedByUserPreference(
content::BrowserContext* browser_context,
const GURL& url,
const net::SiteForCookies& site_for_cookies,
const url::Origin& top_frame_origin) {
return true;
}
bool ContentBrowserClient::AreDeprecatedAutomaticBeaconCredentialsAllowed(
content::BrowserContext* browser_context,
const GURL& destination_url,
@@ -2041,5 +2013,8 @@ std::optional<bool> ContentBrowserClient::GetOverrideValueForStaticStorageQuota(
BrowserContext* browser_context) {
return std::nullopt;
}
std::string ContentBrowserClient::GetDnsTxtResolverUrlPrefix() {
return std::string();
}
} // namespace content
@@ -1,25 +0,0 @@
// Copyright 2021 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// Stub namespace for the "chrome_url_overrides" manifest key.
namespace chrome_url_overrides {
dictionary UrlOverrideInfo {
// Override for the chrome://newtab page.
DOMString? newtab;
// Override for the chrome://bookmarks page.
DOMString? bookmarks;
// Override for the chrome://history page.
DOMString? history;
[nodoc] DOMString? activationmessage;
[nodoc] DOMString? keyboard;
};
dictionary ManifestKeys {
// Chrome url overrides. Note that an extension can override only one page.
UrlOverrideInfo chrome_url_overrides;
};
};
@@ -1,55 +0,0 @@
// Copyright 2016 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// The <code>chrome.clipboard</code> API is provided to allow users to
// access data of the clipboard. This is a temporary solution for
// chromeos platform apps until open-web alternative is available. It will be
// deprecated once open-web solution is available, which could be in 2017 Q4.
[platforms=("chromeos"),
implemented_in="extensions/browser/api/clipboard/clipboard_api.h"]
namespace clipboard {
// Supported image types.
enum ImageType {png, jpeg};
enum DataItemType {textPlain, textHtml};
// Additional data item to be added along with the |image_data| to describe
// the |image_data|.
dictionary AdditionalDataItem {
// Type of the additional data item.
DataItemType type;
// Content of the additional data item. Either the plain text string if
// |type| is "textPlain" or markup string if |type| is "textHtml". The
// data can not exceed 2MB.
DOMString data;
};
interface Events {
// Fired when clipboard data changes.
// Requires clipboard and clipboardRead permissions for adding listener to
// chrome.clipboard.onClipboardDataChanged event.
// After this event fires, the clipboard data is available by calling
// document.execCommand('paste').
static void onClipboardDataChanged();
};
callback SetImageDataCallback = void();
interface Functions {
// Sets image data to clipboard.
//
// |imageData|: The encoded image data.
// |type|: The type of image being passed.
// |additionalItems|: Additional data items for describing image data.
// The callback is called with <code>chrome.runtime.lastError</code>
// set to error code if there is an error.
// Requires clipboard and clipboardWrite permissions.
static void setImageData(
ArrayBuffer imageData,
ImageType type,
optional AdditionalDataItem[] additionalItems,
optional SetImageDataCallback callback);
};
};
@@ -61,6 +61,6 @@ namespace contentScripts {
};
dictionary ManifestKeys {
ContentScript[] content_scripts;
ContentScript[]? content_scripts;
};
};
@@ -1,16 +0,0 @@
// Copyright 2021 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// Stub namespace for manifest keys relating to the cross origin isolation
// response headers.
namespace crossOriginIsolation {
dictionary ResponseHeader {
DOMString? value;
};
dictionary ManifestKeys {
ResponseHeader? cross_origin_embedder_policy;
ResponseHeader? cross_origin_opener_policy;
};
};
@@ -92,6 +92,32 @@ namespace declarativeNetRequest {
memoryLimitExceeded
};
// <!-- Lists the types of condition currently supported by RuleCondition, to
// aid feature detection. Must be kept consistent with the RuleCondition
// dictionary. -->
enum RuleConditionKeys {
urlFilter,
regexFilter,
isUrlFilterCaseSensitive,
initiatorDomains,
excludedInitiatorDomains,
requestDomains,
excludedRequestDomains,
topDomains,
excludedTopDomains,
domains,
excludedDomains,
resourceTypes,
excludedResourceTypes,
requestMethods,
excludedRequestMethods,
domainType,
tabIds,
excludedTabIds,
responseHeaders,
excludedResponseHeaders
};
// Describes a single static ruleset.
dictionary Ruleset {
// A non-empty string uniquely identifying the ruleset. IDs beginning with
@@ -190,6 +216,8 @@ namespace declarativeNetRequest {
DOMString[]? excludedValues;
};
// <!-- When adding/removing keys from this dictionary, also update the
// RuleConditionKeys enum. -->
dictionary RuleCondition {
// The pattern which is matched against the network request url.
@@ -321,7 +349,7 @@ namespace declarativeNetRequest {
// initiated requests, the request initiator's domain is considered
// instead.</li>
// </ul>
[nodoc] DOMString[]? topDomains;
DOMString[]? topDomains;
// The rule will not match network requests when the associated top-level
// frame's domain matches one from the list of
@@ -339,7 +367,7 @@ namespace declarativeNetRequest {
// initiated requests, the request initiator's domain is considered
// instead.</li>
// </ul>
[nodoc] DOMString[]? excludedTopDomains;
DOMString[]? excludedTopDomains;
// The rule will only match network requests originating from the list of
// <code>domains</code>.
@@ -587,7 +615,7 @@ namespace declarativeNetRequest {
long? tabId;
// The associated top-level frame URL (if any) for the request.
[nodoc] DOMString? topUrl;
DOMString? topUrl;
// The headers provided by a hypothetical response if the request does not
// get blocked or redirected before it is sent. Represented as an object
@@ -611,7 +639,7 @@ namespace declarativeNetRequest {
};
[nodoc] dictionary ManifestKeys {
DNRInfo declarative_net_request;
DNRInfo? declarative_net_request;
};
dictionary RegexOptions {
@@ -715,11 +743,11 @@ namespace declarativeNetRequest {
// <a href="#safe_rules">unsafe rules</a> must not exceed
// $(ref:MAX_NUMBER_OF_UNSAFE_DYNAMIC_RULES).</li>
// </ul>
// |callback|: Called once the update is complete or has failed. In case of
// an error, $(ref:runtime.lastError) will be set and no change will be made
// to the rule set. This can happen for multiple reasons, such as invalid
// rule format, duplicate rule ID, rule count limit exceeded, internal
// errors, and others.
// |callback|: Promise that resolves once the update is complete.
// In case of an error, the promise will be rejected and no change will be
// made to the rule set. This can happen for multiple reasons, such as
// invalid rule format, duplicate rule ID, rule count limit exceeded,
// internal errors, and others.
static void updateDynamicRules(
UpdateRuleOptions options,
optional EmptyCallback callback);
@@ -728,8 +756,8 @@ namespace declarativeNetRequest {
// optionally filter the list of fetched rules by specifying a
// <code>filter</code>.
// |filter|: An object to filter the list of fetched rules.
// |callback|: Called with the set of dynamic rules. An error might be
// raised in case of transient internal errors.
// |callback|: Promise that resolves with the set of dynamic rules. The
// Promise may be rejected in case of transient internal errors.
static void getDynamicRules(
optional GetRulesFilter filter,
GetRulesCallback callback);
@@ -746,10 +774,11 @@ namespace declarativeNetRequest {
// <li>$(ref:MAX_NUMBER_OF_SESSION_RULES) is the maximum number
// of session rules an extension can add.</li>
// </ul>
// |callback|: Called once the update is complete or has failed. In case of
// an error, $(ref:runtime.lastError) will be set and no change will be made
// to the rule set. This can happen for multiple reasons, such as invalid
// rule format, duplicate rule ID, rule count limit exceeded, and others.
// |callback|: Promise that resolves once the update is complete. In case
// of an error, the promise will be rejected and no change will be
// made to the rule set. This can happen for multiple reasons, such as
// invalid rule format, duplicate rule ID, rule count limit exceeded, and
// others.
static void updateSessionRules(
UpdateRuleOptions options,
optional EmptyCallback callback);
@@ -758,7 +787,7 @@ namespace declarativeNetRequest {
// Callers can optionally filter the list of fetched rules by specifying a
// <code>filter</code>.
// |filter|: An object to filter the list of fetched rules.
// |callback|: Called with the set of session scoped rules.
// |callback|: Promise that resolves with the set of session scoped rules.
static void getSessionRules(
optional GetRulesFilter filter,
GetRulesCallback callback);
@@ -771,25 +800,25 @@ namespace declarativeNetRequest {
// but not across extension updates, i.e. the <code>rule_resources</code>
// manifest key will determine the set of enabled static rulesets on each
// extension update.
// |callback|: Called once the update is complete. In case of an error,
// $(ref:runtime.lastError) will be set and no change will be made to set of
// enabled rulesets. This can happen for multiple reasons, such as invalid
// ruleset IDs, rule count limit exceeded, or internal errors.
// |callback|: Promise that resolves once the update is complete. In case of
// an error, the promise will be rejected and no change will be made to the
// set of enabled rulesets. This can happen for multiple reasons, such as
// invalid ruleset IDs, rule count limit exceeded, or internal errors.
static void updateEnabledRulesets(
UpdateRulesetOptions options,
optional EmptyCallback callback);
// Returns the ids for the current set of enabled static rulesets.
// |callback|: Called with a list of ids, where each id corresponds to an
// enabled static $(ref:Ruleset).
// |callback|: Promise that resolves with a list of ids, where each id
// corresponds to an enabled static $(ref:Ruleset).
static void getEnabledRulesets(
GetEnabledRulesetsCallback callback);
// Disables and enables individual static rules in a $(ref:Ruleset).
// Changes to rules belonging to a disabled $(ref:Ruleset) will take
// effect the next time that it becomes enabled.
// |callback|: Called once the update is complete. In case of an error,
// $(ref:runtime.lastError) will be set and no change will be made to the
// |callback|: Promise that resolves when the update is complete. In case of
// an error, the promise will be rejected and no change will be made to the
// enabled static rules.
static void updateStaticRules(
UpdateStaticRulesOptions options,
@@ -798,8 +827,8 @@ namespace declarativeNetRequest {
// Returns the list of static rules in the given $(ref:Ruleset) that are
// currently disabled.
// |options|: Specifies the ruleset to query.
// |callback|: Called with a list of ids that correspond to the disabled
// rules in that ruleset.
// |callback|: Promise that resolves with a list of ids that correspond to
// the disabled rules in that ruleset.
static void getDisabledRuleIds(
GetDisabledRuleIdsOptions options,
GetDisabledRuleIdsCallback callback);
@@ -813,10 +842,10 @@ namespace declarativeNetRequest {
// Note: Rules not associated with an active document that were matched more
// than five minutes ago will not be returned.
// |filter|: An object to filter the list of matched rules.
// |callback|: Called once the list of matched rules has been fetched. In
// case of an error, $(ref:runtime.lastError) will be set and no rules will
// be returned. This can happen for multiple reasons, such as insufficient
// permissions, or exceeding the quota.
// |callback|: Promise that resolves once the list of matched rules has been
// fetched. In case of an error, the Promise will be rejected. This can
// happen for multiple reasons, such as insufficient permissions, or
// exceeding the quota.
static void getMatchedRules(
optional MatchedRulesFilter filter,
GetMatchedRulesCallback callback);
@@ -831,8 +860,8 @@ namespace declarativeNetRequest {
// Checks if the given regular expression will be supported as a
// <code>regexFilter</code> rule condition.
// |regexOptions|: The regular expression to check.
// |callback|: Called with details consisting of whether the regular
// expression is supported and the reason if not.
// |callback|: Promise that resolves with details consisting of whether the
// regular expression is supported and the reason if not.
static void isRegexSupported(
RegexOptions regexOptions,
IsRegexSupportedCallback callback);
@@ -848,7 +877,7 @@ namespace declarativeNetRequest {
// Note: Only available for unpacked extensions as this is only intended to
// be used during extension development.
// |requestDetails|: The request details to test.
// |callback|: Called with the details of matched rules.
// |callback|: Promise that resolves with the details of matched rules.
static void testMatchOutcome(
TestMatchRequestDetails request,
TestMatchOutcomeCallback callback);
@@ -1,55 +0,0 @@
// Copyright 2022 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// `file_handlers` manifest key defintion. File Handlers allow developers to
// let extensions interact with files on the operating system. This manifest key
// can be used by developers to register an extension to a given file type.
[generate_error_messages] namespace fileHandlers {
// Icon specification similar to an ImageResource.
dictionary Icon {
// TODO(crbug.com/40238266) Add `DOMString? label;` for accessibility.
// URL from which a user agent can fetch image data.
DOMString src;
// Multiple space-separated size values to also accommodate image formats
// that can act as containers for multiple images of varying dimensions:
// e.g. "16x16", "16x16 32x32".
DOMString? sizes;
// MIME type is purely advisory with no default value.
DOMString? type;
};
// A FileHandler registers the ability to read, stream, or edit files of given
// MIME types and/or file extensions.
dictionary FileHandler {
// A mapping of one or more MIME types to one or more file extensions.
// e.g. "accept": {"text/csv": ".csv"} or {"text/csv": [".csv", ".txt"]}.
object accept;
// Specifies the url after the origin that is the navigation destination for
// file handling launches.
DOMString action;
// Description of the file type.
DOMString name;
// Array of ImageResources. Only icons declared at the manifest level are
// currently supported. The icon for the extension will appear in the "Open"
// menu.
Icon[]? icons;
// Whether multiple files should be opened in a single client or multiple.
// Defaults to `single-client`, which makes all files available in only one
// tab. `multiple-client` opens a new tab for each file.
DOMString? launch_type;
};
dictionary ManifestKeys {
// File Handlers to register onto the target system.
FileHandler[] file_handlers;
};
};
@@ -18,6 +18,6 @@
};
dictionary ManifestKeys {
IconVariant[] icon_variants;
IconVariant[]? icon_variants;
};
};
@@ -1,22 +0,0 @@
// Copyright 2021 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// Stub namespace for the "oauth2" manifest key.
namespace oauth2 {
dictionary OAuth2Info {
// Whether the approval UI should be skipped. Only available to allowlisted
// extensions/apps.
[nodoc] boolean? auto_approve;
// Client ID of the corresponding extension/app.
DOMString? client_id;
// Scopes the extension/app needs access to.
DOMString[] scopes;
};
dictionary ManifestKeys {
OAuth2Info oauth2;
};
};
@@ -66,14 +66,15 @@ namespace offscreen {
interface Functions {
// Creates a new offscreen document for the extension.
// |parameters|: The parameters describing the offscreen document to create.
// |callback|: Invoked when the offscreen document is created and has
// completed its initial page load.
// |callback|: Promise that resolves when the offscreen document is created
// and has completed its initial page load.
static void createDocument(
CreateParameters parameters,
VoidCallback callback);
// Closes the currently-open offscreen document for the extension.
// |callback|: Invoked when the offscreen document has been closed.
// |callback|: Promise that resolves when the offscreen document has been
// closed.
static void closeDocument(VoidCallback callback);
// Determines whether the extension has an active document.
@@ -81,8 +82,8 @@ namespace offscreen {
// ship in its current form (hence the nodoc). Instead of this, we should
// integrate offscreen documents into a service worker-compatible getViews()
// alternative. But this is pretty useful in testing environments.
// |callback|: Invoked with the result of whether the extension has an
// active offscreen document.
// |callback|: Promise that resolves with the result of whether the
// extension has an active offscreen document.
[nodoc] static void hasDocument(BooleanCallback callback);
};
};
@@ -1,27 +0,0 @@
// Copyright 2025 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// `protocol_handlers` manifest key defintion. Protocol Handlers allow developers
// to let extensions register Custom Handlers for URL's schemes unknown to the
// Browser. This manifest key provides a similar behavior than the Web API
// implementing the Custom Handlers section of the HTML specification.
// https://html.spec.whatwg.org/#custom-handlers
[generate_error_messages] namespace protocolHandlers {
// A ProtocolHandler registers the register a Custom Hanlder for an unknown
// URL scheme.
// https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/manifest.json/protocol_handlers
dictionary ProtocolHandler {
// A string definition of the protocol to handle.
DOMString protocol;
// A string representation of the protocol handlers, displayed to the user when prompting for permissions.
DOMString name;
// A string representing the URL of the protocol handler (must be a localizable property).
DOMString uriTemplate;
};
dictionary ManifestKeys {
ProtocolHandler[] protocol_handlers;
};
};
@@ -1,32 +0,0 @@
// Copyright 2021 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// Stub namespace for the "import" and "export" manifest keys.
[generate_error_messages]
namespace sharedModule {
dictionary Import {
// Extension ID of the shared module this extension or app depends on.
DOMString id;
// Minimum supported version of the shared module.
DOMString? minimum_version;
};
dictionary Export {
// Optional list of extension IDs explicitly allowed to import this Shared
// Module's resources. If no allowlist is given, all extensions are allowed
// to import it.
DOMString[]? allowlist;
};
dictionary ManifestKeys {
// The import field is used by extensions and apps to declare that they
// depend on the resources from particular Shared Modules.
Import[]? import;
// The export field indicates an extension is a Shared Module that exports
// its resources.
Export? export;
};
};

Some files were not shown because too many files have changed in this diff Show More