Revert "Only store leading 13 bits of password hash."
[chromium-blink-merge.git] / chrome / common / chrome_switches.cc
blob220bf60ecf2d0006e19e03949cd32a54cac33f0b
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #include "chrome/common/chrome_switches.h"
7 #include "base/base_switches.h"
8 #include "base/command_line.h"
10 namespace switches {
12 // -----------------------------------------------------------------------------
13 // Can't find the switch you are looking for? Try looking in:
14 // ash/ash_switches.cc
15 // base/base_switches.cc
16 // chromeos/chromeos_switches.cc
17 // etc.
19 // When commenting your switch, please use the same voice as surrounding
20 // comments. Imagine "This switch..." at the beginning of the phrase, and it'll
21 // all work out.
22 // -----------------------------------------------------------------------------
24 // If set, Chrome will activate any existing browsers for a specific profile.
25 // Used for example by the fast-user switcher in the Windows JumpList.
26 const char kActivateExistingProfileBrowser[] =
27 "activate-existing-profile-browser";
29 // Allows third-party content included on a page to prompt for a HTTP basic
30 // auth username/password pair.
31 const char kAllowCrossOriginAuthPrompt[] = "allow-cross-origin-auth-prompt";
33 // On ChromeOS, file:// access is disabled except for certain whitelisted
34 // directories. This switch re-enables file:// for testing.
35 const char kAllowFileAccess[] = "allow-file-access";
37 // Allow non-secure origins to use the screen capture API and the desktopCapture
38 // extension API.
39 const char kAllowHttpScreenCapture[] = "allow-http-screen-capture";
41 #if defined(ENABLE_PLUGINS)
42 // Specifies comma-separated list of extension ids or hosts to grant
43 // access to CRX file system APIs.
44 const char kAllowNaClCrxFsAPI[] = "allow-nacl-crxfs-api";
46 // Specifies comma-separated list of extension ids or hosts to grant
47 // access to file handle APIs.
48 const char kAllowNaClFileHandleAPI[] = "allow-nacl-file-handle-api";
50 // Specifies comma-separated list of extension ids or hosts to grant
51 // access to TCP/UDP socket APIs.
52 const char kAllowNaClSocketAPI[] = "allow-nacl-socket-api";
53 #endif
55 // Don't block outdated plugins.
56 const char kAllowOutdatedPlugins[] = "allow-outdated-plugins";
58 // By default, an https page cannot run JavaScript, CSS or plug-ins from http
59 // URLs. This provides an override to get the old insecure behavior.
60 const char kAllowRunningInsecureContent[] = "allow-running-insecure-content";
62 // Specifies the threshold to be used when determining of an Alternate-Protocol
63 // advertisement will be honored. If the advertised probability is larger
64 // than the threshold, then it will be honored.
65 const char kAlternateProtocolProbabilityThreshold[] =
66 "alternate-protocol-probability-threshold";
68 // Prevents Chrome from requiring authorization to run certain widely installed
69 // but less commonly used plug-ins.
70 const char kAlwaysAuthorizePlugins[] = "always-authorize-plugins";
72 // Specifies that the extension-app with the specified id should be launched
73 // according to its configuration.
74 const char kAppId[] = "app-id";
76 // Specifies that the associated value should be launched in "application"
77 // mode.
78 const char kApp[] = "app";
80 // Overrides the apps checkout URL, which is used to determine when to expose
81 // some private APIs.
82 const char kAppsCheckoutURL[] = "apps-checkout-url";
84 // The URL that the webstore APIs download extensions from.
85 // Note: the URL must contain one '%s' for the extension ID.
86 const char kAppsGalleryDownloadURL[] = "apps-gallery-download-url";
88 // The URL to use for the gallery link in the app launcher.
89 const char kAppsGalleryURL[] = "apps-gallery-url";
91 // The update url used by gallery/webstore extensions.
92 const char kAppsGalleryUpdateURL[] = "apps-gallery-update-url";
94 // Value of GAIA auth code for --force-app-mode.
95 const char kAppModeAuthCode[] = "app-mode-auth-code";
97 // Value of OAuth2 refresh token for --force-app-mode.
98 const char kAppModeOAuth2Token[] = "app-mode-oauth-token";
100 // Enables overriding the path for the default authentication extension.
101 const char kAuthExtensionPath[] = "auth-ext-path";
103 // A flag that is used to tell Chrome that it was launched automatically at
104 // computer startup and not by some user action.
105 const char kAutoLaunchAtStartup[] = "auto-launch-at-startup";
107 // This flag makes Chrome auto-select the provided choice when an extension asks
108 // permission to start desktop capture. Should only be used for tests. For
109 // instance, --auto-select-desktop-capture-source="Entire screen" will
110 // automatically select to share the entire screen in English locales.
111 const char kAutoSelectDesktopCaptureSource[] =
112 "auto-select-desktop-capture-source";
114 // Certificate Transparency: Uses the provided log(s) for checking Signed
115 // Certificate Timestamps provided with certificates.
116 // The switch's value is:
117 // log_description:log_key,log_description:log_key,...
118 // where
119 // log_description is a textual description of the log.
120 // log_key is a Base64'd DER-encoded SubjectPublicKeyInfo of the log's
121 // public key.
122 // Multiple logs can be specified by repeating description:key pairs,
123 // separated by a comma.
124 const char kCertificateTransparencyLog[] =
125 "certificate-transparency-log";
127 // How often (in seconds) to check for updates. Should only be used for testing
128 // purposes.
129 const char kCheckForUpdateIntervalSec[] = "check-for-update-interval";
131 // Checks the cloud print connector policy, informing the service process if
132 // the policy is set to disallow the connector, then quits.
133 const char kCheckCloudPrintConnectorPolicy[] =
134 "check-cloud-print-connector-policy";
136 // Comma-separated list of SSL cipher suites to disable.
137 const char kCipherSuiteBlacklist[] = "cipher-suite-blacklist";
139 // Tells chrome to display the cloud print dialog and upload the specified file
140 // for printing.
141 const char kCloudPrintFile[] = "cloud-print-file";
143 // Specifies the mime type to be used when uploading data from the file
144 // referenced by cloud-print-file. Defaults to "application/pdf" if
145 // unspecified.
146 const char kCloudPrintFileType[] = "cloud-print-file-type";
148 // Used with kCloudPrintFile to specify a JSON print ticket for the resulting
149 // print job. Defaults to null if unspecified.
150 const char kCloudPrintPrintTicket[] = "cloud-print-print-ticket";
152 // Used with kCloudPrintFile to specify a title for the resulting print job.
153 const char kCloudPrintJobTitle[] = "cloud-print-job-title";
155 // Setup cloud print proxy for provided printers. This does not start
156 // service or register proxy for autostart.
157 const char kCloudPrintSetupProxy[] = "cloud-print-setup-proxy";
159 // Comma-separated list of BrowserThreads that cause browser process to crash
160 // if the given browser thread is not responsive. UI,IO,DB,FILE,CACHE are the
161 // list of BrowserThreads that are supported.
163 // For example:
164 // --crash-on-hang-threads=UI:3:18,IO:3:18 --> Crash the browser if UI or IO
165 // is not responsive for 18 seconds and the number of browser threads that
166 // are responding is less than or equal to 3.
167 const char kCrashOnHangThreads[] = "crash-on-hang-threads";
169 // Some platforms like ChromeOS default to empty desktop.
170 // Browser tests may need to add this switch so that at least one browser
171 // instance is created on startup.
172 // TODO(nkostylev): Investigate if this switch could be removed.
173 // (http://crbug.com/148675)
174 const char kCreateBrowserOnStartupForTests[] =
175 "create-browser-on-startup-for-tests";
177 // Enables a frame context menu item that toggles the frame in and out of glass
178 // mode (Windows Vista and up only).
179 const char kDebugEnableFrameToggle[] = "debug-enable-frame-toggle";
181 // Adds debugging entries such as Inspect Element to context menus of packed
182 // apps.
183 const char kDebugPackedApps[] = "debug-packed-apps";
185 // Triggers a plethora of diagnostic modes.
186 const char kDiagnostics[] = "diagnostics";
188 // Sets the output format for diagnostic modes enabled by diagnostics flag.
189 const char kDiagnosticsFormat[] = "diagnostics-format";
191 // Tells the diagnostics mode to do the requested recovery step(s).
192 const char kDiagnosticsRecovery[] = "diagnostics-recovery";
194 // When kEnableSettingsWindow is used, About is shown as an overlay in Settings
195 // instead of as a separate page, unless this flag is specified.
196 const char kDisableAboutInSettings[] = "disable-about-in-settings";
198 // Disables the experimental asynchronous DNS client.
199 const char kDisableAsyncDns[] = "disable-async-dns";
201 // Disable several subsystems which run network requests in the background.
202 // This is for use when doing network performance testing to avoid noise in the
203 // measurements.
204 const char kDisableBackgroundNetworking[] = "disable-background-networking";
206 // Disables the bundled PPAPI version of Flash.
207 const char kDisableBundledPpapiFlash[] = "disable-bundled-ppapi-flash";
209 // Disable hardware encoding support for Cast Streaming.
210 const char kDisableCastStreamingHWEncoding[] =
211 "disable-cast-streaming-hw-encoding";
213 // Disables the client-side phishing detection feature. Note that even if
214 // client-side phishing detection is enabled, it will only be active if the
215 // user has opted in to UMA stats and SafeBrowsing is enabled in the
216 // preferences.
217 const char kDisableClientSidePhishingDetection[] =
218 "disable-client-side-phishing-detection";
220 // Disable default component extensions with background pages - useful for
221 // performance tests where these pages may interfere with perf results.
222 const char kDisableComponentExtensionsWithBackgroundPages[] =
223 "disable-component-extensions-with-background-pages";
225 const char kDisableComponentUpdate[] = "disable-component-update";
227 // Disables installation of default apps on first run. This is used during
228 // automated testing.
229 const char kDisableDefaultApps[] = "disable-default-apps";
231 // Disables device discovery notifications.
232 const char kDisableDeviceDiscoveryNotifications[] =
233 "disable-device-discovery-notifications";
235 // Disables Domain Reliability Monitoring.
236 const char kDisableDomainReliability[] = "disable-domain-reliability";
238 // Disable extensions.
239 const char kDisableExtensions[] = "disable-extensions";
241 // Disable checking for user opt-in for extensions that want to inject script
242 // into file URLs (ie, always allow it). This is used during automated testing.
243 const char kDisableExtensionsFileAccessCheck[] =
244 "disable-extensions-file-access-check";
246 // Disable the net::URLRequestThrottlerManager functionality for
247 // requests originating from extensions.
248 const char kDisableExtensionsHttpThrottling[] =
249 "disable-extensions-http-throttling";
251 // Don't resolve hostnames to IPv6 addresses. This can be used when debugging
252 // issues relating to IPv6, but shouldn't otherwise be needed. Be sure to file
253 // bugs if something isn't working properly in the presence of IPv6. This flag
254 // can be overidden by the "enable-ipv6" flag.
255 const char kDisableIPv6[] = "disable-ipv6";
257 // Disable the behavior that the second click on a launcher item (the click when
258 // the item is already active) minimizes the item.
259 const char kDisableMinimizeOnSecondLauncherItemClick[] =
260 "disable-minimize-on-second-launcher-item-click";
262 // Disables the new offline error page generated by NetErrorHelper for ChromeOS
263 // and instead uses the old error page generated by OfflineResourceThrottle.
264 const char kDisableNewOfflineErrorPage[] = "disable-new-offline-error-page";
266 // Disables the menu on the NTP for accessing sessions from other devices.
267 const char kDisableNTPOtherSessionsMenu[] = "disable-ntp-other-sessions-menu";
269 // Disable auto-reload of error pages if offline.
270 const char kDisableOfflineAutoReload[] = "disable-offline-auto-reload";
272 // Disable only auto-reloading error pages when the tab is visible.
273 const char kDisableOfflineAutoReloadVisibleOnly[] =
274 "disable-offline-auto-reload-visible-only";
276 // Disable the origin chip.
277 const char kDisableOriginChip[] = "disable-origin-chip";
279 // Disable the out of process PDF plugin.
280 const char kDisableOutOfProcessPdf[] = "disable-out-of-process-pdf";
282 // Disable the setting to prompt the user for their OS account password before
283 // revealing plaintext passwords in the password manager.
284 const char kDisablePasswordManagerReauthentication[] =
285 "disable-password-manager-reauthentication";
287 // Disable the new material UI - requires out of process PDF plugin.
288 const char kDisablePdfMaterialUI[] = "disable-pdf-material-ui";
290 // Don't use bubbles for content permissions requests instead of infobars.
291 const char kDisablePermissionsBubbles[] = "disable-permissions-bubbles";
293 // Disable pop-up blocking.
294 const char kDisablePopupBlocking[] = "disable-popup-blocking";
296 // Disable speculative TCP/IP preconnection.
297 const char kDisablePreconnect[] = "disable-preconnect";
299 // Disable prerendering based on local browsing history.
300 const char kDisablePrerenderLocalPredictor[] =
301 "disable-prerender-local-predictor";
303 // Disables print preview (For testing, and for users who don't like us. :[ )
304 const char kDisablePrintPreview[] = "disable-print-preview";
306 // Normally when the user attempts to navigate to a page that was the result of
307 // a post we prompt to make sure they want to. This switch may be used to
308 // disable that check. This switch is used during automated testing.
309 const char kDisablePromptOnRepost[] = "disable-prompt-on-repost";
311 // Disables support for the QUIC protocol.
312 const char kDisableQuic[] = "disable-quic";
314 // Disable use of pacing of QUIC packets.
315 // This only has an effect if QUIC protocol is enabled.
316 const char kDisableQuicPacing[] = "disable-quic-pacing";
318 // Disable use of Chromium's port selection for the ephemeral port via bind().
319 // This only has an effect if QUIC protocol is enabled.
320 const char kDisableQuicPortSelection[] = "disable-quic-port-selection";
322 // Prevents the save password bubble from being enabled.
323 const char kDisableSavePasswordBubble[] = "disable-save-password-bubble";
325 // Disables the "search button in omnibox" experiment.
326 const char kDisableSearchButtonInOmnibox[] =
327 "disable-search-button-in-omnibox";
329 // Disables using bubbles for session restore request.
330 const char kDisableSessionCrashedBubble[] = "disable-session-crashed-bubble";
332 // Disables the suggestions service.
333 const char kDisableSuggestionsService[] = "disable-suggestions-service";
335 // Disables the supervised user host blacklist.
336 const char kDisableSupervisedUserBlacklist[] =
337 "disable-supervised-user-blacklist";
339 // Disables SafeSites filtering for supervised users.
340 const char kDisableSupervisedUserSafeSites[] =
341 "disable-supervised-user-safesites";
343 // Disables syncing browser data to a Google Account.
344 const char kDisableSync[] = "disable-sync";
346 // Disables syncing one or more sync data types that are on by default.
347 // See sync/internal_api/public/base/model_type.h for possible types. Types
348 // should be comma separated, and follow the naming convention for string
349 // representation of model types, e.g.:
350 // --disable-synctypes='Typed URLs, Bookmarks, Autofill Profiles'
351 const char kDisableSyncTypes[] = "disable-sync-types";
353 // Disables the backend service for web resources.
354 const char kDisableWebResources[] = "disable-web-resources";
356 // Some tests seem to require the application to close when the last
357 // browser window is closed. Thus, we need a switch to force this behavior
358 // for ChromeOS Aura, disable "zero window mode".
359 // TODO(pkotwicz): Investigate if this bug can be removed.
360 // (http://crbug.com/119175)
361 const char kDisableZeroBrowsersOpenForTests[] =
362 "disable-zero-browsers-open-for-tests";
364 // Use a specific disk cache location, rather than one derived from the
365 // UserDatadir.
366 const char kDiskCacheDir[] = "disk-cache-dir";
368 // Forces the maximum disk space to be used by the disk cache, in bytes.
369 const char kDiskCacheSize[] = "disk-cache-size";
371 const char kDnsLogDetails[] = "dns-log-details";
373 // Disables prefetching of DNS information.
374 const char kDnsPrefetchDisable[] = "dns-prefetch-disable";
376 // Requests that a running browser process dump its collected histograms to a
377 // given file. The file is overwritten if it exists.
378 const char kDumpBrowserHistograms[] = "dump-browser-histograms";
380 // Overrides the path of Easy Unlock component app.
381 const char kEasyUnlockAppPath[] = "easy-unlock-app-path";
383 // If set, the app list will be enabled as if enabled from CWS.
384 const char kEnableAppList[] = "enable-app-list";
386 // Enable OS integration for Chrome app file associations.
387 const char kEnableAppsFileAssociations[] = "enable-apps-file-associations";
389 // Enables the experimental asynchronous DNS client.
390 const char kEnableAsyncDns[] = "enable-async-dns";
392 // Enables the benchmarking extensions.
393 const char kEnableBenchmarking[] = "enable-benchmarking";
395 // Enables client hints, which adds hints about browser state to HTTP requests.
396 const char kEnableClientHints[] = "enable-client-hints";
398 // Enables the multi-level undo system for bookmarks.
399 const char kEnableBookmarkUndo[] = "enable-bookmark-undo";
401 // This applies only when the process type is "service". Enables the Cloud
402 // Print Proxy component within the service process.
403 const char kEnableCloudPrintProxy[] = "enable-cloud-print-proxy";
405 // If true devtools experimental settings are enabled.
406 const char kEnableDevToolsExperiments[] = "enable-devtools-experiments";
408 // Enable device discovery notifications.
409 const char kEnableDeviceDiscoveryNotifications[] =
410 "enable-device-discovery-notifications";
412 // Enables the DOM distiller.
413 const char kEnableDomDistiller[] = "enable-dom-distiller";
415 // Enables Domain Reliability Monitoring.
416 const char kEnableDomainReliability[] = "enable-domain-reliability";
418 // Enable Enhanced Bookmarks.
419 const char kEnhancedBookmarksExperiment[] = "enhanced-bookmarks-experiment";
421 // Enables experimentation with ephemeral apps to be launched from the webstore.
422 const char kEnableEphemeralAppsInWebstore[] =
423 "enable-ephemeral-apps-in-webstore";
425 // Disables v2 hotword detection features. These features include
426 // using a new component extension for performing hotword detection, new UI
427 // flows, and always-on detection.
428 const char kDisableExperimentalHotwording[] = "disable-experimental-hotwording";
430 // Enables experimental hotword features specific to always-on.
431 const char kEnableExperimentalHotwordHardware[] = "enable-hotword-hardware";
433 // Enables logging for extension activity.
434 const char kEnableExtensionActivityLogging[] =
435 "enable-extension-activity-logging";
437 const char kEnableExtensionActivityLogTesting[] =
438 "enable-extension-activity-log-testing";
440 // Enable the fast unload controller, which speeds up tab/window close by
441 // running a tab's onunload js handler independently of the GUI -
442 // crbug.com/142458 .
443 const char kEnableFastUnload[] = "enable-fast-unload";
445 // Enables IPv6 support, even if probes suggest that it may not be fully
446 // supported. Some probes may require internet connections, and this flag will
447 // allow support independent of application testing. This flag overrides
448 // "disable-ipv6" which appears elswhere in this file.
449 const char kEnableIPv6[] = "enable-ipv6";
451 // Enables experimentation with launching ephemeral apps via hyperlinks.
452 const char kEnableLinkableEphemeralApps[] = "enable-linkable-ephemeral-apps";
454 // Runs the Native Client inside the renderer process and enables GPU plugin
455 // (internally adds lEnableGpuPlugin to the command line).
456 const char kEnableNaCl[] = "enable-nacl";
458 // Enables the network-related benchmarking extensions.
459 const char kEnableNetBenchmarking[] = "enable-net-benchmarking";
461 // Enables the new bookmark app system.
462 const char kEnableNewBookmarkApps[] = "enable-new-bookmark-apps";
464 // Enables NPN with HTTP. It means NPN is enabled but SPDY won't be used.
465 // HTTP is still used for all requests.
466 const char kEnableNpnHttpOnly[] = "enable-npn-http";
468 // Enable auto-reload of error pages if offline.
469 const char kEnableOfflineAutoReload[] = "enable-offline-auto-reload";
471 // Only auto-reload error pages when the tab is visible.
472 const char kEnableOfflineAutoReloadVisibleOnly[] =
473 "enable-offline-auto-reload-visible-only";
475 // Enable/Disable offering a "Load stale copy" option to the user if offline.
476 const char kEnableOfflineLoadStaleCache[] = "enable-offline-load-stale-cache";
477 const char kDisableOfflineLoadStaleCache[] =
478 "disable-offline-load-stale-cache";
480 // Controls which branch of the origin chip in location bar experiment is
481 // enabled.
483 // We're using independent flags here (as opposed to a common flag with
484 // different values) to be able to enable/disable the entire experience
485 // associated with this feature server-side from the FieldTrial (the complete
486 // experience includes other flag changes as well). It is not currently possible
487 // to do that with "flag=value" flags.
488 const char kEnableOriginChipAlways[] = "enable-origin-chip-always";
489 const char kEnableOriginChipOnSrp[] = "enable-origin-chip-on-srp";
491 // Enable the out of process PDF plugin.
492 const char kEnableOutOfProcessPdf[] = "enable-out-of-process-pdf";
494 // Enables panels (always on-top docked pop-up windows).
495 const char kEnablePanels[] = "enable-panels";
497 // Enable the new material UI - requires out of process PDF plugin.
498 const char kEnablePdfMaterialUI[] = "enable-pdf-material-ui";
500 // Enables presenting plugin placeholder content as shadow DOM.
501 const char kEnablePluginPlaceholderShadowDom[] =
502 "enable-plugin-placeholder-shadow-dom";
504 // Enables a number of potentially annoying security features (strict mixed
505 // content mode, powerful feature restrictions, etc.)
506 const char kEnablePotentiallyAnnoyingSecurityFeatures[] =
507 "enable-potentially-annoying-security-features";
509 // Enables the Power overlay in Settings.
510 const char kEnablePowerOverlay[] = "enable-power-overlay";
512 // Enables showing unregistered printers in print preview
513 const char kEnablePrintPreviewRegisterPromos[] =
514 "enable-print-preview-register-promos";
516 // Enable Privet storage.
517 const char kEnablePrivetStorage[] = "enable-privet-storage";
519 // Enables tracking of tasks in profiler for viewing via about:profiler.
520 // To predominantly disable tracking (profiling), use the command line switch:
521 // --enable-profiling=0
522 // Some tracking will still take place at startup, but it will be turned off
523 // during chrome_browser_main.
524 const char kEnableProfiling[] = "enable-profiling";
526 // Enables query in the omnibox.
527 const char kEnableQueryExtraction[] = "enable-query-extraction";
529 // Enables support for the QUIC protocol. This is a temporary testing flag.
530 const char kEnableQuic[] = "enable-quic";
532 // Disable use of pacing of QUIC packets.
533 // This only has an effect if QUIC protocol is enabled.
534 const char kEnableQuicPacing[] = "enable-quic-pacing";
536 // Enable use of Chromium's port selection for the ephemeral port via bind().
537 // This only has an effect if QUIC protocol is enabled.
538 const char kEnableQuicPortSelection[] = "enable-quic-port-selection";
540 // Enables context-sensitive reader mode button in the toolbar.
541 const char kEnableReaderModeToolbarIcon[] =
542 "enable-reader-mode-toolbar-icon";
544 // Enables save password prompt bubble.
545 const char kEnableSavePasswordBubble[] = "enable-save-password-bubble";
547 // Enables SDCH for https schemes.
548 const char kEnableSdchOverHttps[] = "enable-sdch-over-https";
550 // Controls which branch of the "search button in omnibox" experiment is
551 // enabled.
553 // We're using independent flags here (as opposed to a common flag with
554 // different values) to be able to enable/disable the entire experience
555 // associated with this feature server-side from the FieldTrial (the complete
556 // experience includes other flag changes as well). It is not currently possible
557 // to do that with "flag=value" flags.
558 const char kEnableSearchButtonInOmniboxAlways[] =
559 "enable-search-button-in-omnibox-always";
560 const char kEnableSearchButtonInOmniboxForStr[] =
561 "enable-search-button-in-omnibox-for-str";
562 const char kEnableSearchButtonInOmniboxForStrOrIip[] =
563 "enable-search-button-in-omnibox-for-str-or-iip";
565 // Enables using bubbles for session restore request instead of infobars.
566 const char kEnableSessionCrashedBubble[] = "enable-session-crashed-bubble";
568 // Enables the deprecated window.showModalDialog API. This is slated for
569 // removal.
570 const char kEnableShowModalDialog[] = "enable-show-modal-dialog";
572 // Enable or disable settings in a separate browser window per profile
573 // (see SettingsWindowEnabled() below).
574 const char kEnableSettingsWindow[] = "enable-settings-window";
575 const char kDisableSettingsWindow[] = "disable-settings-window";
577 // Enable SPDY/4, aka HTTP/2. This is a temporary testing flag.
578 const char kEnableSpdy4[] = "enable-spdy4";
580 // Enables a feature that holds back some SSLConnectJobs in order to
581 // minimize the number of full SSL handshakes completed.
582 const char kEnableSSLConnectJobWaiting[] = "enable-ssl-connect-job-waiting";
584 // Enables implementation of the Cache-Control: stale-while-revalidate directive
585 // which permits servers to allow the use of stale resources while revalidation
586 // proceeds in the background.
587 const char kEnableStaleWhileRevalidate[] = "enable-stale-while-revalidate";
589 // Enables the suggestions service.
590 const char kEnableSuggestionsService[] = "enable-suggestions-service";
592 // Enables the supervised user host blacklist.
593 const char kEnableSupervisedUserBlacklist[] =
594 "enable-supervised-user-blacklist";
596 // Enables SafeSites filtering for supervised users.
597 const char kEnableSupervisedUserSafeSites[] =
598 "enable-supervised-user-safesites";
600 // Enables synced articles.
601 const char kEnableSyncArticles[] = "enable-sync-articles";
603 // Enables user control over muting tab audio from the tab strip.
604 const char kEnableTabAudioMuting[] = "enable-tab-audio-muting";
606 // Enables fanciful thumbnail processing. Used with NTP for
607 // instant-extended-api, where thumbnails are generally smaller.
608 const char kEnableThumbnailRetargeting[] = "enable-thumbnail-retargeting";
610 // Enables Translate experimental new UX which replaces the infobar.
611 const char kEnableTranslateNewUX[] = "enable-translate-new-ux";
613 // Enables Alternate-Protocol when the port is user controlled (> 1024).
614 const char kEnableUserAlternateProtocolPorts[] =
615 "enable-user-controlled-alternate-protocol-ports";
617 // Enables a new "web app" style frame for hosted apps (including bookmark
618 // apps).
619 extern const char kEnableWebAppFrame[] = "enable-web-app-frame";
621 // Enables the Website Settings page on the Settings page.
622 const char kEnableWebsiteSettingsManager[] = "enable-website-settings-manager";
624 // Enables synchronizing WiFi credentials across devices, using Chrome Sync.
625 const char kEnableWifiCredentialSync[] = "enable-wifi-credential-sync";
627 // Explicitly allows additional ports using a comma-separated list of port
628 // numbers.
629 const char kExplicitlyAllowedPorts[] = "explicitly-allowed-ports";
631 // Values for the kExtensionContentVerification flag.
632 // See ContentVerifierDelegate::Mode for more explanation.
633 const char kExtensionContentVerificationBootstrap[] = "bootstrap";
634 const char kExtensionContentVerificationEnforceStrict[] = "enforce_strict";
635 const char kExtensionContentVerificationEnforce[] = "enforce";
637 // Name of the command line flag to force content verification to be on in one
638 // of various modes.
639 const char kExtensionContentVerification[] = "extension-content-verification";
641 // Turns on extension install verification if it would not otherwise have been
642 // turned on.
643 const char kExtensionsInstallVerification[] = "extensions-install-verification";
645 // Specifies a comma-separated list of extension ids that should be forced to
646 // be treated as not from the webstore when doing install verification.
647 const char kExtensionsNotWebstore[] = "extensions-not-webstore";
649 // Frequency in seconds for Extensions auto-update.
650 const char kExtensionsUpdateFrequency[] = "extensions-update-frequency";
652 // Fakes the channel of the browser for purposes of Variations filtering. This
653 // is to be used for testing only. Possible values are "stable", "beta", "dev"
654 // and "canary". Note that this only applies if the browser's reported channel
655 // is UNKNOWN.
656 const char kFakeVariationsChannel[] = "fake-variations-channel";
658 // If this flag is present then this command line is being delegated to an
659 // already running chrome process via the fast path, ie: before chrome.dll is
660 // loaded. It is useful to tell the difference for tracking purposes.
661 const char kFastStart[] = "fast-start";
663 // These two flags are added around the switches about:flags adds to the
664 // command line. This is useful to see which switches were added by about:flags
665 // on about:version. They don't have any effect.
666 const char kFlagSwitchesBegin[] = "flag-switches-begin";
667 const char kFlagSwitchesEnd[] = "flag-switches-end";
669 // Forces application mode. This hides certain system UI elements and forces
670 // the app to be installed if it hasn't been already.
671 const char kForceAppMode[] = "force-app-mode";
673 // Displays the First Run experience when the browser is started, regardless of
674 // whether or not it's actually the First Run (this overrides kNoFirstRun).
675 const char kForceFirstRun[] = "force-first-run";
677 // Forces additional Chrome Variation Ids that will be sent in X-Client-Data
678 // header, specified as a 64-bit encoded list of numeric experiment ids. Ids
679 // prefixed with the character "t" will be treated as Trigger Variation Ids.
680 const char kForceVariationIds[] = "force-variation-ids";
682 // These flags show the man page on Linux. They are equivalent to each
683 // other.
684 const char kHelp[] = "help";
685 const char kHelpShort[] = "h";
687 // Makes Windows happy by allowing it to show "Enable access to this program"
688 // checkbox in Add/Remove Programs->Set Program Access and Defaults. This only
689 // shows an error box because the only way to hide Chrome is by uninstalling
690 // it.
691 const char kHideIcons[] = "hide-icons";
693 // Enables grouping websites by domain and filtering them by period.
694 const char kHistoryEnableGroupByDomain[] = "enable-grouped-history";
696 // Specifies which page will be displayed in newly-opened tabs. We need this
697 // for testing purposes so that the UI tests don't depend on what comes up for
698 // http://google.com.
699 const char kHomePage[] = "homepage";
701 // Comma-separated list of rules that control how hostnames are mapped.
703 // For example:
704 // "MAP * 127.0.0.1" --> Forces all hostnames to be mapped to 127.0.0.1
705 // "MAP *.google.com proxy" --> Forces all google.com subdomains to be
706 // resolved to "proxy".
707 // "MAP test.com [::1]:77 --> Forces "test.com" to resolve to IPv6 loopback.
708 // Will also force the port of the resulting
709 // socket address to be 77.
710 // "MAP * baz, EXCLUDE www.google.com" --> Remaps everything to "baz",
711 // except for "www.google.com".
713 // These mappings apply to the endpoint host in a net::URLRequest (the TCP
714 // connect and host resolver in a direct connection, and the CONNECT in an http
715 // proxy connection, and the endpoint host in a SOCKS proxy connection).
716 const char kHostRules[] = "host-rules";
718 // The maximum number of retry attempts to resolve the host. Set this to zero
719 // to disable host resolver retry attempts.
720 const char kHostResolverRetryAttempts[] = "host-resolver-retry-attempts";
722 // Causes net::URLFetchers to ignore requests for SSL client certificates,
723 // causing them to attempt an unauthenticated SSL/TLS session. This is intended
724 // for use when testing various service URLs (eg: kPromoServerURL, kSbURLPrefix,
725 // kSyncServiceURL, etc)
726 const char kIgnoreUrlFetcherCertRequests[] =
727 "ignore-urlfetcher-cert-requests";
729 // Causes the browser to launch directly in incognito mode.
730 const char kIncognito[] = "incognito";
732 // Causes Chrome to initiate an installation flow for the given app.
733 const char kInstallChromeApp[] = "install-chrome-app";
735 // Causes Chrome to attempt to get metadata from the webstore for the
736 // app/extension ID given, and then prompt the user to download and install it.
737 // This is allowed *only* for ephemeral apps. All other ids will be ignored.
738 const char kInstallEphemeralAppFromWebstore[] =
739 "install-ephemeral-app-from-webstore";
741 // A list of whitelists to install for a supervised user, for testing.
742 // The list is of the following form: <id>[:<name>],[<id>[:<name>],...]
743 const char kInstallSupervisedUserWhitelists[] =
744 "install-supervised-user-whitelists";
746 // Marks a renderer as an Instant process.
747 const char kInstantProcess[] = "instant-process";
749 // Invalidation service should use GCM network channel even if experiment is not
750 // enabled.
751 const char kInvalidationUseGCMChannel[] = "invalidation-use-gcm-channel";
753 // Disable latest shipping ECMAScript 6 features.
754 const char kDisableJavaScriptHarmonyShipping[] =
755 "disable-javascript-harmony-shipping";
757 // Enables experimental Harmony (ECMAScript 6) features.
758 const char kJavaScriptHarmony[] = "javascript-harmony";
760 // Specifies the testcase used by the IPC fuzzer.
761 const char kIpcFuzzerTestcase[] = "ipc-fuzzer-testcase";
763 // Used for testing - keeps browser alive after last browser window closes.
764 const char kKeepAliveForTest[] = "keep-alive-for-test";
766 // Enable Kiosk mode.
767 const char kKioskMode[] = "kiosk";
769 // Print automatically in kiosk mode. |kKioskMode| must be set as well.
770 // See http://crbug.com/31395.
771 const char kKioskModePrinting[] = "kiosk-printing";
773 // Comma-separated list of directories with component extensions to load.
774 const char kLoadComponentExtension[] = "load-component-extension";
776 // Loads an extension from the specified directory.
777 const char kLoadExtension[] = "load-extension";
779 // Makes Chrome default browser
780 const char kMakeDefaultBrowser[] = "make-default-browser";
782 // Use to opt-in user into Finch experiment groups.
783 const char kManualEnhancedBookmarks[] = "manual-enhanced-bookmarks";
784 const char kManualEnhancedBookmarksOptout[] =
785 "manual-enhanced-bookmarks-optout";
787 // Use to opt-in to marking HTTP as non-secure.
788 const char kMarkNonSecureAs[] = "mark-non-secure-as";
789 const char kMarkNonSecureAsNeutral[] = "neutral";
790 const char kMarkNonSecureAsDubious[] = "dubious";
791 const char kMarkNonSecureAsNonSecure[] = "non-secure";
793 // Forces the maximum disk space to be used by the media cache, in bytes.
794 const char kMediaCacheSize[] = "media-cache-size";
796 // Enables histograming of tasks served by MessageLoop. See
797 // about:histograms/Loop for results, which show frequency of messages on each
798 // thread, including APC count, object signalling count, etc.
799 const char kMessageLoopHistogrammer[] = "message-loop-histogrammer";
801 // Enables the recording of metrics reports but disables reporting. In contrast
802 // to kDisableMetrics, this executes all the code that a normal client would
803 // use for reporting, except the report is dropped rather than sent to the
804 // server. This is useful for finding issues in the metrics code during UI and
805 // performance tests.
806 const char kMetricsRecordingOnly[] = "metrics-recording-only";
808 // Sets the base logging level for the net log. Log 0 logs the most data.
809 // Intended primarily for use with --log-net-log.
810 const char kNetLogLevel[] = "net-log-level";
812 // Disables the default browser check. Useful for UI/browser tests where we
813 // want to avoid having the default browser info-bar displayed.
814 const char kNoDefaultBrowserCheck[] = "no-default-browser-check";
816 // By default, an https page can load images, fonts or frames from an http
817 // page. This switch overrides this to block this lesser mixed-content problem.
818 const char kNoDisplayingInsecureContent[] = "no-displaying-insecure-content";
820 // Don't record/playback events when using record & playback.
821 const char kNoEvents[] = "no-events";
823 // Disables all experiments set on about:flags. Does not disable about:flags
824 // itself. Useful if an experiment makes chrome crash at startup: One can start
825 // chrome with --no-experiments, disable the problematic lab at about:flags and
826 // then restart chrome without this switch again.
827 const char kNoExperiments[] = "no-experiments";
829 // Skip First Run tasks, whether or not it's actually the First Run. Overridden
830 // by kForceFirstRun. This does not drop the First Run sentinel and thus doesn't
831 // prevent first run from occuring the next time chrome is launched without this
832 // flag.
833 const char kNoFirstRun[] = "no-first-run";
835 // Whether or not the browser should warn if the profile is on a network share.
836 // This flag is only relevant for Windows currently.
837 const char kNoNetworkProfileWarning[] = "no-network-profile-warning";
839 // Don't send hyperlink auditing pings
840 const char kNoPings[] = "no-pings";
842 // Don't use a proxy server, always make direct connections. Overrides any
843 // other proxy server flags that are passed.
844 const char kNoProxyServer[] = "no-proxy-server";
846 // Disables the service process from adding itself as an autorun process. This
847 // does not delete existing autorun registrations, it just prevents the service
848 // from registering a new one.
849 const char kNoServiceAutorun[] = "no-service-autorun";
851 // Does not automatically open a browser window on startup (used when
852 // launching Chrome for the purpose of hosting background apps).
853 const char kNoStartupWindow[] = "no-startup-window";
855 // Disables checking whether we received an acknowledgment when registering
856 // a supervised user. Also disables the timeout during registration that waits
857 // for the ack. Useful when debugging against a server that does not
858 // support notifications.
859 const char kNoSupervisedUserAcknowledgmentCheck[] =
860 "no-managed-user-acknowledgment-check";
862 // Specifies the maximum number of threads to use for running the Proxy
863 // Autoconfig (PAC) script.
864 const char kNumPacThreads[] = "num-pac-threads";
866 // Launches URL in new browser window.
867 const char kOpenInNewWindow[] = "new-window";
869 // Force use of QUIC for requests to the specified origin.
870 const char kOriginToForceQuicOn[] = "origin-to-force-quic-on";
872 // The time that a new chrome process which is delegating to an already running
873 // chrome process started. (See ProcessSingleton for more details.)
874 const char kOriginalProcessStartTime[] = "original-process-start-time";
876 // Packages an extension to a .crx installable file from a given directory.
877 const char kPackExtension[] = "pack-extension";
879 // Optional PEM private key to use in signing packaged .crx.
880 const char kPackExtensionKey[] = "pack-extension-key";
882 // Specifies the path to the user data folder for the parent profile.
883 const char kParentProfile[] = "parent-profile";
885 // Development flag for permission request API. This flag is needed until
886 // the API is finalized.
887 // TODO(bauerb): Remove when this flag is not needed anymore.
888 const char kPermissionRequestApiScope[] = "permission-request-api-scope";
890 // Development flag for permission request API. This flag is needed until
891 // the API is finalized.
892 // TODO(bauerb): Remove when this flag is not needed anymore.
893 const char kPermissionRequestApiUrl[] = "permission-request-api-url";
895 // Read previously recorded data from the cache. Only cached data is read.
896 // See kRecordMode.
897 const char kPlaybackMode[] = "playback-mode";
899 // Use the PPAPI (Pepper) Flash found at the given path.
900 const char kPpapiFlashPath[] = "ppapi-flash-path";
902 // Report the given version for the PPAPI (Pepper) Flash. The version should be
903 // numbers separated by '.'s (e.g., "12.3.456.78"). If not specified, it
904 // defaults to "10.2.999.999".
905 const char kPpapiFlashVersion[] = "ppapi-flash-version";
907 // Triggers prerendering of search base page to prefetch results for the typed
908 // omnibox query. Only has an effect when prerender is enabled.
909 const char kPrefetchSearchResults[] = "prefetch-search-results";
911 // Triggers prerendering of pages from suggestions in the omnibox. Only has an
912 // effect when Instant is either disabled or restricted to search, and when
913 // prerender is enabled.
914 const char kPrerenderFromOmnibox[] = "prerender-from-omnibox";
915 // These are the values the kPrerenderFromOmnibox switch may have, as in
916 // "--prerender-from-omnibox=auto". auto: Allow field trial selection.
917 const char kPrerenderFromOmniboxSwitchValueAuto[] = "auto";
918 // disabled: No prerendering.
919 const char kPrerenderFromOmniboxSwitchValueDisabled[] = "disabled";
920 // enabled: Guaranteed prerendering.
921 const char kPrerenderFromOmniboxSwitchValueEnabled[] = "enabled";
922 // Controls speculative prerendering of pages, and content prefetching. Both
923 // are dispatched from <link rel=prefetch href=...> elements.
924 const char kPrerenderMode[] = "prerender";
925 // These are the values the kPrerenderMode switch may have, as in
926 // "--prerender=auto".
927 // auto: Allow field trial selection for prerender.
928 const char kPrerenderModeSwitchValueAuto[] = "auto";
929 // disabled: No prerendering.
930 const char kPrerenderModeSwitchValueDisabled[] = "disabled";
931 // enabled: Prerendering.
932 const char kPrerenderModeSwitchValueEnabled[] = "enabled";
934 // Use IPv6 only for privet HTTP.
935 const char kPrivetIPv6Only[] = "privet-ipv6-only";
937 // Outputs the product version information and quit. Used as an internal api to
938 // detect the installed version of Chrome on Linux.
939 const char kProductVersion[] = "product-version";
941 // Selects directory of profile to associate with the first browser launched.
942 const char kProfileDirectory[] = "profile-directory";
944 // Starts the sampling based profiler for the browser process at startup. This
945 // will only work if chrome has been built with the gyp variable profiling=1.
946 // The output will go to the value of kProfilingFile.
947 const char kProfilingAtStart[] = "profiling-at-start";
949 // Specifies a location for profiling output. This will only work if chrome has
950 // been built with the gyp variable profiling=1.
952 // {pid} if present will be replaced by the pid of the process.
953 // {count} if present will be incremented each time a profile is generated
954 // for this process.
955 // The default is chrome-profile-{pid}.
956 const char kProfilingFile[] = "profiling-file";
958 // Specifies a path for the output of task-level profiling which can be loaded
959 // and viewed in about:profiler.
960 const char kProfilingOutputFile[] = "profiling-output-file";
962 // Controls whether profile data is periodically flushed to a file. Normally
963 // the data gets written on exit but cases exist where chrome doesn't exit
964 // cleanly (especially when using single-process). A time in seconds can be
965 // specified.
966 const char kProfilingFlush[] = "profiling-flush";
968 // Specifies a custom URL for fetching NTP promo data.
969 const char kPromoServerURL[] = "promo-server-url";
971 // Forces proxy auto-detection.
972 const char kProxyAutoDetect[] = "proxy-auto-detect";
974 // Specifies a list of hosts for whom we bypass proxy settings and use direct
975 // connections. Ignored if --proxy-auto-detect or --no-proxy-server are also
976 // specified. This is a comma-separated list of bypass rules. See:
977 // "net/proxy/proxy_bypass_rules.h" for the format of these rules.
978 const char kProxyBypassList[] = "proxy-bypass-list";
980 // Uses the pac script at the given URL
981 const char kProxyPacUrl[] = "proxy-pac-url";
983 // Uses a specified proxy server, overrides system settings. This switch only
984 // affects HTTP and HTTPS requests.
985 const char kProxyServer[] = "proxy-server";
987 // Specifies a comma separated list of QUIC connection options to send to
988 // the server.
989 const char kQuicConnectionOptions[] = "quic-connection-options";
991 // Specifies the maximum length for a QUIC packet.
992 const char kQuicMaxPacketLength[] = "quic-max-packet-length";
994 // Specifies the version of QUIC to use.
995 const char kQuicVersion[] = "quic-version";
997 // Chrome supports a playback and record mode. Record mode saves *everything*
998 // to the cache. Playback mode reads data exclusively from the cache. This
999 // allows us to record a session into the cache and then replay it at will.
1000 // See also kPlaybackMode.
1001 const char kRecordMode[] = "record-mode";
1003 // Remember user proceeds through SSL interstitials for a specified amount of
1004 // time. In particular, remember these decisions through session restart. The
1005 // time delta to remember certificates should be specified in seconds.
1006 const char kRememberCertErrorDecisions[] = "remember-cert-error-decisions";
1008 // Requires presence of Certificate Transparency for Extended Validation
1009 // certificates. Enforce the policy detailed at:
1010 // http://dev.chromium.org/Home/chromium-security/certificate-transparency
1011 const char kRequireCTForEV[] = "require-ct-for-ev";
1013 // If set, the app list will forget it has been installed on startup. Note this
1014 // doesn't prevent the app list from running, it just makes Chrome think the app
1015 // list hasn't been enabled (as in kEnableAppList) yet.
1016 const char kResetAppListInstallState[] = "reset-app-list-install-state";
1018 // Indicates the last session should be restored on startup. This overrides the
1019 // preferences value and is primarily intended for testing. The value of this
1020 // switch is the number of tabs to wait until loaded before 'load completed' is
1021 // sent to the ui_test.
1022 const char kRestoreLastSession[] = "restore-last-session";
1024 // Disable saving pages as HTML-only, disable saving pages as HTML Complete
1025 // (with a directory of sub-resources). Enable only saving pages as MHTML.
1026 // See http://crbug.com/120416 for how to remove this switch.
1027 const char kSavePageAsMHTML[] = "save-page-as-mhtml";
1029 // If present, safebrowsing only performs update when
1030 // SafeBrowsingProtocolManager::ForceScheduleNextUpdate() is explicitly called.
1031 // This is used for testing only.
1032 const char kSbDisableAutoUpdate[] = "safebrowsing-disable-auto-update";
1034 // TODO(lzheng): Remove this flag once the feature works fine
1035 // (http://crbug.com/74848).
1037 // Disables safebrowsing feature that checks download url and downloads
1038 // content's hash to make sure the content are not malicious.
1039 const char kSbDisableDownloadProtection[] =
1040 "safebrowsing-disable-download-protection";
1042 // Disables safebrowsing feature that checks for blacklisted extensions.
1043 const char kSbDisableExtensionBlacklist[] =
1044 "safebrowsing-disable-extension-blacklist";
1046 // Disables safebrowsing feature that provides a side-effect free whitelist.
1047 const char kSbDisableSideEffectFreeWhitelist[] =
1048 "safebrowsing-disable-side-effect-free-whitelist";
1050 // Causes the process to run as a service process.
1051 const char kServiceProcess[] = "service";
1053 // Sets a token in the token service, for testing.
1054 const char kSetToken[] = "set-token";
1056 // If true the app list will be shown.
1057 const char kShowAppList[] = "show-app-list";
1059 // See kHideIcons.
1060 const char kShowIcons[] = "show-icons";
1062 // Marks a renderer as the signin process.
1063 const char kSigninProcess[] = "signin-process";
1065 // Does not show an infobar when an extension attaches to a page using
1066 // chrome.debugger page. Required to attach to extension background pages.
1067 const char kSilentDebuggerExtensionAPI[] = "silent-debugger-extension-api";
1069 // Causes Chrome to launch without opening any windows by default. Useful if
1070 // one wishes to use Chrome as an ash server.
1071 const char kSilentLaunch[] = "silent-launch";
1073 // Simulates that elevation is needed to recover upgrade channel.
1074 const char kSimulateElevatedRecovery[] = "simulate-elevated-recovery";
1076 // Simulates a critical update being available.
1077 const char kSimulateCriticalUpdate[] = "simulate-critical-update";
1079 // Simulates that current version is outdated.
1080 const char kSimulateOutdated[] = "simulate-outdated";
1082 // Simulates that current version is outdated and auto-update is off.
1083 const char kSimulateOutdatedNoAU[] = "simulate-outdated-no-au";
1085 // Simulates an update being available.
1086 const char kSimulateUpgrade[] = "simulate-upgrade";
1088 // Speculative resource prefetching.
1089 const char kSpeculativeResourcePrefetching[] =
1090 "speculative-resource-prefetching";
1092 // Speculative resource prefetching is disabled.
1093 const char kSpeculativeResourcePrefetchingDisabled[] = "disabled";
1095 // Speculative resource prefetching will only learn about resources that need to
1096 // be prefetched but will not prefetch them.
1097 const char kSpeculativeResourcePrefetchingLearning[] = "learning";
1099 // Speculative resource prefetching is enabled.
1100 const char kSpeculativeResourcePrefetchingEnabled[] = "enabled";
1102 #if defined(ENABLE_SPELLCHECK)
1103 // Enables auto correction for misspelled words.
1104 const char kEnableSpellingAutoCorrect[] = "enable-spelling-auto-correct";
1105 #endif
1107 // Specifies the maximum SSL/TLS version ("ssl3", "tls1", "tls1.1", or
1108 // "tls1.2").
1109 const char kSSLVersionMax[] = "ssl-version-max";
1111 // Specifies the minimum SSL/TLS version ("ssl3", "tls1", "tls1.1", or
1112 // "tls1.2").
1113 const char kSSLVersionMin[] = "ssl-version-min";
1115 // Specifies the minimum SSL/TLS version ("ssl3", "tls1", "tls1.1", or
1116 // "tls1.2") that TLS fallback will accept.
1117 const char kSSLVersionFallbackMin[] = "ssl-version-fallback-min";
1119 // These values aren't switches, but rather the values that kSSLVersionMax,
1120 // kSSLVersionMin and kSSLVersionFallbackMin can have.
1121 const char kSSLVersionSSLv3[] = "ssl3";
1122 const char kSSLVersionTLSv1[] = "tls1";
1123 const char kSSLVersionTLSv11[] = "tls1.1";
1124 const char kSSLVersionTLSv12[] = "tls1.2";
1126 // Starts the browser maximized, regardless of any previous settings.
1127 const char kStartMaximized[] = "start-maximized";
1129 // Sets the supervised user ID for any loaded or newly created profile to the
1130 // given value. Pass an empty string to mark the profile as non-supervised.
1131 // Used for testing.
1132 const char kSupervisedUserId[] = "managed-user-id";
1134 // Used to authenticate requests to the Sync service for supervised users.
1135 // Setting this switch also causes Sync to be set up for a supervised user.
1136 const char kSupervisedUserSyncToken[] = "managed-user-sync-token";
1138 // This flag causes sync to retry very quickly (see polling_constants.h) the
1139 // when it encounters an error, as the first step towards exponential backoff.
1140 const char kSyncShortInitialRetryOverride[] =
1141 "sync-short-initial-retry-override";
1143 // Overrides the default server used for profile sync.
1144 const char kSyncServiceURL[] = "sync-url";
1146 // Enables deferring sync backend initialization until user initiated changes
1147 // occur.
1148 const char kSyncDisableDeferredStartup[] = "sync-disable-deferred-startup";
1150 // Allows overriding the deferred init fallback timeout.
1151 const char kSyncDeferredStartupTimeoutSeconds[] =
1152 "sync-deferred-startup-timeout-seconds";
1154 // Enables feature to avoid unnecessary GetUpdate requests.
1155 const char kSyncEnableGetUpdateAvoidance[] =
1156 "sync-enable-get-update-avoidance";
1158 // Disable data backup when user's not signed in.
1159 const char kSyncDisableBackup[] = "disable-sync-backup";
1161 // Disable sync rollback.
1162 const char kSyncDisableRollback[] = "disable-sync-rollback";
1164 // Passes the name of the current running automated test to Chrome.
1165 const char kTestName[] = "test-name";
1167 // Disables same-origin check on HTTP resources pushed via a SPDY proxy.
1168 // The value is the host:port of the trusted proxy.
1169 const char kTrustedSpdyProxy[] = "trusted-spdy-proxy";
1171 // Experimental. Shows a dialog asking the user to try chrome. This flag is to
1172 // be used only by the upgrade process.
1173 const char kTryChromeAgain[] = "try-chrome-again";
1175 // Runs un-installation steps that were done by chrome first-run.
1176 const char kUninstall[] = "uninstall";
1178 // Overrides per-origin quota settings to unlimited storage for any
1179 // apps/origins. This should be used only for testing purpose.
1180 const char kUnlimitedStorage[] = "unlimited-storage";
1182 // Uses Spdy for the transport protocol instead of HTTP. This is a temporary
1183 // testing flag.
1184 const char kUseSpdy[] = "use-spdy";
1186 // A string used to override the default user agent with a custom one.
1187 const char kUserAgent[] = "user-agent";
1189 // Specifies the user data directory, which is where the browser will look for
1190 // all of its state.
1191 const char kUserDataDir[] = "user-data-dir";
1193 // Examines a .crx for validity and prints the result.
1194 const char kValidateCrx[] = "validate-crx";
1196 // Uses experimental simple cache backend if possible.
1197 const char kUseSimpleCacheBackend[] = "use-simple-cache-backend";
1199 // Specifies a custom URL for the server which reports variation data to the
1200 // client. Specifying this switch enables the Variations service on
1201 // unofficial builds. See variations_service.cc.
1202 const char kVariationsServerURL[] = "variations-server-url";
1204 // Prints version information and quits.
1205 const char kVersion[] = "version";
1207 // Specify the initial window position: --window-position=x,y
1208 const char kWindowPosition[] = "window-position";
1210 // Specify the initial window size: --window-size=w,h
1211 const char kWindowSize[] = "window-size";
1213 // Uses WinHTTP to fetch and evaluate PAC scripts. Otherwise the default is to
1214 // use Chromium's network stack to fetch, and V8 to evaluate.
1215 const char kWinHttpProxyResolver[] = "winhttp-proxy-resolver";
1217 // Specifies which category option was clicked in the Windows Jumplist that
1218 // resulted in a browser startup.
1219 const char kWinJumplistAction[] = "win-jumplist-action";
1221 #if defined(OS_ANDROID)
1222 // Disables support for playing videos on Chromecast devices.
1223 const char kDisableCast[] = "disable-cast";
1225 // Disables Contextual Search.
1226 const char kDisableContextualSearch[] = "disable-contextual-search";
1228 // Disables zero suggest experiment on Dev channel.
1229 const char kDisableZeroSuggest[] = "disable-zero-suggest";
1231 // Enable the accessibility tab switcher.
1232 const char kEnableAccessibilityTabSwitcher[] =
1233 "enable-accessibility-tab-switcher";
1235 // Enables app install alerts.
1236 const char kEnableAppInstallAlerts[] = "enable-app-install-alerts";
1238 // Enables Contextual Search.
1239 const char kEnableContextualSearch[] = "enable-contextual-search";
1241 // Enables zero suggest functionality on Dev channel, showing most visited
1242 // sites as default suggestions.
1243 const char kEnableZeroSuggestMostVisited[] =
1244 "enable-zero-suggest-most-visited";
1246 // Enable zero suggest functionality on Dev channel, showing most visited
1247 // sites on non-search-result pages as default suggestions.
1248 const char kEnableZeroSuggestMostVisitedWithoutSerp[] =
1249 "enable-zero-suggest-most-visited-without-serp";
1251 // Enables instant search clicks feature.
1252 const char kEnableInstantSearchClicks[] = "enable-instant-search-clicks";
1254 #endif
1256 #if defined(USE_ASH)
1257 const char kOpenAsh[] = "open-ash";
1258 #endif
1260 #if defined(OS_POSIX) && !defined(OS_MACOSX) && !defined(OS_CHROMEOS)
1261 // Specifies which password store to use (detect, default, gnome, kwallet).
1262 const char kPasswordStore[] = "password-store";
1263 #endif
1265 #if defined(OS_LINUX) && !defined(OS_CHROMEOS)
1266 // Triggers migration of user data directory to another directory
1267 // specified as a parameter. The migration is done under singleton lock,
1268 // and sanity checks are made to avoid corrupting the profile.
1269 // The browser exits after migration is complete.
1270 const char kMigrateDataDirForSxS[] = "migrate-data-dir-for-sxs";
1271 #endif // defined(OS_LINUX) && !defined(OS_CHROMEOS)
1273 #if defined(OS_MACOSX)
1274 // Prevents Chrome from quitting when Chrome Apps are open.
1275 const char kAppsKeepChromeAliveInTests[] = "apps-keep-chrome-alive-in-tests";
1277 // Shows a notification when quitting Chrome with hosted apps running. Default
1278 // behavior is to also quit all hosted apps.
1279 const char kHostedAppQuitNotification[] = "enable-hosted-app-quit-notification";
1281 // Forcibly disables Lion-style on newer OSes, to allow developers to test the
1282 // older, SnowLeopard-style fullscreen.
1283 const char kDisableSystemFullscreenForTesting[] =
1284 "disable-system-fullscreen-for-testing";
1286 // Enables app shim creation for hosted apps on Mac.
1287 const char kEnableHostedAppShimCreation[] = "enable-hosted-app-shim-creation";
1289 // A process type (switches::kProcessType) that relaunches the browser. See
1290 // chrome/browser/mac/relauncher.h.
1291 const char kRelauncherProcess[] = "relauncher";
1293 #endif
1295 // Use bubbles for content permissions requests instead of infobars.
1296 const char kEnablePermissionsBubbles[] = "enable-permissions-bubbles";
1298 #if defined(OS_WIN)
1299 // Fallback to XPS. By default connector uses CDD.
1300 const char kEnableCloudPrintXps[] = "enable-cloud-print-xps";
1302 // Force-enables the profile shortcut manager. This is needed for tests since
1303 // they use a custom-user-data-dir which disables this.
1304 const char kEnableProfileShortcutManager[] = "enable-profile-shortcut-manager";
1306 // For the DelegateExecute verb handler to launch Chrome in metro mode on
1307 // Windows 8 and higher. Used when relaunching metro Chrome.
1308 const char kForceImmersive[] = "force-immersive";
1310 // For the DelegateExecute verb handler to launch Chrome in desktop mode on
1311 // Windows 8 and higher. Used when relaunching metro Chrome.
1312 const char kForceDesktop[] = "force-desktop";
1314 // Relaunches metro Chrome on Windows 8 and higher using a given shortcut.
1315 const char kRelaunchShortcut[] = "relaunch-shortcut";
1317 // Requests that Chrome launch the Metro viewer process via the given appid
1318 // (which is assumed to be registered as default browser) and synchronously
1319 // connect to it.
1320 const char kViewerLaunchViaAppId[] = "viewer-launch-via-appid";
1322 // Waits for the given handle to be signaled before relaunching metro Chrome on
1323 // Windows 8 and higher.
1324 const char kWaitForMutex[] = "wait-for-mutex";
1326 // Indicates that chrome was launched to service a search request in Windows 8.
1327 const char kWindows8Search[] = "windows8-search";
1328 #endif
1330 #if defined(ENABLE_PRINT_PREVIEW) && !defined(OFFICIAL_BUILD)
1331 // Enables support to debug printing subsystem.
1332 const char kDebugPrint[] = "debug-print";
1333 #endif
1335 #ifndef NDEBUG
1336 // Enables overriding the path of file manager extension.
1337 const char kFileManagerExtensionPath[] = "filemgr-ext-path";
1338 #endif
1340 bool AboutInSettingsEnabled() {
1341 return SettingsWindowEnabled() &&
1342 !base::CommandLine::ForCurrentProcess()->HasSwitch(
1343 ::switches::kDisableAboutInSettings);
1346 // Will return true as a default value if the "disable-new-offline-error-page"
1347 // command-line switch is not available.
1348 bool NewOfflineErrorPageEnabled() {
1349 return !base::CommandLine::ForCurrentProcess()->HasSwitch(
1350 ::switches::kDisableNewOfflineErrorPage);
1353 bool OutOfProcessPdfEnabled() {
1354 if (base::CommandLine::ForCurrentProcess()->HasSwitch(kEnableOutOfProcessPdf))
1355 return true;
1357 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
1358 kDisableOutOfProcessPdf))
1359 return false;
1361 // Default.
1362 return true;
1365 bool PdfMaterialUIEnabled() {
1366 if (base::CommandLine::ForCurrentProcess()->HasSwitch(kEnablePdfMaterialUI))
1367 return true;
1369 if (base::CommandLine::ForCurrentProcess()->HasSwitch(kDisablePdfMaterialUI))
1370 return false;
1372 // Default.
1373 return false;
1376 bool SettingsWindowEnabled() {
1377 #if defined(OS_CHROMEOS)
1378 return !base::CommandLine::ForCurrentProcess()->HasSwitch(
1379 ::switches::kDisableSettingsWindow);
1380 #else
1381 return base::CommandLine::ForCurrentProcess()->HasSwitch(
1382 ::switches::kEnableSettingsWindow);
1383 #endif
1386 #if defined(OS_CHROMEOS)
1387 bool PowerOverlayEnabled() {
1388 return base::CommandLine::ForCurrentProcess()->HasSwitch(
1389 ::switches::kEnablePowerOverlay);
1391 #endif
1393 // -----------------------------------------------------------------------------
1394 // DO NOT ADD YOUR CRAP TO THE BOTTOM OF THIS FILE.
1396 // You were going to just dump your switches here, weren't you? Instead, please
1397 // put them in alphabetical order above, or in order inside the appropriate
1398 // ifdef at the bottom. The order should match the header.
1399 // -----------------------------------------------------------------------------
1401 } // namespace switches