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