Supervised user whitelists: Cleanup
[chromium-blink-merge.git] / content / public / common / content_switches.cc
blob6672723a9a8e3c9419d67e2e214393e526b8f2cc
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 "content/public/common/content_switches.h"
7 namespace switches {
9 // The number of MSAA samples for canvas2D. Requires MSAA support by GPU to
10 // have an effect. 0 disables MSAA.
11 const char kAcceleratedCanvas2dMSAASampleCount[] = "canvas-msaa-sample-count";
13 // By default, file:// URIs cannot read other file:// URIs. This is an
14 // override for developers who need the old behavior for testing.
15 const char kAllowFileAccessFromFiles[] = "allow-file-access-from-files";
17 // Allows loopback interface to be added in network list for peer connection.
18 const char kAllowLoopbackInPeerConnection[] =
19 "allow-loopback-in-peer-connection";
21 // Enables the sandboxed processes to run without a job object assigned to them.
22 // This flag is required to allow Chrome to run in RemoteApps or Citrix. This
23 // flag can reduce the security of the sandboxed processes and allow them to do
24 // certain API calls like shut down Windows or access the clipboard. Also we
25 // lose the chance to kill some processes until the outer job that owns them
26 // finishes.
27 const char kAllowNoSandboxJob[] = "allow-no-sandbox-job";
29 // Allows debugging of sandboxed processes (see zygote_main_linux.cc).
30 const char kAllowSandboxDebugging[] = "allow-sandbox-debugging";
32 // The same as kAuditHandles except all handles are enumerated.
33 const char kAuditAllHandles[] = "enable-handle-auditing-all";
35 // Enumerates and prints a child process' most dangerous handles when it
36 // is terminated.
37 const char kAuditHandles[] = "enable-handle-auditing";
39 // Choose which logging channels in blink platform to activate. See
40 // Logging.cpp in blink's Source/platform for a list of available channels.
41 const char kBlinkPlatformLogChannels[] = "blink-platform-log-channels";
43 // Set blink settings. Format is <name>[=<value],<name>[=<value>],...
44 // The names are declared in Settings.in. For boolean type, use "true", "false",
45 // or omit '=<value>' part to set to true. For enum type, use the int value of
46 // the enum value. Applied after other command line flags and prefs.
47 const char kBlinkSettings[] = "blink-settings";
49 // Block cross-site documents (i.e., HTML/XML/JSON) from being loaded in
50 // subresources when a document is not supposed to read them. This will later
51 // allow us to block them from the entire renderer process when site isolation
52 // is enabled.
53 const char kBlockCrossSiteDocuments[] = "block-cross-site-documents";
55 // Causes the browser process to crash on startup.
56 const char kBrowserCrashTest[] = "crash-test";
58 // Path to the exe to run for the renderer and plugin subprocesses.
59 const char kBrowserSubprocessPath[] = "browser-subprocess-path";
61 // Dumps extra logging about plugin loading to the log file.
62 const char kDebugPluginLoading[] = "debug-plugin-loading";
64 // Sets the tile size used by composited layers.
65 const char kDefaultTileWidth[] = "default-tile-width";
66 const char kDefaultTileHeight[] = "default-tile-height";
68 // Disable antialiasing on 2d canvas.
69 const char kDisable2dCanvasAntialiasing[] = "disable-canvas-aa";
71 // Disables client-visible 3D APIs, in particular WebGL and Pepper 3D.
72 // This is controlled by policy and is kept separate from the other
73 // enable/disable switches to avoid accidentally regressing the policy
74 // support for controlling access to these APIs.
75 const char kDisable3DAPIs[] = "disable-3d-apis";
77 // Disable gpu-accelerated 2d canvas.
78 const char kDisableAccelerated2dCanvas[] = "disable-accelerated-2d-canvas";
80 // Disables hardware acceleration of video decode, where available.
81 const char kDisableAcceleratedVideoDecode[] =
82 "disable-accelerated-video-decode";
84 // Disable limits on the number of backing stores. Can prevent blinking for
85 // users with many windows/tabs and lots of memory.
86 const char kDisableBackingStoreLimit[] = "disable-backing-store-limit";
88 // Disable one or more Blink runtime-enabled features.
89 // Use names from RuntimeEnabledFeatures.in, separated by commas.
90 // Applied after kEnableBlinkFeatures, and after other flags that change these
91 // features.
92 const char kDisableBlinkFeatures[] = "disable-blink-features";
94 // Disable the creation of compositing layers when it would prevent LCD text.
95 const char kDisablePreferCompositingToLCDText[] =
96 "disable-prefer-compositing-to-lcd-text";
98 // Disables HTML5 DB support.
99 const char kDisableDatabases[] = "disable-databases";
101 // Disables delegated renderer.
102 const char kDisableDelegatedRenderer[] = "disable-delegated-renderer";
104 // Handles URL requests by NPAPI plugins through the renderer.
105 const char kDisableDirectNPAPIRequests[] = "disable-direct-npapi-requests";
107 // Disable the per-domain blocking for 3D APIs after GPU reset.
108 // This switch is intended only for tests.
109 extern const char kDisableDomainBlockingFor3DAPIs[] =
110 "disable-domain-blocking-for-3d-apis";
112 // Disable experimental WebGL support.
113 const char kDisableExperimentalWebGL[] = "disable-webgl";
115 // Disable FileSystem API.
116 const char kDisableFileSystem[] = "disable-file-system";
118 // Disable 3D inside of flapper.
119 const char kDisableFlash3d[] = "disable-flash-3d";
121 // Disable Stage3D inside of flapper.
122 const char kDisableFlashStage3d[] = "disable-flash-stage3d";
124 // Disables GPU hardware acceleration. If software renderer is not in place,
125 // then the GPU process won't launch.
126 const char kDisableGpu[] = "disable-gpu";
128 // Prevent the compositor from using its GPU implementation.
129 const char kDisableGpuCompositing[] = "disable-gpu-compositing";
131 // Disable proactive early init of GPU process.
132 const char kDisableGpuEarlyInit[] = "disable-gpu-early-init";
134 // Disable the limit on the number of times the GPU process may be restarted
135 // This switch is intended only for tests.
136 extern const char kDisableGpuProcessCrashLimit[] =
137 "disable-gpu-process-crash-limit";
139 // Disable GPU rasterization, i.e. rasterize on the CPU only.
140 // Overrides the kEnableGpuRasterization and kForceGpuRasterization flags.
141 const char kDisableGpuRasterization[] = "disable-gpu-rasterization";
143 // When using CPU rasterizing disable low resolution tiling. This uses
144 // less power, particularly during animations, but more white may be seen
145 // during fast scrolling especially on slower devices.
146 const char kDisableLowResTiling[] = "disable-low-res-tiling";
148 // Disable the GPU process sandbox.
149 const char kDisableGpuSandbox[] = "disable-gpu-sandbox";
151 // Disable the thread that crashes the GPU process if it stops responding to
152 // messages.
153 const char kDisableGpuWatchdog[] = "disable-gpu-watchdog";
155 // Suppresses hang monitor dialogs in renderer processes. This may allow slow
156 // unload handlers on a page to prevent the tab from closing, but the Task
157 // Manager can be used to terminate the offending process in this case.
158 const char kDisableHangMonitor[] = "disable-hang-monitor";
160 // Disable hiding the close buttons of inactive tabs when the tabstrip is in
161 // stacked mode.
162 const char kDisableHideInactiveStackedTabCloseButtons[] =
163 "disable-hide-inactive-stacked-tab-close-buttons";
165 // Disable the RenderThread's HistogramCustomizer.
166 const char kDisableHistogramCustomizer[] = "disable-histogram-customizer";
168 // Paint content on the main thread instead of the compositor thread.
169 const char kDisableImplSidePainting[] = "disable-impl-side-painting";
171 // Prevent Java from running.
172 const char kDisableJava[] = "disable-java";
174 // Don't kill a child process when it sends a bad IPC message. Apart
175 // from testing, it is a bad idea from a security perspective to enable
176 // this switch.
177 const char kDisableKillAfterBadIPC[] = "disable-kill-after-bad-ipc";
179 // Disables prefixed Encrypted Media API (e.g. webkitGenerateKeyRequest()).
180 const char kDisablePrefixedEncryptedMedia[] =
181 "disable-prefixed-encrypted-media";
183 // Disables LCD text.
184 const char kDisableLCDText[] = "disable-lcd-text";
186 // Disables distance field text.
187 const char kDisableDistanceFieldText[] = "disable-distance-field-text";
189 // Disable LocalStorage.
190 const char kDisableLocalStorage[] = "disable-local-storage";
192 // Force logging to be disabled. Logging is enabled by default in debug
193 // builds.
194 const char kDisableLogging[] = "disable-logging";
196 // Disables Media Source API (i.e., the MediaSource object).
197 const char kDisableMediaSource[] = "disable-media-source";
199 // Disables usage of the namespace sandbox.
200 const char kDisableNamespaceSandbox[] = "disable-namespace-sandbox";
202 // Disables the Web Notification and the Push APIs.
203 const char kDisableNotifications[] = "disable-notifications";
205 // Disable rasterizer that writes directly to GPU memory.
206 // Overrides the kEnableOneCopy flag.
207 const char kDisableOneCopy[] = "disable-one-copy";
209 // Disable Pepper3D.
210 const char kDisablePepper3d[] = "disable-pepper-3d";
212 // Disables compositor-accelerated touch-screen pinch gestures.
213 const char kDisablePinch[] = "disable-pinch";
215 // Disable discovering third-party plugins. Effectively loading only
216 // ones shipped with the browser plus third-party ones as specified by
217 // --extra-plugin-dir and --load-plugin switches.
218 const char kDisablePluginsDiscovery[] = "disable-plugins-discovery";
220 // Taints all <canvas> elements, regardless of origin.
221 const char kDisableReadingFromCanvas[] = "disable-reading-from-canvas";
223 // Disables remote web font support. SVG font should always work whether this
224 // option is specified or not.
225 const char kDisableRemoteFonts[] = "disable-remote-fonts";
227 // Turns off the accessibility in the renderer.
228 const char kDisableRendererAccessibility[] = "disable-renderer-accessibility";
230 // Disable the seccomp filter sandbox (seccomp-bpf) (Linux only).
231 const char kDisableSeccompFilterSandbox[] = "disable-seccomp-filter-sandbox";
233 // Disable the setuid sandbox (Linux only).
234 const char kDisableSetuidSandbox[] = "disable-setuid-sandbox";
236 // Disable shared workers.
237 const char kDisableSharedWorkers[] = "disable-shared-workers";
239 // For tests, disable single thread scheduler and only manually composite.
240 const char kDisableSingleThreadProxyScheduler[] =
241 "disable-single-thread-proxy-scheduler";
243 // Disable smooth scrolling for testing.
244 const char kDisableSmoothScrolling[] = "disable-smooth-scrolling";
246 // Disables the use of a 3D software rasterizer.
247 const char kDisableSoftwareRasterizer[] = "disable-software-rasterizer";
249 // Disables SVG 1.1 DOM.
250 const char kDisableSVG1DOM[] = "disable-svg1dom";
252 // Disable text blob rendering.
253 const char kDisableTextBlobs[] = "disable-text-blobs";
255 // Disable multithreaded GPU compositing of web content.
256 const char kDisableThreadedCompositing[] = "disable-threaded-compositing";
258 // Disable multithreaded, compositor scrolling of web content.
259 const char kDisableThreadedScrolling[] = "disable-threaded-scrolling";
261 // Disable V8 idle tasks.
262 const char kDisableV8IdleTasks[] = "disable-v8-idle-tasks";
264 // Don't enforce the same-origin policy. (Used by people testing their sites.)
265 const char kDisableWebSecurity[] = "disable-web-security";
267 // Disables Blink's XSSAuditor. The XSSAuditor mitigates reflective XSS.
268 const char kDisableXSSAuditor[] = "disable-xss-auditor";
270 // Specifies if the |DOMAutomationController| needs to be bound in the
271 // renderer. This binding happens on per-frame basis and hence can potentially
272 // be a performance bottleneck. One should only enable it when automating dom
273 // based tests.
274 const char kDomAutomationController[] = "dom-automation";
276 // Enable antialiasing on 2d canvas clips (as opposed to draw operations)
277 const char kEnable2dCanvasClipAntialiasing[] = "enable-2d-canvas-clip-aa";
279 // Disable partially decoding jpeg images using the GPU.
280 // At least YUV decoding will be accelerated when not using this flag.
281 // Has no effect unless GPU rasterization is enabled.
282 const char kDisableAcceleratedJpegDecoding[] =
283 "disable-accelerated-jpeg-decoding";
285 // Enable bleeding-edge code to make Chrome draw content faster. The changes
286 // behind this path are very likely to break lots of content.
287 // ** DO NOT use this flag unless you know what you are doing. **
288 const char kEnableBleedingEdgeRenderingFastPaths[] =
289 "enable-bleeding-edge-rendering-fast-paths";
291 // Enables new cc/animation system (Project Heaviside). crbug.com/394772
292 const char kEnableCompositorAnimationTimelines[] =
293 "enable-compositor-animation-timelines";
295 // Enables LCD text.
296 const char kEnableLCDText[] = "enable-lcd-text";
298 // Enables using signed distance fields when rendering text.
299 // Only valid if GPU rasterization is enabled as well.
300 const char kEnableDistanceFieldText[] = "enable-distance-field-text";
302 // Enable the experimental Credential Manager JavaScript API.
303 const char kEnableCredentialManagerAPI[] = "enable-credential-manager-api";
305 // Use a BeginFrame signal from browser to renderer to schedule rendering.
306 const char kEnableBeginFrameScheduling[] = "enable-begin-frame-scheduling";
308 // Enable the creation of compositing layers when it would prevent LCD text.
309 const char kEnablePreferCompositingToLCDText[] =
310 "enable-prefer-compositing-to-lcd-text";
312 // Disable one or more Blink runtime-enabled features.
313 // Use names from RuntimeEnabledFeatures.in, separated by commas.
314 // Applied before kDisableBlinkFeatures, and after other flags that change these
315 // features.
316 const char kEnableBlinkFeatures[] = "enable-blink-features";
318 // PlzNavigate: Use the experimental browser-side navigation path.
319 const char kEnableBrowserSideNavigation[] = "enable-browser-side-navigation";
321 // Defer image decoding in WebKit until painting.
322 const char kEnableDeferredImageDecoding[] = "enable-deferred-image-decoding";
324 // Enables Delay Agnostic AEC in WebRTC.
325 const char kEnableDelayAgnosticAec[] = "enable-delay-agnostic-aec";
327 // Enables delegated renderer.
328 const char kEnableDelegatedRenderer[] = "enable-delegated-renderer";
330 // Enables display list based 2d canvas implementation. Options:
331 // 1. Enable: allow browser to use display list for 2d canvas (browser makes
332 // decision).
333 // 2. Force: browser always uses display list for 2d canvas.
334 const char kEnableDisplayList2dCanvas[] = "enable-display-list-2d-canvas";
335 const char kForceDisplayList2dCanvas[] = "force-display-list-2d-canvas";
336 const char kDisableDisplayList2dCanvas[] = "disable-display-list-2d-canvas";
338 // Enables restarting interrupted downloads.
339 const char kEnableDownloadResumption[] = "enable-download-resumption";
341 // Disables (unprefixed) Encrypted Media Extensions.
342 const char kDisableEncryptedMedia[] = "disable-encrypted-media";
344 // Enable experimental canvas features, e.g. canvas 2D context attributes
345 const char kEnableExperimentalCanvasFeatures[] =
346 "enable-experimental-canvas-features";
348 // Enables Web Platform features that are in development.
349 const char kEnableExperimentalWebPlatformFeatures[] =
350 "enable-experimental-web-platform-features";
352 // Enables TRACE for GL calls in the renderer.
353 const char kEnableGpuClientTracing[] = "enable-gpu-client-tracing";
355 // Allow heuristics to determine when a layer tile should be drawn with the
356 // Skia GPU backend. Only valid with GPU accelerated compositing +
357 // impl-side painting.
358 const char kEnableGpuRasterization[] = "enable-gpu-rasterization";
360 // When using CPU rasterizing generate low resolution tiling. Low res
361 // tiles may be displayed during fast scrolls especially on slower devices.
362 const char kEnableLowResTiling[] = "enable-low-res-tiling";
364 // Dynamically apply color profiles to web content images.
365 const char kEnableImageColorProfiles[] = "enable-image-color-profiles";
367 // Force logging to be enabled. Logging is disabled by default in release
368 // builds.
369 const char kEnableLogging[] = "enable-logging";
371 // Enables the memory benchmarking extension
372 const char kEnableMemoryBenchmarking[] = "enable-memory-benchmarking";
374 // Enables the network information API.
375 const char kEnableNetworkInformation[] = "enable-network-information";
377 // Enable rasterizer that writes directly to GPU memory.
378 const char kEnableOneCopy[] = "enable-one-copy";
380 // Enables use of hardware overlay for fullscreen video playback. Android only.
381 const char kEnableOverlayFullscreenVideo[] = "enable-overlay-fullscreen-video";
383 // Enables compositor-accelerated touch-screen pinch gestures.
384 const char kEnablePinch[] = "enable-pinch";
386 // Make the values returned to window.performance.memory more granular and more
387 // up to date in shared worker. Without this flag, the memory information is
388 // still available, but it is bucketized and updated less frequently. This flag
389 // also applys to workers.
390 const char kEnablePreciseMemoryInfo[] = "enable-precise-memory-info";
392 // Enables payloads for received push messages when using the W3C Push API.
393 const char kEnablePushMessagePayload[] = "enable-push-message-payload";
395 // Enable hasPermission() method of the W3C Push API.
396 const char kEnablePushMessagingHasPermission[] =
397 "enable-push-messaging-has-permission";
399 // Set options to cache V8 data. (off, preparse data, or code)
400 const char kV8CacheOptions[] = "v8-cache-options";
402 // Signals that the V8 natives file has been transfered to the child process
403 // by a file descriptor.
404 const char kV8NativesPassedByFD[] = "v8-natives-passed-by-fd";
406 // Signals that the V8 startup snapshot file has been transfered to the child
407 // process by a file descriptor.
408 const char kV8SnapshotPassedByFD[] = "v8-snapshot-passed-by-fd";
410 // Enables the CSS multicol implementation that uses the regions implementation.
411 const char kEnableRegionBasedColumns[] =
412 "enable-region-based-columns";
414 // Cause the OS X sandbox write to syslog every time an access to a resource
415 // is denied by the sandbox.
416 const char kEnableSandboxLogging[] = "enable-sandbox-logging";
418 // Enables seccomp-bpf support for Android. Requires experimental kernel
419 // support. <http://crbug.com/166704>
420 const char kEnableSeccompFilterSandbox[] =
421 "enable-seccomp-filter-sandbox";
423 // Enables the Skia benchmarking extension
424 const char kEnableSkiaBenchmarking[] = "enable-skia-benchmarking";
426 // Enables slimming paint: http://www.chromium.org/blink/slimming-paint
427 const char kEnableSlimmingPaint[] = "enable-slimming-paint";
429 // On platforms that support it, enables smooth scroll animation.
430 const char kEnableSmoothScrolling[] = "enable-smooth-scrolling";
432 // Enable spatial navigation
433 const char kEnableSpatialNavigation[] = "enable-spatial-navigation";
435 // Enables implementation of the Cache-Control: stale-while-revalidate directive
436 // which permits servers to allow the use of stale resources while revalidation
437 // proceeds in the background.
438 const char kEnableStaleWhileRevalidate[] = "enable-stale-while-revalidate";
440 // Enables StatsTable, logging statistics to a global named shared memory table.
441 const char kEnableStatsTable[] = "enable-stats-table";
443 // Experimentally ensures that each renderer process:
444 // 1) Only handles rendering for pages from a single site, apart from iframes.
445 // (Note that a page can reference content from multiple origins due to images,
446 // JavaScript files, etc. Cross-site iframes are also loaded in-process.)
447 // 2) Only has authority to see or use cookies for the page's top-level origin.
448 // (So if a.com iframes b.com, the b.com network request will be sent without
449 // cookies.)
450 // This is expected to break compatibility with many pages for now. Unlike the
451 // --site-per-process flag, this allows cross-site iframes, but it blocks all
452 // cookies on cross-site requests.
453 const char kEnableStrictSiteIsolation[] = "enable-strict-site-isolation";
455 // Blocks all insecure requests from secure contexts, and prevents the user
456 // from overriding that decision.
457 const char kEnableStrictMixedContentChecking[] =
458 "enable-strict-mixed-content-checking";
460 // Blocks insecure usage of number of powerful features (geolocation, for
461 // example) that we haven't yet deprecated for the web at large.
462 const char kEnableStrictPowerfulFeatureRestrictions[] =
463 "enable-strict-powerful-feature-restrictions";
465 // Enable support for sync events in ServiceWorkers.
466 const char kEnableServiceWorkerSync[] = "enable-service-worker-sync";
468 // Enable use of experimental TCP sockets API for sending data in the
469 // SYN packet.
470 const char kEnableTcpFastOpen[] = "enable-tcp-fastopen";
472 // Enabled threaded compositing for layout tests.
473 const char kEnableThreadedCompositing[] = "enable-threaded-compositing";
475 // Enable tracing during the execution of browser tests.
476 const char kEnableTracing[] = "enable-tracing";
478 // The filename to write the output of the test tracing to.
479 const char kEnableTracingOutput[] = "enable-tracing-output";
481 // Enable screen capturing support for MediaStream API.
482 const char kEnableUserMediaScreenCapturing[] =
483 "enable-usermedia-screen-capturing";
485 // Enables the use of the @viewport CSS rule, which allows
486 // pages to control aspects of their own layout. This also turns on touch-screen
487 // pinch gestures.
488 const char kEnableViewport[] = "enable-viewport";
490 // Enables the viewport meta tag, the de facto way to control layout which works
491 // only on mobile browsers.
492 const char kEnableViewportMeta[] = "enable-viewport-meta";
494 // Resizes of the main frame are the caused by changing between landscape
495 // and portrait mode (i.e. Android) so the page should be rescaled to fit
496 const char kMainFrameResizesAreOrientationChanges[] =
497 "main-frame-resizes-are-orientation-changes";
499 // Enable the Vtune profiler support.
500 const char kEnableVtune[] = "enable-vtune-support";
502 // Enables WebGL extensions not yet approved by the community.
503 const char kEnableWebGLDraftExtensions[] = "enable-webgl-draft-extensions";
505 // Enables WebGL rendering into a scanout buffer for overlay support.
506 const char kEnableWebGLImageChromium[] = "enable-webgl-image-chromium";
508 // Enable rasterizer that writes directly to GPU memory associated with tiles.
509 const char kEnableZeroCopy[] = "enable-zero-copy";
511 // Explicitly allows additional ports using a comma-separated list of port
512 // numbers.
513 const char kExplicitlyAllowedPorts[] = "explicitly-allowed-ports";
515 // Load NPAPI plugins from the specified directory.
516 const char kExtraPluginDir[] = "extra-plugin-dir";
518 // This option can be used to force field trials when testing changes locally.
519 // The argument is a list of name and value pairs, separated by slashes. If a
520 // trial name is prefixed with an asterisk, that trial will start activated.
521 // For example, the following argument defines two trials, with the second one
522 // activated: "GoogleNow/Enable/*MaterialDesignNTP/Default/"
523 // This option is also used by the browser to send the list of trials to
524 // renderers, using the same format. See
525 // FieldTrialList::CreateTrialsFromString() in field_trial.h for details.
526 const char kForceFieldTrials[] = "force-fieldtrials";
528 // Always use the Skia GPU backend for drawing layer tiles. Only valid with GPU
529 // accelerated compositing + impl-side painting. Overrides the
530 // kEnableGpuRasterization flag.
531 const char kForceGpuRasterization[] = "force-gpu-rasterization";
533 // The number of multisample antialiasing samples for GPU rasterization.
534 // Requires MSAA support on GPU to have an effect. 0 disables MSAA.
535 const char kGpuRasterizationMSAASampleCount[] =
536 "gpu-rasterization-msaa-sample-count";
538 // Force renderer accessibility to be on instead of enabling it on demand when
539 // a screen reader is detected. The disable-renderer-accessibility switch
540 // overrides this if present.
541 const char kForceRendererAccessibility[] = "force-renderer-accessibility";
543 // Always use text blob rendering, overriding kDisableTextBlobs and any
544 // heuristics that may otherwise disable it.
545 // TODO(fmalita): remove after --disable-impl-side-painting is phased out.
546 const char kForceTextBlobs[] = "force-text-blobs";
548 // Passes gpu device_id from browser process to GPU process.
549 const char kGpuDeviceID[] = "gpu-device-id";
551 // Passes gpu driver_vendor from browser process to GPU process.
552 const char kGpuDriverVendor[] = "gpu-driver-vendor";
554 // Passes gpu driver_version from browser process to GPU process.
555 const char kGpuDriverVersion[] = "gpu-driver-version";
557 // Extra command line options for launching the GPU process (normally used
558 // for debugging). Use like renderer-cmd-prefix.
559 const char kGpuLauncher[] = "gpu-launcher";
561 // Makes this process a GPU sub-process.
562 const char kGpuProcess[] = "gpu-process";
564 // Allows shmat() system call in the GPU sandbox.
565 const char kGpuSandboxAllowSysVShm[] = "gpu-sandbox-allow-sysv-shm";
567 // Makes GPU sandbox failures fatal.
568 const char kGpuSandboxFailuresFatal[] = "gpu-sandbox-failures-fatal";
570 // Starts the GPU sandbox before creating a GL context.
571 const char kGpuSandboxStartEarly[] = "gpu-sandbox-start-early";
573 // Causes the GPU process to display a dialog on launch.
574 const char kGpuStartupDialog[] = "gpu-startup-dialog";
576 // Passes gpu vendor_id from browser process to GPU process.
577 const char kGpuVendorID[] = "gpu-vendor-id";
579 // These mappings only apply to the host resolver.
580 const char kHostResolverRules[] = "host-resolver-rules";
582 // Ignores certificate-related errors.
583 const char kIgnoreCertificateErrors[] = "ignore-certificate-errors";
585 // Ignores GPU blacklist.
586 const char kIgnoreGpuBlacklist[] = "ignore-gpu-blacklist";
588 // Run the GPU process as a thread in the browser process.
589 const char kInProcessGPU[] = "in-process-gpu";
591 // Overrides the timeout, in seconds, that a child process waits for a
592 // connection from the browser before killing itself.
593 const char kIPCConnectionTimeout[] = "ipc-connection-timeout";
595 // Specifies the flags passed to JS engine
596 const char kJavaScriptFlags[] = "js-flags";
598 // Load an NPAPI plugin from the specified path.
599 const char kLoadPlugin[] = "load-plugin";
601 // Logs GPU control list decisions when enforcing blacklist rules.
602 const char kLogGpuControlListDecisions[] = "log-gpu-control-list-decisions";
604 // Sets the minimum log level. Valid values are from 0 to 3:
605 // INFO = 0, WARNING = 1, LOG_ERROR = 2, LOG_FATAL = 3.
606 const char kLoggingLevel[] = "log-level";
608 // Enables saving net log events to a file and sets the file name to use.
609 const char kLogNetLog[] = "log-net-log";
611 // Make plugin processes log their sent and received messages to VLOG(1).
612 const char kLogPluginMessages[] = "log-plugin-messages";
614 // Sets the width and height above which a composited layer will get tiled.
615 const char kMaxUntiledLayerHeight[] = "max-untiled-layer-height";
616 const char kMaxUntiledLayerWidth[] = "max-untiled-layer-width";
618 // Sample memory usage with high frequency and store the results to the
619 // Renderer.Memory histogram. Used in memory tests.
620 const char kMemoryMetrics[] = "memory-metrics";
622 // Mutes audio sent to the audio device so it is not audible during
623 // automated testing.
624 const char kMuteAudio[] = "mute-audio";
626 // Don't send HTTP-Referer headers.
627 const char kNoReferrers[] = "no-referrers";
629 // Disables the sandbox for all process types that are normally sandboxed.
630 const char kNoSandbox[] = "no-sandbox";
632 // Number of worker threads used to rasterize content.
633 const char kNumRasterThreads[] = "num-raster-threads";
635 // Controls the behavior of history navigation in response to horizontal
636 // overscroll.
637 // Set the value to '0' to disable.
638 // Set the value to '1' to enable the behavior where pages slide in and out in
639 // response to the horizontal overscroll gesture and a screenshot of the target
640 // page is shown.
641 // Set the value to '2' to enable the simplified overscroll UI where a
642 // navigation arrow slides in from the side of the screen in response to the
643 // horizontal overscroll gesture.
644 // Defaults to '1'.
645 const char kOverscrollHistoryNavigation[] =
646 "overscroll-history-navigation";
648 // Specifies a command that should be used to launch the plugin process. Useful
649 // for running the plugin process through purify or quantify. Ex:
650 // --plugin-launcher="path\to\purify /Run=yes"
651 const char kPluginLauncher[] = "plugin-launcher";
653 // Tells the plugin process the path of the plugin to load
654 const char kPluginPath[] = "plugin-path";
656 // Causes the process to run as a plugin subprocess.
657 const char kPluginProcess[] = "plugin";
659 // Causes the plugin process to display a dialog on launch.
660 const char kPluginStartupDialog[] = "plugin-startup-dialog";
662 // Argument to the process type that indicates a PPAPI broker process type.
663 const char kPpapiBrokerProcess[] = "ppapi-broker";
665 // "Command-line" arguments for the PPAPI Flash; used for debugging options.
666 const char kPpapiFlashArgs[] = "ppapi-flash-args";
668 // Runs PPAPI (Pepper) plugins in-process.
669 const char kPpapiInProcess[] = "ppapi-in-process";
671 // Like kPluginLauncher for PPAPI plugins.
672 const char kPpapiPluginLauncher[] = "ppapi-plugin-launcher";
674 // Argument to the process type that indicates a PPAPI plugin process type.
675 const char kPpapiPluginProcess[] = "ppapi";
677 // Causes the PPAPI sub process to display a dialog on launch. Be sure to use
678 // --no-sandbox as well or the sandbox won't allow the dialog to display.
679 const char kPpapiStartupDialog[] = "ppapi-startup-dialog";
681 // Runs a single process for each site (i.e., group of pages from the same
682 // registered domain) the user visits. We default to using a renderer process
683 // for each site instance (i.e., group of pages from the same registered
684 // domain with script connections to each other).
685 const char kProcessPerSite[] = "process-per-site";
687 // Runs each set of script-connected tabs (i.e., a BrowsingInstance) in its own
688 // renderer process. We default to using a renderer process for each
689 // site instance (i.e., group of pages from the same registered domain with
690 // script connections to each other).
691 const char kProcessPerTab[] = "process-per-tab";
693 // The value of this switch determines whether the process is started as a
694 // renderer or plugin host. If it's empty, it's the browser.
695 const char kProcessType[] = "type";
697 // Enables more web features over insecure connections. Designed to be used
698 // for testing purposes only.
699 const char kReduceSecurityForTesting[] = "reduce-security-for-testing";
701 // Register Pepper plugins (see pepper_plugin_list.cc for its format).
702 const char kRegisterPepperPlugins[] = "register-pepper-plugins";
704 // Enables remote debug over HTTP on the specified port.
705 const char kRemoteDebuggingPort[] = "remote-debugging-port";
707 // The contents of this flag are prepended to the renderer command line.
708 // Useful values might be "valgrind" or "xterm -e gdb --args".
709 const char kRendererCmdPrefix[] = "renderer-cmd-prefix";
711 // Causes the process to run as renderer instead of as browser.
712 const char kRendererProcess[] = "renderer";
714 // Overrides the default/calculated limit to the number of renderer processes.
715 // Very high values for this setting can lead to high memory/resource usage
716 // or instability.
717 const char kRendererProcessLimit[] = "renderer-process-limit";
719 // Causes the renderer process to display a dialog on launch.
720 const char kRendererStartupDialog[] = "renderer-startup-dialog";
722 // Reduce the default `referer` header's granularity.
723 const char kReducedReferrerGranularity[] =
724 "reduced-referrer-granularity";
726 // Handles frame scrolls via the root RenderLayer instead of the FrameView.
727 const char kRootLayerScrolls[] = "root-layer-scrolls";
729 // Causes the process to run as a sandbox IPC subprocess.
730 const char kSandboxIPCProcess[] = "sandbox-ipc";
732 // Enables or disables scroll end effect in response to vertical overscroll.
733 // Set the value to '1' to enable the feature, and set to '0' to disable.
734 // Defaults to disabled.
735 const char kScrollEndEffect[] = "scroll-end-effect";
737 // Visibly render a border around paint rects in the web page to help debug
738 // and study painting behavior.
739 const char kShowPaintRects[] = "show-paint-rects";
741 // Runs the renderer and plugins in the same process as the browser
742 const char kSingleProcess[] = "single-process";
744 // Experimentally enforces a one-site-per-process security policy.
745 // All cross-site navigations force process swaps, and we can restrict a
746 // renderer process's access rights based on its site. For details, see:
747 // http://www.chromium.org/developers/design-documents/site-isolation
749 // Unlike --enable-strict-site-isolation (which allows cross-site iframes),
750 // this flag does not affect which cookies are attached to cross-site requests.
751 // Support is being added to render cross-site iframes in a different process
752 // than their parent pages.
753 const char kSitePerProcess[] = "site-per-process";
755 // Skip gpu info collection, blacklist loading, and blacklist auto-update
756 // scheduling at browser startup time.
757 // Therefore, all GPU features are available, and about:gpu page shows empty
758 // content. The switch is intended only for layout tests.
759 // TODO(gab): Get rid of this switch entirely.
760 const char kSkipGpuDataLoading[] = "skip-gpu-data-loading";
762 // Specifies if the browser should start in fullscreen mode, like if the user
763 // had pressed F11 right after startup.
764 const char kStartFullscreen[] = "start-fullscreen";
766 // Specifies if the |StatsCollectionController| needs to be bound in the
767 // renderer. This binding happens on per-frame basis and hence can potentially
768 // be a performance bottleneck. One should only enable it when running a test
769 // that needs to access the provided statistics.
770 const char kStatsCollectionController[] =
771 "enable-stats-collection-bindings";
773 // Upscale defaults to "good".
774 const char kTabCaptureDownscaleQuality[] = "tab-capture-downscale-quality";
776 // Scaling quality for capturing tab. Should be one of "fast", "good" or "best".
777 // One flag for upscaling, one for downscaling.
778 // Upscale defaults to "best".
779 const char kTabCaptureUpscaleQuality[] = "tab-capture-upscale-quality";
781 // Allows for forcing socket connections to http/https to use fixed ports.
782 const char kTestingFixedHttpPort[] = "testing-fixed-http-port";
783 const char kTestingFixedHttpsPort[] = "testing-fixed-https-port";
785 // Type of the current test harness ("browser" or "ui").
786 const char kTestType[] = "test-type";
788 // Causes TRACE_EVENT flags to be recorded beginning with shutdown. Optionally,
789 // can specify the specific trace categories to include (e.g.
790 // --trace-shutdown=base,net) otherwise, all events are recorded.
791 // --trace-shutdown-file can be used to control where the trace log gets stored
792 // to since there is otherwise no way to access the result.
793 const char kTraceShutdown[] = "trace-shutdown";
795 // If supplied, sets the file which shutdown tracing will be stored into, if
796 // omitted the default will be used "chrometrace.log" in the current directory.
797 // Has no effect unless --trace-shutdown is also supplied.
798 // Example: --trace-shutdown --trace-shutdown-file=/tmp/trace_event.log
799 const char kTraceShutdownFile[] = "trace-shutdown-file";
801 // Causes TRACE_EVENT flags to be recorded from startup. Optionally, can
802 // specify the specific trace categories to include (e.g.
803 // --trace-startup=base,net) otherwise, all events are recorded. Setting this
804 // flag results in the first call to BeginTracing() to receive all trace events
805 // since startup. In Chrome, you may find --trace-startup-file and
806 // --trace-startup-duration to control the auto-saving of the trace (not
807 // supported in the base-only TraceLog component).
808 const char kTraceStartup[] = "trace-startup";
810 // Sets the time in seconds until startup tracing ends. If omitted a default of
811 // 5 seconds is used. Has no effect without --trace-startup, or if
812 // --startup-trace-file=none was supplied.
813 const char kTraceStartupDuration[] = "trace-startup-duration";
815 // If supplied, sets the file which startup tracing will be stored into, if
816 // omitted the default will be used "chrometrace.log" in the current directory.
817 // Has no effect unless --trace-startup is also supplied.
818 // Example: --trace-startup --trace-startup-file=/tmp/trace_event.log
819 // As a special case, can be set to 'none' - this disables automatically saving
820 // the result to a file and the first manually recorded trace will then receive
821 // all events since startup.
822 const char kTraceStartupFile[] = "trace-startup-file";
824 // Sets the target URL for uploading tracing data.
825 const char kTraceUploadURL[] = "trace-upload-url";
828 // Prioritizes the UI's command stream in the GPU process
829 extern const char kUIPrioritizeInGpuProcess[] =
830 "ui-prioritize-in-gpu-process";
832 // Bypass the media stream infobar by selecting the default device for media
833 // streams (e.g. WebRTC). Works with --use-fake-device-for-media-stream.
834 const char kUseFakeUIForMediaStream[] = "use-fake-ui-for-media-stream";
836 // Enable native GPU memory buffer support when available.
837 const char kEnableNativeGpuMemoryBuffers[] = "enable-native-gpu-memory-buffers";
839 // Overrides the default texture target used with CHROMIUM_image extension.
840 const char kUseImageTextureTarget[] = "use-image-texture-target";
842 // Set when Chromium should use a mobile user agent.
843 const char kUseMobileUserAgent[] = "use-mobile-user-agent";
845 // Use normal priority for tile task worker threads. Otherwise they may
846 // be run at background priority on some platforms.
847 const char kUseNormalPriorityForTileTaskWorkerThreads[] =
848 "use-normal-priority-for-tile-task-worker-threads";
850 // Use the new surfaces system to handle compositor delegation.
851 const char kUseSurfaces[] = "use-surfaces";
853 // Disable the use of the new surfaces system to handle compositor delegation.
854 const char kDisableSurfaces[] = "disable-surfaces";
856 // The contents of this flag are prepended to the utility process command line.
857 // Useful values might be "valgrind" or "xterm -e gdb --args".
858 const char kUtilityCmdPrefix[] = "utility-cmd-prefix";
860 // Causes the process to run as a utility subprocess.
861 const char kUtilityProcess[] = "utility";
863 // The utility process is sandboxed, with access to one directory. This flag
864 // specifies the directory that can be accessed.
865 const char kUtilityProcessAllowedDir[] = "utility-allowed-dir";
867 // Allows MDns to access network in sandboxed process.
868 const char kUtilityProcessEnableMDns[] = "utility-enable-mdns";
870 const char kUtilityProcessRunningElevated[] = "utility-run-elevated";
872 // In debug builds, asserts that the stream of input events is valid.
873 const char kValidateInputEventStream[] = "validate-input-event-stream";
875 // Will add kWaitForDebugger to every child processes. If a value is passed, it
876 // will be used as a filter to determine if the child process should have the
877 // kWaitForDebugger flag passed on or not.
878 const char kWaitForDebuggerChildren[] = "wait-for-debugger-children";
880 // The prefix used when starting the zygote process. (i.e. 'gdb --args')
881 const char kZygoteCmdPrefix[] = "zygote-cmd-prefix";
883 // Causes the process to run as a renderer zygote.
884 const char kZygoteProcess[] = "zygote";
886 #if defined(ENABLE_WEBRTC)
887 // Disables HW decode acceleration for WebRTC.
888 const char kDisableWebRtcHWDecoding[] = "disable-webrtc-hw-decoding";
890 // Disables encryption of RTP Media for WebRTC. When Chrome embeds Content, it
891 // ignores this switch on its stable and beta channels.
892 const char kDisableWebRtcEncryption[] = "disable-webrtc-encryption";
894 // Disables HW encode acceleration for WebRTC.
895 const char kDisableWebRtcHWEncoding[] = "disable-webrtc-hw-encoding";
897 // Enables H264 HW encode acceleration for WebRTC.
898 const char kEnableWebRtcHWH264Encoding[] = "enable-webrtc-hw-h264-encoding";
900 // Enables Origin header in Stun messages for WebRTC.
901 const char kEnableWebRtcStunOrigin[] = "enable-webrtc-stun-origin";
903 // Override the maximum framerate as can be specified in calls to getUserMedia.
904 // This flag expects a value. Example: --max-gum-fps=17.5
905 const char kWebRtcMaxCaptureFramerate[] = "max-gum-fps";
906 #endif
908 #if defined(OS_ANDROID)
909 // Disable user gesture requirement for media playback.
910 const char kDisableGestureRequirementForMediaPlayback[] =
911 "disable-gesture-requirement-for-media-playback";
913 // Disable the click delay by sending click events during double tap.
914 const char kDisableClickDelay[] = "disable-click-delay";
916 // Disable overscroll edge effects like those found in Android views.
917 const char kDisableOverscrollEdgeEffect[] = "disable-overscroll-edge-effect";
919 // Disable the pull-to-refresh effect when vertically overscrolling content.
920 const char kDisablePullToRefreshEffect[] = "disable-pull-to-refresh-effect";
922 // Disable the locking feature of the screen orientation API.
923 const char kDisableScreenOrientationLock[] = "disable-screen-orientation-lock";
925 // WebRTC is enabled by default on Android.
926 const char kDisableWebRTC[] = "disable-webrtc";
928 // The telephony region (ISO country code) to use in phone number detection.
929 const char kNetworkCountryIso[] = "network-country-iso";
931 // Enables remote debug over HTTP on the specified socket name.
932 const char kRemoteDebuggingSocketName[] = "remote-debugging-socket-name";
934 // Block ChildProcessMain thread of the renderer's ChildProcessService until a
935 // Java debugger is attached.
936 const char kRendererWaitForJavaDebugger[] = "renderer-wait-for-java-debugger";
937 #endif
939 // Disable web audio API.
940 const char kDisableWebAudio[] = "disable-webaudio";
942 #if defined(OS_CHROMEOS)
943 // Disables panel fitting (used for mirror mode).
944 const char kDisablePanelFitting[] = "disable-panel-fitting";
946 // Disables VA-API accelerated video encode.
947 const char kDisableVaapiAcceleratedVideoEncode[] =
948 "disable-vaapi-accelerated-video-encode";
949 #endif
951 #if defined(OS_LINUX) && !defined(OS_CHROMEOS)
952 // Allows sending text-to-speech requests to speech-dispatcher, a common
953 // Linux speech service. Because it's buggy, the user must explicitly
954 // enable it so that visiting a random webpage can't cause instability.
955 const char kEnableSpeechDispatcher[] = "enable-speech-dispatcher";
956 #endif
958 #if defined(OS_MACOSX) && !defined(OS_IOS)
959 // Disables support for Core Animation plugins. This is triggered when
960 // accelerated compositing is disabled. See http://crbug.com/122430.
961 const char kDisableCoreAnimationPlugins[] =
962 "disable-core-animation-plugins";
963 #endif
965 #if defined(OS_WIN)
966 // Device scale factor passed to certain processes like renderers, etc.
967 const char kDeviceScaleFactor[] = "device-scale-factor";
969 // Disable the Legacy Window which corresponds to the size of the WebContents.
970 const char kDisableLegacyIntermediateWindow[] = "disable-legacy-window";
972 // Enables or disables the Win32K process mitigation policy for renderer
973 // processes which prevents them from invoking user32 and gdi32 system calls
974 // which enter the kernel. This is only supported on Windows 8 and beyond.
975 const char kDisableWin32kRendererLockDown[] =
976 "disable-win32k-renderer-lockdown";
977 const char kEnableWin32kRendererLockDown[] =
978 "enable-win32k-renderer-lockdown";
980 // DirectWrite FontCache is shared by browser to renderers using shared memory.
981 // This switch allows specifying suffix to shared memory section name to avoid
982 // clashes between different instances of Chrome.
983 const char kFontCacheSharedMemSuffix[] = "font-cache-shared-mem-suffix";
985 // Enables the exporting of the tracing events to ETW. This is only supported on
986 // Windows Vista and later.
987 const char kTraceExportEventsToETW[] = "trace-export-events-to-etw";
988 #endif
990 // Enables the use of NPAPI plugins.
991 const char kEnableNpapi[] = "enable-npapi";
993 // Don't dump stuff here, follow the same order as the header.
995 } // namespace switches