components.conf (7271B)
1 # -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*- 2 # vim: set filetype=python: 3 # This Source Code Form is subject to the terms of the Mozilla Public 4 # License, v. 2.0. If a copy of the MPL was not distributed with this 5 # file, You can obtain one at http://mozilla.org/MPL/2.0/. 6 7 about_pages = [ 8 'about', 9 'buildconfig', 10 'certificate', 11 'checkerboard', 12 'config', 13 'crashcontent', 14 'crashparent', 15 'crashgpu', 16 'crashextensions', 17 'credits', 18 'fingerprintingprotection', 19 'httpsonlyerror', 20 'license', 21 'logging', 22 'logo', 23 'memory', 24 # Removed 'mozilla'. tor-browser#42831. 25 'neterror', 26 'networking', 27 'performance', 28 'processes', 29 'restricted', 30 'serviceworkers', 31 'srcdoc', 32 'support', 33 'torconnect', 34 # Removed 'url-classifier'. tor-browser#42831. 35 ] 36 37 if buildconfig.substs['MOZ_WIDGET_TOOLKIT'] != 'android': 38 about_pages.append('addons') 39 if defined('MOZ_CRASHREPORTER'): 40 about_pages.append('crashes') 41 if defined('MOZ_TELEMETRY_REPORTING'): 42 about_pages.append('telemetry') 43 if defined('MOZ_WEBRTC'): 44 about_pages.append('webrtc') 45 if buildconfig.substs['MOZ_WIDGET_TOOLKIT'] != 'android': 46 about_pages.append('profiles') 47 # Remove about:translations since translations are disabled. 48 # See tor-browser#44045 and tor-browser#42872. 49 if buildconfig.substs['MOZ_WIDGET_TOOLKIT'] == 'android': 50 about_pages.append('crashcontentjava') 51 about_pages.append('home') 52 if buildconfig.substs['MOZ_WIDGET_TOOLKIT'] == 'windows': 53 about_pages.append('third-party') 54 about_pages.append('windows-messages') 55 if defined('MOZ_TELEMETRY_REPORTING') and not defined('MOZ_GLEAN_ANDROID'): 56 about_pages.append('glean') 57 if buildconfig.substs['MOZ_WIDGET_TOOLKIT'] != 'android' and buildconfig.substs['MOZ_WIDGET_TOOLKIT'] != 'windows': 58 about_pages.append('webauthn') 59 # Do not include about:inference since "ml" component is missing. 60 # tor-browser#44045. 61 62 Headers = ['/docshell/build/nsDocShellModule.h'] 63 64 InitFunc = 'mozilla::InitDocShellModule' 65 UnloadFunc = 'mozilla::UnloadDocShellModule' 66 67 Classes = [ 68 { 69 'name': 'DocLoader', 70 'cid': '{057b04d0-0ccf-11d2-beba-00805f8a66dc}', 71 'contract_ids': ['@mozilla.org/docloaderservice;1'], 72 'type': 'nsDocLoader', 73 'headers': ['nsDocLoader.h'], 74 'init_method': 'Init', 75 }, 76 { 77 'name': 'URIFixup', 78 'js_name': 'uriFixup', 79 'cid': '{c6cf88b7-452e-47eb-bdc9-86e3561648ef}', 80 'contract_ids': ['@mozilla.org/docshell/uri-fixup;1'], 81 'interfaces': ['nsIURIFixup'], 82 'esModule': 'resource://gre/modules/URIFixup.sys.mjs', 83 'singleton': True, 84 'constructor': 'URIFixup', 85 }, 86 { 87 'cid': '{33d75835-722f-42c0-89cc-44f328e56a86}', 88 'contract_ids': ['@mozilla.org/docshell/uri-fixup-info;1'], 89 'esModule': 'resource://gre/modules/URIFixup.sys.mjs', 90 'constructor': 'URIFixupInfo', 91 }, 92 { 93 'cid': '{56ebedd4-6ccf-48e8-bdae-adc77f044567}', 94 'contract_ids': [ 95 '@mozilla.org/network/protocol/about;1?what=%s' % path 96 for path in about_pages 97 ], 98 'legacy_constructor': 'nsAboutRedirector::Create', 99 'headers': ['/docshell/base/nsAboutRedirector.h'], 100 }, 101 { 102 'name': 'ExternalProtocolHandler', 103 'cid': '{bd6390c8-fbea-11d4-98f6-001083010e9b}', 104 'contract_ids': ['@mozilla.org/network/protocol;1?name=default'], 105 'type': 'nsExternalProtocolHandler', 106 'headers': ['/uriloader/exthandler/nsExternalProtocolHandler.h'], 107 'protocol_config': { 108 'scheme': 'default', 109 'flags': [ 110 'URI_NORELATIVE', 111 'URI_NOAUTH', 112 'URI_LOADABLE_BY_ANYONE', 113 'URI_NON_PERSISTABLE', 114 'URI_DOES_NOT_RETURN_DATA', 115 ], 116 'default_port': 0, 117 }, 118 'processes': ProcessSelector.ALLOW_IN_SOCKET_PROCESS, 119 }, 120 { 121 'cid': '{95790842-75a0-430d-98bf-f5ce3788ea6d}', 122 'contract_ids': ['@mozilla.org/ospermissionrequest;1'], 123 'type': 'nsOSPermissionRequest', 124 'headers': ['nsOSPermissionRequest.h'], 125 'processes': ProcessSelector.MAIN_PROCESS_ONLY, 126 }, 127 { 128 'name': 'Prefetch', 129 'cid': '{6b8bdffc-3394-417d-be83-a81b7c0f63bf}', 130 'contract_ids': ['@mozilla.org/prefetch-service;1'], 131 'type': 'nsPrefetchService', 132 'headers': ['/uriloader/prefetch/nsPrefetchService.h'], 133 'init_method': 'Init', 134 }, 135 { 136 'cid': '{c4b6fb7c-bfb1-49dc-a65f-035796524b53}', 137 'contract_ids': ['@mozilla.org/uriloader/handler-service;1'], 138 'type': 'nsIHandlerService', 139 'headers': ['ContentHandlerService.h'], 140 'constructor': 'mozilla::dom::ContentHandlerService::Create', 141 }, 142 { 143 'cid': '{bc0017e3-2438-47be-a567-41db58f17627}', 144 'contract_ids': ['@mozilla.org/uriloader/local-handler-app;1'], 145 'type': 'PlatformLocalHandlerApp_t', 146 'headers': ['/uriloader/exthandler/nsLocalHandlerApp.h'], 147 }, 148 { 149 'name': 'URILoader', 150 'cid': '{9f6d5d40-90e7-11d3-af80-00a024ffc08c}', 151 'contract_ids': ['@mozilla.org/uriloader;1'], 152 'type': 'nsURILoader', 153 'headers': ['nsURILoader.h'], 154 }, 155 { 156 'cid': '{f30bc0a2-958b-4287-bf62-ce38ba0c811e}', 157 'contract_ids': ['@mozilla.org/webnavigation-info;1'], 158 'type': 'nsWebNavigationInfo', 159 'headers': ['/docshell/base/nsWebNavigationInfo.h'], 160 }, 161 ] 162 163 if defined('MOZ_ENABLE_DBUS'): 164 Classes += [ 165 { 166 'name': 'DBusHandlerApp', 167 'cid': '{6c3c274b-4cbf-4bb5-a635-05ad2cbb6535}', 168 'contract_ids': ['@mozilla.org/uriloader/dbus-handler-app;1'], 169 'type': 'nsDBusHandlerApp', 170 'headers': ['/uriloader/exthandler/nsDBusHandlerApp.h'], 171 }, 172 ] 173 174 if buildconfig.substs['MOZ_WIDGET_TOOLKIT'] in ('android', 'uikit'): 175 Classes += [ 176 # Android has its own externel-helper-app-service, so we omit 177 # that here for nsExternalHelperAppService. 178 { 179 'cid': '{a7f800e0-4306-11d4-98d0-001083010e9b}', 180 'contract_ids': [ 181 '@mozilla.org/mime;1', 182 '@mozilla.org/uriloader/external-protocol-service;1', 183 ], 184 'type': 'nsExternalHelperAppService', 185 'constructor': 'nsExternalHelperAppService::GetSingleton', 186 'headers': ['nsExternalHelperAppService.h'], 187 'init_method': 'Init', 188 'processes': ProcessSelector.ALLOW_IN_SOCKET_PROCESS, 189 }, 190 ] 191 else: 192 Classes += [ 193 { 194 'cid': '{a7f800e0-4306-11d4-98d0-001083010e9b}', 195 'contract_ids': [ 196 '@mozilla.org/mime;1', 197 '@mozilla.org/uriloader/external-helper-app-service;1', 198 '@mozilla.org/uriloader/external-protocol-service;1', 199 ], 200 'type': 'nsExternalHelperAppService', 201 'constructor': 'nsExternalHelperAppService::GetSingleton', 202 'headers': ['nsExternalHelperAppService.h'], 203 'init_method': 'Init', 204 'processes': ProcessSelector.ALLOW_IN_SOCKET_PROCESS, 205 }, 206 ]