[AUTO][FILECONTROL] - version 146.0.7680.31 (#2745)

[AUTO][FILECONTROL] - version 146.0.7680.31
This commit is contained in:
uazo
2026-03-27 12:13:00 +01:00
committed by GitHub
163 changed files with 5976 additions and 7943 deletions
+1 -1
View File
@@ -1 +1 @@
145.0.7632.120
146.0.7680.31
@@ -55,7 +55,6 @@
#include "base/base_paths_android.h"
#include "base/base_switches.h"
#include "base/command_line.h"
#include "base/containers/contains.h"
#include "base/feature_list.h"
#include "base/files/scoped_file.h"
#include "base/functional/bind.h"
@@ -238,7 +237,7 @@ std::string AwContentBrowserClient::GetAcceptLangsImpl() {
// If accept languages do not contain en-US, add in en-US which will be
// used with a lower q-value.
if (!base::Contains(locales_string, "en-US")) {
if (!locales_string.contains("en-US")) {
locales_string += ",en-US";
}
return locales_string;
@@ -1095,12 +1094,6 @@ bool AwContentBrowserClient::ShouldLockProcessToSite(
return false;
}
bool AwContentBrowserClient::ShouldEnforceNewCanCommitUrlChecks() {
// TODO(https://crbug.com/326250356): Diagnose any remaining Android WebView
// crashes from these new checks and then remove this function.
return true;
}
void AwContentBrowserClient::WillCreateURLLoaderFactory(
content::BrowserContext* browser_context,
content::RenderFrameHost* frame,
@@ -1303,16 +1296,16 @@ void AwContentBrowserClient::LogWebDXFeatureForCurrentPage(
render_frame_host, feature);
}
content::ContentBrowserClient::PrivateNetworkRequestPolicyOverride
AwContentBrowserClient::ShouldOverridePrivateNetworkRequestPolicy(
content::ContentBrowserClient::LocalNetworkAccessRequestPolicyOverride
AwContentBrowserClient::ShouldOverrideLocalNetworkAccessRequestPolicy(
content::BrowserContext* browser_context,
const url::Origin& origin) {
// Webview does not implement support for deprecation trials, so webview apps
// broken by Private Network Access restrictions cannot help themselves by
// broken by Local Network Access restrictions cannot help themselves by
// registering for the trial.
// See crbug.com/1255675.
return content::ContentBrowserClient::PrivateNetworkRequestPolicyOverride::
kForceAllow;
return content::ContentBrowserClient::
LocalNetworkAccessRequestPolicyOverride::kForceAllow;
}
content::SpeechRecognitionManagerDelegate*
@@ -1527,4 +1520,9 @@ bool AwContentBrowserClient::ShouldAnimateBackForwardTransitions() {
return false;
}
bool AwContentBrowserClient::OriginSupportsConcreteCrossOriginIsolation(
const url::Origin& origin) {
return false;
}
} // namespace android_webview
@@ -18,6 +18,7 @@
#include "components/payments/content/android/payment_feature_map.h"
#include "components/permissions/features.h"
#include "components/safe_browsing/core/common/features.h"
#include "components/stylus_handwriting/android/stylus_handwriting_feature_map.h"
#include "components/variations/feature_overrides.h"
#include "components/viz/common/features.h"
#include "content/public/common/content_features.h"
@@ -32,7 +33,6 @@
#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"
@@ -82,10 +82,6 @@ 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);
@@ -317,4 +313,8 @@ void AwFieldTrials::RegisterFeatureOverrides(base::FeatureList* feature_list) {
// Don't pass the data about browser window position on screen to WebView.
aw_feature_overrides.DisableFeature(ui::kAndroidUseCorrectWindowBounds);
// Launched for WebView. Experimentation needed for Chrome on Android.
aw_feature_overrides.EnableFeature(
stylus_handwriting::android::kProbeStylusWritingInBackground);
}
@@ -180,6 +180,7 @@ interface AudioContext : BaseAudioContext
getter onerror
getter onsinkchange
getter outputLatency
getter playbackStats
getter playoutStats
getter sinkId
method close
@@ -292,6 +293,17 @@ interface AudioParamMap
method has
method keys
method values
interface AudioPlaybackStats
attribute @@toStringTag
getter averageLatency
getter maximumLatency
getter minimumLatency
getter totalDuration
getter underrunDuration
getter underrunEvents
method constructor
method resetLatency
method toJSON
interface AudioPlayoutStats
attribute @@toStringTag
getter averageLatency
@@ -352,6 +364,11 @@ interface AudioWorkletNode : AudioNode
getter port
method constructor
setter onprocessorerror
interface AutofillEvent : Event
attribute @@toStringTag
getter autofillValues
getter refill
method constructor
interface BackForwardCacheRestoration : PerformanceEntry
attribute @@toStringTag
getter pageshowEventEnd
@@ -1365,11 +1382,18 @@ interface ChildNodePart : Part
method replaceChildren
interface Clipboard : EventTarget
attribute @@toStringTag
getter onclipboardchange
method constructor
method read
method readText
method write
method writeText
setter onclipboardchange
interface ClipboardChangeEvent : Event
attribute @@toStringTag
getter changeId
getter types
method constructor
interface ClipboardEvent : Event
attribute @@toStringTag
getter clipboardData
@@ -1514,6 +1538,7 @@ interface CustomElementRegistry
method define
method get
method getName
method initialize
method upgrade
method whenDefined
interface CustomEvent : Event
@@ -1890,6 +1915,7 @@ interface Document : Node
getter contentType
getter cookie
getter currentScript
getter customElementRegistry
getter defaultView
getter designMode
getter dir
@@ -2346,6 +2372,7 @@ interface EditContext : EventTarget
interface Element : Node
attribute @@toStringTag
attribute @@unscopables
getter activeViewTransition
getter anchorElement
getter ariaActiveDescendantElement
getter ariaAtomic
@@ -2414,6 +2441,7 @@ interface Element : Node
getter containerTiming
getter containerTimingIgnore
getter currentCSSZoom
getter customElementRegistry
getter elementTiming
getter firstElementChild
getter headingOffset
@@ -5042,12 +5070,14 @@ interface HTMLTemplateElement : HTMLElement
getter content
getter parseparts
getter shadowRootClonable
getter shadowRootCustomElementRegistry
getter shadowRootDelegatesFocus
getter shadowRootMode
getter shadowRootSerializable
method constructor
setter parseparts
setter shadowRootClonable
setter shadowRootCustomElementRegistry
setter shadowRootDelegatesFocus
setter shadowRootMode
setter shadowRootSerializable
@@ -6438,6 +6468,7 @@ interface NavigateEvent : Event
getter sourceElement
getter userInitiated
method constructor
method deferPageSwap
method intercept
method scroll
interface Navigation : EventTarget
@@ -6474,6 +6505,10 @@ interface NavigationCurrentEntryChangeEvent : Event
getter from
getter navigationType
method constructor
interface NavigationDeferPageSwapController
attribute @@toStringTag
method addRestoreCallback
method constructor
interface NavigationDestination
attribute @@toStringTag
getter id
@@ -7119,6 +7154,7 @@ interface PerformanceLongAnimationFrameTiming : PerformanceEntry
getter renderStart
getter scripts
getter styleAndLayoutStart
getter styleDuration
method constructor
method toJSON
interface PerformanceLongTaskTiming : PerformanceEntry
@@ -7219,6 +7255,7 @@ interface PerformanceScriptTiming : PerformanceEntry
attribute @@toStringTag
getter executionStart
getter forcedStyleAndLayoutDuration
getter forcedStyleDuration
getter invoker
getter invokerType
getter pauseDuration
@@ -9282,6 +9319,7 @@ interface ShadowRoot : DocumentFragment
getter activeElement
getter adoptedStyleSheets
getter clonable
getter customElementRegistry
getter delegatesFocus
getter fullscreenElement
getter host
@@ -9552,8 +9590,10 @@ interface StyleSheetList
method item
interface SubmitEvent : Event
attribute @@toStringTag
getter agentInvoked
getter submitter
method constructor
method respondWith
interface Subscriber
attribute @@toStringTag
getter active
@@ -9766,10 +9806,10 @@ interface TimelineTrigger : AnimationTrigger
method constructor
interface TimelineTriggerRange
attribute @@toStringTag
getter exitRangeEnd
getter exitRangeStart
getter rangeEnd
getter rangeStart
getter activationRangeEnd
getter activationRangeStart
getter activeRangeEnd
getter activeRangeStart
getter timeline
method constructor
interface TimelineTriggerRangeList
@@ -11594,6 +11634,10 @@ interface WebKitMutationObserver
method disconnect
method observe
method takeRecords
interface WebMCPEvent : Event
attribute @@toStringTag
getter toolName
method constructor
interface WebSocket : EventTarget
attribute @@toStringTag
attribute CLOSED
@@ -168,6 +168,9 @@ by a child template that "extends" this file.
<uses-permission android:name="com.google.android.apps.now.CURRENT_ACCOUNT_ACCESS" />
<!-- Permission for using pinned windowing layer for document picture-in-picture. -->
<uses-permission android:name="android.permission.USE_PINNED_WINDOWING_LAYER" />
{% block extra_uses_permissions %}
{% endblock %}
@@ -1116,7 +1119,6 @@ by a child template that "extends" this file.
android:exported="false"
android:autoRemoveFromRecents="true"
android:excludeFromRecents="true"
android:documentLaunchMode="always"
android:noHistory="true"/>
<activity
@@ -1125,7 +1127,6 @@ by a child template that "extends" this file.
android:exported="false"
android:autoRemoveFromRecents="true"
android:excludeFromRecents="true"
android:documentLaunchMode="always"
android:noHistory="true"/>
<activity
@@ -1134,7 +1135,6 @@ by a child template that "extends" this file.
android:exported="false"
android:autoRemoveFromRecents="true"
android:excludeFromRecents="true"
android:documentLaunchMode="always"
android:noHistory="true"/>
<!-- Activities for task manager. -->
@@ -839,7 +839,7 @@ public class CustomTabIntentDataProvider extends BrowserServicesIntentDataProvid
@BrowserServicesIntentDataProvider.CustomTabsUiType
private int getCustomTabsUiType(int requestedUiType) {
if (mNetwork != null) return CustomTabsUiType.NETWORK_BOUND_TAB;
if (isTrustedWebActivity() && resolveDisplayMode() == DisplayMode.MINIMAL_UI) {
if (isTrustedWebActivity()) {
return CustomTabsUiType.TRUSTED_WEB_ACTIVITY;
}
if (!isTrustedIntent()) {
@@ -1068,14 +1068,13 @@ public class CustomTabIntentDataProvider extends BrowserServicesIntentDataProvid
switch (type) {
case CustomTabsUiType.MEDIA_VIEWER:
case CustomTabsUiType.READER_MODE:
case CustomTabsUiType.MINIMAL_UI_WEBAPP:
case CustomTabsUiType.OFFLINE_PAGE:
case CustomTabsUiType.AUTH_TAB:
case CustomTabsUiType.NETWORK_BOUND_TAB:
case CustomTabsUiType.TRUSTED_WEB_ACTIVITY:
case CustomTabsUiType.POPUP:
return false;
case CustomTabsUiType.TRUSTED_WEB_ACTIVITY:
return !ChromeFeatureList.sAndroidWebAppMenuButton.isEnabled();
case CustomTabsUiType.MINIMAL_UI_WEBAPP:
case CustomTabsUiType.DEFAULT:
default:
return true;
@@ -1323,6 +1322,18 @@ public class CustomTabIntentDataProvider extends BrowserServicesIntentDataProvid
if (IntentUtils.safeHasExtra(intent, EXTRA_CUSTOM_CONTENT_ACTIONS)) {
featureUsage.log(CustomTabsFeature.EXTRA_CUSTOM_CONTENT_ACTIONS);
}
if (IntentUtils.safeHasExtra(
intent, CustomTabActivityTimeoutHandler.EXTRA_TIMEOUT_MINUTES)) {
featureUsage.log(CustomTabsFeature.EXTRA_TIMEOUT_MINUTES);
}
if (IntentUtils.safeHasExtra(
intent, CustomTabActivityTimeoutHandler.EXTRA_TIMEOUT_MINUTES_ALLOWED)) {
featureUsage.log(CustomTabsFeature.EXTRA_TIMEOUT_MINUTES_ALLOWED);
}
if (IntentUtils.safeHasExtra(
intent, CustomTabActivityTimeoutHandler.EXTRA_TIMEOUT_PENDING_INTENT)) {
featureUsage.log(CustomTabsFeature.EXTRA_TIMEOUT_PENDING_INTENT);
}
}
@Override
File diff suppressed because it is too large Load Diff
@@ -34,7 +34,6 @@
#include "chrome/browser/autocomplete/zero_suggest_cache_service_factory.h"
#include "chrome/browser/autofill/autofill_entity_data_manager_factory.h"
#include "chrome/browser/autofill/personal_data_manager_factory.h"
#include "chrome/browser/autofill/strike_database_factory.h"
#include "chrome/browser/bookmarks/bookmark_model_factory.h"
#include "chrome/browser/browser_process.h"
#include "chrome/browser/browsing_data/chrome_browsing_data_remover_constants.h"
@@ -80,6 +79,7 @@
#include "chrome/browser/signin/identity_manager_factory.h"
#include "chrome/browser/spellchecker/spellcheck_factory.h"
#include "chrome/browser/spellchecker/spellcheck_service.h"
#include "chrome/browser/strike_database/strike_database_factory.h"
#include "chrome/browser/sync/sync_service_factory.h"
#include "chrome/browser/tpcd/metadata/manager_factory.h"
#include "chrome/browser/translate/chrome_translate_client.h"
@@ -336,10 +336,10 @@ void ChromeBrowsingDataRemoverDelegate::RemoveEmbedderData(
FROM_HERE, slow_pending_tasks_closure_.callback(), kSlowTaskTimeout);
// Embedder-defined DOM-accessible storage currently contains only
// one datatype, which is the durable storage permission.
// one datatype, which is the persistent storage permission.
if (remove_mask &
content::BrowsingDataRemover::DATA_TYPE_EMBEDDER_DOM_STORAGE) {
remove_mask |= constants::DATA_TYPE_DURABLE_PERMISSION;
remove_mask |= constants::DATA_TYPE_PERSISTENT_PERMISSION;
}
if (origin_type_mask &
@@ -416,7 +416,7 @@ void ChromeBrowsingDataRemoverDelegate::RemoveEmbedderData(
HistoryServiceFactory::GetForProfile(
profile_, ServiceAccessType::EXPLICIT_ACCESS);
if (history_service) {
// TODO(dmurph): Support all backends with filter (crbug.com/113621).
// TODO(dmurph): Support all backends with filter (crbug.com/40152186).
base::RecordAction(UserMetricsAction("ClearBrowsingData_History"));
history_service->DeleteLocalAndRemoteHistoryBetween(
WebHistoryServiceFactory::GetForProfile(profile_), delete_begin_,
@@ -437,7 +437,7 @@ void ChromeBrowsingDataRemoverDelegate::RemoveEmbedderData(
// The extension activity log contains details of which websites extensions
// were active on. It therefore indirectly stores details of websites a
// user has visited so best clean from here as well.
// TODO(msramek): Support all backends with filter (crbug.com/589586).
// TODO(msramek): Support all backends with filter (crbug.com/40458377).
extensions::ActivityLog::GetInstance(profile_)->RemoveURLs(
std::set<GURL>());
@@ -469,7 +469,7 @@ void ChromeBrowsingDataRemoverDelegate::RemoveEmbedderData(
prerender::NoStatePrefetchManagerFactory::GetForBrowserContext(
profile_);
if (no_state_prefetch_manager) {
// TODO(dmurph): Support all backends with filter (crbug.com/113621).
// TODO(dmurph): Support all backends with filter (crbug.com/40152186).
no_state_prefetch_manager->ClearData(
prerender::NoStatePrefetchManager::CLEAR_PRERENDER_CONTENTS |
prerender::NoStatePrefetchManager::CLEAR_PRERENDER_HISTORY);
@@ -477,11 +477,11 @@ void ChromeBrowsingDataRemoverDelegate::RemoveEmbedderData(
base::ThreadPool::PostTaskAndReply(
FROM_HERE, {base::TaskPriority::USER_VISIBLE, base::MayBlock()},
base::BindOnce(
&webrtc_logging::DeleteOldAndRecentWebRtcLogFiles,
webrtc_logging::TextLogList::
GetWebRtcLogDirectoryForBrowserContextPath(profile_->GetPath()),
delete_begin_),
base::BindOnce(&webrtc_logging::DeleteOldAndRecentWebRtcLogFiles,
webrtc_logging::TextLogList::
GetWebRtcLogDirectoriesForBrowserContextPath(
profile_->GetPath()),
delete_begin_),
CreateTaskCompletionClosure(TracingDataType::kWebrtcLogs));
#if BUILDFLAG(IS_ANDROID)
@@ -825,11 +825,11 @@ void ChromeBrowsingDataRemoverDelegate::RemoveEmbedderData(
}
//////////////////////////////////////////////////////////////////////////////
// DATA_TYPE_DURABLE_PERMISSION
if (remove_mask & constants::DATA_TYPE_DURABLE_PERMISSION) {
// DATA_TYPE_PERSISTENT_PERMISSION
if (remove_mask & constants::DATA_TYPE_PERSISTENT_PERMISSION) {
host_content_settings_map_->ClearSettingsForOneTypeWithPredicate(
ContentSettingsType::DURABLE_STORAGE, base::Time(), base::Time::Max(),
website_settings_filter);
ContentSettingsType::PERSISTENT_STORAGE, base::Time(),
base::Time::Max(), website_settings_filter);
}
//////////////////////////////////////////////////////////////////////////////
@@ -1036,7 +1036,7 @@ void ChromeBrowsingDataRemoverDelegate::RemoveEmbedderData(
//////////////////////////////////////////////////////////////////////////////
// DATA_TYPE_FORM_DATA
// TODO(dmurph): Support all backends with filter (crbug.com/113621).
// TODO(dmurph): Support all backends with filter (crbug.com/40152186).
if (remove_mask & constants::DATA_TYPE_FORM_DATA) {
base::RecordAction(UserMetricsAction("ClearBrowsingData_Autofill"));
scoped_refptr<autofill::AutofillWebDataService> web_data_service =
@@ -1056,10 +1056,10 @@ void ChromeBrowsingDataRemoverDelegate::RemoveEmbedderData(
// TODO(crbug.com/40594007): Respect |delete_begin_| and |delete_end_| and
// only clear out entries whose last strikes were created in that
// timeframe.
strike_database::StrikeDatabase* strike_database =
autofill::StrikeDatabaseFactory::GetForProfile(profile_);
if (strike_database)
if (strike_database::StrikeDatabase* strike_database =
StrikeDatabaseFactory::GetForProfile(profile_)) {
strike_database->ClearAllStrikes();
}
autofill::PersonalDataManager* data_manager =
autofill::PersonalDataManagerFactory::GetForBrowserContext(profile_);
@@ -1734,7 +1734,12 @@ void ChromeBrowsingDataRemoverDelegate::DisablePasswordsAutoSignin(
TracingDataType::kDisableAutoSigninForProfilePasswords));
}
if (account_store &&
password_manager::features_util::IsAccountStorageEnabled(sync_service)) {
// TODO(crbug.com/470332074): This should check for
// "enabled" instead of "active" because this code is just trying to
// delete data from all relevant places. The if() statement is just making
// sure the storage exists before we make a deletion call on it. This
// seems to match the semantics of "enabled".
password_manager::features_util::IsAccountStorageActive(sync_service)) {
account_store->DisableAutoSignInForOrigins(
url_filter,
CreateTaskCompletionClosure(
@@ -12,6 +12,7 @@
#include "build/chromeos_buildflags.h"
#include "chrome/browser/accessibility/accessibility_labels_service.h"
#include "chrome/browser/accessibility/accessibility_labels_service_factory.h"
#include "chrome/browser/actor/actor_script_tool_receiver.h"
#include "chrome/browser/buildflags.h"
#include "chrome/browser/dom_distiller/dom_distiller_service_factory.h"
#include "chrome/browser/navigation_predictor/navigation_predictor.h"
@@ -86,7 +87,7 @@
BUILDFLAG(IS_CHROMEOS)
#include "chrome/browser/screen_ai/screen_ai_service_router.h"
#include "chrome/browser/screen_ai/screen_ai_service_router_factory.h"
#include "chrome/browser/ui/web_applications/sub_apps_service_impl.h"
#include "chrome/browser/web_applications/sub_apps_service_impl.h"
#endif
#if BUILDFLAG(IS_ANDROID)
@@ -438,6 +439,9 @@ void PopulateChromeFrameBinders(
content::RenderFrameHost* render_frame_host) {
map->Add<image_annotation::mojom::Annotator>(&BindImageAnnotator);
map->Add<blink::mojom::ScriptToolHost>(
&actor::ActorScriptToolReceiver::Create);
map->Add<blink::mojom::AnchorElementMetricsHost>(
&NavigationPredictor::Create);
@@ -542,7 +546,7 @@ void PopulateChromeFrameBinders(
#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \
BUILDFLAG(IS_CHROMEOS)
if (base::FeatureList::IsEnabled(blink::features::kDesktopPWAsSubApps) &&
if (base::FeatureList::IsEnabled(blink::features::kSubApps) &&
!render_frame_host->GetParentOrOuterDocument()) {
// The service binder will reject non-primary main frames, but we still need
// to register it for them because a non-primary main frame could become a
@@ -18,9 +18,11 @@
#include "base/base_switches.h"
#include "base/byte_count.h"
#include "base/check_deref.h"
#include "base/check_op.h"
#include "base/command_line.h"
#include "base/containers/fixed_flat_map.h"
#include "base/containers/fixed_flat_set.h"
#include "base/containers/to_vector.h"
#include "base/dcheck_is_on.h"
#include "base/feature_list.h"
#include "base/files/file_path.h"
@@ -125,10 +127,12 @@
#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"
#include "chrome/browser/preloading/prefetch/search_prefetch/search_prefetch_keep_alive_request_tracker.h"
#include "chrome/browser/preloading/prefetch/search_prefetch/search_prefetch_url_loader.h"
#include "chrome/browser/preloading/prefetch/search_prefetch/search_prefetch_url_loader_interceptor.h"
#include "chrome/browser/preloading/preloading_features.h"
#include "chrome/browser/preloading/preloading_prefs.h"
#include "chrome/browser/preloading/preloading_utils.h"
#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"
@@ -171,13 +175,13 @@
#include "chrome/browser/ui/color/chrome_color_id.h"
#include "chrome/browser/ui/login/http_auth_coordinator.h"
#include "chrome/browser/ui/prefs/pref_watcher.h"
#include "chrome/browser/ui/startup/google_chrome_scheme_util.h"
#include "chrome/browser/ui/tab_contents/chrome_web_contents_view_delegate.h"
#include "chrome/browser/ui/ui_features.h"
#include "chrome/browser/ui/webid/identity_dialog_controller.h"
#include "chrome/browser/ui/webui/chrome_web_ui_controller_factory.h"
#include "chrome/browser/ui/webui/internal_debug_pages_disabled/internal_debug_pages_disabled_ui.h"
#include "chrome/browser/ui/webui/log_web_ui_url.h"
#include "chrome/browser/ui/webui/top_chrome/webui_url_utils.h"
#include "chrome/browser/universal_web_contents_observers.h"
#include "chrome/browser/usb/chrome_usb_delegate.h"
#include "chrome/browser/vr/vr_tab_helper.h"
@@ -205,6 +209,7 @@
#include "chrome/common/secure_origin_allowlist.h"
#include "chrome/common/url_constants.h"
#include "chrome/common/webui_url_constants.h"
#include "chrome/common/webui_url_utils.h"
#include "chrome/grit/generated_resources.h"
#include "chrome/installer/util/google_update_settings.h"
#include "components/autofill/core/common/autofill_features.h"
@@ -238,6 +243,8 @@
#include "components/error_page/common/error_page_switches.h"
#include "components/error_page/common/localized_error.h"
#include "components/google/core/common/google_switches.h"
#include "components/google/core/common/google_util.h"
#include "components/guest_view/buildflags/buildflags.h"
#include "components/heap_profiling/in_process/heap_profiler_controller.h"
#include "components/keep_alive_registry/keep_alive_types.h"
#include "components/keep_alive_registry/scoped_keep_alive.h"
@@ -268,6 +275,7 @@
#include "components/performance_manager/public/performance_manager.h"
#include "components/permissions/content_setting_permission_context_base.h"
#include "components/policy/core/browser/url_list/policy_blocklist_service.h"
#include "components/policy/core/common/features.h"
#include "components/policy/core/common/management/management_service.h"
#include "components/policy/core/common/policy_pref_names.h"
#include "components/pref_registry/pref_registry_syncable.h"
@@ -391,6 +399,7 @@
#include "third_party/blink/public/common/permissions/permission_utils.h"
#include "third_party/blink/public/common/switches.h"
#include "third_party/blink/public/mojom/browsing_topics/browsing_topics.mojom.h"
#include "third_party/blink/public/mojom/navigation/navigation_params.mojom.h"
#include "third_party/blink/public/mojom/use_counter/metrics/web_feature.mojom.h"
#include "third_party/blink/public/public_buildflags.h"
#include "third_party/widevine/cdm/buildflags.h"
@@ -420,14 +429,15 @@
#include "chrome/browser/tracing/tracing_features.h"
#include "chrome/browser/tracing/windows_system_tracing_client_win.h"
#include "chrome/install_static/install_util.h"
#include "chrome/installer/util/isolation_support.h"
#include "chrome/services/util_win/public/mojom/util_win.mojom.h"
#include "content/public/browser/tracing_service.h"
#include "sandbox/win/src/sandbox_policy.h"
#elif BUILDFLAG(IS_MAC)
#include "chrome/browser/browser_process_platform_part_mac.h"
#include "chrome/browser/enterprise/platform_auth/platform_auth_features.h"
#include "chrome/browser/enterprise/platform_auth/platform_auth_proxying_url_loader_factory.h"
#include "chrome/common/chrome_version.h"
#include "components/enterprise/platform_auth/platform_auth_features.h"
#include "components/soda/constants.h"
#include "sandbox/mac/sandbox_serializer.h"
#include "sandbox/policy/mac/params.h"
@@ -464,7 +474,7 @@
#include "chrome/browser/speech/tts_chromeos.h"
#include "chrome/browser/speech/tts_controller_delegate_impl.h"
#include "chrome/browser/ui/ash/system_web_apps/system_web_app_ui_utils.h"
#include "chrome/browser/ui/browser_dialogs.h"
#include "chrome/browser/ui/dialogs/browser_dialogs.h"
#include "chrome/browser/ui/webui/ash/kerberos/kerberos_in_browser_dialog.h"
#include "chrome/common/webui_url_constants.h"
#include "chromeos/ash/components/browser_context_helper/browser_context_types.h"
@@ -525,10 +535,10 @@
#include "chrome/browser/themes/theme_service.h"
#include "chrome/browser/themes/theme_service_factory.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/ui/browser_dialogs.h"
#include "chrome/browser/ui/browser_finder.h"
#include "chrome/browser/ui/browser_list.h"
#include "chrome/browser/ui/chrome_pages.h"
#include "chrome/browser/ui/dialogs/browser_dialogs.h"
#include "chrome/browser/ui/tabs/tab_strip_model.h"
#include "chrome/browser/ui/waap/waap_utils.h"
#include "chrome/browser/ui/webui/chrome_content_browser_client_webui_part.h"
@@ -536,6 +546,8 @@
#include "chrome/browser/web_applications/isolated_web_apps/chrome_content_browser_client_isolated_web_apps_part.h"
#include "chrome/browser/web_applications/isolated_web_apps/isolated_web_app_error_page.h"
#include "chrome/browser/web_applications/isolated_web_apps/isolated_web_app_url_info.h"
#include "chrome/browser/web_applications/isolated_web_apps/iwa_permissions_policy_cache.h"
#include "chrome/browser/web_applications/isolated_web_apps/policy/isolated_web_app_policy_manager.h"
#include "chrome/browser/web_applications/locks/app_lock.h"
#include "chrome/browser/web_applications/policy/web_app_policy_manager.h"
#include "chrome/browser/web_applications/proto/web_app_install_state.pb.h"
@@ -552,6 +564,7 @@
#include "components/password_manager/content/common/web_ui_constants.h"
#include "components/password_manager/core/common/password_manager_features.h"
#include "components/soda/soda_util.h"
#include "components/webapps/isolated_web_apps/types/iwa_origin.h"
#include "components/webapps/isolated_web_apps/url_loading/url_loader_factory.h"
#include "services/network/public/mojom/permissions_policy/permissions_policy_feature.mojom.h"
#include "third_party/blink/public/mojom/installedapp/related_application.mojom.h"
@@ -613,6 +626,15 @@
#include "extensions/common/manifest_handlers/background_info.h"
#include "extensions/common/permissions/permissions_data.h"
#include "extensions/common/switches.h"
#if BUILDFLAG(ENABLE_GUEST_VIEW)
#include "extensions/browser/guest_view/web_view/web_view_guest.h"
#include "extensions/browser/guest_view/web_view/web_view_permission_helper.h"
#include "extensions/browser/guest_view/web_view/web_view_renderer_state.h"
#endif
#elif BUILDFLAG(IS_ANDROID)
#include "chrome/browser/android/guest_view/chrome_content_browser_client_guest_view_part.h"
#endif // BUILDFLAG(ENABLE_EXTENSIONS_CORE)
#if BUILDFLAG(ENABLE_EXTENSIONS)
@@ -625,12 +647,6 @@
#include "extensions/common/user_script.h"
#endif // BUILDFLAG(ENABLE_EXTENSIONS)
#if BUILDFLAG(ENABLE_GUEST_VIEW)
#include "extensions/browser/guest_view/web_view/web_view_guest.h"
#include "extensions/browser/guest_view/web_view/web_view_permission_helper.h"
#include "extensions/browser/guest_view/web_view/web_view_renderer_state.h"
#endif
#if BUILDFLAG(ENABLE_PLUGINS)
#include "chrome/browser/plugins/chrome_content_browser_client_plugins_part.h"
#include "chrome/browser/plugins/plugin_response_interceptor_url_loader_throttle.h"
@@ -711,8 +727,7 @@
#endif // BUILDFLAG(IS_ANDROID)
#if BUILDFLAG(ENABLE_ON_DEVICE_TRANSLATION)
#include "chrome/browser/on_device_translation/component_manager.h"
#include "components/on_device_translation/pref_names.h"
#include "components/on_device_translation/component_manager.h"
#endif // BUILDFLAG(ENABLE_ON_DEVICE_TRANSLATION)
#if BUILDFLAG(ENABLE_REQUEST_HEADER_INTEGRITY)
@@ -809,8 +824,7 @@ bool HandleNewTabPageLocationOverride(
return false;
}
url::Component scheme;
if (!url::ExtractScheme(ntp_location.data(),
static_cast<int>(ntp_location.length()), &scheme)) {
if (!url::ExtractScheme(ntp_location, &scheme)) {
ntp_location = base::StrCat(
{url::kHttpsScheme, url::kStandardSchemeSeparator, ntp_location});
}
@@ -986,13 +1000,24 @@ GetRendererConfiguration(content::RenderProcessHost* render_process_host) {
#endif // !BUILDFLAG(IS_ANDROID)
bool ShouldHonorPolicies() {
bool management_check_required = false;
#if BUILDFLAG(IS_WIN)
return policy::ManagementServiceFactory::GetForPlatform()
->GetManagementAuthorityTrustworthiness() >=
policy::ManagementAuthorityTrustworthiness::TRUSTED;
#else
return true;
management_check_required = true;
#elif BUILDFLAG(IS_MAC)
if (base::FeatureList::GetInstance() &&
base::FeatureList::IsEnabled(
policy::features::kUseManagementServiceForSensitivePolicies)) {
management_check_required = true;
}
#endif
if (management_check_required) {
return policy::ManagementServiceFactory::GetForPlatform()
->GetManagementAuthorityTrustworthiness() >=
policy::ManagementAuthorityTrustworthiness::TRUSTED;
}
return true;
}
// Used by Enterprise policy. Disable blocking of navigations toward external
@@ -1377,6 +1402,9 @@ ChromeContentBrowserClient::ChromeContentBrowserClient() {
#if BUILDFLAG(ENABLE_EXTENSIONS_CORE)
extra_parts_.push_back(
std::make_unique<ChromeContentBrowserClientExtensionsPart>());
#elif BUILDFLAG(IS_ANDROID)
extra_parts_.push_back(
std::make_unique<android::ChromeContentBrowserClientGuestViewPart>());
#endif
#if !BUILDFLAG(IS_ANDROID)
@@ -1452,9 +1480,6 @@ void ChromeContentBrowserClient::RegisterProfilePrefs(
registry->RegisterListPref(prefs::kSSLErrorOverrideAllowedForOrigins);
registry->RegisterBooleanPref(prefs::kCompressionDictionaryTransportEnabled,
true);
#if BUILDFLAG(ENABLE_ON_DEVICE_TRANSLATION)
registry->RegisterBooleanPref(prefs::kTranslatorAPIAllowed, true);
#endif
registry->RegisterBooleanPref(
prefs::kSuppressDifferentOriginSubframeJSDialogs, true);
#if BUILDFLAG(IS_ANDROID)
@@ -1478,6 +1503,8 @@ void ChromeContentBrowserClient::RegisterProfilePrefs(
registry->RegisterBooleanPref(prefs::kDataUrlInSvgUseEnabled, false);
registry->RegisterBooleanPref(prefs::kPartitionedBlobUrlUsage, true);
registry->RegisterBooleanPref(policy::policy_prefs::kXSLTEnabled, false);
registry->RegisterBooleanPref(
policy::policy_prefs::kCSSCustomStateDeprecatedSyntaxEnabled,
/*default_value=*/false);
@@ -1605,7 +1632,7 @@ void ChromeContentBrowserClient::MaybeProxyNetworkBoundRequest(
// the hijacked remote to this.
network::mojom::URLLoaderFactoryParamsPtr params =
network::mojom::URLLoaderFactoryParams::New();
params->process_id = network::mojom::kBrowserProcessId;
params->process_id = network::OriginatingProcess::browser();
params->is_trusted = true;
params->isolation_info = isolation_info;
// Disable CORS wrapping, this is already handled by the caller.
@@ -1757,7 +1784,7 @@ std::optional<GURL> ChromeContentBrowserClient::GetEffectiveURL(
// If the input |url| should be assigned to the Instant renderer, make its
// effective URL distinct from other URLs on the search provider's domain.
// This needs to happen even if |url| corresponds to an isolated origin; see
// https://crbug.com/755595.
// https://crbug.com/41339429.
if (search::ShouldAssignURLToInstantRenderer(url, profile)) {
return search::GetEffectiveURLForInstant(url, profile);
}
@@ -2275,33 +2302,34 @@ size_t ChromeContentBrowserClient::GetProcessCountToIgnoreForLimit() {
#endif
}
std::optional<network::ParsedPermissionsPolicy>
std::optional<std::vector<blink::mojom::IsolatedAppPermissionPolicyEntryPtr>>
ChromeContentBrowserClient::GetPermissionsPolicyForIsolatedWebApp(
content::WebContents* web_contents,
const url::Origin& app_origin) {
content::BrowserContext* browser_context,
const url::Origin& iwa_origin) {
#if !BUILDFLAG(IS_ANDROID)
// Extensions are exempt from manifest policy enforcement and retain the
// default frame permissions policy.
if (app_origin.scheme() == extensions::kExtensionScheme) {
Profile* profile = Profile::FromBrowserContext(browser_context);
web_app::IwaPermissionsPolicyCache* cache =
web_app::IwaPermissionsPolicyCacheFactory::GetForProfile(profile);
if (!cache) {
return std::nullopt;
}
CHECK(web_contents);
Profile* profile =
Profile::FromBrowserContext(web_contents->GetBrowserContext());
auto& registrar =
web_app::WebAppProvider::GetForWebApps(profile)->registrar_unsafe();
std::vector<webapps::AppId> app_ids_for_origin =
registrar.FindAllAppsNestedInUrl(
app_origin.GetURL(), web_app::WebAppFilter::InstalledInChrome());
if (app_ids_for_origin.empty()) {
return network::ParsedPermissionsPolicy();
ASSIGN_OR_RETURN(web_app::IwaOrigin origin,
web_app::IwaOrigin::Create(iwa_origin.GetURL()),
[](auto) { return std::nullopt; });
const web_app::IwaPermissionsPolicyCache::CacheEntry* policy =
cache->GetPolicy(origin);
if (!policy) {
return std::nullopt;
}
return registrar.GetPermissionsPolicy(app_ids_for_origin[0]);
return base::ToVector(*policy, [](const auto& entry) {
return blink::mojom::IsolatedAppPermissionPolicyEntry::New(
entry.feature, entry.allowed_origins);
});
#else
NOTIMPLEMENTED();
return network::ParsedPermissionsPolicy();
return std::nullopt;
#endif
}
@@ -2405,7 +2433,7 @@ void ChromeContentBrowserClient::WillComputeSiteForNavigation(
content::BrowserContext* browser_context,
const GURL& url) {
if (!site_isolation::SiteIsolationPolicy::
IsOriginIsolationForJsOptExceptionsEnabled()) {
IsOriginIsolationForJsOptExceptionsEnabled(browser_context)) {
return;
}
@@ -2755,6 +2783,7 @@ void ChromeContentBrowserClient::AppendExtraCommandLineSwitches(
Profile* profile =
Profile::FromBrowserContext(process->GetBrowserContext());
PrefService* prefs = profile->GetPrefs();
PrefService* local_state = g_browser_process->local_state();
// Currently this pref is only registered if applied via a policy.
if (prefs->HasPrefPath(prefs::kDisable3DAPIs) &&
prefs->GetBoolean(prefs::kDisable3DAPIs)) {
@@ -2770,6 +2799,14 @@ void ChromeContentBrowserClient::AppendExtraCommandLineSwitches(
command_line->AppendSwitch(blink::switches::kDataUrlInSvgUseEnabled);
}
if (prefs->FindPreference(policy::policy_prefs::kXSLTEnabled)
->IsManaged()) {
command_line->AppendSwitchASCII(
blink::switches::kXSLTEnabledPolicy,
prefs->GetBoolean(policy::policy_prefs::kXSLTEnabled) ? "true"
: "false");
}
if (!prefs->GetBoolean(prefs::kPartitionedBlobUrlUsage)) {
command_line->AppendSwitch(
blink::switches::kDisableBlobUrlPartitioning);
@@ -2792,6 +2829,14 @@ void ChromeContentBrowserClient::AppendExtraCommandLineSwitches(
network::switches::kForcePermissionPolicyUnloadDefaultEnabled);
}
if (local_state->GetBoolean(
policy::policy_prefs::
kLocalNetworkAccessPermissionsPolicyDefaultEnabled)) {
command_line->AppendSwitch(
network::switches::
kLocalNetworkAccessPermissionsPolicyDefaultEnabled);
}
if (prefs->GetBoolean(prefs::kWebAudioOutputBufferingEnabled)) {
command_line->AppendSwitch(
blink::switches::kWebAudioBypassOutputBufferingOptOut);
@@ -2847,7 +2892,6 @@ void ChromeContentBrowserClient::AppendExtraCommandLineSwitches(
// base::Feature, but it has a managed policy override. The override is
// communicated to blink via a custom command-line flag. See
// PageSchedulerImpl for the other half of related logic.
PrefService* local_state = g_browser_process->local_state();
const PrefService::Preference* pref = local_state->FindPreference(
policy::policy_prefs::kIntensiveWakeUpThrottlingEnabled);
if (pref && pref->IsManaged()) {
@@ -3232,14 +3276,14 @@ void ChromeContentBrowserClient::AllowWorkerFileSystem(
Profile::FromBrowserContext(browser_context));
bool allow = embedder_support::AllowWorkerFileSystem(
url, {}, cookie_settings.get(), storage_key);
#if BUILDFLAG(ENABLE_GUEST_VIEW)
#if BUILDFLAG(ENABLE_EXTENSIONS_CORE) && BUILDFLAG(ENABLE_GUEST_VIEW)
GuestPermissionRequestHelper(url, render_frames, std::move(callback), allow);
#else
FileSystemAccessed(url, render_frames, std::move(callback), allow);
#endif
#endif // BUILDFLAG(ENABLE_EXTENSIONS_CORE) && BUILDFLAG(ENABLE_GUEST_VIEW)
}
#if BUILDFLAG(ENABLE_GUEST_VIEW)
#if BUILDFLAG(ENABLE_EXTENSIONS_CORE) && BUILDFLAG(ENABLE_GUEST_VIEW)
void ChromeContentBrowserClient::GuestPermissionRequestHelper(
const GURL& url,
const std::vector<content::GlobalRenderFrameHostId>& render_frames,
@@ -3937,7 +3981,7 @@ bool ShouldDisableForcedColorsForWebContent(content::WebContents* contents,
Profile::FromBrowserContext(contents->GetBrowserContext())->GetPrefs();
CHECK(prefs);
const base::Value::List& forced_colors_blocklist =
const base::ListValue& forced_colors_blocklist =
prefs->GetList(prefs::kPageColorsBlockList);
if (forced_colors_blocklist.empty()) {
@@ -4362,12 +4406,12 @@ bool ChromeContentBrowserClient::CanCreateWindow(
return true;
}
#if BUILDFLAG(ENABLE_GUEST_VIEW)
#if BUILDFLAG(ENABLE_EXTENSIONS_CORE) && BUILDFLAG(ENABLE_GUEST_VIEW)
if (extensions::WebViewRendererState::GetInstance()->IsGuest(
opener->GetProcess()->GetDeprecatedID())) {
return true;
}
#endif
#endif // BUILDFLAG(ENABLE_EXTENSIONS_CORE) && BUILDFLAG(ENABLE_GUEST_VIEW)
#if BUILDFLAG(ENABLE_PLATFORM_APPS)
if (target_url.SchemeIs(extensions::kExtensionScheme)) {
@@ -4467,7 +4511,7 @@ void ChromeContentBrowserClient::OverrideWebPreferences(
// Fill font preferences. These are not registered on Android unless we're built
// with extensions (the chrome.fontSettings API can change these).
// - http://crbug.com/308033, http://crbug.com/696364.
// - http://crbug.com/40337093, http://crbug.com/41304476.
#if !BUILDFLAG(IS_ANDROID) || BUILDFLAG(ENABLE_DESKTOP_ANDROID_EXTENSIONS)
// Enabling the FontFamilyCache needs some KeyedService that might not be
// available for some irregular profiles, like the System Profile.
@@ -4599,7 +4643,6 @@ void ChromeContentBrowserClient::OverrideWebPreferences(
switches::kEnablePotentiallyAnnoyingSecurityFeatures)) {
web_prefs->disable_reading_from_canvas = true;
web_prefs->strict_mixed_content_checking = true;
web_prefs->strict_powerful_feature_restrictions = true;
}
web_prefs->data_saver_enabled = IsDataSaverEnabled(profile);
@@ -5090,7 +5133,7 @@ void ChromeContentBrowserClient::GetAdditionalMappedFilesForChildProcess(
std::wstring ChromeContentBrowserClient::GetAppContainerSidForSandboxType(
sandbox::mojom::Sandbox sandbox_type,
AppContainerFlags flags) {
// TODO(wfh): Add support for more process types here. crbug.com/499523
// TODO(wfh): Add support for more process types here. crbug.com/41182255
switch (sandbox_type) {
case sandbox::mojom::Sandbox::kRenderer:
if (flags & AppContainerFlags::kAppContainerFlagDisableAppContainer) {
@@ -5299,6 +5342,10 @@ bool ChromeContentBrowserClient::ShouldRestrictCoreSharingOnRenderer() {
return false;
}
std::optional<std::wstring>
ChromeContentBrowserClient::GetWindowsSecurityAttributeName() const {
return installer::GetIsolationAttributeName();
}
#endif // BUILDFLAG(IS_WIN)
void ChromeContentBrowserClient::
@@ -5467,7 +5514,7 @@ void ChromeContentBrowserClient::UpdateDevToolsBackgroundServiceExpiration(
ScopedDictPrefUpdate pref_update(
pref_service, prefs::kDevToolsBackgroundServicesExpirationDict);
base::Value::Dict& exp_dict = pref_update.Get();
base::DictValue& exp_dict = pref_update.Get();
// Convert |expiration_time| to minutes since that is the most granular
// option that returns an int. base::Value does not accept int64.
@@ -6391,7 +6438,7 @@ void ChromeContentBrowserClient::WillCreateURLLoaderFactory(
// WARNING: This factory blocks certain requests from going out via the
// final network bound factory.
enterprise_auth::ProxyingURLLoaderFactory::MaybeProxyRequest(
request_initiator, type, factory_builder);
request_initiator, type, browser_context, factory_builder);
}
#endif
@@ -6621,7 +6668,7 @@ ChromeContentBrowserClient::GetNetworkContextsParentDirectory() {
return network_contexts_parent_directory_;
}
base::Value::Dict ChromeContentBrowserClient::GetNetLogConstants() {
base::DictValue ChromeContentBrowserClient::GetNetLogConstants() {
return net_log::GetPlatformConstantsForNetLog(
base::CommandLine::ForCurrentProcess()->GetCommandLineString(),
chrome::GetChannelName(chrome::WithExtendedStable(true)));
@@ -6870,6 +6917,30 @@ bool ChromeContentBrowserClient::HandleExternalProtocol(
mojo::PendingRemote<network::mojom::URLLoaderFactory>* out_factory) {
CHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::UI));
#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \
BUILDFLAG(IS_WIN)
// Handle the google-chrome:// scheme (and chromium://).
// If the scheme is present, we strip it and navigate to the inner URL.
// This avoids launching a new browser instance via the OS handler.
if (std::optional<GURL> new_url =
startup::ExtractGoogleChromeSchemeInnerUrl(url)) {
if (startup::ValidateUrl(*new_url)) {
auto* web_contents = web_contents_getter.Run();
if (web_contents) {
content::OpenURLParams params(
*new_url,
content::Referrer(web_contents->GetLastCommittedURL(),
network::mojom::ReferrerPolicy::kDefault),
WindowOpenDisposition::NEW_FOREGROUND_TAB, page_transition,
/*is_renderer_initiated=*/false);
params.initiator_origin = initiating_origin;
web_contents->OpenURL(params, /*navigation_handle_callback=*/{});
return true;
}
}
}
#endif
#if !BUILDFLAG(IS_ANDROID)
content::WebContents* web_contents = web_contents_getter.Run();
if (web_contents && IsActorActingOnWebContents(web_contents)) {
@@ -6978,16 +7049,14 @@ bool ChromeContentBrowserClient::HandleWebUI(
#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \
BUILDFLAG(IS_CHROMEOS)
// Rewrite chrome://settings/autofill and chrome://settings/enhancedAutofill
// to chrome://settings/yourSavedInfo.
// Rewrite chrome://settings/enhancedAutofill to chrome://settings/autofill.
if (url->SchemeIs(content::kChromeUIScheme) &&
url->GetHost() == chrome::kChromeUISettingsHost &&
(url->GetPath() == chrome::kChromeUIAutofillPath ||
url->GetPath() == chrome::kChromeUIAutofillAiPath) &&
url->GetPath() == chrome::kChromeUIAutofillAiPath &&
base::FeatureList::IsEnabled(
autofill::features::kYourSavedInfoSettingsPage)) {
GURL::Replacements replacements;
replacements.SetPathStr(chrome::kChromeUIYourSavedInfoPath);
replacements.SetPathStr(chrome::kChromeUIAutofillPath);
*url = url->ReplaceComponents(replacements);
}
@@ -7644,6 +7713,16 @@ void ChromeContentBrowserClient::IsClipboardCopyAllowedByPolicy(
#endif // BUILDFLAG(ENTERPRISE_DATA_CONTROLS) && !BUILDFLAG(IS_ANDROID)
}
bool ChromeContentBrowserClient::IsDragAllowedByPolicy(
const content::ClipboardEndpoint& source,
const content::DropData& drop_data) {
#if BUILDFLAG(ENTERPRISE_DATA_CONTROLS)
return enterprise_data_protection::IsDragAllowedByPolicy(source, drop_data);
#else
return true;
#endif // BUILDFLAG(ENTERPRISE_DATA_CONTROLS)
}
#if BUILDFLAG(ENABLE_VR)
content::XrIntegrationClient*
ChromeContentBrowserClient::GetXrIntegrationClient() {
@@ -7692,14 +7771,14 @@ void ChromeContentBrowserClient::
// BUILDFLAG(IS_CHROMEOS)
}
content::ContentBrowserClient::PrivateNetworkRequestPolicyOverride
ChromeContentBrowserClient::ShouldOverridePrivateNetworkRequestPolicy(
content::ContentBrowserClient::LocalNetworkAccessRequestPolicyOverride
ChromeContentBrowserClient::ShouldOverrideLocalNetworkAccessRequestPolicy(
content::BrowserContext* browser_context,
const url::Origin& origin) {
#if BUILDFLAG(IS_ANDROID)
if (base::android::device_info::is_automotive()) {
return content::ContentBrowserClient::PrivateNetworkRequestPolicyOverride::
kBlockInsteadOfWarn;
return content::ContentBrowserClient::
LocalNetworkAccessRequestPolicyOverride::kBlockInsteadOfWarn;
}
#endif
@@ -7707,12 +7786,12 @@ ChromeContentBrowserClient::ShouldOverridePrivateNetworkRequestPolicy(
if (profile->GetPrefs()->GetBoolean(
prefs::kManagedLocalNetworkAccessRestrictionsTemporaryOptOut)) {
return content::ContentBrowserClient::PrivateNetworkRequestPolicyOverride::
kWarnInsteadOfBlock;
return content::ContentBrowserClient::
LocalNetworkAccessRequestPolicyOverride::kWarnInsteadOfBlock;
}
return content::ContentBrowserClient::PrivateNetworkRequestPolicyOverride::
kDefault;
return content::ContentBrowserClient::
LocalNetworkAccessRequestPolicyOverride::kDefault;
}
bool ChromeContentBrowserClient::IsJitDisabledForSite(
@@ -8238,23 +8317,6 @@ bool ChromeContentBrowserClient::AreIsolatedWebAppsEnabled(
#endif
}
bool ChromeContentBrowserClient::IsThirdPartyStoragePartitioningAllowed(
content::BrowserContext* browser_context,
const url::Origin& top_level_origin) {
const HostContentSettingsMap* const content_settings =
HostContentSettingsMapFactory::GetForProfile(
Profile::FromBrowserContext(browser_context));
if (!content_settings) {
// We fail permissive as this function is used to check whether partitioning
// should be blocked, but isn't the final word on if it's allowed.
return true;
}
return content_settings->GetContentSetting(
top_level_origin.GetURL(), top_level_origin.GetURL(),
ContentSettingsType::THIRD_PARTY_STORAGE_PARTITIONING) ==
CONTENT_SETTING_ALLOW;
}
bool ChromeContentBrowserClient::AreDeprecatedAutomaticBeaconCredentialsAllowed(
content::BrowserContext* browser_context,
const GURL& destination_url,
@@ -8323,7 +8385,7 @@ bool ChromeContentBrowserClient::DoesGaiaOriginRequireDedicatedProcess() {
return true;
#else
// Sign-in process isolation is not strictly needed on Android, see
// https://crbug.com/739418. On Android, it's more optional but it does
// https://. On Android, it's more optional but it does
// improve security generally and specifically it allows the exposure of
// certain optional privileged APIs.
@@ -8555,8 +8617,7 @@ void ChromeContentBrowserClient::BindAIManager(
if (!context_user_data->GetUserData(kAIManagerUserDataKey)) {
context_user_data->SetUserData(
kAIManagerUserDataKey,
std::make_unique<AIManager>(
browser_context, g_browser_process->component_updater(), rfh));
std::make_unique<AIManager>(browser_context, rfh));
}
AIManager* ai_manager = static_cast<AIManager*>(
@@ -8632,9 +8693,9 @@ void ChromeContentBrowserClient::QueryInstalledWebAppsByManifestId(
base::BindOnce(
[](webapps::AppId app_id, webapps::ManifestId manifest_id,
GURL frame_url, web_app::AppLock& lock,
base::Value::Dict& debug_value)
base::DictValue& debug_value)
-> std::optional<blink::mojom::RelatedApplication> {
debug_value.Set("input", base::Value::Dict()
debug_value.Set("input", base::DictValue()
.Set("manifest_id", manifest_id.spec())
.Set("frame_url", frame_url.spec()));
@@ -8664,7 +8725,7 @@ void ChromeContentBrowserClient::QueryInstalledWebAppsByManifestId(
debug_value.Set("did_find_application", true);
debug_value.Set(
"application",
base::Value::Dict()
base::DictValue()
.Set("app_id", application.id.value_or(""))
.Set("manifest_url", application.url.value_or("")));
return application;
@@ -8769,14 +8830,31 @@ bool ChromeContentBrowserClient::ShouldPrioritizeForBackForwardCache(
->IsSearchResultsPageFromDefaultSearchProvider(url);
}
std::unique_ptr<content::KeepAliveRequestTracker>
std::vector<std::unique_ptr<content::KeepAliveRequestTracker>>
ChromeContentBrowserClient::MaybeCreateKeepAliveRequestTracker(
const network::ResourceRequest& request,
std::optional<ukm::SourceId> ukm_source_id,
content::BrowserContext* browser_context,
content::KeepAliveRequestTracker::IsContextDetachedCallback
is_context_detached_callback) {
return ChromeKeepAliveRequestTracker::MaybeCreateKeepAliveRequestTracker(
request, ukm_source_id, std::move(is_context_detached_callback));
// Do not need to track non-keepalive requests.
if (!request.keepalive || !request.keepalive_token.has_value()) {
return {};
}
std::vector<std::unique_ptr<content::KeepAliveRequestTracker>> trackers;
std::unique_ptr<ChromeKeepAliveRequestTracker> chrome_tracker =
ChromeKeepAliveRequestTracker::MaybeCreateKeepAliveRequestTracker(
request, ukm_source_id, is_context_detached_callback);
if (chrome_tracker) {
trackers.push_back(std::move(chrome_tracker));
}
std::unique_ptr<SearchPrefetchKeepAliveRequestTracker> search_tracker =
SearchPrefetchKeepAliveRequestTracker::MaybeCreateKeepAliveRequestTracker(
request, browser_context);
if (search_tracker) {
trackers.push_back(std::move(search_tracker));
}
return trackers;
}
std::optional<std::vector<std::u16string>>
@@ -8894,3 +8972,27 @@ std::string ChromeContentBrowserClient::GetDnsTxtResolverUrlPrefix() {
"https://dns.google/resolve?type=txt&do=1&name=";
return kGoogleDnsResolverUrl;
}
bool ChromeContentBrowserClient::ShouldAllowPrefetchRedirection(
content::BrowserContext& browser_context,
const GURL& url,
const std::string& embedder_histogram_suffix) {
// TODO(crbug.com/413259638): Use the constant in `preloading_utils` once it
// is created, currently this is set to be the same constant in
// c/b/p/b_p/bookmarkbar_preload_pipeline.cc.
// This function is only interested in specific triggers. The related triggers
// don't generate parameters to be identified by search results providers, so
// the triggering search related urls is avoided. See crbug.com/40282403 for
// more details.
if (embedder_histogram_suffix != preloading_utils::kBookmarkBarMetricSuffix &&
embedder_histogram_suffix != preloading_utils::kNewTabPageMetricSuffix) {
return true;
}
auto* profile = Profile::FromBrowserContext(&browser_context);
TemplateURLService* template_url_service =
TemplateURLServiceFactory::GetForProfile(profile);
return !((template_url_service &&
template_url_service->IsSearchResultsPageFromDefaultSearchProvider(
url)) ||
google_util::IsGoogleSearchUrl(url));
}
@@ -8,7 +8,10 @@
#include "base/feature_list.h"
#include "build/build_config.h"
#include "build/buildflag.h"
#include "chrome/browser/actor/actor_navigation_throttle.h"
#include "chrome/browser/browser_process.h"
#include "chrome/browser/custom_handlers/chrome_protocol_handler_navigation_throttle.h"
#include "chrome/browser/custom_handlers/protocol_handler_registry_factory.h"
#include "chrome/browser/data_sharing/data_sharing_navigation_throttle.h"
#include "chrome/browser/enterprise/data_protection/view_source_navigation_throttle.h"
#include "chrome/browser/first_party_sets/first_party_sets_navigation_throttle.h"
@@ -37,7 +40,11 @@
#include "components/captive_portal/content/captive_portal_service.h"
#include "components/captive_portal/core/buildflags.h"
#include "components/contextual_tasks/public/features.h"
#include "components/custom_handlers/protocol_handler_navigation_throttle.h"
#include "components/dom_distiller/content/browser/distiller_page_web_contents.h"
#include "components/dom_distiller/content/browser/distiller_referrer_throttle.h"
#include "components/dom_distiller/core/url_constants.h"
#include "components/dom_distiller/core/url_utils.h"
#include "components/error_page/content/browser/net_error_auto_reloader.h"
#include "components/guest_view/buildflags/buildflags.h"
#include "components/history/content/browser/visited_link_navigation_throttle.h"
@@ -61,8 +68,11 @@
#include "content/public/browser/web_contents.h"
#include "content/public/common/content_switches.h"
#include "extensions/buildflags/buildflags.h"
#include "extensions/common/extension_features.h"
#include "pdf/buildflags.h"
#include "services/network/public/mojom/referrer_policy.mojom.h"
#include "third_party/blink/public/common/features.h"
#include "third_party/blink/public/mojom/loader/referrer.mojom.h"
#include "url/gurl.h"
#if BUILDFLAG(IS_ANDROID)
@@ -75,7 +85,6 @@
#endif // BUILDFLAG(DFMIFY_DEV_UI)
#else // BUILDFLAG(IS_ANDROID)
#include "chrome/browser/actor/actor_navigation_throttle.h"
#include "chrome/browser/apps/link_capturing/link_capturing_navigation_throttle.h"
#include "chrome/browser/apps/link_capturing/web_app_link_capturing_delegate.h"
#include "chrome/browser/contextual_tasks/contextual_tasks_navigation_throttle.h"
@@ -112,9 +121,9 @@
#include "chrome/browser/ui/web_applications/app_browser_controller.h"
#endif // BUILDFLAG(ENABLE_EXTENSIONS)
#if BUILDFLAG(ENABLE_GUEST_VIEW)
#if BUILDFLAG(ENABLE_GUEST_VIEW) && BUILDFLAG(ENABLE_EXTENSIONS_CORE)
#include "extensions/browser/guest_view/web_view/web_view_guest.h"
#endif
#endif // BUILDFLAG(ENABLE_GUEST_VIEW) && BUILDFLAG(ENABLE_EXTENSIONS_CORE)
#if BUILDFLAG(ENABLE_PDF)
#include "chrome/browser/pdf/chrome_pdf_stream_delegate.h"
@@ -275,7 +284,7 @@ void CreateAndAddChromeThrottlesForNavigation(
#if BUILDFLAG(IS_ANDROID)
// TODO(davidben): This is insufficient to integrate with prerender properly.
// https://crbug.com/370595
// https://crbug.com/40364296
prerender::NoStatePrefetchContents* no_state_prefetch_contents =
prerender::ChromeNoStatePrefetchContentsDelegate::FromWebContents(
handle.GetWebContents());
@@ -314,6 +323,9 @@ void CreateAndAddChromeThrottlesForNavigation(
apps::ChromeOsDisabledAppsThrottle::MaybeCreateAndAdd(registry);
#endif // BUILDFLAG(IS_CHROMEOS)
Profile* profile =
Profile::FromBrowserContext(handle.GetWebContents()->GetBrowserContext());
#if !BUILDFLAG(IS_ANDROID)
std::unique_ptr<apps::LinkCapturingNavigationThrottle::Delegate>
link_capturing_delegate;
@@ -340,10 +352,17 @@ void CreateAndAddChromeThrottlesForNavigation(
#endif // BUILDFLAG(IS_CHROMEOS)
web_app::NavigationCapturingRedirectionThrottle::MaybeCreateAndAdd(registry);
#endif // !BUILDFLAG(IS_ANDROID)
Profile* profile =
Profile::FromBrowserContext(handle.GetWebContents()->GetBrowserContext());
if (base::FeatureList::IsEnabled(
extensions_features::kExtensionProtocolHandlers)) {
// Could be null in some unit tests.
if (auto* protocol_handler_registry =
ProtocolHandlerRegistryFactory::GetForBrowserContext(profile)) {
custom_handlers::ChromeProtocolHandlerNavigationThrottle::
MaybeCreateAndAdd(protocol_handler_registry, registry);
}
}
#endif // !BUILDFLAG(IS_ANDROID)
#if BUILDFLAG(ENABLE_EXTENSIONS_CORE)
if (!extensions::ChromeContentBrowserClientExtensionsPart::
@@ -355,11 +374,12 @@ void CreateAndAddChromeThrottlesForNavigation(
->GetUserScriptListener()
->CreateAndAddNavigationThrottle(registry);
}
#endif
#if BUILDFLAG(ENABLE_GUEST_VIEW)
extensions::WebViewGuest::MaybeCreateAndAddNavigationThrottle(registry);
#endif
#endif // BUILDFLAG(ENABLE_GUEST_VIEW)
#endif // BUILDFLAG(ENABLE_EXTENSIONS_CORE)
SupervisedUserGoogleAuthNavigationThrottle::MaybeCreateAndAdd(registry);
supervised_user::ClassifyUrlNavigationThrottle::MaybeCreateAndAdd(registry);
@@ -570,9 +590,11 @@ void CreateAndAddChromeThrottlesForNavigation(
#if !BUILDFLAG(IS_ANDROID)
web_app::IsolatedWebAppThrottle::MaybeCreateAndAdd(registry);
actor::ActorNavigationThrottle::MaybeCreateAndAdd(registry);
#endif // !BUILDFLAG(IS_ANDROID)
actor::ActorNavigationThrottle::MaybeCreateAndAdd(registry);
dom_distiller::DistillerPageWebContents::MaybeCreateAndAddNavigationThrottle(
registry);
dom_distiller::DistillerReferrerThrottle::MaybeCreateAndAdd(registry);
}
@@ -165,6 +165,11 @@ public abstract class ChromeFeatureList {
"AdaptiveButtonInTopToolbarCustomizationV2";
public static final String ADAPTIVE_BUTTON_IN_TOP_TOOLBAR_PAGE_SUMMARY =
"AdaptiveButtonInTopToolbarPageSummary";
// Don't clean up this flag yet, BCIV is launched, so this needs to be enabled by
// default, but some render tests need to disable this so that the hairline isn't
// included in the screenshot. See https://crbug.com/394842006 for more details.
public static final String ALWAYS_DRAW_COMPOSITED_TOOLBAR_HAIRLINE =
"AlwaysDrawCompositedToolbarHairline";
public static final String ANDROID_ANIMATED_PROGRESS_BAR_IN_BROWSER =
"AndroidAnimatedProgressBarInBrowser";
public static final String ANDROID_APPEARANCE_SETTINGS = "AndroidAppearanceSettings";
@@ -212,13 +217,11 @@ public abstract class ChromeFeatureList {
public static final String ANDROID_THEME_MODULE = "AndroidThemeModule";
public static final String ANDROID_THEME_RESOURCE_PROVIDER = "AndroidThemeResourceProvider";
public static final String ANDROID_TIPS_NOTIFICATIONS = "AndroidTipsNotifications";
public static final String ANDROID_TIPS_NOTIFICATIONS_V2 = "AndroidTipsNotificationsV2";
public static final String ANDROID_TWA_ORIGIN_DISPLAY = "AndroidTWAOriginDisplay";
public static final String ANDROID_USE_ADMINS_FOR_ENTERPRISE_INFO =
"AndroidUseAdminsForEnterpriseInfo";
public static final String ANDROID_WEB_APP_HEADER_FOR_STANDALONE_MODE =
"AndroidWebAppHeaderForStandaloneMode";
public static final String ANDROID_WEB_APP_LAUNCH_HANDLER = "AndroidWebAppLaunchHandler";
public static final String ANDROID_WEB_APP_MENU_BUTTON = "AndroidWebAppMenuButton";
public static final String ANDROID_WINDOW_CONTROLS_OVERLAY = "AndroidWindowControlsOverlay";
public static final String ANDROID_WINDOW_MANAGEMENT_WEB_API = "AndroidWindowManagementWebApi";
public static final String ANDROID_WINDOW_POPUP_CUSTOM_TAB_UI = "AndroidWindowPopupCustomTabUi";
@@ -237,6 +240,7 @@ public abstract class ChromeFeatureList {
public static final String ASYNC_NOTIFICATION_MANAGER = "AsyncNotificationManager";
public static final String ASYNC_NOTIFICATION_MANAGER_FOR_DOWNLOAD =
"AsyncNotificationManagerForDownload";
public static final String AUTOFILL_AI_WITH_DATA_SCHEMA = "AutofillAiWithDataSchema";
public static final String AUTOFILL_ALLOW_NON_HTTP_ACTIVATION =
"AutofillAllowNonHttpActivation";
public static final String AUTOFILL_ANDROID_DESKTOP_KEYBOARD_ACCESSORY_REVAMP =
@@ -279,6 +283,8 @@ public abstract class ChromeFeatureList {
public static final String AUTOFILL_SYNC_EWALLET_ACCOUNTS = "AutofillSyncEwalletAccounts";
public static final String AUTOFILL_THIRD_PARTY_MODE_CONTENT_PROVIDER =
"AutofillThirdPartyModeContentProvider";
public static final String AUTOFILL_THIRD_PARTY_MODE_RESTORED_ON_START =
"AutofillThirdPartyModeRestoredOnStart";
public static final String AUTOMOTIVE_BACK_BUTTON_BAR_STREAMLINE =
"AutomotiveBackButtonBarStreamline";
public static final String AUTO_DOC_PIP_PERMISSION_PROMPT_ANDROID =
@@ -297,7 +303,6 @@ public abstract class ChromeFeatureList {
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";
@@ -342,20 +347,21 @@ public abstract class ChromeFeatureList {
public static final String CCT_REPORT_PARALLEL_REQUEST_STATUS =
"CCTReportParallelRequestStatus";
public static final String CCT_REPORT_PRERENDER_EVENTS = "CCTReportPrerenderEvents";
public static final String CCT_RESET_TIMEOUT_ALLOWED = "CCTResetTimeoutAllowed";
public static final String CCT_RESET_TIMEOUT_ENABLED = "CCTResetTimeoutEnabled";
public static final String CCT_RESIZABLE_FOR_THIRD_PARTIES = "CCTResizableForThirdParties";
public static final String CCT_SHOW_TAB_FIX = "CCTShowTabFix";
public static final String CCT_TAB_MODAL_DIALOG = "CCTTabModalDialog";
public static final String CCT_TOOLBAR_REFACTOR = "CCTToolbarRefactor";
public static final String CHANGE_UNFOCUSED_PRIORITY = "ChangeUnfocusedPriority";
public static final String CHROME_FINDS = "ChromeFinds";
public static final String CHROME_ITEM_PICKER_UI = "ChromeItemPickerUi";
public static final String CHROME_NATIVE_URL_OVERRIDING = "ChromeNativeUrlOverriding";
public static final String CHROME_SURVEY_NEXT_ANDROID = "ChromeSurveyNextAndroid";
public static final String CLAMP_AUTOMOTIVE_SCALING = "ClampAutomotiveScaling";
public static final String CLANK_DEFAULT_SEARCH_API = "ClankDefaultSearchApi";
public static final String CLANK_STARTUP_LATENCY_INJECTION = "ClankStartupLatencyInjection";
public static final String CLANK_WHATS_NEW = "ClankWhatsNew";
public static final String CLEAR_INSTANCE_INFO_WHEN_CLOSED_INTENTIONALLY =
"ClearInstanceInfoWhenClosedIntentionally";
public static final String CLEAR_INTENT_WHEN_RECREATED = "ClearIntentWhenRecreated";
public static final String COMMAND_LINE_ON_NON_ROOTED = "CommandLineOnNonRooted";
public static final String COMMERCE_MERCHANT_VIEWER = "CommerceMerchantViewer";
@@ -370,6 +376,7 @@ public abstract class ChromeFeatureList {
"ContextualSearchDisableOnlineDetection";
public static final String CONTEXTUAL_SEARCH_SUPPRESS_SHORT_VIEW =
"ContextualSearchSuppressShortView";
public static final String CONTEXTUAL_TASKS = "ContextualTasks";
public static final String CONTEXT_MENU_EMPTY_SPACE = "ContextMenuEmptySpace";
public static final String CONTEXT_MENU_PICTURE_IN_PICTURE_ANDROID =
"ContextMenuPictureInPictureAndroid";
@@ -388,6 +395,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 DEFAULT_BROWSER_PROMO_ENTRY_POINT = "DefaultBrowserPromoEntryPoint";
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";
@@ -409,9 +417,9 @@ public abstract class ChromeFeatureList {
"EdgeToEdgeUseBackupNavbarInsets";
public static final String EDUCATIONAL_TIP_DEFAULT_BROWSER_PROMO_CARD =
"EducationalTipDefaultBrowserPromoCard";
public static final String EDUCATIONAL_TIP_MODULE = "EducationalTipModule";
public static final String EMPTY_TAB_LIST_ANIMATION_KILL_SWITCH =
"EmptyTabListAnimationKillSwitch";
public static final String ENABLE_ANDROID_SIDE_PANEL = "EnableAndroidSidePanel";
public static final String ENABLE_CLIPBOARD_DATA_CONTROLS_ANDROID =
"EnableClipboardDataControlsAndroid";
public static final String ENABLE_DISCOUNT_INFO_API = "EnableDiscountInfoApi";
@@ -443,6 +451,7 @@ public abstract class ChromeFeatureList {
public static final String FULLSCREEN_INSETS_API_MIGRATION = "FullscreenInsetsApiMigration";
public static final String FULLSCREEN_INSETS_API_MIGRATION_ON_AUTOMOTIVE =
"FullscreenInsetsApiMigrationOnAutomotive";
public static final String GLIC = "Glic";
public static final String GRID_TAB_SWITCHER_SURFACE_COLOR_UPDATE =
"GridTabSwitcherSurfaceColorUpdate";
public static final String GRID_TAB_SWITCHER_UPDATE = "GridTabSwitcherUpdate";
@@ -455,11 +464,10 @@ public abstract class ChromeFeatureList {
public static final String HISTORY_PANE_ANDROID = "HistoryPaneAndroid";
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 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 INLINE_PDF_V2 = "InlinePdfV2";
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";
@@ -487,8 +495,6 @@ public abstract class ChromeFeatureList {
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";
public static final String NAV_BAR_COLOR_ANIMATION = "NavBarColorAnimation";
public static final String NEW_TAB_PAGE_CUSTOMIZATION = "NewTabPageCustomization";
@@ -500,6 +506,8 @@ public abstract class ChromeFeatureList {
"NotificationPermissionBottomSheet";
public static final String NOTIFICATION_PERMISSION_VARIANT = "NotificationPermissionVariant";
public static final String NOTIFICATION_TRAMPOLINE = "NotificationTrampoline";
public static final String NOTIFICATION_TRAMPOLINE_NO_NEW_TASK =
"NotificationTrampolineNoNewTask";
public static final String OMAHA_MIN_SDK_VERSION_ANDROID = "OmahaMinSdkVersionAndroid";
public static final String OMNIBOX_AUTOFOCUS_ON_INCOGNITO_NTP =
"OmniboxAutofocusOnIncognitoNtp";
@@ -518,6 +526,7 @@ public abstract class ChromeFeatureList {
public static final String PERMISSION_SITE_SETTING_RADIO_BUTTON =
"PermissionSiteSettingsRadioButton";
public static final String PERSIST_ACROSS_REBOOTS = "PersistAcrossReboots";
public static final String PERSIST_ACROSS_REBOOTS_DEBUG_LOGS = "PersistAcrossRebootsDebugLogs";
public static final String PLUS_ADDRESSES_ENABLED = "PlusAddressesEnabled";
public static final String PLUS_ADDRESS_ANDROID_OPEN_GMS_CORE_MANAGEMENT_PAGE =
"PlusAddressAndroidOpenGmsCoreManagementPage";
@@ -539,10 +548,6 @@ public abstract class ChromeFeatureList {
public static final String PRIVACY_SANDBOX_SENTIMENT_SURVEY = "PrivacySandboxSentimentSurvey";
public static final String PRIVACY_SANDBOX_SETTINGS_4 = "PrivacySandboxSettings4";
public static final String PROCESS_RANK_POLICY_ANDROID = "ProcessRankPolicyAndroid";
// Do not access directly, use SupervisedUserService::IsLocallySupervised() or
// 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";
@@ -556,13 +561,9 @@ public abstract class ChromeFeatureList {
"ReadAloudAudioOverviewsFeedback";
public static final String READALOUD_AUDIO_OVERVIEWS_SKIP_DISCLAIMER_WHEN_POSSIBLE =
"ReadAloudAudioOverviewsSkipDisclaimerWhenPossible";
public static final String READALOUD_BACKGROUND_PLAYBACK = "ReadAloudBackgroundPlayback";
public static final String READALOUD_IN_MULTI_WINDOW = "ReadAloudInMultiWindow";
public static final String READALOUD_IN_OVERFLOW_MENU_IN_CCT = "ReadAloudInOverflowMenuInCCT";
public static final String READALOUD_IPH_MENU_BUTTON_HIGHLIGHT_CCT =
"ReadAloudIPHMenuButtonHighlightCCT";
public static final String READALOUD_PLAYBACK = "ReadAloudPlayback";
public static final String READALOUD_TAP_TO_SEEK = "ReadAloudTapToSeek";
public static final String RECENTLY_CLOSED_TABS_AND_WINDOWS = "RecentlyClosedTabsAndWindows";
public static final String RECORD_INCOGNITO_NTP_TIME_TO_FIRST_NAVIGATION_METRIC =
"RecordIncognitoNtpTimeToFirstNavigationMetric";
@@ -641,6 +642,8 @@ 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 SYNC_TRUSTED_VAULT_ERROR_MESSAGE_DURATION =
"SyncTrustedVaultErrorMessageDuration";
public static final String TAB_BOTTOM_SHEET = "TabBottomSheet";
public static final String TAB_CLOSURE_METHOD_REFACTOR = "TabClosureMethodRefactor";
public static final String TAB_FREEZING_USES_DISCARD = "TabFreezingUsesDiscard";
@@ -650,7 +653,8 @@ public abstract class ChromeFeatureList {
"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_INCOGNITO_MIGRATION = "TabStripIncognitoMigration";
public static final String TAB_STRIP_EMPTY_SPACE_CONTEXT_MENU_ANDROID =
"TabStripEmptySpaceContextMenuAndroid";
public static final String TAB_SWITCHER_DRAG_DROP_ANDROID = "TabSwitcherDragDropAndroid";
public static final String TAB_SWITCHER_GROUP_SUGGESTIONS_ANDROID =
"TabSwitcherGroupSuggestionsAndroid";
@@ -736,7 +740,7 @@ public abstract class ChromeFeatureList {
newCachedFlag(
ANDROID_PROGRESS_BAR_VISUAL_UPDATE,
/* defaultValue= */ false,
/* defaultValueInTests= */ true);
/* defaultValueInTests= */ false);
public static final CachedFlag sAndroidSettingsContainment =
newCachedFlag(
ANDROID_SETTINGS_CONTAINMENT,
@@ -763,12 +767,8 @@ public abstract class ChromeFeatureList {
newCachedFlag(ANDROID_TWA_ORIGIN_DISPLAY, false);
public static final CachedFlag sAndroidUseAdminsForEnterpriseInfo =
newCachedFlag(ANDROID_USE_ADMINS_FOR_ENTERPRISE_INFO, true);
public static final CachedFlag sAndroidWebAppHeaderForStandaloneMode =
newCachedFlag(ANDROID_WEB_APP_HEADER_FOR_STANDALONE_MODE, false);
public static final CachedFlag sAndroidWebAppLaunchHandler =
newCachedFlag(ANDROID_WEB_APP_LAUNCH_HANDLER, false, true);
public static final CachedFlag sAndroidWebAppMenuButton =
newCachedFlag(ANDROID_WEB_APP_MENU_BUTTON, true);
public static final CachedFlag sAndroidWindowControlsOverlay =
newCachedFlag(ANDROID_WINDOW_CONTROLS_OVERLAY, true);
public static final CachedFlag sAndroidWindowManagementWebApi =
@@ -791,6 +791,8 @@ public abstract class ChromeFeatureList {
newCachedFlag(ASYNC_NOTIFICATION_MANAGER, false, true);
public static final CachedFlag sAsyncNotificationManagerForDownload =
newCachedFlag(ASYNC_NOTIFICATION_MANAGER_FOR_DOWNLOAD, true);
public static final CachedFlag sAutoDocPipPermissionPromptAndroid =
newCachedFlag(AUTO_DOC_PIP_PERMISSION_PROMPT_ANDROID, false);
public static final CachedFlag sAutomotiveBackButtonBarStreamline =
newCachedFlag(AUTOMOTIVE_BACK_BUTTON_BAR_STREAMLINE, /* defaultValue= */ true);
public static final CachedFlag sBackgroundThreadPoolFieldTrial =
@@ -808,9 +810,7 @@ public abstract class ChromeFeatureList {
newCachedFlag(CACHE_IS_MULTI_INSTANCE_API_31_ENABLED, true);
public static final CachedFlag sCctAdaptiveButton =
newCachedFlag(
CCT_ADAPTIVE_BUTTON,
/* defaultValue= */ false,
/* defaultValueInTests= */ true);
CCT_ADAPTIVE_BUTTON, /* defaultValue= */ true, /* defaultValueInTests= */ true);
public static final CachedFlag sCctAuthTab = newCachedFlag(CCT_AUTH_TAB, true);
public static final CachedFlag sCctAuthTabDisableAllExternalIntents =
newCachedFlag(CCT_AUTH_TAB_DISABLE_ALL_EXTERNAL_INTENTS, false);
@@ -848,6 +848,8 @@ public abstract class ChromeFeatureList {
newCachedFlag(CCT_OPEN_IN_BROWSER_BUTTON_IF_ENABLED_BY_EMBEDDER, true);
public static final CachedFlag sCctRealtimeEngagementEventsInBackground =
newCachedFlag(CCT_REALTIME_ENGAGEMENT_EVENTS_IN_BACKGROUND, true);
public static final CachedFlag sCctResetTimeoutAllowed =
newCachedFlag(CCT_RESET_TIMEOUT_ALLOWED, true);
public static final CachedFlag sCctResetTimeoutEnabled =
newCachedFlag(CCT_RESET_TIMEOUT_ENABLED, false);
public static final CachedFlag sCctResizableForThirdParties =
@@ -858,7 +860,7 @@ public abstract class ChromeFeatureList {
public static final CachedFlag sChromeItemPickerUi =
newCachedFlag(CHROME_ITEM_PICKER_UI, /* defaultValue= */ false);
public static final CachedFlag sChromeNativeUrlOverriding =
newCachedFlag(CHROME_NATIVE_URL_OVERRIDING, /* defaultValue= */ false);
newCachedFlag(CHROME_NATIVE_URL_OVERRIDING, BuildConfig.IS_DESKTOP_ANDROID);
public static final CachedFlag sClampAutomotiveScaling =
newCachedFlag(CLAMP_AUTOMOTIVE_SCALING, true);
public static final CachedFlag sClankStartupLatencyInjection =
@@ -867,8 +869,6 @@ public abstract class ChromeFeatureList {
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 sCpaTabGroupingButton =
newCachedFlag(
CONTEXTUAL_PAGE_ACTION_TAB_GROUPING,
@@ -876,6 +876,11 @@ public abstract class ChromeFeatureList {
/* defaultValueInTests= */ true);
public static final CachedFlag sCrossDeviceTabPaneAndroid =
newCachedFlag(CROSS_DEVICE_TAB_PANE_ANDROID, false);
public static final CachedFlag sDefaultBrowserPromoEntryPoint =
newCachedFlag(
DEFAULT_BROWSER_PROMO_ENTRY_POINT,
/* defaultValue= */ false,
/* defaultValueInTests= */ true);
public static final CachedFlag sDesktopAndroidLinkCapturing =
newCachedFlag(DESKTOP_ANDROID_LINK_CAPTURING, false);
public static final CachedFlag sDesktopUAOnConnectedDisplay =
@@ -899,10 +904,10 @@ public abstract class ChromeFeatureList {
newCachedFlag(EDGE_TO_EDGE_USE_BACKUP_NAVBAR_INSETS, true);
public static final CachedFlag sEducationalTipDefaultBrowserPromoCard =
newCachedFlag(EDUCATIONAL_TIP_DEFAULT_BROWSER_PROMO_CARD, false, true);
public static final CachedFlag sEducationalTipModule =
newCachedFlag(EDUCATIONAL_TIP_MODULE, true);
public static final CachedFlag sEnableAndroidSidePanel =
newCachedFlag(ENABLE_ANDROID_SIDE_PANEL, false);
public static final CachedFlag sEnableExclusiveAccessManager =
newCachedFlag(ENABLE_EXCLUSIVE_ACCESS_MANAGER, false, true);
newCachedFlag(ENABLE_EXCLUSIVE_ACCESS_MANAGER, true);
public static final CachedFlag sEnableFullscreenToAnyScreenAndroid =
newCachedFlag(ENABLE_FULLSCREEN_TO_ANY_SCREEN_ANDROID, false, true);
public static final CachedFlag sEnableXAxisActivityTransition =
@@ -952,7 +957,8 @@ public abstract class ChromeFeatureList {
public static final CachedFlag sLockTopControlsOnLargeTabletsV2 =
newCachedFlag(
LOCK_TOP_CONTROLS_ON_LARGE_TABLETS_V2,
/* defaultValue= */ false);
/* defaultValue= */ false,
/* defaultValueInTests= */ true);
public static final CachedFlag sMagicStackAndroid = newCachedFlag(MAGIC_STACK_ANDROID, true);
public static final CachedFlag sMaliciousApkDownloadCheck =
newCachedFlag(
@@ -971,8 +977,6 @@ public abstract class ChromeFeatureList {
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 =
newCachedFlag(
MVC_UPDATE_VIEW_WHEN_MODEL_CHANGED,
@@ -987,20 +991,24 @@ public abstract class ChromeFeatureList {
public static final CachedFlag sNewTabPageCustomizationToolbarButton =
newCachedFlag(NEW_TAB_PAGE_CUSTOMIZATION_TOOLBAR_BUTTON, false);
public static final CachedFlag sNewTabPageCustomizationV2 =
newCachedFlag(NEW_TAB_PAGE_CUSTOMIZATION_V2, false);
newCachedFlag(NEW_TAB_PAGE_CUSTOMIZATION_V2, false, true);
public static final CachedFlag sNotificationTrampoline =
newCachedFlag(NOTIFICATION_TRAMPOLINE, false);
public static final CachedFlag sNotificationTrampolineNoNewTask =
newCachedFlag(NOTIFICATION_TRAMPOLINE_NO_NEW_TASK, 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 sPersistAcrossRebootsDebugLogs =
newCachedFlag(PERSIST_ACROSS_REBOOTS_DEBUG_LOGS, 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);
newCachedFlag(PROTECT_RECENTLY_VISIBLE_TAB, BuildConfig.IS_DESKTOP_ANDROID);
public static final CachedFlag sReportNotificationContentDetectionData =
newCachedFlag(
REPORT_NOTIFICATION_CONTENT_DETECTION_DATA,
@@ -1019,7 +1027,9 @@ public abstract class ChromeFeatureList {
newCachedFlag(SEARCH_IN_CCT_ALTERNATE_TAP_HANDLING_IF_ENABLED_BY_EMBEDDER, true);
public static final CachedFlag sSearchInCCTIfEnabledByEmbedder =
newCachedFlag(SEARCH_IN_CCT_IF_ENABLED_BY_EMBEDDER, true);
public static final CachedFlag sSearchInSettings = newCachedFlag(SEARCH_IN_SETTINGS, false);
public static final CachedFlag sSearchInSettings =
newCachedFlag(
SEARCH_IN_SETTINGS, /* defaultValue= */ false, /* defaultValueInTests= */ true);
public static final CachedFlag sSettingsMultiColumn =
newCachedFlag(
SETTINGS_MULTI_COLUMN,
@@ -1048,8 +1058,6 @@ public abstract class ChromeFeatureList {
/* defaultValueInTests= */ true);
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, true);
public static final CachedFlag sTabWindowManagerReportIndicesMismatch =
newCachedFlag(TAB_WINDOW_MANAGER_REPORT_INDICES_MISMATCH, true);
public static final CachedFlag sTestDefaultDisabled =
@@ -1131,9 +1139,7 @@ public abstract class ChromeFeatureList {
sAndroidThemeResourceProvider,
sAndroidTwaOriginDisplay,
sAndroidUseAdminsForEnterpriseInfo,
sAndroidWebAppHeaderForStandaloneMode,
sAndroidWebAppLaunchHandler,
sAndroidWebAppMenuButton,
sAndroidWindowControlsOverlay,
sAndroidWindowManagementWebApi,
sAndroidWindowPopupCustomTabUi,
@@ -1143,6 +1149,7 @@ public abstract class ChromeFeatureList {
sAppSpecificHistory,
sAppSpecificHistoryViewIntent,
sAsyncNotificationManager,
sAutoDocPipPermissionPromptAndroid,
sAutomotiveBackButtonBarStreamline,
sBackgroundThreadPoolFieldTrial,
sBlockIntentsWhileLocked,
@@ -1167,6 +1174,7 @@ public abstract class ChromeFeatureList {
sCctOpenInBrowserButtonIfAllowedByEmbedder,
sCctOpenInBrowserButtonIfEnabledByEmbedder,
sCctRealtimeEngagementEventsInBackground,
sCctResetTimeoutAllowed,
sCctResetTimeoutEnabled,
sCctResizableForThirdParties,
sCctTabModalDialog,
@@ -1177,9 +1185,9 @@ public abstract class ChromeFeatureList {
sClankStartupLatencyInjection,
sClearIntentWhenRecreated,
sCommandLineOnNonRooted,
sContextMenuPictureInPictureAndroid,
sCpaTabGroupingButton,
sCrossDeviceTabPaneAndroid,
sDefaultBrowserPromoEntryPoint,
sDesktopAndroidLinkCapturing,
sDesktopUAOnConnectedDisplay,
sDocumentPictureInPictureAPI,
@@ -1190,7 +1198,7 @@ public abstract class ChromeFeatureList {
sEdgeToEdgeTablet,
sEdgeToEdgeUseBackupNavbarInsets,
sEducationalTipDefaultBrowserPromoCard,
sEducationalTipModule,
sEnableAndroidSidePanel,
sEnableExclusiveAccessManager,
sEnableFullscreenToAnyScreenAndroid,
sEnableXAxisActivityTransition,
@@ -1213,7 +1221,6 @@ public abstract class ChromeFeatureList {
sMostVisitedTilesCustomization,
sMostVisitedTilesReselect,
sMoveToFrontInLaunchIntentDispatcher,
sMultiInstanceApplicationStatusCleanup,
sMvcUpdateViewWhenModelChanged,
sNavBarColorAnimation,
sNewTabPageCustomization,
@@ -1221,9 +1228,11 @@ public abstract class ChromeFeatureList {
sNewTabPageCustomizationToolbarButton,
sNewTabPageCustomizationV2,
sNotificationTrampoline,
sNotificationTrampolineNoNewTask,
sPCctMinimumHeight,
sPaintPreviewDemo,
sPersistAcrossReboots,
sPersistAcrossRebootsDebugLogs,
sPostGetMyMemoryStateToBackground,
sPowerSavingModeBroadcastReceiverInBackground,
sPriceChangeModule,
@@ -1244,7 +1253,6 @@ public abstract class ChromeFeatureList {
sTabModelInitFixes,
sTabStorageSqlitePrototype,
sTabStripDensityChangeAndroid,
sTabStripIncognitoMigration,
sTabWindowManagerReportIndicesMismatch,
sToolbarPhoneAnimationRefactor,
sToolbarSnapshotRefactor,
@@ -1279,6 +1287,8 @@ public abstract class ChromeFeatureList {
// keep-sorted start group_prefixes=["public static final MutableFlagWithSafeDefault"]
public static final MutableFlagWithSafeDefault sAdaptiveButtonInTopToolbarCustomizationV2 =
newMutableFlagWithSafeDefault(ADAPTIVE_BUTTON_IN_TOP_TOOLBAR_CUSTOMIZATION_V2, false);
public static final MutableFlagWithSafeDefault sAlwaysDrawCompositedToolbarHairline =
newMutableFlagWithSafeDefault(ALWAYS_DRAW_COMPOSITED_TOOLBAR_HAIRLINE, true);
public static final MutableFlagWithSafeDefault sAndroidAppearanceSettings =
newMutableFlagWithSafeDefault(ANDROID_APPEARANCE_SETTINGS, false);
public static final MutableFlagWithSafeDefault sAndroidBookmarkBar =
@@ -1288,17 +1298,17 @@ public abstract class ChromeFeatureList {
public static final MutableFlagWithSafeDefault sAndroidContextMenuDuplicateTabs =
newMutableFlagWithSafeDefault(ANDROID_CONTEXT_MENU_DUPLICATE_TABS, false);
public static final MutableFlagWithSafeDefault sAndroidPinnedTabs =
newMutableFlagWithSafeDefault(ANDROID_PINNED_TABS, false);
newMutableFlagWithSafeDefault(ANDROID_PINNED_TABS, true);
public static final MutableFlagWithSafeDefault sAndroidPinnedTabsTabletTabStrip =
newMutableFlagWithSafeDefault(ANDROID_PINNED_TABS_TABLET_TAB_STRIP, false);
newMutableFlagWithSafeDefault(ANDROID_PINNED_TABS_TABLET_TAB_STRIP, true);
public static final MutableFlagWithSafeDefault sAndroidTabHighlighting =
newMutableFlagWithSafeDefault(ANDROID_TAB_HIGHLIGHTING, false);
newMutableFlagWithSafeDefault(ANDROID_TAB_HIGHLIGHTING, true);
public static final MutableFlagWithSafeDefault sAndroidTipsNotifications =
newMutableFlagWithSafeDefault(ANDROID_TIPS_NOTIFICATIONS, false);
public static final MutableFlagWithSafeDefault sAndroidTipsNotificationsV2 =
newMutableFlagWithSafeDefault(ANDROID_TIPS_NOTIFICATIONS_V2, false);
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.
@@ -1316,8 +1326,8 @@ public abstract class ChromeFeatureList {
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 sGlic =
newMutableFlagWithSafeDefault(GLIC, false);
public static final MutableFlagWithSafeDefault sIncognitoNtpSmallIcon =
newMutableFlagWithSafeDefault(INCOGNITO_NTP_SMALL_ICON, false);
public static final MutableFlagWithSafeDefault sIncognitoScreenshot =
@@ -1330,8 +1340,6 @@ public abstract class ChromeFeatureList {
newMutableFlagWithSafeDefault(ANDROID_NO_VISIBLE_HINT_FOR_DIFFERENT_TLD, true);
public static final MutableFlagWithSafeDefault sOmniboxAutofocusOnIncognitoNtp =
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 =
@@ -1342,7 +1350,7 @@ public abstract class ChromeFeatureList {
public static final MutableFlagWithSafeDefault sRobustWindowManagement =
newMutableFlagWithSafeDefault(ROBUST_WINDOW_MANAGEMENT, false);
public static final MutableFlagWithSafeDefault sShowNewTabAnimations =
newMutableFlagWithSafeDefault(SHOW_NEW_TAB_ANIMATIONS, false);
newMutableFlagWithSafeDefault(SHOW_NEW_TAB_ANIMATIONS, true);
public static final MutableFlagWithSafeDefault sShowTabListAnimations =
newMutableFlagWithSafeDefault(SHOW_TAB_LIST_ANIMATIONS, false);
public static final MutableFlagWithSafeDefault sSuppressToolbarCapturesAtGestureEnd =
@@ -1350,7 +1358,7 @@ public abstract class ChromeFeatureList {
public static final MutableFlagWithSafeDefault sTabBottomSheet =
newMutableFlagWithSafeDefault(TAB_BOTTOM_SHEET, false);
public static final MutableFlagWithSafeDefault sTabFreezingUsesDiscard =
newMutableFlagWithSafeDefault(TAB_FREEZING_USES_DISCARD, false);
newMutableFlagWithSafeDefault(TAB_FREEZING_USES_DISCARD, true);
public static final MutableFlagWithSafeDefault sTabSwitcherGroupSuggestionsAndroid =
newMutableFlagWithSafeDefault(TAB_SWITCHER_GROUP_SUGGESTIONS_ANDROID, false);
public static final MutableFlagWithSafeDefault sTabSwitcherGroupSuggestionsTestModeAndroid =
@@ -1513,7 +1521,11 @@ public abstract class ChromeFeatureList {
false);
public static final IntCachedFeatureParam sCctResetMinimumTimeoutMinutes =
newIntCachedFeatureParam(CCT_RESET_TIMEOUT_ENABLED, "minimum_reset_timeout_mins", 1);
newIntCachedFeatureParam(CCT_RESET_TIMEOUT_ENABLED, "minimum_reset_timeout_mins", 30);
public static final IntCachedFeatureParam sCctResetMinimumTimeoutMinutesAllowed =
newIntCachedFeatureParam(
CCT_RESET_TIMEOUT_ALLOWED, "minimum_reset_timeout_mins_allowed", 30);
public static final StringCachedFeatureParam sCctResizableForThirdPartiesAllowlistEntries =
newStringCachedFeatureParam(CCT_RESIZABLE_FOR_THIRD_PARTIES, "allowlist_entries", "");
@@ -1531,6 +1543,14 @@ public abstract class ChromeFeatureList {
newIntCachedFeatureParam(
CLANK_STARTUP_LATENCY_INJECTION, "latency_injection_amount_millis", 0);
/*
A cached param that determines whether we show the menu item (entry point) in the app menu
(3-dot menu).
*/
public static final BooleanCachedFeatureParam sDefaultBrowserPromoEntryPointShowAppMenu =
newBooleanCachedFeatureParam(
DEFAULT_BROWSER_PROMO_ENTRY_POINT, "show_app_menu_item", true);
/**
* Cached param whether we disable animations for color changes to the edge-to-edge bottom chin.
*/
@@ -1660,7 +1680,7 @@ public abstract class ChromeFeatureList {
public static final IntCachedFeatureParam sReadAloudReadabilityDelayMsAfterPageLoad =
newIntCachedFeatureParam(
READALOUD, "read_aloud_readability_delay_ms_after_page_load", 1500);
READALOUD, "read_aloud_readability_delay_ms_after_page_load", 500);
public static final BooleanCachedFeatureParam sShouldConsiderLanguageInOverviewReadability =
newBooleanCachedFeatureParam(
@@ -1678,6 +1698,10 @@ public abstract class ChromeFeatureList {
"start_surface_return_time_on_tablet_seconds",
14400); // 4 hours
public static final BooleanCachedFeatureParam sTabStorageSqlitePrototypeAllowFullMigration =
newBooleanCachedFeatureParam(
TAB_STORAGE_SQLITE_PROTOTYPE, "allow_full_migration", false);
public static final BooleanCachedFeatureParam
sTabStorageSqlitePrototypeAuthoritativeReadSource =
newBooleanCachedFeatureParam(
@@ -1747,11 +1771,13 @@ public abstract class ChromeFeatureList {
sCctGoogleBottomBarVariantLayoutsVariantLayout,
sCctMinimizedEnabledByDefaultManufacturerExcludeList,
sCctResetMinimumTimeoutMinutes,
sCctResetMinimumTimeoutMinutesAllowed,
sCctResizableForThirdPartiesAllowlistEntries,
sCctResizableForThirdPartiesDefaultPolicy,
sCctResizableForThirdPartiesDenylistEntries,
sClampAutomotiveScalingMaxScalingPercentage,
sClankStartupLatencyInjectionAmountMs,
sDefaultBrowserPromoEntryPointShowAppMenu,
sDesktopUAAllowedOnExternalDisplayForOem,
sEdgeToEdgeBottomChinOemList,
sEdgeToEdgeBottomChinOemMinVersions,
@@ -1789,6 +1815,7 @@ public abstract class ChromeFeatureList {
sShouldConsiderLanguageInOverviewReadability,
sStartSurfaceReturnTimeTabletSecs,
sTabGroupListContainment,
sTabStorageSqlitePrototypeAllowFullMigration,
sTabStorageSqlitePrototypeAuthoritativeReadSource,
sTabWindowManagerReportIndicesMismatchTimeDiffThresholdMs,
sTopControlsRefactorNarrowWidthTransitionThreshold,
@@ -1803,11 +1830,11 @@ public abstract class ChromeFeatureList {
/* Alphabetical: */
public static final MutableBooleanParamWithSafeDefault sAndroidPinnedTabsSearchBoxMovement =
sAndroidPinnedTabs.newBooleanParam("search_box_movement", false);
sAndroidPinnedTabs.newBooleanParam("search_box_movement", true);
public static final MutableBooleanParamWithSafeDefault
sAndroidPinnedTabsSearchBoxSquishAnimation =
sAndroidPinnedTabs.newBooleanParam("search_box_squish_animation", false);
sAndroidPinnedTabs.newBooleanParam("search_box_squish_animation", true);
public static final MutableIntParamWithSafeDefault sDisableInstanceLimitMemoryThresholdMb =
sDisableInstanceLimit.newIntParam("max_instance_limit_memory_threshold_mb", 6500);
@@ -1839,6 +1866,9 @@ public abstract class ChromeFeatureList {
public static final MutableBooleanParamWithSafeDefault sAndroidTabHighlightingForceShiftClick =
sAndroidTabHighlighting.newBooleanParam("force_shift_click", false);
public static final MutableBooleanParamWithSafeDefault sTabBottomSheetDontShowFusebox =
sTabBottomSheet.newBooleanParam("dont_show_fusebox", false);
public static final MutableBooleanParamWithSafeDefault sRobustWindowManagementBulkClose =
sRobustWindowManagement.newBooleanParam("bulk_close", false);
}
@@ -11,6 +11,7 @@
#include "base/files/file_path.h"
#include "base/files/file_util.h"
#include "base/json/values_util.h"
#include "base/time/time.h"
#include "base/trace_event/trace_event.h"
#include "build/android_buildflags.h"
@@ -24,6 +25,7 @@
#include "chrome/browser/browser_process_impl.h"
#include "chrome/browser/chrome_content_browser_client.h"
#include "chrome/browser/component_updater/component_updater_prefs.h"
#include "chrome/browser/contextual_cueing/contextual_cueing_prefs.h"
#include "chrome/browser/download/download_prefs.h"
#include "chrome/browser/engagement/important_sites_util.h"
#include "chrome/browser/enterprise/reporting/prefs.h"
@@ -44,7 +46,6 @@
#include "chrome/browser/metrics/tab_stats/tab_stats_tracker.h"
#include "chrome/browser/net/net_error_tab_helper.h"
#include "chrome/browser/net/profile_network_context_service.h"
#include "chrome/browser/net/secure_dns_util.h"
#include "chrome/browser/net/system_network_context_manager.h"
#include "chrome/browser/notifications/notification_display_service_impl.h"
#include "chrome/browser/notifications/notifier_state_tracker.h"
@@ -75,6 +76,7 @@
#include "chrome/browser/signin/chrome_signin_client.h"
#include "chrome/browser/ssl/ssl_config_service_manager.h"
#include "chrome/browser/subscription_eligibility/subscription_eligibility_prefs.h"
#include "chrome/browser/themes/theme_service.h"
#include "chrome/browser/tracing/chrome_tracing_delegate.h"
#include "chrome/browser/ui/browser_ui_prefs.h"
#include "chrome/browser/ui/network_profile_bubble.h"
@@ -82,6 +84,7 @@
#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/tabs/projects/projects_prefs.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"
@@ -182,7 +185,7 @@
#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/device_statistics_scheduler.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"
@@ -257,7 +260,6 @@
#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"
@@ -533,14 +535,14 @@
#endif
#if BUILDFLAG(ENABLE_ON_DEVICE_TRANSLATION)
#include "chrome/browser/on_device_translation/pref_names.h"
#include "components/on_device_translation/public/pref_names.h"
#endif // BUILDFLAG(ENABLE_ON_DEVICE_TRANSLATION)
#if BUILDFLAG(ENTERPRISE_DATA_CONTROLS)
#include "components/enterprise/data_controls/core/browser/prefs.h"
#endif
#if BUILDFLAG(ENABLE_GLIC) || BUILDFLAG(ENABLE_GLIC_ANDROID)
#if BUILDFLAG(ENABLE_GLIC)
#include "chrome/browser/glic/glic_pref_names.h"
#endif
@@ -956,6 +958,28 @@ constexpr char kTPCDExperimentProfileState[] = "tpcd_experiment.profile_state";
constexpr char kDeviceName[] = "device_name";
#endif // BUILDFLAG(IS_CHROMEOS)
#if BUILDFLAG(IS_ANDROID)
// Deprecated 01/2026.
constexpr char kDSEGeolocationSettingDeprecated[] = "dse_geolocation_setting";
constexpr char kDSEPermissionsSettings[] = "dse_permissions_settings";
constexpr char kDSEWasDisabledByPolicy[] = "dse_was_disabled_by_policy";
#endif // BUILDFLAG(IS_ANDROID)
// Deprecated 01/2026.
constexpr char kCookieClearOnExitMigrationNoticeComplete[] =
"signin.cookie_clear_on_exit_migration_notice_complete";
// Deprecated 02/2026.
// Note that these were replaced by local state prefs of the same names and
// functions: those should not be removed. Only the profile prefs registered
// here are deprecated.
constexpr char kGlicGuestUrlPresetAutopush[] = "glic.guest_url_preset_autopush";
constexpr char kGlicGuestUrlPresetPreprod[] = "glic.guest_url_preset_preprod";
constexpr char kGlicGuestUrlPresetProd[] = "glic.guest_url_preset_prod";
// Deprecated 02/2026.
constexpr char kProfilesDeletedOld[] = "profiles.profiles_deleted";
// Register local state used only for migration (clearing or moving to a new
// key).
void RegisterLocalStatePrefsForMigration(PrefRegistrySimple* registry) {
@@ -1077,13 +1101,14 @@ void RegisterLocalStatePrefsForMigration(PrefRegistrySimple* registry) {
// Deprecated 01/2026.
registry->RegisterStringPref(kDeviceName, "");
#endif // BUILDFLAG(IS_CHROMEOS)
// Deprecated 02/2026.
registry->RegisterListPref(kProfilesDeletedOld);
}
// Register prefs used only for migration (clearing or moving to a new key).
void RegisterProfilePrefsForMigration(
user_prefs::PrefRegistrySyncable* registry) {
chrome_browser_net::secure_dns::RegisterProbesSettingBackupPref(registry);
// Deprecated 01/2025.
registry->RegisterBooleanPref(kCompactModeEnabled, false);
@@ -1318,6 +1343,22 @@ void RegisterProfilePrefsForMigration(
// Deprecated 12/2025.
registry->RegisterBooleanPref(kCloudPrintProxyEnabled, true);
registry->RegisterStringPref(kCloudPrintEmail, std::string());
#if BUILDFLAG(IS_ANDROID)
// Deprecated 01/2026.
registry->RegisterDictionaryPref(kDSEGeolocationSettingDeprecated);
registry->RegisterDictionaryPref(kDSEPermissionsSettings);
registry->RegisterBooleanPref(kDSEWasDisabledByPolicy, false);
#endif // BUILDFLAG(IS_ANDROID)
// Deprecated 01/2026.
registry->RegisterBooleanPref(kCookieClearOnExitMigrationNoticeComplete,
false);
// Deprecated 02/2026.
registry->RegisterStringPref(kGlicGuestUrlPresetAutopush, std::string());
registry->RegisterStringPref(kGlicGuestUrlPresetPreprod, std::string());
registry->RegisterStringPref(kGlicGuestUrlPresetProd, std::string());
}
} // namespace
@@ -1447,6 +1488,10 @@ void RegisterLocalState(PrefRegistrySimple* registry) {
registry->RegisterIntegerPref(prefs::kLastWhatsNewVersion, 0);
#endif // BUILDFLAG(IS_ANDROID)
#if BUILDFLAG(ENABLE_EXTENSIONS)
extensions::ExtensionPrefs::RegisterBrowserPrefs(registry);
#endif
#if BUILDFLAG(ENABLE_ON_DEVICE_TRANSLATION)
on_device_translation::RegisterLocalStatePrefs(registry);
#endif // BUILDFLAG(ENABLE_ON_DEVICE_TRANSLATION)
@@ -1561,6 +1606,11 @@ void RegisterLocalState(PrefRegistrySimple* registry) {
MediaFoundationServiceMonitor::RegisterPrefs(registry);
os_crypt_async::AppBoundEncryptionProviderWin::RegisterLocalPrefs(registry);
webnn::RegisterLocalPrefs(registry);
registry->RegisterBooleanPref(prefs::kForegroundLaunchOnLogin, false);
registry->RegisterBooleanPref(prefs::kStartupLaunchInfobarAccepted, false);
registry->RegisterTimePref(prefs::kStartupLaunchInfobarLastDeclinedTime,
base::Time());
registry->RegisterIntegerPref(prefs::kStartupLaunchInfobarDeclinedCount, 0);
#endif // BUILDFLAG(IS_WIN)
#if BUILDFLAG(ENABLE_DOWNGRADE_PROCESSING)
@@ -1619,7 +1669,7 @@ void RegisterLocalState(PrefRegistrySimple* registry) {
registry->RegisterIntegerPref(prefs::kChromeDataRegionSetting, 0);
#if BUILDFLAG(ENABLE_GLIC) || BUILDFLAG(ENABLE_GLIC_ANDROID)
#if BUILDFLAG(ENABLE_GLIC)
glic::prefs::RegisterLocalStatePrefs(registry);
#endif
@@ -1630,6 +1680,12 @@ void RegisterLocalState(PrefRegistrySimple* registry) {
registry->RegisterBooleanPref(prefs::kSilentPrintingEnabled, false);
#endif // !BUILDFLAG(IS_ANDROID)
registry->RegisterListPref(
prefs::kManagedLocalNetworkAccessIpAddressSpaceOverrides);
registry->RegisterBooleanPref(
policy::policy_prefs::kLocalNetworkAccessPermissionsPolicyDefaultEnabled,
false);
// This is intentionally last.
RegisterLocalStatePrefsForMigration(registry);
}
@@ -1655,6 +1711,7 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry,
chrome_browser_net::NetErrorTabHelper::RegisterProfilePrefs(registry);
chrome_prefs::RegisterProfilePrefs(registry);
collaboration::prefs::RegisterProfilePrefs(registry);
contextual_cueing::prefs::RegisterProfilePrefs(registry);
commerce::RegisterProfilePrefs(registry);
contextual_search::ContextualSearchService::RegisterProfilePrefs(registry);
registry->RegisterIntegerPref(prefs::kContextualTasksNextPanelOpenCount, 0);
@@ -1665,7 +1722,7 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry,
enterprise_reporting::RegisterProfilePrefs(registry);
dom_distiller::DistilledPagePrefs::RegisterProfilePrefs(registry);
DownloadPrefs::RegisterProfilePrefs(registry);
#if BUILDFLAG(ENABLE_GLIC) || BUILDFLAG(ENABLE_GLIC_ANDROID)
#if BUILDFLAG(ENABLE_GLIC)
glic::prefs::RegisterProfilePrefs(registry);
#endif
permissions::PermissionHatsTriggerHelper::RegisterProfilePrefs(registry);
@@ -1688,6 +1745,9 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry,
NotifierStateTracker::RegisterProfilePrefs(registry);
ntp_tiles::CustomLinksManagerImpl::RegisterProfilePrefs(registry);
ntp_tiles::MostVisitedSites::RegisterProfilePrefs(registry);
#if BUILDFLAG(ENABLE_ON_DEVICE_TRANSLATION)
on_device_translation::RegisterProfilePrefs(registry);
#endif // BUILDFLAG(ENABLE_ON_DEVICE_TRANSLATION)
optimization_guide::prefs::RegisterProfilePrefs(registry);
optimization_guide::model_execution::prefs::RegisterProfilePrefs(registry);
PageColorsController::RegisterProfilePrefs(registry);
@@ -1743,7 +1803,7 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry,
supervised_user::RegisterProfilePrefs(registry);
sync_sessions::SessionSyncPrefs::RegisterProfilePrefs(registry);
syncer::DeviceInfoPrefs::RegisterProfilePrefs(registry);
syncer::DeviceStatisticsTracker::RegisterProfilePrefs(registry);
syncer::DeviceStatisticsScheduler::RegisterProfilePrefs(registry);
syncer::SyncPrefs::RegisterProfilePrefs(registry);
syncer::SyncTransportDataPrefs::RegisterProfilePrefs(registry);
TemplateURLPrepopulateData::RegisterProfilePrefs(registry);
@@ -1785,7 +1845,7 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry,
#if BUILDFLAG(ENABLE_PDF)
registry->RegisterListPref(prefs::kPdfLocalFileAccessAllowedForDomains,
base::Value::List());
base::ListValue());
registry->RegisterBooleanPref(prefs::kPdfUseSkiaRendererEnabled, true);
#if BUILDFLAG(IS_CHROMEOS)
registry->RegisterBooleanPref(prefs::kPdfXfaFormsEnabled, false);
@@ -1826,7 +1886,6 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry,
captions::LiveTranslateController::RegisterProfilePrefs(registry);
ChromeAuthenticatorRequestDelegate::RegisterProfilePrefs(registry);
commerce::CommerceUiTabHelper::RegisterProfilePrefs(registry);
contextual_cueing::prefs::RegisterProfilePrefs(registry);
DriveService::RegisterProfilePrefs(registry);
first_run::RegisterProfilePrefs(registry);
gcm::RegisterProfilePrefs(registry);
@@ -1857,6 +1916,7 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry,
tab_organization_prefs::RegisterProfilePrefs(registry);
tab_search_prefs::RegisterProfilePrefs(registry);
ThemeColorPickerHandler::RegisterProfilePrefs(registry);
ThemeService::RegisterProfilePrefs(registry);
toolbar::RegisterProfilePrefs(registry);
UnifiedAutoplayConfig::RegisterProfilePrefs(registry);
#endif // BUILDFLAG(IS_ANDROID)
@@ -2039,6 +2099,8 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry,
CertificateManagerPageHandler::RegisterProfilePrefs(registry);
actor::ui::RegisterProfilePrefs(registry);
projects::RegisterProfilePrefs(registry);
#endif // !BUILDFLAG(IS_ANDROID)
registry->RegisterBooleanPref(webauthn::pref_names::kAllowWithBrokenCerts,
@@ -2084,8 +2146,6 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry,
registry->RegisterIntegerPref(prefs::kLensOverlayStartCount, 0);
registry->RegisterDictionaryPref(prefs::kReportingEndpoints);
registry->RegisterBooleanPref(prefs::kViewSourceLineWrappingEnabled, false);
// TODO(crbug.com/442891187): Move these to appropriate manager files when
@@ -2279,6 +2339,26 @@ void MigrateObsoleteLocalStatePrefs(PrefService* local_state) {
local_state->ClearPref(kDeviceName);
#endif // BUILDFLAG(IS_CHROMEOS)
// Added 02/2026.
if (local_state->HasPrefPath(kProfilesDeletedOld)) {
const base::ListValue& old_list = local_state->GetList(kProfilesDeletedOld);
if (!old_list.empty()) {
ScopedListPrefUpdate update(local_state, prefs::kProfilesDeleted);
for (const auto& value : old_list) {
std::optional<base::FilePath> path = base::ValueToFilePath(value);
if (path) {
base::FilePath basename = path->BaseName();
// Avoid the edge case where the base name is the root, e.g `/` on
// linux.
if (!basename.IsAbsolute()) {
update->Append(base::FilePathToValue(basename));
}
}
}
}
local_state->ClearPref(kProfilesDeletedOld);
}
// Please don't delete the following line. It is used by PRESUBMIT.py.
// END_MIGRATE_OBSOLETE_LOCAL_STATE_PREFS
@@ -2328,24 +2408,12 @@ void MigrateObsoleteProfilePrefs(PrefService* profile_prefs,
// Check MigrateDeprecatedAutofillPrefs() to see if this is safe to remove.
autofill::prefs::MigrateDeprecatedAutofillPrefs(profile_prefs);
// Added 3/2020.
// TODO(crbug.com/40122991): Remove this once the privacy settings redesign
// is fully launched.
chrome_browser_net::secure_dns::MigrateProbesSettingToOrFromBackup(
profile_prefs);
// TODO(326079444): After experiment is over, update the deprecated date and
// allow this to be cleaned up.
#if !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_CHROMEOS)
MigrateDefaultBrowserLastDeclinedPref(profile_prefs);
#endif
#if !BUILDFLAG(IS_ANDROID)
// Added 01/2025.
password_manager::features_util::MigrateDefaultProfileStorePref(
profile_prefs);
#endif // !BUILDFLAG(IS_ANDROID)
// Added 01/2025.
profile_prefs->ClearPref(kCompactModeEnabled);
@@ -2563,6 +2631,21 @@ void MigrateObsoleteProfilePrefs(PrefService* profile_prefs,
profile_prefs->ClearPref(kCloudPrintProxyEnabled);
profile_prefs->ClearPref(kCloudPrintEmail);
#if BUILDFLAG(IS_ANDROID)
// Added 01/2026.
profile_prefs->ClearPref(kDSEGeolocationSettingDeprecated);
profile_prefs->ClearPref(kDSEPermissionsSettings);
profile_prefs->ClearPref(kDSEWasDisabledByPolicy);
#endif // BUILDFLAG(IS_ANDROID)
// Added 01/2026.
profile_prefs->ClearPref(kCookieClearOnExitMigrationNoticeComplete);
// Added 02/2026.
profile_prefs->ClearPref(kGlicGuestUrlPresetAutopush);
profile_prefs->ClearPref(kGlicGuestUrlPresetPreprod);
profile_prefs->ClearPref(kGlicGuestUrlPresetProd);
// Please don't delete the following line. It is used by PRESUBMIT.py.
// END_MIGRATE_OBSOLETE_PROFILE_PREFS
@@ -4,7 +4,9 @@
#include "chrome/browser/ui/tab_helpers.h"
#include <cstdint>
#include <memory>
#include <optional>
#include <utility>
#include "base/command_line.h"
@@ -44,8 +46,9 @@
#include "chrome/browser/optimization_guide/optimization_guide_keyed_service.h"
#include "chrome/browser/optimization_guide/optimization_guide_keyed_service_factory.h"
#include "chrome/browser/optimization_guide/optimization_guide_web_contents_observer.h"
#include "chrome/browser/page_content_annotations/multi_source_page_context_fetcher.h"
#include "chrome/browser/page_content_annotations/page_content_annotations_service_factory.h"
#include "chrome/browser/page_content_annotations/page_content_annotations_web_contents_observer.h"
#include "chrome/browser/page_content_annotations/page_content_extraction_service_factory.h"
#include "chrome/browser/page_info/about_this_site_tab_helper.h"
#include "chrome/browser/page_info/page_info_features.h"
#include "chrome/browser/page_load_metrics/page_load_metrics_initialize.h"
@@ -75,7 +78,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/http_error_observer/http_error_tab_helper.h"
#include "chrome/browser/tpcd/metadata/devtools_observer.h"
#include "chrome/browser/translate/chrome_translate_client.h"
#include "chrome/browser/trusted_vault/trusted_vault_encryption_keys_tab_helper.h"
@@ -85,7 +87,6 @@
#include "chrome/browser/ui/focus_tab_after_navigation_helper.h"
#include "chrome/browser/ui/passwords/manage_passwords_ui_controller.h"
#include "chrome/browser/ui/prefs/prefs_tab_helper.h"
#include "chrome/browser/ui/privacy_sandbox/privacy_sandbox_prompt_helper.h"
#include "chrome/browser/ui/recently_audible_helper.h"
#include "chrome/browser/ui/safety_hub/revoked_permissions_service.h"
#include "chrome/browser/ui/safety_hub/revoked_permissions_service_factory.h"
@@ -121,10 +122,11 @@
#include "components/javascript_dialogs/tab_modal_dialog_manager.h"
#include "components/metrics/content/metrics_services_web_contents_observer.h"
#include "components/metrics_services_manager/metrics_services_manager.h"
#include "components/no_state_prefetch/browser/no_state_prefetch_manager.h"
#include "components/offline_pages/buildflags/buildflags.h"
#include "components/omnibox/common/omnibox_feature_configs.h"
#include "components/optimization_guide/core/optimization_guide_features.h"
#include "components/page_content_annotations/content/page_content_annotations_web_contents_observer.h"
#include "components/page_content_annotations/core/page_content_extraction_types.h"
#include "components/page_info/core/features.h"
#include "components/password_manager/core/browser/password_manager.h"
#include "components/performance_manager/embedder/performance_manager_registry.h"
@@ -148,7 +150,6 @@
#include "content/public/common/buildflags.h"
#include "extensions/buildflags/buildflags.h"
#include "media/base/media_switches.h"
#include "net/base/features.h"
#include "pdf/buildflags.h"
#include "printing/buildflags/buildflags.h"
#include "rlz/buildflags/buildflags.h"
@@ -162,10 +163,10 @@
#include "chrome/browser/android/persisted_tab_data/language_persisted_tab_data_android.h"
#include "chrome/browser/android/persisted_tab_data/sensitivity_persisted_tab_data_android.h"
#include "chrome/browser/android/policy/policy_auditor_bridge.h"
#include "chrome/browser/android/tab_android.h"
#include "chrome/browser/banners/android/chrome_app_banner_manager_android.h"
#include "chrome/browser/content_settings/request_desktop_site_web_contents_observer_android.h"
#include "chrome/browser/facilitated_payments/ui/chrome_facilitated_payments_client.h"
#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"
@@ -268,10 +269,6 @@
#include "chrome/browser/rlz/chrome_rlz_tracker_web_contents_observer.h"
#endif
#if BUILDFLAG(ENABLE_REPORTING)
#include "components/tpcd/enterprise_reporting/enterprise_reporting_tab_helper.h"
#endif
#if BUILDFLAG(SAFE_BROWSING_AVAILABLE)
#include "chrome/browser/safe_browsing/chrome_password_reuse_detection_manager_client.h"
#include "chrome/browser/safe_browsing/chrome_safe_browsing_tab_observer_delegate.h"
@@ -289,6 +286,17 @@ namespace {
const char kTabContentsAttachedTabHelpersUserDataKey[] =
"TabContentsAttachedTabHelpers";
std::optional<int64_t> GetPageContentAnnotationsTabId(
content::WebContents* web_contents) {
#if BUILDFLAG(IS_ANDROID)
if (TabAndroid* tab = TabAndroid::FromWebContents(web_contents)) {
return tab->GetAndroidId();
}
#endif
// TODO(crbug.com/440643544): Implement a usable tab ID for other platforms.
return std::nullopt;
}
} // namespace
// static
@@ -424,13 +432,6 @@ void TabHelpers::AttachTabHelpers(WebContents* web_contents) {
web_contents,
std::make_unique<PageSpecificContentSettingsDelegate>(web_contents));
CoreTabHelper::CreateForWebContents(web_contents);
#if BUILDFLAG(ENABLE_REPORTING)
if (base::FeatureList::IsEnabled(
net::features::kReportingApiEnableEnterpriseCookieIssues)) {
tpcd::enterprise_reporting::EnterpriseReportingTabHelper::
CreateForWebContents(web_contents);
}
#endif
ExternalProtocolObserver::CreateForWebContents(web_contents);
favicon::CreateContentFaviconDriverForWebContents(web_contents);
FileSystemAccessPermissionRequestManager::CreateForWebContents(web_contents);
@@ -469,7 +470,12 @@ void TabHelpers::AttachTabHelpers(WebContents* web_contents) {
PageContentAnnotationsServiceFactory::GetForProfile(profile);
if (page_content_annotations_service) {
page_content_annotations::PageContentAnnotationsWebContentsObserver::
CreateForWebContents(web_contents);
CreateForWebContents(
web_contents, *page_content_annotations_service,
page_content_annotations::PageContentExtractionServiceFactory::
GetForProfile(profile),
base::BindRepeating(&page_content_annotations::FetchPageContext),
base::BindRepeating(&GetPageContentAnnotationsTabId));
#if BUILDFLAG(IS_ANDROID)
// If enabled, save sensitivity data for each non-incognito android tab.
@@ -499,15 +505,7 @@ void TabHelpers::AttachTabHelpers(WebContents* web_contents) {
performance_manager::PerformanceManagerRegistry::GetInstance()) {
pm_registry->SetPageType(web_contents, performance_manager::PageType::kTab);
}
// The tab interface is only needed on Desktop to support Split View.
tabs::TabInterface* desktop_tab_interface =
#if BUILDFLAG(IS_ANDROID)
nullptr;
#else
tabs::TabInterface::MaybeGetFromContents(web_contents);
#endif // BUILDFLAG(IS_ANDROID)
permissions::PermissionRequestManager::CreateForWebContents(
web_contents, desktop_tab_interface);
permissions::PermissionRequestManager::CreateForWebContents(web_contents);
permissions::PermissionRecoverySuccessRateTracker::CreateForWebContents(
web_contents);
// The PopupBlockerTabHelper has an implicit dependency on
@@ -586,7 +584,6 @@ void TabHelpers::AttachTabHelpers(WebContents* web_contents) {
SupervisedUserNavigationObserver::CreateForWebContents(web_contents);
}
#endif
HttpErrorTabHelper::CreateForWebContents(web_contents);
tasks::TaskTabHelper::CreateForWebContents(web_contents);
tpcd::metadata::TpcdMetadataDevtoolsObserver::CreateForWebContents(
web_contents);
@@ -620,7 +617,6 @@ void TabHelpers::AttachTabHelpers(WebContents* web_contents) {
*web_contents));
}
ContextMenuHelper::CreateForWebContents(web_contents);
FastCheckoutTabHelper::CreateForWebContents(web_contents);
if (base::FeatureList::IsEnabled(
page_load_metrics::features::kBeaconLeakageLogging)) {
@@ -660,9 +656,6 @@ void TabHelpers::AttachTabHelpers(WebContents* web_contents) {
std::make_unique<JavaScriptTabModalDialogManagerDelegateDesktop>(
web_contents));
ManagePasswordsUIController::CreateForWebContents(web_contents);
if (PrivacySandboxPromptHelper::ProfileRequiresPrompt(profile)) {
PrivacySandboxPromptHelper::CreateForWebContents(web_contents);
}
if (SearchEngineChoiceTabHelper::IsHelperNeeded()) {
SearchEngineChoiceTabHelper::CreateForWebContents(web_contents);
@@ -158,6 +158,7 @@ namespace autofillPrivate {
FLIGHT_RESERVATION_DEPARTURE_AIRPORT,
FLIGHT_RESERVATION_ARRIVAL_AIRPORT,
FLIGHT_RESERVATION_DEPARTURE_DATE,
ADDRESS_HOME_ZIP_AND_CITY,
MAX_VALID_FIELD_TYPE
};
@@ -416,6 +417,10 @@ namespace autofillPrivate {
DOMString guid;
// The nickname of the entity instance.
DOMString nickname;
// Whether the user should be authenticated to view the entity instance.
boolean? shouldAuthenticateToView;
// Whether the entity is (or should be) stored in Google Wallet servers.
boolean? storedInWallet;
};
// Contains the minimum amount of information needed to display an entity
@@ -466,15 +471,15 @@ namespace autofillPrivate {
callback GetCreditCardCallback = void(optional CreditCardEntry card);
callback CheckForDeviceAuthCallback = void(boolean isDeviceAuthAvailable);
callback LoadEntityInstancesCallback = void(EntityInstanceWithLabels[] entries);
callback GetEntityInstanceByGuid = void(EntityInstance entityInstance);
callback GetEntityInstanceByGuid = void(optional EntityInstance entityInstance);
callback GetWritableEntityTypesCallback = void(EntityType[] entityTypes);
callback GetAllAttributeTypesForEntityTypeNameCallback =
void(AttributeType[] attributeTypes);
callback GetAttributeTypesCallback = void(AttributeType[] attributeTypes);
callback GetAutofillAiOptInStatusCallback = void(boolean optedIn);
callback SetAutofillAiOptInStatusCallback = void(boolean success);
callback GetWalletablePassDetectionOptInStatusCallback = void(boolean optedIn);
callback SetWalletablePassDetectionOptInStatusCallback = void(boolean success);
callback GetPayOverTimeIssuerListCallback = void(PayOverTimeIssuerEntry[] entries);
callback AuthenticateUserBeforeViewingEntityDataCallback = void(boolean success);
interface Functions {
// Gets currently signed-in user profile info, no value is returned if
@@ -571,6 +576,15 @@ namespace autofillPrivate {
// will then flip the mandatory auth toggle.
static void authenticateUserAndFlipMandatoryAuthToggle();
// Authenticates the user before viewing entity data. Returns true if
// authentication was successful or if no authentication was required.
static void authenticateUserBeforeViewingEntityData(
AuthenticateUserBeforeViewingEntityDataCallback callback);
// Authenticates the user before updating the reauth requirement when
// viewing sensitive entity information.
static void toggleAutofillAiReauthRequirement();
// Returns the local card based on the `guid` provided. The user could
// also be challenged with a reauth if that is enabled. For a successful
// auth, the local card is returned otherwise return a null object.
@@ -603,7 +617,8 @@ namespace autofillPrivate {
// Returns all of the user's entity instances with labels.
static void loadEntityInstances(LoadEntityInstancesCallback callback);
// Returns the entity instance by its guid.
// Returns the entity instance by its guid or null if authentication is required to
// view the entity and the attempted Reauth was unsuccessful.
static void getEntityInstanceByGuid(
DOMString guid, GetEntityInstanceByGuid callback);
@@ -616,7 +631,15 @@ namespace autofillPrivate {
// adding/editing a new entity instance.
static void getAllAttributeTypesForEntityTypeName(
long entityTypeName,
GetAllAttributeTypesForEntityTypeNameCallback callback);
GetAttributeTypesCallback callback);
// Returns the list of attributes satisfying the entity type's import
// requirements. The list represents a disjunction: presenting any one
// attribute is sufficient. Returns an empty list if there are no
// requirements.
static void getRequiredAttributeTypesForEntityTypeName(
long entityTypeName,
GetAttributeTypesCallback callback);
// Gets the AutofillAI opt-in status for the current user.
static void getAutofillAiOptInStatus(
@@ -210,10 +210,6 @@ namespace developerPrivate {
// Only populated for extensions that can be affected by the runtime host
// permissions feature.
RuntimeHostPermissions? runtimeHostPermissions;
// True if the extension can access site data through host permissions or
// API permissions such as activeTab.
boolean canAccessSiteData;
};
dictionary ExtensionInfo {
@@ -149,7 +149,12 @@ namespace downloads {
// For use by the Secure Enterprise Browser extension. When required, Chrome
// will block the download to disc and download the file directly to Google
// Drive.
forceSaveToGdrive
forceSaveToGdrive,
// For use by the Secure Enterprise Browser extension. When required, Chrome
// will block the download to disc and download the file directly to
// OneDrive.
forceSaveToOnedrive
};
// <dl><dt>in_progress</dt>
@@ -372,7 +372,7 @@ namespace passwordsPrivate {
callback ExceptionListCallback = void(ExceptionEntry[] exceptions);
callback ExportProgressStatusCallback = void(ExportProgressStatus status);
callback VoidCallback = void();
callback IsAccountStorageEnabledCallback = void(boolean enabled);
callback IsAccountStorageActiveCallback = void(boolean enabled);
callback ShouldShowAccountStorageSettingToggleCallback = void(boolean show);
callback PasswordCheckStatusCallback = void(PasswordCheckStatus status);
callback ImportPasswordsCallback = void(ImportResults results);
@@ -508,9 +508,9 @@ namespace passwordsPrivate {
static void requestExportProgressStatus(
ExportProgressStatusCallback callback);
// Requests the account-storage enabled state of the current user.
static void isAccountStorageEnabled(
IsAccountStorageEnabledCallback callback);
// Requests the account-storage active state of the current user.
static void isAccountStorageActive(
IsAccountStorageActiveCallback callback);
// Triggers the enabling / disabling flow for the account storage.
static void setAccountStorageEnabled(boolean enabled);
@@ -621,9 +621,9 @@ namespace passwordsPrivate {
// |status|: The progress status and an optional UI message.
static void onPasswordsFileExportProgress(PasswordExportProgress status);
// Fired when the enabled state for the account-scoped storage has changed.
// |enabled|: The new enabled state.
static void onAccountStorageEnabledStateChanged(boolean enabled);
// Fired when the active state for the account-scoped storage has changed.
// |enabled|: The new active state.
static void onAccountStorageActiveStateChanged(boolean enabled);
// Fired when the visibility of the account storage toggle in Settings
// should change.
@@ -87,8 +87,11 @@ namespace sidePanel {
long? windowId;
// The tab in which to close the side panel. If a tab-specific side panel
// is open in the specified tab, it will be closed for that tab.
// At least one of this or <code>windowId</code> must be provided.
// is open in the specified tab, it will be closed for that tab. If only the
// global side panel is open, the promise returned by the call to
// <code>close()</code> will reject with an error. This behavior was changed
// in Chrome 145, with prior versions falling back to closing the global
// panel. At least one of this or <code>windowId</code> must be provided.
long? tabId;
};
@@ -179,7 +182,7 @@ namespace sidePanel {
// |options|: Specifies the context in which to close the side panel.
// |callback|: Returns a Promise which resolves when the side panel has been
// closed.
[nodoc] static void close(
static void close(
CloseOptions options,
VoidCallback callback);
};
@@ -103,14 +103,6 @@ namespace webrtcLoggingPrivate {
DOMString logId,
GenericDoneCallback callback);
// Uploads a previously kept log that was stored via a call to store().
// The caller needs to know the logId as was originally provided in the
// call to store().
static void uploadStored(RequestInfo request,
DOMString securityOrigin,
DOMString logId,
UploadDoneCallback callback);
// Uploads the log and the RTP dumps, if they exist. Logging and RTP dumping
// must be stopped before this function is called.
static void upload(RequestInfo request,
@@ -119,6 +119,7 @@
#include "components/subresource_filter/content/renderer/subresource_filter_agent.h"
#include "components/subresource_filter/content/renderer/unverified_ruleset_dealer.h"
#include "components/subresource_filter/core/common/common_features.h"
#include "components/surface_embed/buildflags/buildflags.h"
#include "components/variations/net/variations_http_headers.h"
#include "components/variations/variations_switches.h"
#include "components/version_info/version_info.h"
@@ -225,9 +226,9 @@
#include "third_party/blink/public/web/web_settings.h"
#endif // BUIDFLAG(ENABLE_EXTENSIONS_CORE)
#if BUILDFLAG(ENABLE_GUEST_VIEW)
#if BUILDFLAG(ENABLE_EXTENSIONS) && BUILDFLAG(ENABLE_GUEST_VIEW)
#include "extensions/renderer/guest_view/mime_handler_view/mime_handler_view_container_manager.h"
#endif // BUILDFLAG(ENABLE_GUEST_VIEW)
#endif // BUILDFLAG(ENABLE_EXTENSIONS) && BUILDFLAG(ENABLE_GUEST_VIEW)
#if BUILDFLAG(ENABLE_PDF)
#include "components/pdf/renderer/internal_plugin_renderer_helpers.h"
@@ -256,6 +257,11 @@
#endif // BUILDFLAG(HAS_SPELLCHECK_PANEL)
#endif // BUILDFLAG(ENABLE_SPELLCHECK)
#if BUILDFLAG(ENABLE_SURFACE_EMBED)
#include "components/surface_embed/common/features.h"
#include "components/surface_embed/renderer/create_plugin.h"
#endif // BUILDFLAG(ENABLE_SURFACE_EMBED)
#if BUILDFLAG(ENABLE_LIBRARY_CDMS) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID)
#include "chrome/renderer/media/chrome_key_systems.h"
#endif
@@ -693,13 +699,13 @@ void ChromeContentRendererClient::RenderFrameCreated(
associated_interfaces);
}
#if BUILDFLAG(ENABLE_GUEST_VIEW)
#if BUILDFLAG(ENABLE_EXTENSIONS) && BUILDFLAG(ENABLE_GUEST_VIEW)
associated_interfaces
->AddInterface<extensions::mojom::MimeHandlerViewContainerManager>(
base::BindRepeating(
&extensions::MimeHandlerViewContainerManager::BindReceiver,
base::Unretained(render_frame)));
#endif
#endif // BUILDFLAG(ENABLE_EXTENSIONS) && BUILDFLAG(ENABLE_GUEST_VIEW)
// Owned by |render_frame|.
new page_load_metrics::MetricsRenderFrameObserver(render_frame);
@@ -811,7 +817,7 @@ bool ChromeContentRendererClient::IsPluginHandledExternally(
mime_type, &plugin_info);
// TODO(ekaramad): Not continuing here due to a disallowed status should take
// us to CreatePlugin. See if more in depths investigation of |status| is
// necessary here (see https://crbug.com/965747). For now, returning false
// necessary here (see https://crbug.com/41460326). 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) {
@@ -842,10 +848,6 @@ bool ChromeContentRendererClient::IsPluginHandledExternally(
}
bool ChromeContentRendererClient::IsDomStorageDisabled() const {
if (!base::FeatureList::IsEnabled(features::kPdfEnforcements)) {
return false;
}
#if BUILDFLAG(ENABLE_PDF) && BUILDFLAG(ENABLE_EXTENSIONS)
// PDF renderers shouldn't need to access DOM storage interfaces. Note that
// it's still possible to access localStorage or sessionStorage in a PDF
@@ -877,6 +879,19 @@ bool ChromeContentRendererClient::OverrideCreatePlugin(
const WebPluginParams& params,
WebPlugin** plugin) {
std::string orig_mime_type = params.mime_type.Utf8();
#if BUILDFLAG(ENABLE_SURFACE_EMBED)
if (base::FeatureList::IsEnabled(surface_embed::features::kSurfaceEmbed)) {
GURL url = render_frame->GetWebFrame()->GetDocument().Url();
if (url.SchemeIs(content::kChromeUIScheme) &&
url.host() == chrome::kChromeUIWebuiBrowserHost) {
if (surface_embed::MaybeCreatePlugin(render_frame, params, plugin)) {
return true;
}
}
}
#endif // BUILDFLAG(ENABLE_SURFACE_EMBED)
#if BUILDFLAG(ENABLE_EXTENSIONS)
// Used for plugins.
if (!extensions::ExtensionsRendererClient::Get()->OverrideCreatePlugin(
@@ -1285,7 +1285,7 @@ policies:
1284: SystemShortcutBehavior
1285: DeletingUndecryptablePasswordsEnabled
1286: StandardizedBrowserZoomEnabled
1287: ReportingEndpoints
1287: ''
1288: PrintingLPACSandboxEnabled
1289: ShowGeminiIntroScreenEnabled
1290: DeviceRestrictionSchedule
@@ -1403,7 +1403,7 @@ policies:
1402: GeminiActOnWebSettings
1403: LocalAuthFactorsComplexity
1404: ProxyOverrideRules
1405: LocalAuthFactors
1405: AllowedLocalAuthFactors
1406: EnableProxyOverrideRulesForAllUsers
1407: DefaultIdleDetectionSetting
1408: IdleDetectionAllowedForUrls
@@ -1416,13 +1416,21 @@ policies:
1415: DeviceLoginScreenPreferSlowCiphers
1416: SearchContentSharingSettings
1417: StaticStorageQuotaEnabled
1418: SaaSReportDomainUrlsForBrowser
1419: SaaSReportDomainUrlsForProfile
1418: SaasUsageReportingDomainUrlsForBrowsers
1419: SaasUsageReportingDomainUrlsForProfiles
1420: GeminiActOnWebAllowedForURLs
1421: GeminiActOnWebBlockedForURLs
1422: WebAppInstallByUserEnabled
1423: ''
1423: LocalNetworkAccessIpAddressSpaceOverrides
1424: RestrictPdfSaveToGoogleDriveAccountsToPattern
1425: LocalNetworkAllowedForUrls
1426: LocalNetworkBlockedForUrls
1427: LoopbackNetworkAllowedForUrls
1428: LoopbackNetworkBlockedForUrls
1429: XSLTEnabled
1430: LocalNetworkAccessPermissionsPolicyDefaultEnabled
1431: ForceForegroundPriorityForAllTabs
1432: WebRtcDiagnosticLogCollectionAllowedForOrigins
atomic_groups:
1: Homepage
@@ -1478,7 +1486,7 @@ atomic_groups:
51: WebPrintingSettings
52: DirectSocketsSettings
53: SkyVaultSettings
54: BrowserEventReporting
54: ''
55: SmartCardConnectSettings
56: WebRtc
57: ControlledFrameSettings
@@ -29,5 +29,6 @@ schema:
type: boolean
supported_on:
- chrome.*:140-
- chrome_os:145-
tags: []
type: main
@@ -31,5 +31,6 @@ schema:
type: boolean
supported_on:
- chrome.*:133-
- chrome_os:145-
tags: []
type: main
@@ -1,2 +0,0 @@
caption: Browser Event Reporting
desc: Controls settings for Browser Event Reporting.
@@ -1,26 +0,0 @@
caption: Reporting Endpoints
default: {}
desc: |-
Allows you to configure the list of Reporting API Endpoints[1] where
enterprise reports can be sent.
[1] https://www.w3.org/TR/reporting-1/#endpoint
example_value:
endpoint-1: https://example.com
reporting-endpoint: https://reporting.example/cookie-issues
features:
dynamic_refresh: true
per_profile: true
owners:
- sandormajor@chromium.org
- selya@google.com
schema:
type: object
additionalProperties:
type: string
future_on:
- android
- chrome.*
- chrome_os
tags: []
type: dict
@@ -1,4 +0,0 @@
BrowserEventReporting:
caption: Browser Event Reporting
policies:
- ReportingEndpoints
@@ -2,7 +2,7 @@ caption: Specifies a list of SaaS domains that will be reported for managed brow
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 set, the URLs matching SaaS domains will be used to generate report. Unmatched URLs will be ignored.
When the policy is not set or set to an empty list, no report will be generated.
@@ -2,7 +2,7 @@ caption: Specifies a list of SaaS domains that will be reported for managed prof
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 set, the URLs matching SaaS domains will be used to generate report. Unmatched URLs will be ignored.
When the policy is not set or set to an empty list, no report will be generated.
@@ -24,6 +24,7 @@ features:
dynamic_refresh: true
per_profile: true
future_on:
- android
- fuchsia
owners:
- file://third_party/blink/renderer/core/fullscreen/OWNERS
@@ -24,6 +24,7 @@ features:
dynamic_refresh: true
per_profile: true
future_on:
- android
- fuchsia
owners:
- file://third_party/blink/renderer/core/fullscreen/OWNERS
@@ -25,10 +25,10 @@ label: Idle detection
owners:
- pastarmovj@chromium.org
- zmin@chromium.org
future_on:
- chrome.*
- chrome_os
- android
supported_on:
- chrome.*:146-
- chrome_os:146-
- android:146-
tags:
- website-sharing
type: int-enum
@@ -9,7 +9,7 @@ desc: |-
Use <ph name="THIRD_PARTY_STORAGE_PARTITIONING_BLOCKED_FOR_ORIGINS_POLICY_NAME">ThirdPartyStoragePartitioningBlockedForOrigins</ph> to disable third-party storage partitioning for specific top-level origins. For detailed information on third-party storage partitioning, please see https://developers.google.com/privacy-sandbox/cookies/storage-partitioning.
This will be removed in Chrome 145, and the requestStorageAccess method is recommended for use instead: https://developer.mozilla.org/en-US/docs/Web/API/Document/requestStorageAccess. Feedback can be left at https://crbug.com/425248669.
This was removed in Chrome 145, and the requestStorageAccess method is recommended for use instead: https://developer.mozilla.org/en-US/docs/Web/API/Document/requestStorageAccess. Feedback can be left at https://crbug.com/425248669.
example_value: 1
features:
dynamic_refresh: true
@@ -32,9 +32,9 @@ schema:
- 2
type: integer
supported_on:
- android:113-
- chrome.*:113-
- chrome_os:113-
- android:113-145
- chrome.*:113-145
- chrome_os:113-145
deprecated: true
tags: []
type: int-enum
@@ -19,10 +19,10 @@ schema:
type: array
items:
type: string
future_on:
- chrome.*
- chrome_os
- android
supported_on:
- chrome.*:146-
- chrome_os:146-
- android:146-
tags:
- website-sharing
type: list
@@ -19,10 +19,10 @@ schema:
type: array
items:
type: string
future_on:
- chrome.*
- chrome_os
- android
supported_on:
- chrome.*:146-
- chrome_os:146-
- android:146-
tags:
- website-sharing
type: list
@@ -7,11 +7,6 @@ desc: |-
If this policy is set to Enabled or not set, Blob URLs will be partitioned.
If this policy is set to Disabled, Blob URLs won't be partitioned.
If storage partitioning is disabled for a given top-level origin by either
<ph name="THIRD_PARTY_STORAGE_PARTITIONING_BLOCKED_FOR_ORIGINS_POLICY_NAME">ThirdPartyStoragePartitioningBlockedForOrigins</ph>
or <ph name="DEFAULT_THIRD_PARTY_STORAGE_PARTITIONING_SETTING_POLICY_NAME">DefaultThirdPartyStoragePartitioningSetting</ph>,
then Blob URLs will also not be partitioned.
If you must use the policy, please file a bug at
<ph name="BUG_URL">$1<ex>https://crbug.com/new?component=1779870&amp;cc=awillia@chromium.org&amp;priority=p1&amp;type=bug&amp;noWizard=true</ex></ph>
explaining your use case. The policy is scheduled to be offered through
@@ -8,7 +8,7 @@ desc: |-
For detailed information on third-party storage partitioning, please see https://developers.google.com/privacy-sandbox/cookies/storage-partitioning.
This will be removed in Chrome 145, and the requestStorageAccess method is recommended for use instead: https://developer.mozilla.org/en-US/docs/Web/API/Document/requestStorageAccess. Feedback can be left at https://crbug.com/425248669.
This was removed in Chrome 145, and the requestStorageAccess method is recommended for use instead: https://developer.mozilla.org/en-US/docs/Web/API/Document/requestStorageAccess. Feedback can be left at https://crbug.com/425248669.
example_value:
- www.example.com
- '[*.]example.edu'
@@ -25,9 +25,9 @@ schema:
type: string
type: array
supported_on:
- android:113-
- chrome.*:113-
- chrome_os:113-
- android:113-145
- chrome.*:113-145
- chrome_os:113-145
deprecated: true
tags: []
type: list
@@ -59,11 +59,6 @@ SensorsSettings:
- DefaultSensorsSetting
- SensorsAllowedForUrls
- SensorsBlockedForUrls
ThirdPartyStoragePartitioningSettings:
caption: Third-party storage partitioning settings
policies:
- DefaultThirdPartyStoragePartitioningSetting
- ThirdPartyStoragePartitioningBlockedForOrigins
WebUsbSettings:
caption: Web USB settings
policies:
@@ -33,8 +33,8 @@ items:
owners:
- file://crypto/OWNERS
- trusty-transport@chromium.org
future_on:
- chrome_os
supported_on:
- chrome_os:146-
schema:
enum:
- cnsa
@@ -35,8 +35,8 @@ items:
owners:
- file://crypto/OWNERS
- trusty-transport@chromium.org
future_on:
- chrome_os
supported_on:
- chrome_os:146-
schema:
enum:
- cnsa2
@@ -30,10 +30,10 @@ items:
owners:
- file://crypto/OWNERS
- trusty-transport@chromium.org
future_on:
- android
- chrome.*
- chrome_os
supported_on:
- android:146-
- chrome.*:146-
- chrome_os:146-
schema:
enum:
- cnsa
@@ -32,10 +32,10 @@ items:
owners:
- file://crypto/OWNERS
- trusty-transport@chromium.org
future_on:
- android
- chrome.*
- chrome_os
supported_on:
- android:146-
- chrome.*:146-
- chrome_os:146-
schema:
enum:
- cnsa2
@@ -1,5 +1,5 @@
owners:
- artyomchen@chromium.org
- vsavu@google.com
- chromeos-commercial-remote-management@google.com
caption: Enable/disable Extended Automatic Updates
@@ -9,12 +9,12 @@ desc: |-
External extensions and their installation are documented at https://developer.chrome.com/docs/extensions/how-to/distribute/install-extensions.
Note: This policy only applies to platforms that support extensions.
example_value: true
features:
dynamic_refresh: false
per_profile: true
future_on:
- android
items:
- caption: Block installation of external extensions
value: true
@@ -27,5 +27,6 @@ schema:
type: boolean
supported_on:
- chrome.*:80-
- android:146-
tags: []
type: main
@@ -2,34 +2,35 @@ caption: Configure allowed app/extension types
desc: |-
Setting the policy controls which apps and extensions may be installed in <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph>, which hosts they can interact with, and limits runtime access.
Leaving the policy unset results in no restrictions on the acceptable extension and app types.
Leaving the policy unset results in no restrictions on the acceptable extension and app types.
Extensions and apps which have a type that's not on the list won't be installed. Each value should be one of these strings:
Extensions and apps which have a type that's not on the list won't be installed. Each value should be one of these strings:
* "extension"
* "extension"
* "theme"
* "theme"
* "user_script"
* "user_script"
* "hosted_app"
* "hosted_app"
* "legacy_packaged_app"
* "legacy_packaged_app"
* "platform_app"
* "platform_app"
See the <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> extensions documentation for more information on these types.
See the <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> extensions documentation for more information on these types.
Versions earlier than 75 that use multiple comma separated extension IDs aren't supported and are skipped. The rest of the policy applies.
Versions earlier than 75 that use multiple comma separated extension IDs aren't supported and are skipped. The rest of the policy applies.
Note: This policy also affects extensions and apps to be force-installed using <ph name="EXTENSION_INSTALL_FORCELIST_POLICY_NAME">ExtensionInstallForcelist</ph>.
Note: This policy only applies to platforms that support extensions.
Note: This policy also affects extensions and apps to be force-installed using <ph name="EXTENSION_INSTALL_FORCELIST_POLICY_NAME">ExtensionInstallForcelist</ph>.
example_value:
- hosted_app
features:
dynamic_refresh: true
per_profile: true
future_on:
- android
items:
- caption: Extension
name: extension
@@ -57,5 +58,6 @@ schema:
supported_on:
- chrome.*:25-
- chrome_os:25-
- android:146-
tags: []
type: string-enum-list
@@ -8,9 +8,12 @@ desc: |-
If this policy is set, <ph name="DEVELOPER_TOOLS_AVAILABILITY_POLICY_NAME">DeveloperToolsAvailability</ph> can no longer control extensions developer mode.
Note: This policy only applies to platforms that support extensions.
supported_on:
- chrome.*:128-
- chrome_os:128-
- android:146-
features:
dynamic_refresh: true
per_profile: true
@@ -2,17 +2,18 @@ caption: Configure extension installation allow list
desc: |-
Setting the policy specifies which extensions are not subject to the blocklist.
A blocklist value of <ph name="ALL_EXTENSIONS">*</ph> means all extensions are blocked and users can only install extensions listed in the allow list.
A blocklist value of <ph name="ALL_EXTENSIONS">*</ph> means all extensions are blocked and users can only install extensions listed in the allow list.
By default, all extensions are allowed. But, if you prohibited extensions by policy, use the list of allowed extensions to change that policy.
Note: This policy only applies to platforms that support extensions.
By default, all extensions are allowed. But, if you prohibited extensions by policy, use the list of allowed extensions to change that policy.
example_value:
- extension_id1
- extension_id2
features:
dynamic_refresh: true
per_profile: true
future_on:
- android
label: Extension IDs to exempt from the blocklist
owners:
- rdevlin.cronin@chromium.org
@@ -24,5 +25,6 @@ schema:
supported_on:
- chrome.*:86-
- chrome_os:86-
- android:146-
tags: []
type: list
@@ -2,17 +2,18 @@ caption: Configure extension installation blocklist
desc: |-
Allows you to specify which extensions the users can NOT install. Extensions already installed will be disabled if blocked, without a way for the user to enable them. Once an extension disabled due to the blocklist is removed from it, it will automatically get re-enabled.
A blocklist value of '*' means all extensions are blocked by default. Extensions that are explicitly listed in the allowlist are allowed if they are signed (packed). All unpacked extensions are blocked.
A blocklist value of '*' means all extensions are blocked by default. Extensions that are explicitly listed in the allowlist are allowed if they are signed (packed). All unpacked extensions are blocked.
If this policy is left not set the user can install any extension in <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph>.
Note: This policy only applies to platforms that support extensions.
If this policy is left not set the user can install any extension in <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph>.
example_value:
- extension_id1
- extension_id2
features:
dynamic_refresh: true
per_profile: true
future_on:
- android
label: Extension IDs the user should be prevented from installing (or * for all)
owners:
- lazyboy@chromium.org
@@ -24,5 +25,6 @@ schema:
supported_on:
- chrome.*:86-
- chrome_os:86-
- android:146-
tags: []
type: list
@@ -19,14 +19,15 @@ desc: |-
On <ph name="MAC_OS_NAME">macOS</ph> instances, apps and extensions from outside the Chrome Web Store can only be force installed if the instance is managed via MDM, joined to a domain via MCX or enrolled in <ph name="CHROME_ENTERPRISE_CORE_NAME">Chrome Enterprise Core</ph>.
Note: This policy doesn't apply to Incognito mode. Read about hosting extensions ( https://developer.chrome.com/extensions/hosting ).
Note: This policy only applies to platforms that support extensions.
example_value:
- aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa;https://clients2.google.com/service/update2/crx
- abcdefghijklmnopabcdefghijklmnop
features:
dynamic_refresh: true
per_profile: true
future_on:
- android
label: Extension/App IDs and update URLs to be silently installed
owners:
- karandeepb@chromium.org
@@ -38,6 +39,7 @@ schema:
supported_on:
- chrome.*:9-
- chrome_os:11-
- android:146-
tags:
- full-admin-access
type: list
@@ -2,16 +2,17 @@ caption: Configure extension, app, and user script install sources
desc: |-
Setting the policy specifies which URLs may install extensions, apps, and themes. Before <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> 21, users could click on a link to a *.crx file, and <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> would offer to install the file after a few warnings. Afterwards, such files must be downloaded and dragged to the <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> settings page. This setting allows specific URLs to have the old, easier installation flow.
Each item in this list is an extension-style match pattern (see https://developer.chrome.com/extensions/match_patterns). Users can easily install items from any URL that matches an item in this list. Both the location of the *.crx file and the page where the download is started from (the referrer) must be allowed by these patterns.
Each item in this list is an extension-style match pattern (see https://developer.chrome.com/extensions/match_patterns). Users can easily install items from any URL that matches an item in this list. Both the location of the *.crx file and the page where the download is started from (the referrer) must be allowed by these patterns.
<ph name="EXTENSION_INSTALL_BLOCKLIST_POLICY_NAME">ExtensionInstallBlocklist</ph> takes precedence over this policy. That is, an extension on the blocklist won't be installed, even if it happens from a site on this list.
Note: This policy only applies to platforms that support extensions.
<ph name="EXTENSION_INSTALL_BLOCKLIST_POLICY_NAME">ExtensionInstallBlocklist</ph> takes precedence over this policy. That is, an extension on the blocklist won't be installed, even if it happens from a site on this list.
example_value:
- https://corp.mycompany.com/*
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
@@ -21,6 +22,7 @@ schema:
supported_on:
- chrome.*:21-
- chrome_os:21-
- android:146-
tags:
- full-admin-access
- system-security
@@ -7,6 +7,9 @@ desc: |-
On <ph name="MS_WIN_NAME">Microsoft® Windows®</ph> instances, apps and extensions from outside the Chrome Web Store can only be forced installed if the instance is 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> instances, apps and extensions from outside the Chrome Web Store can only be force installed if the instance is managed via MDM, joined to a domain via MCX or enrolled in <ph name="CHROME_ENTERPRISE_CORE_NAME">Chrome Enterprise Core</ph>.
Note: This policy only applies to platforms that support extensions.
example_value:
'*':
allowed_types:
@@ -60,8 +63,6 @@ example_value:
features:
dynamic_refresh: true
per_profile: true
future_on:
- android
owners:
- finnur@chromium.org
- file://extensions/OWNERS
@@ -144,6 +145,7 @@ schema:
supported_on:
- chrome.*:62-
- chrome_os:62-
- android:146-
tags: []
type: dict
url_schema: https://www.chromium.org/administrators/policy-list-3/extension-settings-full
@@ -7,7 +7,7 @@ desc: |-
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.
A set can also contain a list of service sites that it owns, as well as a map from a site to all of its ccTLD variants.
See https://github.com/WICG/first-party-sets for more information on First-Party Sets are used by <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph>.
See https://github.com/WICG/first-party-sets for more information on how First-Party Sets are used by <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph>.
All sites in a First-Party Set must be a registrable domain served over HTTPS. Each site in a First-Party Set must also be unique,
meaning a site cannot be listed more than once in a First-Party Set.
@@ -33,10 +33,6 @@ desc: |-
All sets provided by the policy must be valid First-Party Sets, if they aren't then an
appropriate error will be outputted.
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>.
This is the equivalent of the <ph name="RELATED_WEBSITE_SETS_OVERRIDES_POLICY_NAME">RelatedWebsiteSetsOverrides</ph> policy.
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.
@@ -19,9 +19,10 @@ example_value:
- https://server:8080/path
- .exact.hostname.com
future_on:
- chrome.*
- chrome_os
- android
supported_on:
- chrome.*:146-
- chrome_os:146-
features:
dynamic_refresh: true
per_profile: true
@@ -19,9 +19,10 @@ example_value:
- https://server:8080/path
- .exact.hostname.com
future_on:
- chrome.*
- chrome_os
- android
supported_on:
- chrome.*:146-
- chrome_os:146-
features:
dynamic_refresh: true
per_profile: true
@@ -5,7 +5,7 @@ desc: |-
When the policy is set to Allowed (0) or not set, the model is downloaded automatically, and used for inference.
When the policy is set to Disabled (1), the model will not be downloaded.
When the policy is set to Disabled (1), the model will not be downloaded, and the existing model (if already downloaded) will be deleted.
On desktop platforms, model downloading can also be disabled by <ph name="COMPONENT_UPDATES_ENABLED_POLICY_NAME">ComponentUpdatesEnabled</ph>.
@@ -3,14 +3,14 @@ caption: Set the default policy value for <ph name="PRODUCT_NAME">$1<ex>Google C
desc: |-
This policy defines the default setting for all covered generative AI features. For example, if this policy is set to value 1, then 1 will be the default setting for all covered generative AI features. It will not impact any manually set policy values. This setting will define the defaults for covered generative AI features in Chrome. See https://support.google.com/chrome/a?p=generative_ai_settings for the list of covered features.
Some policies, e.g. <ph name="GEMINI_SETTINGS_POLICY_NAME">GeminiSettings</ph>, only support the states Allowed and Do not allow. In this case, if <ph name="GEN_AI_DEFAULT_SETTINGS_POLICY_NAME">GenAiDefaultSettings</ph> is set to 0 or 1, this feature will be enabled. If <ph name="GEN_AI_DEFAULT_SETTINGS_POLICY_NAME">GenAiDefaultSettings</ph> is set to 2, this feature will be disabled. The documentation for each feature contains more details about how it interacts with values in this policy (e.g. Gemini in Chrome - https://support.google.com/chrome/a/?p=gemini_in_chrome). This applies to the following features: Gemini in Chrome, Google Lens, and AI Mode as they are subject to their own guarantees and/or terms of service (https://support.google.com/chrome/a/?p=genai_features_chrome).
0 = Allow the feature to be used, while allowing Google to use relevant data to improve its AI models. Relevant data may include prompts, inputs, outputs, source materials, and written feedback, depending on the feature. It may also be reviewed by humans to improve AI models. 0 is the default value, except when noted below.
1 = Allow the feature to be used, but does not allow Google to improve models using users' content (including prompts, inputs, outputs, source materials, and written feedback). 1 is the default value for Enterprise users managed by <ph name="GOOGLE_ADMIN_CONSOLE_PRODUCT_NAME">Google Admin console</ph> and for Education accounts managed by <ph name="GOOGLE_WORKSPACE_PRODUCT_NAME">Google Workspace</ph>.
2 = Do not allow the feature.
If a covered Chrome feature does not have an equivalent policy value, the closest higher value will be used. Some policies, e.g. <ph name="GEMINI_SETTINGS_POLICY_NAME">GeminiSettings</ph>, only support the states Allowed and Not Allowed. If <ph name="GEN_AI_DEFAULT_SETTINGS_POLICY_NAME">GenAiDefaultSettings</ph> policy is set to 0 or 1, this feature will be allowed. If policy is set to 2, this feature will not be allowed. Please review documentation for each feature for more details about how it interacts with values in this 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
@@ -7,7 +7,7 @@ desc: |-
0/unset = users can share page or file content with <ph name="GOOGLE_AI_MODE_PRODUCT_NAME">Google AI Mode</ph>.
1 = users cannot share page or file content with <ph name="GOOGLE_AI_MODE_PRODUCT_NAME">Google AI Mode</ph>. The entry points for sharing context will be disabled or hidden.
1 = users cannot share page or file content with <ph name="GOOGLE_AI_MODE_PRODUCT_NAME">Google AI Mode</ph>. The entry points for sharing context and the side panel will be disabled or hidden.
This policy will be ignored when <ph name="GOOGLE_SEARCH_PRODUCT_NAME">Google Search</ph> is not users' default search engine as the feature is disabled.
@@ -3,12 +3,10 @@ owners:
- cthomp@chromium.org
- chrome-secure-web-and-net@chromium.org
caption: Allow sites to make requests to local network endpoints.
caption: Allow sites to make network requests to local devices and local network endpoints.
desc: |-
List of URL patterns. Requests initiated from websites served by matching origins are not subject to <ph name="LOCAL_NETWORK_ACCESS">Local Network Access</ph> checks.
If an origin is covered by both this policy and by LocalNetworkAccessBlockedForUrls, LocalNetworkAccessBlockedForUrls takes precedence.
List of URL patterns. Network requests initiated from websites served by matching origins are not subject to <ph name="LOCAL_NETWORK_ACCESS">Local Network Access</ph> checks.
For origins not covered by the patterns specified here, the user's personal configuration will apply.
@@ -17,6 +15,15 @@ desc: |-
See https://wicg.github.io/local-network-access/ for <ph
name="LOCAL_NETWORK_ACCESS">Local Network Access</ph> restrictions.
There are multiple policies listing origins that impact requests to local device and local network endpoints. If an origin is matched by more than one of the following policies, the policies take precedence in the following order:
- LocalNetworkBlockedForUrls
- LocalNetworkAllowedForUrls
- LoopbackNetworkAccessBlockedForUrls
- LoopbackNetworkAccessAllowedForUrls
- LocalNetworkAccessBlockedForUrls
- LocalNetworkAccessAllowedForUrls
example_value:
- http://www.example.com:8080
- '[*.]example.edu'
@@ -3,14 +3,10 @@ owners:
- cthomp@chromium.org
- chrome-secure-web-and-net@chromium.org
caption: Block sites from making requests to local network endpoints.
caption: Block sites from making network requests to local devices and local network endpoints.
desc: |-
List of URL patterns. Requests initiated from websites served by matching origins are blocked from issuing <ph name="LOCAL_NETWORK_ACCESS">Local Network Access</ph> requests.
If an origin is covered by both this policy and by LocalNetworkAccessAllowedForUrls, this policy takes precedence.
Depending on the stage of the rollout of <ph name="LOCAL_NETWORK_ACCESS">Local Network Access</ph>, LocalNetworkAccessRestrictionsEnabled may also need to be enabled for this policy to block <ph name="LOCAL_NETWORK_ACCESS">Local Network Access</ph> requests.
List of URL patterns. Network requests initiated from websites served by matching origins are blocked from issuing <ph name="LOCAL_NETWORK_ACCESS">Local Network Access</ph> requests.
For origins not covered by the patterns specified here, the user's personal configuration will apply.
@@ -19,6 +15,15 @@ desc: |-
See https://wicg.github.io/local-network-access/ for <ph
name="LOCAL_NETWORK_ACCESS">Local Network Access</ph> restrictions.
There are multiple policies listing origins that impact requests to local device and local network endpoints. If an origin is matched by more than one of the following policies, the policies take precedence in the following order:
- LocalNetworkBlockedForUrls
- LocalNetworkAllowedForUrls
- LoopbackNetworkAccessBlockedForUrls
- LoopbackNetworkAccessAllowedForUrls
- LocalNetworkAccessBlockedForUrls
- LocalNetworkAccessAllowedForUrls
example_value:
- http://www.example.com:8080
- '[*.]example.edu'
@@ -0,0 +1,50 @@
owners:
- cthomp@chromium.org
- hchao@chromium.org
- chrome-swan@google.com
caption: Override IP address space mappings
desc: |-
This can be used to treat certain internal address ranges as "public" and thus not subject to <ph name="LOCAL_NETWORK_ACCES">Local Network Access</ph> checks. Conversely, this can be used to treat certain public address ranges that might be used internally as "local" so that they are protected by <ph name="LOCAL_NETWORK_ACCESS">Local Network Access</ph> checks.
IP address space overrides have two forms:
[cidr]=[public|local|loopback]
where [cidr] is a IP address range in CIDR notation (see section 3.1 of https://tools.ietf.org/html/rfc4632 for IPv4 and section 2.3 of https://tools.ietf.org/html/rfc4291 for IPv6). IPv6 addresses must be specified in URL-safe (bracketed) format. CIDR overrides apply to all ports.
or
[ip-address]:[port]=[public|local|loopback]
For more information on <ph name="LOCAL_NETWORK_ACCESS">Local Network Access</ph>, see https://wicg.github.io/local-network-access/ and https://developer.chrome.com/blog/local-network-access.
This policy does not support dynamic refresh.
Overrides from the command-line switch --ip-address-space-overrides take precedence over overrides set by this policy.
example_value:
- '100.64.0.0/10=public'
- '[2001:db8::]/32=local'
- '192.168.0.1:8000=public'
- '[2001:DB8::8:800:200C:417A]:8080=local'
supported_on:
- chrome.*:146-
- chrome_os:146-
- android:146-
features:
dynamic_refresh: false
per_profile: false
type: list
schema:
items:
type: string
type: array
tags:
- system-security
@@ -0,0 +1,46 @@
owners:
- cthomp@chromium.org
- hchao@chromium.org
- chrome-swan@google.com
caption: Allow Local Network Access (LNA) requests in subframes without explicit delegation
desc: |-
By default, the permissions for Local Network Access (LNA) are only allowed to be requested in cross-origin subframes if they are explicitly delegated. This policy can be used to override this default behavior so that LNA permissions are default inherited into subframes, unless explicitly denied in permissions policy.
If this policy is set to enabled, then subframes are by default delegated all LNA permissions policy features and can make local network requests (triggering the permission prompt).
If this policy is set to disabled or not set, then subframes must be explicitly delegated the permissions policy feature in order make local network requests and trigger the permission prompt.
This policy applies to the permissions policy features <ph name="LOCAL_NETWORK_ACCESS_FEATURE_NAME">"local-network-access"</ph>, <ph name="LOOPBACK_NETWORK_FEATURE_NAME">"loopback-network"</ph>, and <ph name="LOCAL_NETWORK_FEATURE_NAME">"local-network"</ph>.
For more information on Local Network Access, see https://wicg.github.io/local-network-access/ and https://developer.chrome.com/blog/local-network-access.
For more information on permissions policy, see https://developer.mozilla.org/en-US/docs/Web/HTTP/Guides/Permissions_Policy.
supported_on:
- chrome.*:146-
- chrome_os:146-
- android:146-
features:
dynamic_refresh: false
per_profile: false
items:
- caption: Allow LNA requests in subframes without explicit delegation
value: true
- caption: Do not allow LNA requests in subframes without explicit delegation
value: false
type: main
schema:
type: boolean
default: false
example_value: true
tags:
- system-security
@@ -0,0 +1,47 @@
owners:
- hchao@chromium.org
- cthomp@chromium.org
- chrome-secure-web-and-net@chromium.org
caption: Allow sites to make network requests to local network endpoints.
desc: |-
List of URL patterns. Network requests initiated from websites served by matching origins to local network endpoints are not subject to <ph name="LOCAL_NETWORK_ACCESS">Local Network Access</ph> checks.
For origins not covered by the patterns specified here, the user's personal configuration will apply.
For detailed information on valid URL patterns, please see https://chromeenterprise.google/policies/url-patterns/.
See https://wicg.github.io/local-network-access/ for <ph
name="LOCAL_NETWORK_ACCESS">Local Network Access</ph> restrictions.
There are multiple policies listing origins that impact requests to local network endpoints. If an origin is matched by more than one of the following policies, the policies take precedence in the following order:
- LocalNetworkBlockedForUrls
- LocalNetworkAllowedForUrls
- LocalNetworkAccessBlockedForUrls
- LocalNetworkAccessAllowedForUrls
example_value:
- http://www.example.com:8080
- '[*.]example.edu'
- '*'
supported_on:
- chrome.*:146-
- chrome_os:146-
- android:146-
features:
dynamic_refresh: true
per_profile: true
type: list
schema:
items:
type: string
type: array
tags:
- system-security
@@ -0,0 +1,47 @@
owners:
- hchao@chromium.org
- cthomp@chromium.org
- chrome-secure-web-and-net@chromium.org
caption: Block sites from making network requests to local network endpoints.
desc: |-
List of URL patterns. Network requests initiated from websites served by matching origins to local network endpoints are blocked from issuing <ph name="LOCAL_NETWORK_ACCESS">Local Network Access</ph> requests.
For origins not covered by the patterns specified here, the user's personal configuration will apply.
For detailed information on valid URL patterns, please see https://chromeenterprise.google/policies/url-patterns/.
See https://wicg.github.io/local-network-access/ for <ph
name="LOCAL_NETWORK_ACCESS">Local Network Access</ph> restrictions.
There are multiple policies listing origins that impact requests to local network endpoints. If an origin is matched by more than one of the following policies, the policies take precedence in the following order:
- LocalNetworkBlockedForUrls
- LocalNetworkAllowedForUrls
- LocalNetworkAccessBlockedForUrls
- LocalNetworkAccessAllowedForUrls
example_value:
- http://www.example.com:8080
- '[*.]example.edu'
- '*'
supported_on:
- chrome.*:146-
- chrome_os:146-
- android:146-
features:
dynamic_refresh: true
per_profile: true
type: list
schema:
items:
type: string
type: array
tags: []
@@ -0,0 +1,47 @@
owners:
- hchao@chromium.org
- cthomp@chromium.org
- chrome-secure-web-and-net@chromium.org
caption: Allow sites to make network requests to the local device.
desc: |-
List of URL patterns. Network requests initiated from websites served by matching origins to the local device are not subject to <ph name="LOCAL_NETWORK_ACCESS">Local Network Access</ph> checks.
For origins not covered by the patterns specified here, the user's personal configuration will apply.
For detailed information on valid URL patterns, please see https://chromeenterprise.google/policies/url-patterns/.
See https://wicg.github.io/local-network-access/ for <ph
name="LOCAL_NETWORK_ACCESS">Local Network Access</ph> restrictions.
There are multiple policies listing origins that impact requests to the local device. If an origin is matched by more than one of the following policies, the policies take precedence in the following order:
- LoopbackNetworkBlockedForUrls
- LoopbackNetworkAllowedForUrls
- LocalNetworkAccessBlockedForUrls
- LocalNetworkAccessAllowedForUrls
example_value:
- http://www.example.com:8080
- '[*.]example.edu'
- '*'
supported_on:
- chrome.*:146-
- chrome_os:146-
- android:146-
features:
dynamic_refresh: true
per_profile: true
type: list
schema:
items:
type: string
type: array
tags:
- system-security
@@ -0,0 +1,46 @@
owners:
- hchao@chromium.org
- cthomp@chromium.org
- chrome-secure-web-and-net@chromium.org
caption: Block sites from making network requests to the local device.
desc: |-
List of URL patterns. Network requests initiated from websites served by matching origins to the local device are blocked from issuing <ph name="LOCAL_NETWORK_ACCESS">Local Network Access</ph> requests.
For origins not covered by the patterns specified here, the user's personal configuration will apply.
For detailed information on valid URL patterns, please see https://chromeenterprise.google/policies/url-patterns/.
See https://wicg.github.io/local-network-access/ for <ph
name="LOCAL_NETWORK_ACCESS">Local Network Access</ph> restrictions.
There are multiple policies listing origins that impact requests to the local device. If an origin is matched by more than one of the following policies, the policies take precedence in the following order:
- LoopbackNetworkBlockedForUrls
- LoopbackNetworkAllowedForUrls
- LocalNetworkAccessBlockedForUrls
- LocalNetworkAccessAllowedForUrls
example_value:
- http://www.example.com:8080
- '[*.]example.edu'
- '*'
supported_on:
- chrome.*:146-
- chrome_os:146-
- android:146-
features:
dynamic_refresh: true
per_profile: true
type: list
schema:
items:
type: string
type: array
tags: []
@@ -3,5 +3,11 @@ LocalNetworkAccessSettings:
policies:
- LocalNetworkAccessAllowedForUrls
- LocalNetworkAccessBlockedForUrls
- LocalNetworkAccessIpAddressSpaceOverrides
- LocalNetworkAllowedForUrls
- LocalNetworkBlockedForUrls
- LocalNetworkAccessRestrictionsEnabled
- LocalNetworkAccessRestrictionsTemporaryOptOut
- LoopbackNetworkAllowedForUrls
- LoopbackNetworkBlockedForUrls
- LocalNetworkAccessPermissionsPolicyDefaultEnabled
@@ -5,8 +5,6 @@ desc: |-
Files with types that should be automatically opened will still be subject to the enabled safe browsing checks and won't be opened if they fail those checks.
If this policy isn't set, only file types that a user has already specified to automatically be opened will do so when downloaded.
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>.
example_value:
- exe
- txt
@@ -18,7 +18,6 @@ items:
- caption: Disable browser experimental features toolbar entrypoint
value: false
owners:
- elainechien@chromium.org
- labs-on-chrome@google.com
schema:
type: boolean
@@ -12,9 +12,10 @@ owners:
- valadkevich@google.com
- cbe-cep-eng@google.com
future_on:
- chrome.*
- chrome_os
- android
supported_on:
- chrome.*:146-
- chrome_os:146-
features:
dynamic_refresh: true
per_profile: true
@@ -12,7 +12,7 @@ desc: |-
example_value: ${google_drive}/Camera
features:
can_be_recommended: false
dynamic_refresh: true
dynamic_refresh: false
per_profile: false
owners:
- file://components/policy/OWNERS
@@ -21,8 +21,8 @@ owners:
- orko@igalia.com
schema:
type: string
future_on:
- chrome_os
supported_on:
- chrome_os:146-
tags:
- local-data-access
type: string
@@ -4,10 +4,6 @@ desc: |-
Setting the policy to Enabled or leaving it unset means security warnings appear when potentially dangerous command-line flags are used to launch Chrome.
Setting the policy to Disabled prevents security warnings from appearing when Chrome is launched with potentially dangerous command-line flags.
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:
dynamic_refresh: false
@@ -4,10 +4,6 @@ desc: |-
This policy controls a custom label used to indicate a managed browser. For managed browsers, this label will be shown in a management disclaimer on a footer on the New Tab page. The custom label will not be translated.
Note that this policy is only applied for managed browsers, so it will have no effect for managed users on unmanaged browsers.
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: Chromium
features:
dynamic_refresh: true
@@ -6,10 +6,6 @@ desc: |-
It is recommended to use the favicon (example https://www.google.com/favicon.ico) or an icon no smaller than 48 x 48 px.
Note that this policy is only applied for managed browsers, so it will have no effect for managed users on unmanaged browsers.
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://example.com/image.png
features:
dynamic_refresh: true
@@ -17,11 +17,6 @@ desc: |-
The <ph name="ICON_URL_SEARCH_AGGREGATOR_SETTINGS_FIELD">icon_url</ph> field specifies the URL to an image that will be used on the search suggestions. A default icon will be used when this field is not set. It's recommended to use a favicon (example <ph name="ICON_URL_EXAMPLE">https://www.google.com/favicon.ico</ph>). Supported image file formats: JPEG, PNG, and ICO.
The <ph name="REQUIRE_SHORTCUT_SEARCH_AGGREGATOR_SETTINGS_FIELD">require_shortcut</ph> field specifies whether the address bar <ph name="SHORTCUT_SEARCH_AGGREGATOR_SETTINGS_FIELD">shortcut</ph> is required to see search recommendations. If required, suggestions will not be shown in the search box on the New Tab page, but will continue to be shown in the omnibox (address bar) in scoped search mode. If this field is not set, the address bar <ph name="SHORTCUT_SEARCH_AGGREGATOR_SETTINGS_FIELD">shortcut</ph> is 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:
name: My Search Aggregator
shortcut: work
@@ -0,0 +1,39 @@
caption: Force foreground priority for all tabs
desc: |-
This policy controls whether background web content is forced to run at
foreground priority.
By default, the browser optimizes resources by deprioritizing content in
background tabs. Enabling this policy overrides that behavior, causing
background tabs to be scheduled the same way as the active tab.
Note that forcing background content to run at foreground priority may
slightly impact the responsiveness of the active tab.
If this policy is set to Enabled, all web content runs at foreground priority
regardless of its visibility state.
If this policy is set to Disabled or not set, the browser determines priority
based on standard heuristics (e.g., deprioritizing content that is not
visible, not playing audio, not participating in video calls...).
owners:
- mdanowski@google.com
- file://components/policy/OWNERS
supported_on:
- chrome.*:146-
- chrome_os:146-
features:
dynamic_refresh: false
per_profile: false
type: main
schema:
type: boolean
items:
- caption: Force foreground priority for all tabs
value: true
- caption: Use standard tab prioritization
value: false
default: false
example_value: true
tags: []
@@ -8,6 +8,8 @@ desc: |-
If 'Forced' is selected, pages may be opened ONLY in Incognito mode. Note that 'Forced' does not work for Android-on-Chrome
The <ph name="INCOGNITO_MODE_URL_ALLOWLIST_POLICY_NAME">IncognitoModeUrlAllowlist</ph> policy takes precedence over this policy and can re-enable Incognito mode for specific URLs. When Incognito mode is disabled by this policy when an allowlist is provided, Incognito mode is available only for URLs matching the allowlist, while all other pages are blocked.
Note: On iOS, if the policy is changed during a session, it will only take effect on relaunch.
default: 0
example_value: 1
@@ -1,10 +1,18 @@
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.
Setting the policy provides access to the listed URLs in Incognito mode. Use it to open exceptions to certain URL patterns defined in <ph name="INCOGNITO_MODE_URL_BLOCKLIST_POLICY_NAME">IncognitoModeUrlBlocklist</ph>, using the format specified at ( https://support.google.com/chrome/a?p=url_blocklist_filter_format ).
Leaving the policy unset allows no exceptions to <ph name="INCOGNITO_MODE_URL_BLOCKLIST_POLICY_NAME">IncognitoModeUrlBlocklist</ph>.
If both this policy and <ph name="INCOGNITO_MODE_URL_BLOCKLIST_POLICY_NAME">IncognitoModeUrlBlocklist</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 the blocklist (but not the allowlist), it will be blocked. If a URL matches neither, the general <ph name="URL_BLOCKLIST_POLICY_NAME">URLBlocklist</ph>/<ph name="URL_ALLOWLIST_POLICY_NAME">URLAllowlist</ph> policies will be used as a fallback.
If this policy is set and <ph name="INCOGNITO_MODE_URL_BLOCKLIST_POLICY_NAME">IncognitoModeUrlBlocklist</ph> is not, any URL not on the allowlist will be blocked in Incognito mode.
If <ph name="INCOGNITO_MODE_AVAILABILITY_POLICY_NAME">IncognitoModeAvailability</ph> is set to disallow (value 1), but this policy is configured, Incognito mode will be available only for the URLs matching the allowlist.
Leaving the policy unset allows no exceptions to <ph name="INCOGNITO_MODE_URL_BLOCKLIST_POLICY_NAME">IncognitoModeUrlBlocklist</ph> and <ph name="INCOGNITO_MODE_AVAILABILITY_POLICY_NAME">IncognitoModeAvailability</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.
This policy is limited to 1000 entries.
example_value:
- example.com
- https://ssl.server.com
@@ -1,8 +1,16 @@
caption: Block access to a list of URLs in Incognito mode.
desc: |-
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 ).
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. See how to format a URL pattern ( https://support.google.com/chrome/a?p=url_blocklist_filter_format ).
If both this and the <ph name="INCOGNITO_MODE_URL_ALLOWLIST_POLICY_NAME">IncognitoModeUrlAllowlist</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 the blocklist but not the allowlist, it will be blocked. If a URL matches neither, the general <ph name="URL_BLOCKLIST_POLICY_NAME">URLBlocklist</ph>/<ph name="URL_ALLOWLIST_POLICY_NAME">URLAllowlist</ph> policies will be used as a fallback.
If the <ph name="INCOGNITO_MODE_URL_ALLOWLIST_POLICY_NAME">IncognitoModeUrlAllowlist</ph> policy is set and this policy is not, any URL not on the allowlist will be blocked in Incognito mode.
If <ph name="INCOGNITO_MODE_AVAILABILITY_POLICY_NAME">IncognitoModeAvailability</ph> is set to disallow (value 1), but the <ph name="INCOGNITO_MODE_URL_ALLOWLIST_POLICY_NAME">IncognitoModeUrlAllowlist</ph> policy is configured, Incognito mode will be available only for the URLs matching the allowlist.
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.
This policy is limited to 1000 entries.
example_value:
- example.com
- https://ssl.server.com
@@ -6,6 +6,9 @@ desc: Leaving the policy unset or setting it to Enabled allows users to search w
the policy to Disabled means users can't see the <ph name="GOOGLE_LENS_PRODUCT_NAME">Google
Lens</ph> button in the search box when <ph name="GOOGLE_LENS_PRODUCT_NAME">Google
Lens</ph> camera assisted 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: false
@@ -7,10 +7,6 @@ desc: |-
When this policy is not set, users can choose the anonymous reporting behavior at installation or first run, and can change this setting later.
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>.
(For <ph name="PRODUCT_OS_NAME">$2<ex>Google ChromeOS</ex></ph>, see <ph name="DEVICE_METRICS_REPORTING_ENABLED_POLICY_NAME">DeviceMetricsReportingEnabled</ph>.)
example_value: true
features:
@@ -11,6 +11,7 @@ features:
per_profile: true
future_on:
- fuchsia
- android
items:
- caption: Users can customize the New Tab page background
value: true
@@ -8,10 +8,6 @@ desc: |-
If this policy is set to false, the management notice will be hidden.
Note that this policy is only applied for managed browsers, so it will have no effect for managed users on unmanaged browsers.
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:
dynamic_refresh: true
@@ -71,7 +71,6 @@ future_on:
- fuchsia
owners:
- cbe-cep-eng@google.com
- drubery@chromium.org
- domfc@chromium.org
schema:
items:
@@ -155,6 +154,8 @@ schema:
type: object
type: object
type: array
future_on:
- android
supported_on:
- chrome.*:84-
- chrome_os:84-
@@ -16,6 +16,7 @@ owners:
schema:
type: string
supported_on:
- chrome_os:146-
- chrome.*:145-
tags: []
type: string
@@ -6,8 +6,6 @@ desc: |-
Setting the policy to Disabled means downloaded files won't be sent to be analyzed by Safe Browsing when it's from a trusted source.
These restrictions apply to downloads triggered from webpage content, as well as the Download link menu option. These restrictions don't apply to the save or download of the currently displayed page or to saving as PDF from the printing options.
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>.
example_value: false
features:
dynamic_refresh: true
@@ -14,6 +14,7 @@ features:
per_profile: true
future_on:
- fuchsia
- android
items:
- caption: Display the full URL
value: true
@@ -17,11 +17,6 @@ desc: |-
Users cannot create new site search entries with a shortcut previously created via this policy unless <ph name="ALLOW_USER_OVERRIDE_SITE_SEARCH_SETTINGS_FIELD">allow_user_override</ph> is set to true for the site search entry.
In case of a conflict with a shortcut previously created by the user, the user setting takes precedence. However, users can still trigger the option created by the policy by typing "@" in the search bar. For example, if the user already defined "work" as a shortcut to URL1 and the policy defines "work" as a shortcut to URL2, then typing "work" in the search bar will trigger a search to URL1, but typing "@work" in the search bar will trigger a search to URL2.
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:
- featured: true
name: Google Wikipedia
@@ -0,0 +1,31 @@
caption: Control the availability of the XSLT feature
default: null
desc: |-
This policy controls the availability of the XSLT feature (the XSLTProcessor Javascript API and the XSL processing instruction).
If this policy is set to Enabled, XSLT will be available, regardless of the default state of the feature in the browser.
If this policy is set to Disabled, XSLT will be unavailable, regardless of the default state of the feature in the browser.
If this policy is left unset, XSLT availability will be determined by the browser's default settings and field trials.
This policy is a temporary measure, and will be removed in M164.
example_value: true
features:
dynamic_refresh: true
per_profile: true
items:
- caption: 'Enabled: XSLT is explicitly enabled.'
value: true
- caption: 'Disabled: XSLT is explicitly disabled.'
value: false
- caption: 'Default: XSLT availability will be determined by browser defaults and field trials.'
value: null
owners:
- masonf@chromium.org
- dom-dev@google.com
schema:
type: boolean
supported_on:
- chrome.*:146-
- chrome_os:146-
- android:146-
- webview_android:146-
tags: []
type: main
@@ -1,6 +1,9 @@
caption: Allow user to configure their device hostname
default: false
deprecated: true
desc: |-
Deprecated: The host name setting feature was removed in M145. The Administrator can still control the hostname using the <ph name="DEVICE_HOSTNAME_TEMPLATE_POLICY_NAME">DeviceHostnameTemplate</ph> policy.
Determine whether a user is allowed to configure the device hostname.
If <ph name="DEVICE_HOSTNAME_TEMPLATE_POLICY_NAME">DeviceHostnameTemplate</ph> is set, the admininistrator sets hostname and the user cannot choose regardless of what this policy is set to.
@@ -23,7 +26,7 @@ owners:
schema:
type: boolean
supported_on:
- chrome_os:97-
- chrome_os:97-144
tags: []
type: main
generate_device_proto: False
@@ -2,7 +2,6 @@ caption: Enable adaptive charging model to hold charging process to extend batte
life
deprecated: true
default: true
default_for_enterprise_users: false
desc: |-
Specifies whether an adaptive charging model is allowed to hold charging process to extend battery life.
@@ -1,4 +1,4 @@
caption: Configure allowed local auth factors
caption: Configure allowed local authentication factors
desc: |-
Setting the policy controls which local authentication factors can be used for both login and reauthentication on <ph name="PRODUCT_OS_NAME">$2<ex>Google ChromeOS</ex></ph>.
@@ -15,6 +15,7 @@ features:
per_profile: true
future_on:
- fuchsia
- android
label: New Tab page URL
owners:
- chrome-desktop-ntp@google.com
@@ -7,10 +7,6 @@ desc: |-
Setting this policy to <ph name="POLICY_ENUM_RESTOREONSTARTUP_RESTOREONSTARTUPISLASTSESSION">RestoreOnStartupIsLastSession</ph> or <ph name="POLICY_ENUM_RESTOREONSTARTUP_RESTOREONSTARTUPISLASTSESSIONANDURLS">RestoreOnStartupIsLastSessionAndURLs</ph> turns off some settings that rely on sessions or that perform actions on exit, such as clearing browsing data on exit or session-only cookies.
If this policy is set to <ph name="POLICY_ENUM_RESTOREONSTARTUP_RESTOREONSTARTUPISLASTSESSIONANDURLS">RestoreOnStartupIsLastSessionAndURLs</ph>, browser will restore previous session and open a separate window to show URLs that are set from <ph name="RESTORE_ON_STARTUP_URLS_POLICY_NAME">RestoreOnStartupURLs</ph>. Note that users can choose to keep those URLs open and they will also be restored in the future session.
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: 4
features:
@@ -3,8 +3,6 @@ desc: |-
If <ph name="RESTORE_ON_STARTUP_POLICY_NAME">RestoreOnStartup</ph> is set to RestoreOnStartupIsURLs, then setting <ph name="RESTORE_ON_STARTUP_URLS_POLICY_NAME">RestoreOnStartupURLs</ph> to a list of URLs specify which URLs open.
If not set, the New Tab page opens on start up.
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>.
example_value:
- https://example.com
- https://www.chromium.org
@@ -0,0 +1,32 @@
caption: Enable WebRTC diagnostic log collection for specific origins
default: null
desc: |-
This policy allows enabling diagnostic log collection for WebRTC for specific origins.
For detailed information on valid input patterns, please see https://chromeenterprise.google/policies/url-patterns. <ph name="WILDCARD_VALUE">*</ph> is not an accepted value for this policy. This policy only matches based on origin, so any path in the URL pattern is ignored. Scheme and subdomains are supported.
If the policy is set, diagnostic log collection will be enabled for the origins matched by the patterns in the list.
If the policy is not set, diagnostic log collection will be disabled by default.
example_value:
- https://www.example.com
- example.com
- '[*.]example.com'
- '*://example.edu:*/'
- https://example.com:8080
features:
dynamic_refresh: true
per_profile: true
owners:
- file://third_party/blink/renderer/modules/peerconnection/OWNERS
- agpalak@chromium.org
- guidou@chromium.org
schema:
items:
type: string
type: array
future_on:
- chrome.*
- chrome_os
tags: []
type: list
@@ -3,4 +3,5 @@ WebRtc:
policies:
- WebRtcIPHandling
- WebRtcIPHandlingUrl
- WebRtcPostQuantumKeyAgreement
- WebRtcPostQuantumKeyAgreement
- WebRtcDiagnosticLogCollectionAllowedForOrigins
@@ -21,7 +21,6 @@
#include "base/base_switches.h"
#include "base/check_op.h"
#include "base/command_line.h"
#include "base/containers/contains.h"
#include "base/containers/flat_set.h"
#include "base/debug/crash_logging.h"
#include "base/feature_list.h"
@@ -73,7 +72,6 @@
#include "content/browser/browser_plugin/browser_plugin_embedder.h"
#include "content/browser/browser_plugin/browser_plugin_guest.h"
#include "content/browser/btm/btm_bounce_detector.h"
#include "content/browser/btm/btm_navigation_flow_detector.h"
#include "content/browser/child_process_security_policy_impl.h"
#include "content/browser/closewatcher/close_listener_manager.h"
#include "content/browser/compositor/surface_utils.h"
@@ -93,6 +91,7 @@
#include "content/browser/host_zoom_map_impl.h"
#include "content/browser/media/audio_stream_monitor.h"
#include "content/browser/media/media_web_contents_observer.h"
#include "content/browser/memory/scheduler_loop_quarantine_web_contents_observer.h"
#include "content/browser/permissions/permission_controller_impl.h"
#include "content/browser/permissions/permission_util.h"
#include "content/browser/preloading/prefetch/prefetch_request.h"
@@ -1052,7 +1051,7 @@ void WebContentsImpl::WebContentsTreeNode::DetachInnerWebContents(
bool WebContentsImpl::WebContentsTreeNode::IsUnownedInnerWebContents(
WebContents* inner_web_contents) const {
CHECK_EQ(inner_web_contents->GetOuterWebContents(), current_web_contents_);
return base::Contains(unowned_inner_web_contents_, inner_web_contents);
return std::ranges::contains(unowned_inner_web_contents_, inner_web_contents);
}
void WebContentsImpl::WebContentsTreeNode::DetachUnownedInnerWebContents(
@@ -3135,8 +3134,6 @@ void WebContentsImpl::SetPrimaryPageImportance(
base::android::ScopedServiceBindingBatch scoped_service_binding_batch;
if (base::FeatureList::IsEnabled(features::kSubframeImportance)) {
CHECK(
base::FeatureList::IsEnabled(features::kSubframePriorityContribution));
if (subframe_importance != primary_subframe_importance_) {
primary_subframe_importance_ = subframe_importance;
ApplyPrimaryPageSubframeImportance();
@@ -3796,9 +3793,6 @@ const blink::web_pref::WebPreferences WebContentsImpl::ComputeWebPreferences(
prefs.strict_mixed_content_checking =
command_line.HasSwitch(switches::kEnableStrictMixedContentChecking);
prefs.strict_powerful_feature_restrictions = command_line.HasSwitch(
switches::kEnableStrictPowerfulFeatureRestrictions);
const std::string blockable_mixed_content_group =
base::FieldTrialList::FindFullName("BlockableMixedContent");
prefs.strictly_block_blockable_mixed_content =
@@ -4086,16 +4080,6 @@ void WebContentsImpl::OnVibrate(RenderFrameHostImpl* rfh) {
observers_.NotifyObservers(&WebContentsObserver::VibrationRequested);
}
std::optional<network::ParsedPermissionsPolicy>
WebContentsImpl::GetPermissionsPolicyForIsolatedWebApp(
RenderFrameHostImpl* source) {
WebExposedIsolationInfo weii =
source->GetSiteInstance()->GetWebExposedIsolationInfo();
CHECK(weii.is_isolated_application());
return GetContentClient()->browser()->GetPermissionsPolicyForIsolatedWebApp(
this, weii.origin());
}
void WebContentsImpl::Stop() {
TRACE_EVENT0("content", "WebContentsImpl::Stop");
ForEachFrameTree([](FrameTree& frame_tree) { frame_tree.StopLoading(); });
@@ -4231,9 +4215,9 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params,
AttributionHost::CreateForWebContents(this);
}
SchedulerLoopQuarantineWebContentsObserver::MaybeCreateForWebContents(this);
RedirectChainDetector::CreateForWebContents(this);
BtmWebContentsObserver::MaybeCreateForWebContents(this);
BtmNavigationFlowDetector::CreateForWebContents(this);
RedirectHeuristicTabHelper::CreateForWebContents(this);
OpenerHeuristicTabHelper::CreateForWebContents(this);
@@ -4567,6 +4551,23 @@ bool WebContentsImpl::PreHandleGestureEvent(
const blink::WebGestureEvent& event) {
OPTIONAL_TRACE_EVENT0(TRACE_DISABLED_BY_DEFAULT("content.verbose"),
"WebContentsImpl::PreHandleGestureEvent");
if (ignore_zoom_gestures_) {
if (event.GetType() == blink::WebInputEvent::Type::kGestureDoubleTap) {
return true;
}
// Disable pinch zooming in app windows.
if (blink::WebInputEvent::IsPinchGestureEventType(event.GetType())) {
// Only suppress pinch events that cause a scale change. We still
// allow synthetic wheel events for touchpad pinch to go to the page.
return !(event.SourceDevice() == blink::WebGestureDevice::kTouchpad &&
event.NeedsWheelEvent());
}
}
// TODO(crbug.com/475836809)
// Remove this delegate method. It exposes Blink types to the embedder. Since
// zoom blocking is now handled natively, we should audit remaining consumers.
return delegate_ && delegate_->PreHandleGestureEvent(this, event);
}
@@ -4820,6 +4821,13 @@ void WebContentsImpl::Restore() {
}
GetDelegate()->RestoreFromWebAPI();
}
void WebContentsImpl::SetResizable(bool resizable) {
if (!GetDelegate()) {
return;
}
GetDelegate()->SetResizableFromWebAPI(resizable);
}
#endif // !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_IOS)
// TODO(laurila, crbug.com/1466855): Map into new `ui::DisplayState` enum
@@ -5521,8 +5529,7 @@ FrameTree* WebContentsImpl::CreateNewWindow(
? NavigationController::UA_OVERRIDE_TRUE
: NavigationController::UA_OVERRIDE_FALSE;
load_params->download_policy = params.download_policy;
load_params->initiator_activation_and_ad_status =
params.initiator_activation_and_ad_status;
load_params->started_by_ad = params.started_by_ad;
if (delegate_ && !is_guest &&
!delegate_->ShouldResumeRequestsForCreatedWindow()) {
@@ -6025,7 +6032,7 @@ std::string WebContentsImpl::DumpAccessibilityTree(
// This only runs during integration tests, or if a developer is
// using an inspection tool, e.g. chrome://accessibility.
ui::AXTreeManager::AlwaysFailFast();
DCHECK(base::Contains(AXInspectFactory::SupportedApis(), api_type));
DCHECK(std::ranges::contains(AXInspectFactory::SupportedApis(), api_type));
std::unique_ptr<ui::AXTreeFormatter> formatter =
AXInspectFactory::CreateFormatter(api_type);
@@ -6060,7 +6067,7 @@ void WebContentsImpl::RecordAccessibilityEvents(
ax_mgr->GetBrowserAccessibilityRoot()
->GetTargetForNativeAccessibilityEvent();
DCHECK(base::Contains(AXInspectFactory::SupportedApis(), api_type));
DCHECK(std::ranges::contains(AXInspectFactory::SupportedApis(), api_type));
event_recorder_ = content::AXInspectFactory::CreateRecorder(
api_type, ax_mgr, pid, ui::AXTreeSelector(widget));
event_recorder_->ListenToEvents(*callback);
@@ -6946,6 +6953,10 @@ void WebContentsImpl::SetPageScale(float scale_factor) {
scale_factor);
}
void WebContentsImpl::SetIgnoreZoomGestures(bool ignore) {
ignore_zoom_gestures_ = ignore;
}
gfx::Size WebContentsImpl::GetPreferredSize() {
return IsBeingCaptured() ? preferred_size_for_capture_ : preferred_size_;
}
@@ -11905,10 +11916,6 @@ void WebContentsImpl::CancelPreviewByMojoBinderPolicy(
}
}
void WebContentsImpl::OnWebApiWindowResizableChanged() {
delegate_->OnWebApiWindowResizableChanged();
}
FrameTreeNodeId WebContentsImpl::GetOuterDelegateFrameTreeNodeId() {
return node_.outer_contents_frame_tree_node_id();
}
@@ -219,6 +219,8 @@ void SetRuntimeFeaturesFromChromiumFeatures() {
raw_ref(features::kFedCmIdPRegistration), kDefault},
{wf::EnableFedCmLightweightMode,
raw_ref(features::kFedCmLightweightMode), kDefault},
{wf::EnableFedCmNavigationInterception,
raw_ref(features::kFedCmNavigationInterception), kDefault},
{wf::EnableFedCmErrorAttribute,
raw_ref(features::kFedCmErrorAttribute), kDefault},
{wf::EnableFedCmNonStringToken,
@@ -278,8 +280,6 @@ void SetRuntimeFeaturesFromChromiumFeatures() {
raw_ref(device::kWebAuthnAmbientSignin)},
{wf::EnableWebAuthenticationImmediateGet,
raw_ref(device::kWebAuthnImmediateGet), kSetOnlyIfOverridden},
{wf::EnableWebAuthenticationConditionalCreate,
raw_ref(device::kWebAuthnPasskeyUpgrade)},
{wf::EnableWebBluetooth, raw_ref(features::kWebBluetooth),
kSetOnlyIfOverridden},
{wf::EnableWebBluetoothGetDevices,
@@ -310,12 +310,13 @@ void SetRuntimeFeaturesFromChromiumFeatures() {
raw_ref(device::features::kWebXRIncubations)},
{wf::EnableWebXRLayers, raw_ref(device::features::kWebXRLayers)},
{wf::EnableWebXRPlaneDetection,
raw_ref(device::features::kWebXRIncubations)},
raw_ref(device::features::kWebXRPlaneDetection)},
{wf::EnableWebXRPoseMotionData,
raw_ref(device::features::kWebXRIncubations)},
{wf::EnableWebXRSpecParity,
raw_ref(device::features::kWebXRIncubations)},
#endif
{wf::EnableXSLT, raw_ref(blink::features::kXSLT)},
{wf::EnablePermissions, raw_ref(features::kWebPermissionsApi),
kSetOnlyIfOverridden},
};
@@ -531,8 +532,6 @@ void SetCustomizedRuntimeFeaturesFromCombinedArgs(
ui::NativeTheme::GetInstanceForWeb()->use_overlay_scrollbar());
#endif
WebRuntimeFeatures::EnableFluentScrollbars(ui::IsFluentScrollbarEnabled());
WebRuntimeFeatures::EnableFluentOverlayScrollbars(
ui::IsFluentOverlayScrollbarEnabled());
// TODO(rodneyding): This is a rare case for a stable feature
// Need to investigate more to determine whether to refactor it.
@@ -716,6 +715,12 @@ void SetRuntimeFeaturesDefaultsAndUpdateFromArgs(
WebRuntimeFeatures::EnableFeatureFromString(feature, false);
}
if (command_line.HasSwitch(blink::switches::kXSLTEnabledPolicy)) {
std::string value =
command_line.GetSwitchValueASCII(blink::switches::kXSLTEnabledPolicy);
WebRuntimeFeatures::EnableXSLT(value == "true");
}
ResolveInvalidConfigurations();
}
@@ -189,7 +189,7 @@ bool ContentBrowserClient::
BrowserContext* browser_context,
const GURL& site_instance_original_url) {
DCHECK(browser_context);
return true;
return false;
}
bool ContentBrowserClient::ShouldAllowProcessPerSiteForMultipleMainFrames(
@@ -227,10 +227,6 @@ bool ContentBrowserClient::ShouldLockProcessToSite(
return true;
}
bool ContentBrowserClient::ShouldEnforceNewCanCommitUrlChecks() {
return true;
}
bool ContentBrowserClient::DoesWebUIUrlRequireProcessLock(const GURL& url) {
return true;
}
@@ -323,11 +319,11 @@ size_t ContentBrowserClient::GetProcessCountToIgnoreForLimit() {
return 0;
}
std::optional<network::ParsedPermissionsPolicy>
std::optional<std::vector<blink::mojom::IsolatedAppPermissionPolicyEntryPtr>>
ContentBrowserClient::GetPermissionsPolicyForIsolatedWebApp(
WebContents* web_contents,
const url::Origin& app_origin) {
return network::ParsedPermissionsPolicy();
BrowserContext* browser_context,
const url::Origin& iwa_origin) {
return std::nullopt;
}
bool ContentBrowserClient::ShouldTryToUseExistingProcessHost(
@@ -1082,6 +1078,13 @@ bool ContentBrowserClient::ShouldRestrictCoreSharingOnRenderer() {
return false;
}
std::optional<std::wstring>
ContentBrowserClient::GetWindowsSecurityAttributeName() const {
// Embedders should override this method and return the name of the security
// attribute previously assigned to the browser's process token.
return std::nullopt;
}
#endif // BUILDFLAG(IS_WIN)
std::vector<std::unique_ptr<blink::URLLoaderThrottle>>
@@ -1223,8 +1226,8 @@ ContentBrowserClient::GetNetworkContextsParentDirectory() {
return {};
}
base::Value::Dict ContentBrowserClient::GetNetLogConstants() {
return base::Value::Dict();
base::DictValue ContentBrowserClient::GetNetLogConstants() {
return base::DictValue();
}
#if BUILDFLAG(IS_ANDROID)
@@ -1576,6 +1579,12 @@ void ContentBrowserClient::IsClipboardCopyAllowedByPolicy(
std::move(callback).Run(metadata.format_type, data, std::nullopt);
}
bool ContentBrowserClient::IsDragAllowedByPolicy(
const ClipboardEndpoint& source,
const DropData& drop_data) {
return true;
}
#if BUILDFLAG(ENABLE_VR)
XrIntegrationClient* ContentBrowserClient::GetXrIntegrationClient() {
return nullptr;
@@ -1599,11 +1608,11 @@ void ContentBrowserClient::GrantAdditionalRequestPrivilegesToWorkerProcess(
int child_id,
const GURL& script_url) {}
ContentBrowserClient::PrivateNetworkRequestPolicyOverride
ContentBrowserClient::ShouldOverridePrivateNetworkRequestPolicy(
ContentBrowserClient::LocalNetworkAccessRequestPolicyOverride
ContentBrowserClient::ShouldOverrideLocalNetworkAccessRequestPolicy(
BrowserContext* browser_context,
const url::Origin& origin) {
return PrivateNetworkRequestPolicyOverride::kDefault;
return LocalNetworkAccessRequestPolicyOverride::kDefault;
}
bool ContentBrowserClient::IsJitDisabledForSite(BrowserContext* browser_context,
@@ -1749,12 +1758,6 @@ bool ContentBrowserClient::AreIsolatedWebAppsEnabled(
return false;
}
bool ContentBrowserClient::IsThirdPartyStoragePartitioningAllowed(
content::BrowserContext*,
const url::Origin&) {
return true;
}
bool ContentBrowserClient::AreDeprecatedAutomaticBeaconCredentialsAllowed(
content::BrowserContext* browser_context,
const GURL& destination_url,
@@ -1965,13 +1968,14 @@ bool ContentBrowserClient::IsRendererProcessPriorityEnabled() {
return true;
}
std::unique_ptr<KeepAliveRequestTracker>
std::vector<std::unique_ptr<KeepAliveRequestTracker>>
ContentBrowserClient::MaybeCreateKeepAliveRequestTracker(
const network::ResourceRequest& request,
std::optional<ukm::SourceId> ukm_source_id,
content::BrowserContext* browser_context,
KeepAliveRequestTracker::IsContextDetachedCallback
is_context_detached_callback) {
return nullptr;
return {};
}
std::optional<std::vector<std::u16string>>
@@ -2017,4 +2021,16 @@ std::string ContentBrowserClient::GetDnsTxtResolverUrlPrefix() {
return std::string();
}
bool ContentBrowserClient::ShouldAllowPrefetchRedirection(
content::BrowserContext& browser_context,
const GURL& url,
const std::string& embedder_histogram_suffix) {
return true;
}
bool ContentBrowserClient::OriginSupportsConcreteCrossOriginIsolation(
const url::Origin& origin) {
return true;
}
} // namespace content
@@ -1,167 +0,0 @@
// Copyright 2014 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// This is the implementation layer of the chrome.automation API, and is
// essentially a translation of the internal accessibility tree update system
// into an extension API.
namespace automationInternal {
// Data for an accessibility event and/or an atomic change to an accessibility
// tree. See ui/accessibility/ax_tree_update.h for an extended explanation of
// the tree update format.
[nocompile] dictionary AXEventParams {
// The tree id of the web contents that this update is for.
DOMString treeID;
// ID of the node that the event applies to.
long targetID;
// The type of event that this update represents.
DOMString eventType;
// The source of this event.
DOMString eventFrom;
// The mouse coordinates when this event fired.
double mouseX;
double mouseY;
// ID of an action request resulting in this event.
long actionRequestID;
};
dictionary AXTextLocationParams {
DOMString treeID;
long nodeID;
boolean result;
long left;
long top;
long width;
long height;
long requestID;
};
// Arguments required for all actions supplied to performAction.
dictionary PerformActionRequiredParams {
DOMString treeID;
long automationNodeID;
// This can be either automation::ActionType or
// automation_internal::ActionTypePrivate.
DOMString actionType;
long? requestID;
};
// Arguments for the customAction action. Those args are passed to
// performAction as opt_args.
dictionary PerformCustomActionParams {
long customActionID;
};
// Arguments for the setSelection action supplied to performAction.
dictionary SetSelectionParams {
// Reuses ActionRequiredParams automationNodeID to mean anchor node id,
// and treeID to apply to both anchor and focus node ids.
long focusNodeID;
long anchorOffset;
long focusOffset;
};
// Arguments for the replaceSelectedText action supplied to performAction.
dictionary ReplaceSelectedTextParams {
DOMString value;
};
// Arguments for the setValue action supplied to performAction.
dictionary SetValueParams {
DOMString value;
};
// Arguments for the scrollToPoint action supplied to performAction.
dictionary ScrollToPointParams {
long x;
long y;
};
// Arguments for the scrollToPositionAtRowColumn action supplied to performAction.
dictionary ScrollToPositionAtRowColumnParams {
long row;
long column;
};
// Arguments for the SetScrollOffset action supplied to performAction.
dictionary SetScrollOffsetParams {
long x;
long y;
};
// Arguments for the getImageData action.
dictionary GetImageDataParams {
long maxWidth;
long maxHeight;
};
// Arguments for the hitTest action.
dictionary HitTestParams {
long x;
long y;
DOMString eventToFire;
};
// Arguments for getTextLocation action.
dictionary GetTextLocationDataParams {
long startIndex;
long endIndex;
};
// Callback called when enableDesktop() returns. Returns the accessibility
// tree id of the desktop tree.
callback EnableDesktopCallback = void(DOMString tree_id);
// Callback called when disableDesktop() returns. It is safe to clear
// accessibility api state at that point.
callback DisableDesktopCallback = void();
interface Functions {
// Enable automation of the tree with the given id.
static void enableTree(DOMString tree_id);
// Enables desktop automation.
static void enableDesktop(
EnableDesktopCallback callback);
// Disables desktop automation.
static void disableDesktop(DisableDesktopCallback callback);
// Performs an action on an automation node.
static void performAction(PerformActionRequiredParams args,
object opt_args);
};
interface Events {
// Fired when an accessibility event occurs
static void onAccessibilityEvent(AXEventParams update);
static void onAccessibilityTreeDestroyed(DOMString treeID);
static void onGetTextLocationResult(AXTextLocationParams params);
static void onTreeChange(long observerID,
DOMString treeID,
long nodeID,
DOMString changeType);
static void onChildTreeID(DOMString treeID);
static void onNodesRemoved(DOMString treeID, long[] nodeIDs);
static void onAccessibilityTreeSerializationError(DOMString treeID);
static void onActionResult(DOMString treeID, long requestID, boolean result);
static void onAllAutomationEventListenersRemoved();
};
};

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