1 // Copyright 2014 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 // This features file defines extension APIs implemented under src/extensions.
6 // See extensions/common/features/* to understand this file, in particular
7 // feature.h, simple_feature.h, and base_feature_provider.h.
9 // Note that specifying "web_page", "blessed_web_page", or "all" as a context
10 // type will require manually updating chrome/renderer/resources/dispatcher.cc.
12 // To add a new whitelisted ID, SHA-1 it and force it to uppercase. In Bash:
14 // $ echo -n "aaaabbbbccccddddeeeeffffgggghhhh" | \
15 // sha1sum | tr '[:lower:]' '[:upper:]'
16 // 9A0417016F345C934A1A88F55CA17C05014EEEBA -
18 // Google employees: please update http://go/chrome-api-whitelist to map
19 // hashes back to ids.
23 "dependencies": ["permission:alarms"],
24 "contexts": ["blessed_extension"]
28 "contexts": ["blessed_extension"],
29 "extension_types": ["platform_app"],
33 "component_extensions_auto_granted": false,
34 "contexts": ["blessed_extension"],
35 "extension_types": ["extension"],
38 "2FC374607C2DF285634B67C64A2E356C607091C3", // Quickoffice
39 "3727DD3E564B6055387425027AD74C58784ACC15", // Quickoffice internal
40 "12E618C3C6E97495AAECF2AC12DEB082353241C6" // QO component extension
45 "contexts": ["blessed_extension"],
46 "extension_types": ["platform_app"],
50 "contexts": ["blessed_extension"],
51 "extension_types": ["extension"],
53 "component_extensions_auto_granted": false,
55 "B9EF10DDFEA11EF77873CC5009809E5037FC4C7A", // Google input tools
56 "06BE211D5F014BAB34BC22D9DDA09C63A81D828E", // Official xkb extension
57 "F94EE6AB36D6C6588670B2B01EB65212D9C64E33" // Open source xkb extension
60 "app.currentWindowInternal": {
64 "contexts": ["blessed_extension"]
66 "app.currentWindowInternal.setShape": {
67 "dependencies": ["permission:app.window.shape"],
68 "contexts": ["blessed_extension"]
70 // The API for the *embedder* of appview. Appview has both an embedder and
71 // guest API, which are different.
72 "appViewEmbedderInternal": {
74 "contexts": ["blessed_extension"],
75 "dependencies": ["permission:appview"]
77 // Note that exposing this doesn't necessarily expose AppView,
78 // appViewEmbedderInternal is required for that.
79 // See http://crbug.com/437891.
80 "appViewGuestInternal": {
83 "contexts": ["blessed_extension"]
86 "dependencies": ["permission:audio"],
87 "contexts": ["blessed_extension"]
90 "dependencies": ["manifest:bluetooth"],
91 "contexts": ["blessed_extension"]
93 "bluetoothLowEnergy": {
94 "dependencies": ["manifest:bluetooth"],
95 "contexts": ["blessed_extension"]
98 "dependencies": ["permission:bluetoothPrivate"],
99 "contexts": ["blessed_extension"]
102 "dependencies": ["manifest:bluetooth"],
103 "contexts": ["blessed_extension"]
105 "declarativeWebRequest": {
106 "dependencies": ["permission:declarativeWebRequest"],
107 "contexts": ["blessed_extension"]
110 "dependencies": ["permission:diagnostics"],
111 "extension_types": ["platform_app"],
112 "contexts": ["blessed_extension"]
115 "dependencies": ["permission:dns"],
116 "contexts": ["blessed_extension"]
119 "dependencies": ["permission:documentScan"],
120 "contexts": ["blessed_extension"]
122 // This is not a real API, only here for documentation purposes.
123 // See http://crbug.com/275944 for background.
127 "extension_types": ["extension", "legacy_packaged_app", "platform_app"],
128 "contexts": ["blessed_extension"]
130 "extensionViewInternal": {
132 "contexts": ["blessed_extension"],
133 "dependencies": ["permission:extensionview"]
138 "extension_types": ["platform_app", "extension"],
140 "matches": ["<all_urls>"]
142 "guestViewInternal": [
146 "contexts": ["blessed_extension"]
150 "contexts": ["webui"],
152 "chrome://extensions-frame/*",
153 "chrome://extensions/*",
154 "chrome://chrome-signin/*",
158 // This allows GuestViews to be created on regular web pages for the Worker
159 // Thread Frame prototype: http://crbug.com/434226.
164 "matches": ["<all_urls>"]
168 "dependencies": ["permission:hid"],
169 "contexts": ["blessed_extension"]
172 "dependencies": ["permission:idle"],
173 "contexts": ["blessed_extension"]
176 "dependencies": ["permission:management"],
177 "contexts": ["blessed_extension"],
178 "default_parent": true
181 "contexts": ["webui"],
183 "chrome://extensions/*",
184 "chrome://extensions-frame/*",
185 "chrome://chrome/extensions/*"
188 "management.getPermissionWarningsByManifest": {
191 "extension_types": ["extension", "legacy_packaged_app", "platform_app"]
193 "management.getSelf": {
196 "extension_types": ["extension", "legacy_packaged_app", "platform_app"]
198 "management.uninstallSelf": {
201 "extension_types": ["extension", "legacy_packaged_app", "platform_app"]
203 "mimeHandlerPrivate": {
204 "dependencies": ["manifest:mime_types_handler"],
205 "contexts": ["blessed_extension"]
208 "contexts": ["blessed_extension"],
210 "extension_types": ["platform_app", "extension"],
212 "63ED55E43214C211F82122ED56407FF1A807F2A3" // http://crbug.com/448569
215 "networking.config": {
216 "dependencies": ["permission:networking.config"],
217 "contexts": ["blessed_extension"]
219 "networkingPrivate": [{
220 "dependencies": ["permission:networkingPrivate"],
221 "contexts": ["blessed_extension"]
224 "contexts": ["webui"],
226 "chrome://md-settings/*",
227 "chrome://network/*",
228 "chrome://settings/*",
229 "chrome://settings-frame/*"
233 "dependencies": ["permission:power"],
234 "contexts": ["blessed_extension"]
237 "dependencies": ["permission:printerProvider"],
238 "contexts": ["blessed_extension"]
240 "printerProviderInternal": {
242 "dependencies": ["permission:printerProvider"],
243 "contexts": ["blessed_extension"]
247 "extension_types": ["extension", "legacy_packaged_app", "platform_app"],
248 "contexts": ["blessed_extension"]
250 "runtime.getManifest": {
251 "contexts": ["blessed_extension", "unblessed_extension", "content_script"]
254 // Everything except WebUI.
259 "unblessed_extension",
262 "matches": ["<all_urls>"]
264 "runtime.connectNative": {
265 "dependencies": ["permission:nativeMessaging"],
266 "contexts": ["blessed_extension"]
269 "contexts": ["blessed_extension", "unblessed_extension", "content_script"]
272 "contexts": ["blessed_extension", "unblessed_extension", "content_script"]
274 "runtime.lastError": {
276 "extension_types": "all",
277 "matches": ["<all_urls>"]
279 "runtime.onConnect": {
280 "contexts": ["blessed_extension", "unblessed_extension", "content_script"]
282 "runtime.onMessage": {
283 "contexts": ["blessed_extension", "unblessed_extension", "content_script"]
285 "runtime.sendMessage": {
286 // Everything except WebUI.
291 "unblessed_extension",
294 "matches": ["<all_urls>"]
296 "runtime.sendNativeMessage": {
297 "dependencies": ["permission:nativeMessaging"],
298 "contexts": ["blessed_extension"]
301 "dependencies": ["permission:serial"],
302 "contexts": ["blessed_extension"]
305 "dependencies": ["permission:socket"],
306 "contexts": ["blessed_extension"]
309 "dependencies": ["manifest:sockets"],
310 "contexts": ["blessed_extension"]
312 "sockets.tcpServer": {
313 "dependencies": ["manifest:sockets"],
314 "contexts": ["blessed_extension"]
317 "dependencies": ["manifest:sockets"],
318 "contexts": ["blessed_extension"]
321 "dependencies": ["permission:storage"],
322 "contexts": ["blessed_extension", "unblessed_extension", "content_script"]
324 "surfaceWorkerInternal": {
328 "matches": ["<all_urls>"]
331 "dependencies": ["permission:system.cpu"],
332 "contexts": ["blessed_extension"]
335 "dependencies": ["permission:system.display"],
336 "contexts": ["blessed_extension"]
339 "dependencies": ["permission:system.memory"],
340 "contexts": ["blessed_extension"]
343 "dependencies": ["permission:system.network"],
344 "contexts": ["blessed_extension"]
347 "dependencies": ["permission:system.storage"],
348 "contexts": ["blessed_extension"]
350 "system.storage.getAvailableCapacity": {
355 "extension_types": "all",
356 // Everything except web pages and WebUI. WebUI is declared in a separate
357 // rule to keep the "matches" property isolated.
362 "unblessed_extension"
366 "contexts": ["webui"],
368 "chrome://extensions/*",
369 "chrome://extensions-frame/*",
370 "chrome://chrome/extensions/*"
376 "extension_types": ["extension", "legacy_packaged_app", "platform_app"],
377 "contexts": ["blessed_extension"]
380 // preferencesPrivate is the only API that uses types.private.
381 // If any other APIs need it then they'll need to be added in
383 "dependencies": ["permission:preferencesPrivate"],
384 "contexts": ["blessed_extension"]
387 "dependencies": ["permission:usb"],
388 "contexts": ["blessed_extension"]
391 "dependencies": ["permission:vpnProvider"],
392 "contexts": ["blessed_extension"]
395 "dependencies": ["permission:webRequest"],
396 "contexts": ["blessed_extension"]
398 "webRequestInternal": [{
401 "contexts": ["blessed_extension"]
403 // webview uses webRequestInternal API.
406 "contexts": ["webui"],
407 "matches": ["chrome://chrome-signin/*", "chrome://oobe/*"]
409 "webViewInternal": [{
411 "dependencies": ["permission:webview"],
412 "contexts": ["blessed_extension"]
416 "contexts": ["webui"],
417 "matches": ["chrome://chrome-signin/*", "chrome://oobe/*"]
420 "dependencies": ["permission:webview"],
421 "contexts": ["blessed_extension"]
424 "contexts": ["webui"],
425 "matches": ["chrome://chrome-signin/*", "chrome://oobe/*"]