1// Copyright 2013 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. 4 5#include "extensions/common/manifest_constants.h" 6 7namespace extensions { 8 9namespace manifest_keys { 10 11const char kAboutPage[] = "about_page"; 12const char kAllFrames[] = "all_frames"; 13const char kAltKey[] = "altKey"; 14const char kApp[] = "app"; 15const char kAutomation[] = "automation"; 16const char kBackgroundAllowJsAccess[] = "background.allow_js_access"; 17const char kBackgroundPage[] = "background.page"; 18const char kBackgroundPageLegacy[] = "background_page"; 19const char kBackgroundPersistent[] = "background.persistent"; 20const char kBackgroundScripts[] = "background.scripts"; 21const char kBluetooth[] = "bluetooth"; 22const char kBookmarkUI[] = "bookmarks_ui"; 23const char kBrowserAction[] = "browser_action"; 24const char kChromeURLOverrides[] = "chrome_url_overrides"; 25const char kCommands[] = "commands"; 26const char kContentPack[] = "content_pack"; 27const char kContentPackSites[] = "sites"; 28const char kContentScripts[] = "content_scripts"; 29const char kContentSecurityPolicy[] = "content_security_policy"; 30const char kConvertedFromUserScript[] = "converted_from_user_script"; 31const char kCss[] = "css"; 32const char kCtrlKey[] = "ctrlKey"; 33const char kCurrentLocale[] = "current_locale"; 34const char kDefaultLocale[] = "default_locale"; 35const char kDescription[] = "description"; 36const char kDevToolsPage[] = "devtools_page"; 37const char kDisplayInLauncher[] = "display_in_launcher"; 38const char kDisplayInNewTabPage[] = "display_in_new_tab_page"; 39const char kEventName[] = "event_name"; 40const char kExcludeGlobs[] = "exclude_globs"; 41const char kExcludeMatches[] = "exclude_matches"; 42const char kExport[] = "export"; 43const char kExternallyConnectable[] = "externally_connectable"; 44const char kFileAccessList[] = "file_access"; 45const char kFileFilters[] = "file_filters"; 46const char kFileBrowserHandlers[] = "file_browser_handlers"; 47const char kFileHandlers[] = "file_handlers"; 48const char kFileHandlerExtensions[] = "extensions"; 49const char kFileHandlerTypes[] = "types"; 50const char kGlobal[] = "global"; 51const char kHideBookmarkButton[] = "hide_bookmark_button"; 52const char kHomepageURL[] = "homepage_url"; 53const char kIcons[] = "icons"; 54const char kId[] = "id"; 55const char kImeOptionsPage[] = "options_page"; 56const char kImport[] = "import"; 57const char kIncognito[] = "incognito"; 58const char kIncludeGlobs[] = "include_globs"; 59const char kInputComponents[] = "input_components"; 60const char kInputView[] = "input_view"; 61const char kIsolation[] = "app.isolation"; 62const char kJs[] = "js"; 63const char kKey[] = "key"; 64const char kKeycode[] = "keyCode"; 65const char kKioskEnabled[] = "kiosk_enabled"; 66const char kKioskOnly[] = "kiosk_only"; 67const char kKioskMode[] = "kiosk_mode"; 68const char kLanguage[] = "language"; 69const char kLaunch[] = "app.launch"; 70const char kLaunchContainer[] = "app.launch.container"; 71const char kLauncherPage[] = "launcher_page"; 72const char kLauncherPagePage[] = "launcher_page.page"; 73const char kLaunchHeight[] = "app.launch.height"; 74const char kLaunchLocalPath[] = "app.launch.local_path"; 75const char kLaunchWebURL[] = "app.launch.web_url"; 76const char kLaunchWidth[] = "app.launch.width"; 77const char kLayouts[] = "layouts"; 78const char kManifestVersion[] = "manifest_version"; 79const char kMatchAboutBlank[] = "match_about_blank"; 80const char kMatches[] = "matches"; 81const char kMinimumChromeVersion[] = "minimum_chrome_version"; 82const char kMinimumVersion[] = "minimum_version"; 83const char kMIMETypes[] = "mime_types"; 84const char kMimeTypesHandler[] = "mime_types_handler"; 85const char kName[] = "name"; 86const char kNaClArch[] = "nacl_arch"; 87const char kNaClModules[] = "nacl_modules"; 88const char kNaClModulesMIMEType[] = "mime_type"; 89const char kNaClModulesPath[] = "path"; 90const char kOAuth2[] = "oauth2"; 91const char kOAuth2AutoApprove[] = "oauth2.auto_approve"; 92const char kOAuth2ClientId[] = "oauth2.client_id"; 93const char kOAuth2Scopes[] = "oauth2.scopes"; 94const char kOfflineEnabled[] = "offline_enabled"; 95const char kOmnibox[] = "omnibox"; 96const char kOmniboxKeyword[] = "omnibox.keyword"; 97const char kOptionalPermissions[] = "optional_permissions"; 98const char kOptionsPage[] = "options_page"; 99const char kOptionsUI[] = "options_ui"; 100const char kOverrideHomepage[] = "chrome_settings_overrides.homepage"; 101const char kOverrideSearchProvider[] = 102 "chrome_settings_overrides.search_provider"; 103const char kOverrideStartupPage[] = "chrome_settings_overrides.startup_pages"; 104const char kPageAction[] = "page_action"; 105const char kPageActionDefaultIcon[] = "default_icon"; 106const char kPageActionDefaultPopup[] = "default_popup"; 107const char kPageActionDefaultTitle[] = "default_title"; 108const char kPageActionIcons[] = "icons"; 109const char kPageActionId[] = "id"; 110const char kPageActionPopup[] = "popup"; 111const char kPageActionPopupPath[] = "path"; 112const char kPageActions[] = "page_actions"; 113const char kPermissions[] = "permissions"; 114const char kPlatformAppBackground[] = "app.background"; 115const char kPlatformAppBackgroundPage[] = "app.background.page"; 116const char kPlatformAppBackgroundScripts[] = "app.background.scripts"; 117const char kPlatformAppContentSecurityPolicy[] = "app.content_security_policy"; 118const char kPlatforms[] = "platforms"; 119const char kPlugins[] = "plugins"; 120const char kPluginsPath[] = "path"; 121const char kPluginsPublic[] = "public"; 122const char kPublicKey[] = "key"; 123const char kRemoveButton[] = "remove_button"; 124const char kResources[] = "resources"; 125const char kRequirements[] = "requirements"; 126const char kRunAt[] = "run_at"; 127const char kSandboxedPages[] = "sandbox.pages"; 128const char kSandboxedPagesCSP[] = "sandbox.content_security_policy"; 129const char kScriptBadge[] = "script_badge"; 130const char kSettingsOverride[] = "chrome_settings_overrides"; 131const char kSettingsOverrideAlternateUrls[] = 132 "chrome_settings_overrides.search_provider.alternate_urls"; 133const char kShiftKey[] = "shiftKey"; 134const char kShortcutKey[] = "shortcutKey"; 135const char kShortName[] = "short_name"; 136const char kSignature[] = "signature"; 137const char kSockets[] = "sockets"; 138const char kSpellcheck[] = "spellcheck"; 139const char kSpellcheckDictionaryFormat[] = "dictionary_format"; 140const char kSpellcheckDictionaryLanguage[] = "dictionary_language"; 141const char kSpellcheckDictionaryLocale[] = "dictionary_locale"; 142const char kSpellcheckDictionaryPath[] = "dictionary_path"; 143const char kStorageManagedSchema[] = "storage.managed_schema"; 144const char kSubPackagePath[] = "sub_package_path"; 145const char kSuggestedKey[] = "suggested_key"; 146const char kSynthesizeBrowserAction[] = "_synthesize_browser_action"; 147const char kSystemIndicator[] = "system_indicator"; 148const char kTheme[] = "theme"; 149const char kThemeColors[] = "colors"; 150const char kThemeDisplayProperties[] = "properties"; 151const char kThemeImages[] = "images"; 152const char kThemeTints[] = "tints"; 153const char kTtsEngine[] = "tts_engine"; 154const char kTtsGenderFemale[] = "female"; 155const char kTtsGenderMale[] = "male"; 156const char kTtsVoices[] = "voices"; 157const char kTtsVoicesEventTypeEnd[] = "end"; 158const char kTtsVoicesEventTypeError[] = "error"; 159const char kTtsVoicesEventTypeMarker[] = "marker"; 160const char kTtsVoicesEventTypeSentence[] = "sentence"; 161const char kTtsVoicesEventTypeStart[] = "start"; 162const char kTtsVoicesEventTypeWord[] = "word"; 163const char kTtsVoicesEventTypes[] = "event_types"; 164const char kTtsVoicesGender[] = "gender"; 165const char kTtsVoicesLang[] = "lang"; 166const char kTtsVoicesRemote[] = "remote"; 167const char kTtsVoicesVoiceName[] = "voice_name"; 168const char kType[] = "type"; 169const char kUIOverride[] = "chrome_ui_overrides"; 170const char kUpdateURL[] = "update_url"; 171const char kUrlHandlers[] = "url_handlers"; 172const char kUrlHandlerTitle[] = "title"; 173const char kVersion[] = "version"; 174const char kWebAccessibleResources[] = "web_accessible_resources"; 175const char kWebURLs[] = "app.urls"; 176const char kWebview[] = "webview"; 177const char kWebviewAccessibleResources[] = "accessible_resources"; 178const char kWebviewName[] = "name"; 179const char kWebviewPartitions[] = "partitions"; 180const char kWhitelist[] = "whitelist"; 181 182} // namespace manifest_keys 183 184namespace manifest_values { 185 186const char kBrowserActionCommandEvent[] = "_execute_browser_action"; 187const char kIncognitoSplit[] = "split"; 188const char kIncognitoSpanning[] = "spanning"; 189const char kIntentDispositionWindow[] = "window"; 190const char kIntentDispositionInline[] = "inline"; 191const char kIsolatedStorage[] = "storage"; 192const char kKeybindingPlatformChromeOs[] = "chromeos"; 193const char kKeybindingPlatformDefault[] = "default"; 194const char kKeybindingPlatformLinux[] = "linux"; 195const char kKeybindingPlatformMac[] = "mac"; 196const char kKeybindingPlatformWin[] = "windows"; 197const char kKeyAlt[] = "Alt"; 198const char kKeyComma[] = "Comma"; 199const char kKeyCommand[] = "Command"; 200const char kKeyCtrl[] = "Ctrl"; 201const char kKeyDel[] = "Delete"; 202const char kKeyDown[] = "Down"; 203const char kKeyEnd[] = "End"; 204const char kKeyHome[] = "Home"; 205const char kKeyIns[] = "Insert"; 206const char kKeyLeft[] = "Left"; 207const char kKeyMacCtrl[] = "MacCtrl"; 208const char kKeyMediaNextTrack[] = "MediaNextTrack"; 209const char kKeyMediaPlayPause[] = "MediaPlayPause"; 210const char kKeyMediaPrevTrack[] = "MediaPrevTrack"; 211const char kKeyMediaStop[] = "MediaStop"; 212const char kKeyPgDwn[] = "PageDown"; 213const char kKeyPgUp[] = "PageUp"; 214const char kKeyPeriod[] = "Period"; 215const char kKeyRight[] = "Right"; 216const char kKeySearch[] = "Search"; 217const char kKeySeparator[] = "+"; 218const char kKeyShift[] = "Shift"; 219const char kKeyTab[] = "Tab"; 220const char kKeyUp[] = "Up"; 221const char kRunAtDocumentStart[] = "document_start"; 222const char kRunAtDocumentEnd[] = "document_end"; 223const char kRunAtDocumentIdle[] = "document_idle"; 224const char kPageActionCommandEvent[] = "_execute_page_action"; 225const char kPageActionTypeTab[] = "tab"; 226const char kPageActionTypePermanent[] = "permanent"; 227const char kScriptBadgeCommandEvent[] = "_execute_script_badge"; 228const char kLaunchContainerPanel[] = "panel"; 229const char kLaunchContainerTab[] = "tab"; 230const char kLaunchContainerWindow[] = "window"; 231 232} // namespace manifest_values 233 234// Extension-related error messages. Some of these are simple patterns, where a 235// '*' is replaced at runtime with a specific value. This is used instead of 236// printf because we want to unit test them and scanf is hard to make 237// cross-platform. 238namespace manifest_errors { 239 240const char kActiveTabPermissionNotGranted[] = 241 "The 'activeTab' permission is not in effect because this extension has " 242 "not been in invoked."; 243const char kAllURLOrActiveTabNeeded[] = 244 "Either the '<all_urls>' or 'activeTab' permission is required."; 245const char kAppsNotEnabled[] = 246 "Apps are not enabled."; 247const char kBackgroundPermissionNeeded[] = 248 "Hosted apps that use 'background_page' must have the 'background' " 249 "permission."; 250const char kBackgroundRequiredForPlatformApps[] = 251 "Packaged apps must have a background page or background scripts."; 252const char kCannotAccessChromeUrl[] = "Cannot access a chrome:// URL"; 253const char kCannotAccessExtensionUrl[] = 254 "Cannot access a chrome-extension:// URL of different extension"; 255const char kCannotAccessPage[] = 256 "Cannot access contents of url \"*\". " 257 "Extension manifest must request permission to access this host."; 258const char kCannotChangeExtensionID[] = 259 "Installed extensions cannot change their IDs."; 260const char kCannotClaimAllHostsInExtent[] = 261 "Cannot claim all hosts ('*') in an extent."; 262const char kCannotClaimAllURLsInExtent[] = 263 "Cannot claim all URLs in an extent."; 264const char kCannotScriptGallery[] = 265 "The extensions gallery cannot be scripted."; 266const char kCannotScriptSigninPage[] = 267 "The sign-in page cannot be scripted."; 268const char kChromeVersionTooLow[] = 269 "This extension requires * version * or greater."; 270const char kDisabledByPolicy[] = 271 "This extension has been disabled by your administrator."; 272const char kExpectString[] = "Expect string value."; 273const char kExperimentalFlagRequired[] = 274 "Loading extensions with 'experimental' permission is turned off by " 275 "default. You can enable 'Experimental Extension APIs' " 276 "by visiting chrome://flags."; 277const char kInvalidAboutPage[] = "Invalid value for 'about_page'."; 278const char kInvalidAboutPageExpectRelativePath[] = 279 "Invalid value for 'about_page'. Value must be a relative path."; 280const char kInvalidAllFrames[] = 281 "Invalid value for 'content_scripts[*].all_frames'."; 282const char kInvalidBackground[] = 283 "Invalid value for 'background_page'."; 284const char kInvalidBackgroundAllowJsAccess[] = 285 "Invalid value for 'background.allow_js_access'."; 286const char kInvalidBackgroundCombination[] = 287 "The background.page and background.scripts properties cannot be used at " 288 "the same time."; 289const char kInvalidBackgroundScript[] = 290 "Invalid value for 'background.scripts[*]'."; 291const char kInvalidBackgroundScripts[] = 292 "Invalid value for 'background.scripts'."; 293const char kInvalidBackgroundInHostedApp[] = 294 "Invalid value for 'background_page'. Hosted apps must specify an " 295 "absolute HTTPS URL for the background page."; 296const char kInvalidBackgroundPersistent[] = 297 "Invalid value for 'background.persistent'."; 298const char kInvalidBackgroundPersistentNoPage[] = 299 "Must specify one of background.page or background.scripts to use" 300 " background.persistent."; 301const char kInvalidBrowserAction[] = 302 "Invalid value for 'browser_action'."; 303const char kInvalidChromeURLOverrides[] = 304 "Invalid value for 'chrome_url_overrides'."; 305const char kInvalidCommandsKey[] = 306 "Invalid value for 'commands'."; 307const char kInvalidContentPack[] = 308 "Invalid value for 'content_pack'."; 309const char kInvalidContentPackSites[] = 310 "Invalid value for Content Pack sites - files must be strings."; 311const char kInvalidContentScript[] = 312 "Invalid value for 'content_scripts[*]'."; 313const char kInvalidContentSecurityPolicy[] = 314 "Invalid value for 'content_security_policy'."; 315const char kInvalidContentScriptsList[] = 316 "Invalid value for 'content_scripts'."; 317const char kInvalidCss[] = 318 "Invalid value for 'content_scripts[*].css[*]'."; 319const char kInvalidCssList[] = 320 "Required value 'content_scripts[*].css' is invalid."; 321const char kInvalidDefaultLocale[] = 322 "Invalid value for default locale - locale name must be a string."; 323const char kInvalidDescription[] = 324 "Invalid value for 'description'."; 325const char kInvalidDevToolsPage[] = 326 "Invalid value for 'devtools_page'."; 327const char kInvalidDisplayInLauncher[] = 328 "Invalid value for 'display_in_launcher'."; 329const char kInvalidDisplayInNewTabPage[] = 330 "Invalid value for 'display_in_new_tab_page'."; 331const char kInvalidEmptyDictionary[] = "Empty dictionary for '*'."; 332const char kInvalidExcludeMatch[] = 333 "Invalid value for 'content_scripts[*].exclude_matches[*]': *"; 334const char kInvalidExcludeMatches[] = 335 "Invalid value for 'content_scripts[*].exclude_matches'."; 336const char kInvalidExport[] = 337 "Invalid value for 'export'."; 338const char kInvalidExportPermissions[] = 339 "Permissions are not allowed for extensions that export resources."; 340const char kInvalidExportResources[] = 341 "Invalid value for 'export.resources'."; 342const char kInvalidExportResourcesString[] = 343 "Invalid value for 'export.resources[*]'."; 344const char kInvalidExportWhitelist[] = 345 "Invalid value for 'export.whitelist'."; 346const char kInvalidExportWhitelistString[] = 347 "Invalid value for 'export.whitelist[*]'."; 348const char kInvalidFileAccessList[] = 349 "Invalid value for 'file_access'."; 350const char kInvalidFileAccessValue[] = 351 "Invalid value for 'file_access[*]'."; 352const char kInvalidFileBrowserHandler[] = 353 "Invalid value for 'file_browser_handlers'."; 354const char kInvalidFileFiltersList[] = 355 "Invalid value for 'file_filters'."; 356const char kInvalidFileFilterValue[] = 357 "Invalid value for 'file_filters[*]'."; 358const char kInvalidFileHandlers[] = 359 "Invalid value for 'file_handlers'."; 360const char kInvalidFileHandlersTooManyTypesAndExtensions[] = 361 "Too many MIME and extension file_handlers have been declared."; 362const char kInvalidFileHandlerExtension[] = 363 "Invalid value for 'file_handlers[*].extensions'."; 364const char kInvalidFileHandlerExtensionElement[] = 365 "Invalid value for 'file_handlers[*].extensions[*]'."; 366const char kInvalidFileHandlerNoTypeOrExtension[] = 367 "'file_handlers[*]' must contain a non-empty 'types' or 'extensions'."; 368const char kInvalidFileHandlerType[] = 369 "Invalid value for 'file_handlers[*].types'."; 370const char kInvalidFileHandlerTypeElement[] = 371 "Invalid value for 'file_handlers[*].types[*]'."; 372const char kInvalidGlob[] = 373 "Invalid value for 'content_scripts[*].*[*]'."; 374const char kInvalidGlobList[] = 375 "Invalid value for 'content_scripts[*].*'."; 376const char kInvalidHomepageOverrideURL[] = 377 "Invalid value for overriding homepage url: '[*]'."; 378const char kInvalidHomepageURL[] = 379 "Invalid value for homepage url: '[*]'."; 380const char kInvalidIconPath[] = 381 "Invalid value for 'icons[\"*\"]'."; 382const char kInvalidIcons[] = 383 "Invalid value for 'icons'."; 384const char kInvalidImport[] = 385 "Invalid value for 'import'."; 386const char kInvalidImportAndExport[] = 387 "Simultaneous 'import' and 'export' are not allowed."; 388const char kInvalidImportId[] = 389 "Invalid value for 'import[*].id'."; 390const char kInvalidImportVersion[] = 391 "Invalid value for 'import[*].minimum_version'."; 392const char kInvalidIncognitoBehavior[] = 393 "Invalid value for 'incognito'."; 394const char kInvalidInputComponents[] = 395 "Invalid value for 'input_components'"; 396const char kInvalidInputComponentDescription[] = 397 "Invalid value for 'input_components[*].description"; 398const char kInvalidInputComponentLayoutName[] = 399 "Invalid value for 'input_components[*].layouts[*]"; 400const char kInvalidInputComponentName[] = 401 "Invalid value for 'input_components[*].name"; 402const char kInvalidInputComponentShortcutKey[] = 403 "Invalid value for 'input_components[*].shortcutKey"; 404const char kInvalidInputComponentShortcutKeycode[] = 405 "Invalid value for 'input_components[*].shortcutKey.keyCode"; 406const char kInvalidInputComponentType[] = 407 "Invalid value for 'input_components[*].type"; 408const char kInvalidInputView[] = 409 "Invalid value for 'input_view'."; 410const char kInvalidIntent[] = 411 "Invalid value for intents[*]"; 412const char kInvalidIntentDisposition[] = 413 "Invalid value for intents[*].disposition"; 414const char kInvalidIntentDispositionInPlatformApp[] = 415 "Invalid value for intents[*].disposition. Packaged apps cannot specify " 416 "a disposition"; 417const char kInvalidIntentHref[] = 418 "Invalid value for intents[*].href"; 419const char kInvalidIntentHrefEmpty[] = 420 "Missing value for intents[*].href"; 421const char kInvalidIntentHrefInPlatformApp[] = 422 "Invalid value for intents[*].href. Packaged apps cannot specify a " 423 "URL for intents"; 424const char kInvalidIntentHrefOldAndNewKey[] = 425 "intents[*]: Key \"*\" is deprecated. Key \"*\" has the same meaning. " 426 "You can not use both."; 427const char kInvalidIntentPageInHostedApp[] = 428 "Invalid value for intents[*].href. Hosted apps must specify an " 429 "absolute URL within app.urls[]."; 430const char kInvalidIntents[] = 431 "Invalid value for intents"; 432const char kInvalidIntentType[] = 433 "Invalid value for intents[*].type"; 434const char kInvalidIntentTypeElement[] = 435 "Invalid value for intents[*].type[*]"; 436const char kInvalidIntentTitle[] = 437 "Invalid value for intents[*].title"; 438const char kInvalidIsolation[] = 439 "Invalid value for 'app.isolation'."; 440const char kInvalidIsolationValue[] = 441 "Invalid value for 'app.isolation[*]'."; 442const char kInvalidJs[] = 443 "Invalid value for 'content_scripts[*].js[*]'."; 444const char kInvalidJsList[] = 445 "Required value 'content_scripts[*].js' is invalid."; 446const char kInvalidKey[] = 447 "Value 'key' is missing or invalid."; 448const char kInvalidKeyBinding[] = 449 "Invalid value for 'commands[*].*': *."; 450const char kInvalidKeyBindingDescription[] = 451 "Invalid value for 'commands[*].description'."; 452const char kInvalidKeyBindingDictionary[] = 453 "Contents of 'commands[*]' invalid."; 454const char kInvalidKeyBindingMediaKeyWithModifier[] = 455 "Media key cannot have any modifier for 'commands[*].*': *."; 456const char kInvalidKeyBindingMissingPlatform[] = 457 "Could not find key specification for 'command[*].*': Either specify a key " 458 "for '*', or specify a default key."; 459const char kInvalidKeyBindingTooMany[] = 460 "Too many shortcuts specified for 'commands': The maximum is *."; 461const char kInvalidKeyBindingUnknownPlatform[] = 462 "Unknown platform for 'command[*]': *. Valid values are: 'windows', 'mac'" 463 " 'chromeos', 'linux' and 'default'."; 464const char kInvalidKioskEnabled[] = 465 "Invalid value for 'kiosk_enabled'."; 466const char kInvalidKioskOnly[] = 467 "Invalid value for 'kiosk_only'."; 468const char kInvalidKioskOnlyButNotEnabled[] = 469 "The 'kiosk_only' key is set, but 'kiosk_enabled' is not set."; 470const char kInvalidLauncherPage[] = "Invalid value for 'launcher_page'."; 471const char kInvalidLauncherPagePage[] = 472 "Invalid value for 'launcher_page.page'."; 473const char kInvalidLaunchContainer[] = 474 "Invalid value for 'app.launch.container'."; 475const char kInvalidLaunchValue[] = 476 "Invalid value for '*'."; 477const char kInvalidLaunchValueContainer[] = 478 "Invalid container type for '*'."; 479const char kInvalidManifest[] = 480 "Manifest file is invalid."; 481const char kInvalidManifestVersion[] = 482 "Invalid value for 'manifest_version'. Must be an integer greater than " 483 "zero."; 484const char kInvalidManifestVersionOld[] = 485 "The 'manifest_version' key must be present and set to * (without quotes). " 486 "See developer.chrome.com/*/manifestVersion.html for details."; 487const char kInvalidMatch[] = 488 "Invalid value for 'content_scripts[*].matches[*]': *"; 489const char kInvalidMatchAboutBlank[] = 490 "Invalid value for 'content_scripts[*].match_about_blank'."; 491const char kInvalidMatchCount[] = 492 "Invalid value for 'content_scripts[*].matches'. There must be at least " 493 "one match specified."; 494const char kInvalidMatches[] = 495 "Required value 'content_scripts[*].matches' is missing or invalid."; 496const char kInvalidMIMETypes[] = 497 "Invalid value for 'mime_types'"; 498const char kInvalidMimeTypesHandler[] = 499 "Invalid value for 'mime_types'."; 500const char kInvalidMinimumChromeVersion[] = 501 "Invalid value for 'minimum_chrome_version'."; 502const char kInvalidName[] = 503 "Required value 'name' is missing or invalid."; 504const char kInvalidNaClModules[] = 505 "Invalid value for 'nacl_modules'."; 506const char kInvalidNaClModulesPath[] = 507 "Invalid value for 'nacl_modules[*].path'."; 508const char kInvalidNaClModulesMIMEType[] = 509 "Invalid value for 'nacl_modules[*].mime_type'."; 510const char kInvalidOAuth2AutoApprove[] = 511 "Invalid value for 'oauth2.auto_approve'. Value must be true or false."; 512const char kInvalidOAuth2ClientId[] = 513 "Invalid value for 'oauth2.client_id'."; 514const char kInvalidOAuth2Scopes[] = 515 "Invalid value for 'oauth2.scopes'."; 516const char kInvalidOfflineEnabled[] = 517 "Invalid value for 'offline_enabled'."; 518const char kInvalidOmniboxKeyword[] = 519 "Invalid value for 'omnibox.keyword'."; 520const char kInvalidOptionsPage[] = "Invalid value for '*'."; 521const char kInvalidOptionsPageExpectUrlInPackage[] = 522 "Invalid value for 'options_page'. Value must be a relative path."; 523const char kInvalidOptionsPageInHostedApp[] = 524 "Invalid value for 'options_page'. Hosted apps must specify an " 525 "absolute URL."; 526const char kInvalidOptionsUIChromeStyle[] = 527 "Invalid value for 'options_ui.chrome_style'."; 528const char kInvalidOptionsUIOpenInTab[] = 529 "Invalid value for 'options_ui.open_in_tab'."; 530const char kInvalidPageAction[] = 531 "Invalid value for 'page_action'."; 532const char kInvalidPageActionDefaultTitle[] = 533 "Invalid value for 'default_title'."; 534const char kInvalidPageActionIconPath[] = 535 "Invalid value for 'page_action.default_icon'."; 536const char kInvalidPageActionId[] = 537 "Required value 'id' is missing or invalid."; 538const char kInvalidPageActionName[] = 539 "Invalid value for 'page_action.name'."; 540const char kInvalidPageActionOldAndNewKeys[] = 541 "Key \"*\" is deprecated. Key \"*\" has the same meaning. You can not " 542 "use both."; 543const char kInvalidPageActionPopup[] = 544 "Invalid type for page action popup."; 545const char kInvalidPageActionPopupPath[] = 546 "Invalid value for page action popup path [*]."; 547const char kInvalidPageActionsList[] = 548 "Invalid value for 'page_actions'."; 549const char kInvalidPageActionsListSize[] = 550 "Invalid value for 'page_actions'. There can be at most one page action."; 551const char kInvalidPageActionTypeValue[] = 552 "Invalid value for 'page_actions[*].type', expected 'tab' or 'permanent'."; 553const char kInvalidPermissionWithDetail[] = 554 "Invalid value for 'permissions[*]': *."; 555const char kInvalidPermission[] = 556 "Invalid value for 'permissions[*]'."; 557const char kInvalidPermissions[] = 558 "Invalid value for 'permissions'."; 559const char kInvalidPermissionScheme[] = 560 "Invalid scheme for 'permissions[*]'."; 561const char kInvalidPlugins[] = 562 "Invalid value for 'plugins'."; 563const char kInvalidPluginsPath[] = 564 "Invalid value for 'plugins[*].path'."; 565const char kInvalidPluginsPublic[] = 566 "Invalid value for 'plugins[*].public'."; 567const char kInvalidRequirement[] = 568 "Invalid value for requirement \"*\""; 569const char kInvalidRequirements[] = 570 "Invalid value for 'requirements'"; 571const char kInvalidRunAt[] = 572 "Invalid value for 'content_scripts[*].run_at'."; 573const char kInvalidSandboxedPagesList[] = 574 "Invalid value for 'sandbox.pages'."; 575const char kInvalidSandboxedPage[] = 576 "Invalid value for 'sandbox.pages[*]'."; 577const char kInvalidSandboxedPagesCSP[] = 578 "Invalid value for 'sandbox.content_security_policy'."; 579const char kInvalidScriptBadge[] = 580 "Invalid value for 'script_badge'."; 581const char kInvalidSearchEngineMissingKeys[] = 582 "Missing mandatory parameters for " 583 "'chrome_settings_overrides.search_provider'."; 584const char kInvalidSearchEngineURL[] = 585 "Invalid URL [*] for 'chrome_settings_overrides.search_provider'."; 586const char kInvalidShortName[] = 587 "Invalid value for 'short_name'."; 588const char kInvalidSignature[] = 589 "Value 'signature' is missing or invalid."; 590const char kInvalidSpellcheck[] = 591 "Invalid value for 'spellcheck'."; 592const char kInvalidSpellcheckDictionaryFormat[] = 593 "Invalid value for spellcheck dictionary format."; 594const char kInvalidSpellcheckDictionaryLanguage[] = 595 "Invalid value for spellcheck dictionary language."; 596const char kInvalidSpellcheckDictionaryLocale[] = 597 "Invalid value for spellcheck dictionary locale."; 598const char kInvalidSpellcheckDictionaryPath[] = 599 "Invalid value for spellcheck dictionary path."; 600const char kInvalidStartupOverrideURL[] = 601 "Invalid value for overriding startup URL: '[*]'."; 602const char kInvalidSystemIndicator[] = 603 "Invalid value for 'system_indicator'."; 604const char kInvalidTheme[] = 605 "Invalid value for 'theme'."; 606const char kInvalidThemeColors[] = 607 "Invalid value for theme colors - colors must be integers"; 608const char kInvalidThemeImages[] = 609 "Invalid value for theme images - images must be strings."; 610const char kInvalidThemeImagesMissing[] = 611 "An image specified in the theme is missing."; 612const char kInvalidThemeTints[] = 613 "Invalid value for theme images - tints must be decimal numbers."; 614const char kInvalidTts[] = 615 "Invalid value for 'tts_engine'."; 616const char kInvalidTtsVoices[] = 617 "Invalid value for 'tts_engine.voices'."; 618const char kInvalidTtsVoicesEventTypes[] = 619 "Invalid value for 'tts_engine.voices[*].event_types'."; 620const char kInvalidTtsVoicesGender[] = 621 "Invalid value for 'tts_engine.voices[*].gender'."; 622const char kInvalidTtsVoicesLang[] = 623 "Invalid value for 'tts_engine.voices[*].lang'."; 624const char kInvalidTtsVoicesRemote[] = 625 "Invalid value for 'tts_engine.voices[*].remote'."; 626const char kInvalidTtsVoicesVoiceName[] = 627 "Invalid value for 'tts_engine.voices[*].voice_name'."; 628const char kInvalidUpdateURL[] = 629 "Invalid value for update url: '[*]'."; 630const char kInvalidURLHandlers[] = 631 "Invalid value for 'url_handlers'."; 632const char kInvalidURLHandlerPatternElement[] = 633 "Invalid value for 'url_handlers[*]'."; 634const char kInvalidURLHandlerTitle[] = 635 "Invalid value for 'url_handlers[*].title'."; 636const char kInvalidURLHandlerPattern[] = 637 "Invalid value for 'url_handlers[*].matches[*]'."; 638const char kInvalidURLPatternError[] = 639 "Invalid url pattern '*'"; 640const char kInvalidVersion[] = 641 "Required value 'version' is missing or invalid. It must be between 1-4 " 642 "dot-separated integers each between 0 and 65536."; 643const char kInvalidWebAccessibleResourcesList[] = 644 "Invalid value for 'web_accessible_resources'."; 645const char kInvalidWebAccessibleResource[] = 646 "Invalid value for 'web_accessible_resources[*]'."; 647const char kInvalidWebview[] = 648 "Invalid value for 'webview'."; 649const char kInvalidWebviewAccessibleResourcesList[] = 650 "Invalid value for'webview.accessible_resources'."; 651const char kInvalidWebviewAccessibleResource[] = 652 "Invalid value for 'webview.accessible_resources[*]'."; 653const char kInvalidWebviewPartition[] = 654 "Invalid value for 'webview.partitions[*]'."; 655const char kInvalidWebviewPartitionName[] = 656 "Invalid value for 'webview.partitions[*].name'."; 657const char kInvalidWebviewPartitionsList[] = 658 "Invalid value for 'webview.partitions'."; 659const char kInvalidWebURL[] = 660 "Invalid value for 'app.urls[*]': *"; 661const char kInvalidWebURLs[] = 662 "Invalid value for 'app.urls'."; 663const char kInvalidZipHash[] = 664 "Required key 'zip_hash' is missing or invalid."; 665const char kInsecureContentSecurityPolicy[] = 666 "Invalid value for 'content_security_policy': Both 'script-src' and" 667 " 'object-src' directives must be specified (either explicitly, or" 668 " implicitly via 'default-src'), and both must whitelist only secure" 669 " resources. You may include any of the following sources: \"'self'\"," 670 " \"'unsafe-eval'\", \"http://127.0.0.1\", \"http://localhost\", or any" 671 " \"https://\" or \"chrome-extension://\" origin. For more information," 672 " see http://developer.chrome.com/extensions/contentSecurityPolicy.html"; 673const char kKeyIsDeprecatedWithReplacement[] = 674 "Key \"*\" is deprecated. Key \"*\" should be used instead."; 675const char kLauncherPagePageRequired[] = 676 "The 'launcher_page.page' key is required."; 677const char kLaunchPathAndExtentAreExclusive[] = 678 "The 'app.launch.local_path' and 'app.urls' keys cannot both be set."; 679const char kLaunchPathAndURLAreExclusive[] = 680 "The 'app.launch.local_path' and 'app.launch.web_url' keys cannot " 681 "both be set."; 682const char kLaunchURLRequired[] = 683 "Either 'app.launch.local_path' or 'app.launch.web_url' is required."; 684const char kLocalesInvalidLocale[] = 685 "Invalid locale file '*': *"; 686const char kLocalesMessagesFileMissing[] = 687 "Messages file is missing for locale."; 688const char kLocalesNoDefaultLocaleSpecified[] = 689 "Localization used, but default_locale wasn't specified in the manifest."; 690const char kLocalesNoDefaultMessages[] = 691 "Default locale is defined but default data couldn't be loaded."; 692const char kLocalesNoValidLocaleNamesListed[] = 693 "No valid locale name could be found in _locales directory."; 694const char kLocalesTreeMissing[] = 695 "Default locale was specified, but _locales subtree is missing."; 696const char kManifestParseError[] = 697 "Manifest is not valid JSON."; 698const char kManifestUnreadable[] = 699 "Manifest file is missing or unreadable."; 700const char kMissingFile[] = 701 "At least one js or css file is required for 'content_scripts[*]'."; 702const char kMultipleOverrides[] = 703 "An extension cannot override more than one page."; 704const char kNoPermissionForMIMETypes[] = 705 "The extension is not allowed to use mime_types key."; 706const char kNoWildCardsInPaths[] = 707 "Wildcards are not allowed in extent URL pattern paths."; 708const char kOneUISurfaceOnly[] = 709 "Only one of 'browser_action', 'page_action', and 'app' can be specified."; 710const char kPermissionMustBeOptional[] = 711 "Permission '*' must be specified in the optional section of the manifest."; 712const char kPermissionNotAllowed[] = 713 "Access to permission '*' denied."; 714const char kPermissionNotAllowedInManifest[] = 715 "Permission '*' cannot be specified in the manifest."; 716const char kPermissionUnknownOrMalformed[] = 717 "Permission '*' is unknown or URL pattern is malformed."; 718const char kReservedMessageFound[] = 719 "Reserved key * found in message catalog."; 720const char kScriptBadgeRequiresFlag[] = 721 "The script_badge manifest key is turned off by default. " 722 "You can enable it with the --enable-script-badges command-line flag."; 723const char kScriptBadgeIconIgnored[] = 724 "default_icon specified in script_badge manifest section will not be used."; 725const char kScriptBadgeTitleIgnored[] = 726 "default_title specified in script_badge manifest section will not be " 727 "used."; 728const char kUnrecognizedManifestKey[] = "Unrecognized manifest key '*'."; 729const char kUnrecognizedManifestProperty[] = 730 "Unrecognized property '*' of manifest key '*'."; 731const char kWebRequestConflictsWithLazyBackground[] = 732 "The 'webRequest' API cannot be used with event pages."; 733#if defined(OS_CHROMEOS) 734const char kIllegalPlugins[] = 735 "Extensions cannot install plugins on Chrome OS"; 736#endif 737 738} // namespace manifest_errors 739 740} // namespace extensions 741