Suppress tabs permission warning if there is already a browsingHistory warning.
[chromium-blink-merge.git] / chrome / common / chrome_content_client.cc
blobe245a0efc9d452a83304dffceefda4b8fa56c67d
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 "chrome/common/chrome_content_client.h"
7 #include "base/command_line.h"
8 #include "base/cpu.h"
9 #include "base/debug/crash_logging.h"
10 #include "base/file_util.h"
11 #include "base/path_service.h"
12 #include "base/strings/string16.h"
13 #include "base/strings/string_number_conversions.h"
14 #include "base/strings/string_split.h"
15 #include "base/strings/string_util.h"
16 #include "base/strings/stringprintf.h"
17 #include "base/strings/utf_string_conversions.h"
18 #include "build/build_config.h"
19 #include "chrome/common/child_process_logging.h"
20 #include "chrome/common/chrome_paths.h"
21 #include "chrome/common/chrome_switches.h"
22 #include "chrome/common/chrome_version_info.h"
23 #include "chrome/common/crash_keys.h"
24 #include "chrome/common/pepper_flash.h"
25 #include "chrome/common/render_messages.h"
26 #include "chrome/common/url_constants.h"
27 #include "components/nacl/common/nacl_process_type.h"
28 #include "content/public/common/content_constants.h"
29 #include "content/public/common/content_switches.h"
30 #include "content/public/common/pepper_plugin_info.h"
31 #include "content/public/common/url_constants.h"
32 #include "content/public/common/user_agent.h"
33 #include "extensions/common/constants.h"
34 #include "gpu/config/gpu_info.h"
35 #include "grit/common_resources.h"
36 #include "ppapi/shared_impl/ppapi_permissions.h"
37 #include "ui/base/l10n/l10n_util.h"
38 #include "ui/base/layout.h"
39 #include "ui/base/resource/resource_bundle.h"
41 #include "flapper_version.h" // In SHARED_INTERMEDIATE_DIR.
42 #include "widevine_cdm_version.h" // In SHARED_INTERMEDIATE_DIR.
44 #if defined(OS_WIN)
45 #include "base/win/registry.h"
46 #include "base/win/windows_version.h"
47 #elif defined(OS_MACOSX)
48 #include "components/nacl/common/nacl_sandbox_type_mac.h"
49 #endif
51 #if defined(ENABLE_REMOTING)
52 #include "remoting/client/plugin/pepper_entrypoints.h"
53 #endif
55 #if defined(WIDEVINE_CDM_AVAILABLE) && defined(ENABLE_PEPPER_CDMS) && \
56 !defined(WIDEVINE_CDM_IS_COMPONENT)
57 #include "chrome/common/widevine_cdm_constants.h"
58 #endif
60 namespace {
62 const char kPDFPluginMimeType[] = "application/pdf";
63 const char kPDFPluginExtension[] = "pdf";
64 const char kPDFPluginDescription[] = "Portable Document Format";
65 const char kPDFPluginPrintPreviewMimeType[] =
66 "application/x-google-chrome-print-preview-pdf";
67 const char kPDFPluginOutOfProcessMimeType[] =
68 "application/x-google-chrome-pdf";
69 const uint32 kPDFPluginPermissions = ppapi::PERMISSION_PRIVATE |
70 ppapi::PERMISSION_DEV;
72 const char kNaClPluginMimeType[] = "application/x-nacl";
73 const char kNaClPluginExtension[] = "";
74 const char kNaClPluginDescription[] = "Native Client Executable";
75 const uint32 kNaClPluginPermissions = ppapi::PERMISSION_PRIVATE |
76 ppapi::PERMISSION_DEV;
78 const char kPnaclPluginMimeType[] = "application/x-pnacl";
79 const char kPnaclPluginExtension[] = "";
80 const char kPnaclPluginDescription[] = "Portable Native Client Executable";
82 const char kO1DPluginName[] = "Google Talk Plugin Video Renderer";
83 const char kO1DPluginMimeType[] ="application/o1d";
84 const char kO1DPluginExtension[] = "";
85 const char kO1DPluginDescription[] = "Google Talk Plugin Video Renderer";
86 const uint32 kO1DPluginPermissions = ppapi::PERMISSION_PRIVATE |
87 ppapi::PERMISSION_DEV;
89 const char kEffectsPluginName[] = "Google Talk Effects Plugin";
90 const char kEffectsPluginMimeType[] ="application/x-ppapi-hangouts-effects";
91 const char kEffectsPluginExtension[] = "";
92 const char kEffectsPluginDescription[] = "Google Talk Effects Plugin";
93 const uint32 kEffectsPluginPermissions = ppapi::PERMISSION_PRIVATE |
94 ppapi::PERMISSION_DEV;
96 const char kGTalkPluginName[] = "Google Talk Plugin";
97 const char kGTalkPluginMimeType[] ="application/googletalk";
98 const char kGTalkPluginExtension[] = ".googletalk";
99 const char kGTalkPluginDescription[] = "Google Talk Plugin";
100 const uint32 kGTalkPluginPermissions = ppapi::PERMISSION_PRIVATE |
101 ppapi::PERMISSION_DEV;
103 #if defined(ENABLE_REMOTING)
104 #if defined(GOOGLE_CHROME_BUILD)
105 const char kRemotingViewerPluginName[] = "Chrome Remote Desktop Viewer";
106 #else
107 const char kRemotingViewerPluginName[] = "Chromoting Viewer";
108 #endif // defined(GOOGLE_CHROME_BUILD)
109 const char kRemotingViewerPluginDescription[] =
110 "This plugin allows you to securely access other computers that have been "
111 "shared with you. To use this plugin you must first install the "
112 "<a href=\"https://chrome.google.com/remotedesktop\">"
113 "Chrome Remote Desktop</a> webapp.";
114 // Use a consistent MIME-type regardless of branding.
115 const char kRemotingViewerPluginMimeType[] =
116 "application/vnd.chromium.remoting-viewer";
117 const char kRemotingViewerPluginMimeExtension[] = "";
118 const char kRemotingViewerPluginMimeDescription[] = "";
119 const uint32 kRemotingViewerPluginPermissions = ppapi::PERMISSION_PRIVATE |
120 ppapi::PERMISSION_DEV;
121 #endif // defined(ENABLE_REMOTING)
123 #if defined(OS_MACOSX) && !defined(OS_IOS)
124 const char kInterposeLibraryPath[] =
125 "@executable_path/../../../libplugin_carbon_interpose.dylib";
126 #endif // defined(OS_MACOSX) && !defined(OS_IOS)
128 // Appends the known built-in plugins to the given vector. Some built-in
129 // plugins are "internal" which means they are compiled into the Chrome binary,
130 // and some are extra shared libraries distributed with the browser (these are
131 // not marked internal, aside from being automatically registered, they're just
132 // regular plugins).
133 void ComputeBuiltInPlugins(std::vector<content::PepperPluginInfo>* plugins) {
134 // PDF.
136 // Once we're sandboxed, we can't know if the PDF plugin is available or not;
137 // but (on Linux) this function is always called once before we're sandboxed.
138 // So the first time through test if the file is available and then skip the
139 // check on subsequent calls if yes.
140 static bool skip_pdf_file_check = false;
141 base::FilePath path;
142 if (PathService::Get(chrome::FILE_PDF_PLUGIN, &path)) {
143 if (skip_pdf_file_check || base::PathExists(path)) {
144 content::PepperPluginInfo pdf;
145 pdf.path = path;
146 pdf.name = ChromeContentClient::kPDFPluginName;
147 if (CommandLine::ForCurrentProcess()->HasSwitch(
148 switches::kOutOfProcessPdf)) {
149 pdf.is_out_of_process = true;
150 content::WebPluginMimeType pdf_mime_type(kPDFPluginOutOfProcessMimeType,
151 kPDFPluginExtension,
152 kPDFPluginDescription);
153 pdf.mime_types.push_back(pdf_mime_type);
154 // TODO(raymes): Make print preview work with out of process PDF.
155 } else {
156 content::WebPluginMimeType pdf_mime_type(kPDFPluginMimeType,
157 kPDFPluginExtension,
158 kPDFPluginDescription);
159 content::WebPluginMimeType print_preview_pdf_mime_type(
160 kPDFPluginPrintPreviewMimeType,
161 kPDFPluginExtension,
162 kPDFPluginDescription);
163 pdf.mime_types.push_back(pdf_mime_type);
164 pdf.mime_types.push_back(print_preview_pdf_mime_type);
166 pdf.permissions = kPDFPluginPermissions;
167 plugins->push_back(pdf);
169 skip_pdf_file_check = true;
173 // Handle Native Client just like the PDF plugin. This means that it is
174 // enabled by default for the non-portable case. This allows apps installed
175 // from the Chrome Web Store to use NaCl even if the command line switch
176 // isn't set. For other uses of NaCl we check for the command line switch.
177 // Specifically, Portable Native Client is only enabled by the command line
178 // switch.
179 static bool skip_nacl_file_check = false;
180 if (PathService::Get(chrome::FILE_NACL_PLUGIN, &path)) {
181 if (skip_nacl_file_check || base::PathExists(path)) {
182 content::PepperPluginInfo nacl;
183 nacl.path = path;
184 nacl.name = ChromeContentClient::kNaClPluginName;
185 content::WebPluginMimeType nacl_mime_type(kNaClPluginMimeType,
186 kNaClPluginExtension,
187 kNaClPluginDescription);
188 nacl.mime_types.push_back(nacl_mime_type);
189 if (!CommandLine::ForCurrentProcess()->HasSwitch(
190 switches::kDisablePnacl)) {
191 content::WebPluginMimeType pnacl_mime_type(kPnaclPluginMimeType,
192 kPnaclPluginExtension,
193 kPnaclPluginDescription);
194 nacl.mime_types.push_back(pnacl_mime_type);
196 nacl.permissions = kNaClPluginPermissions;
197 plugins->push_back(nacl);
199 skip_nacl_file_check = true;
203 static bool skip_o1d_file_check = false;
204 if (PathService::Get(chrome::FILE_O1D_PLUGIN, &path)) {
205 if (skip_o1d_file_check || base::PathExists(path)) {
206 content::PepperPluginInfo o1d;
207 o1d.path = path;
208 o1d.name = kO1DPluginName;
209 o1d.is_out_of_process = true;
210 o1d.is_sandboxed = false;
211 o1d.permissions = kO1DPluginPermissions;
212 content::WebPluginMimeType o1d_mime_type(kO1DPluginMimeType,
213 kO1DPluginExtension,
214 kO1DPluginDescription);
215 o1d.mime_types.push_back(o1d_mime_type);
216 plugins->push_back(o1d);
218 skip_o1d_file_check = true;
222 // TODO(vrk): Remove this when NaCl effects plugin replaces the ppapi effects
223 // plugin.
224 static bool skip_effects_file_check = false;
225 if (PathService::Get(chrome::FILE_EFFECTS_PLUGIN, &path)) {
226 if (skip_effects_file_check || base::PathExists(path)) {
227 content::PepperPluginInfo effects;
228 effects.path = path;
229 effects.name = kEffectsPluginName;
230 effects.is_out_of_process = true;
231 effects.is_sandboxed = true;
232 effects.permissions = kEffectsPluginPermissions;
233 content::WebPluginMimeType effects_mime_type(kEffectsPluginMimeType,
234 kEffectsPluginExtension,
235 kEffectsPluginDescription);
236 effects.mime_types.push_back(effects_mime_type);
237 plugins->push_back(effects);
239 skip_effects_file_check = true;
243 static bool skip_gtalk_file_check = false;
244 if (PathService::Get(chrome::FILE_GTALK_PLUGIN, &path)) {
245 if (skip_gtalk_file_check || base::PathExists(path)) {
246 content::PepperPluginInfo gtalk;
247 gtalk.path = path;
248 gtalk.name = kGTalkPluginName;
249 gtalk.is_out_of_process = true;
250 gtalk.is_sandboxed = false;
251 gtalk.permissions = kGTalkPluginPermissions;
252 content::WebPluginMimeType gtalk_mime_type(kGTalkPluginMimeType,
253 kGTalkPluginExtension,
254 kGTalkPluginDescription);
255 gtalk.mime_types.push_back(gtalk_mime_type);
256 plugins->push_back(gtalk);
258 skip_gtalk_file_check = true;
262 #if defined(WIDEVINE_CDM_AVAILABLE) && defined(ENABLE_PEPPER_CDMS) && \
263 !defined(WIDEVINE_CDM_IS_COMPONENT)
264 static bool skip_widevine_cdm_file_check = false;
265 if (PathService::Get(chrome::FILE_WIDEVINE_CDM_ADAPTER, &path)) {
266 if (skip_widevine_cdm_file_check || base::PathExists(path)) {
267 content::PepperPluginInfo widevine_cdm;
268 widevine_cdm.is_out_of_process = true;
269 widevine_cdm.path = path;
270 widevine_cdm.name = kWidevineCdmDisplayName;
271 widevine_cdm.description = kWidevineCdmDescription;
272 widevine_cdm.version = WIDEVINE_CDM_VERSION_STRING;
273 content::WebPluginMimeType widevine_cdm_mime_type(
274 kWidevineCdmPluginMimeType,
275 kWidevineCdmPluginExtension,
276 kWidevineCdmPluginMimeTypeDescription);
278 // Add the supported codecs as if they came from the component manifest.
279 std::vector<std::string> codecs;
280 codecs.push_back(kCdmSupportedCodecVorbis);
281 codecs.push_back(kCdmSupportedCodecVp8);
282 #if defined(USE_PROPRIETARY_CODECS)
283 // TODO(ddorwin): Rename these macros to reflect their real meaning: whether the
284 // CDM Chrome was built [and shipped] with support these types.
285 #if defined(WIDEVINE_CDM_AAC_SUPPORT_AVAILABLE)
286 codecs.push_back(kCdmSupportedCodecAac);
287 #endif
288 #if defined(WIDEVINE_CDM_AVC1_SUPPORT_AVAILABLE)
289 codecs.push_back(kCdmSupportedCodecAvc1);
290 #endif
291 #endif // defined(USE_PROPRIETARY_CODECS)
292 std::string codec_string =
293 JoinString(codecs, kCdmSupportedCodecsValueDelimiter);
294 widevine_cdm_mime_type.additional_param_names.push_back(
295 base::ASCIIToUTF16(kCdmSupportedCodecsParamName));
296 widevine_cdm_mime_type.additional_param_values.push_back(
297 base::ASCIIToUTF16(codec_string));
299 widevine_cdm.mime_types.push_back(widevine_cdm_mime_type);
300 widevine_cdm.permissions = kWidevineCdmPluginPermissions;
301 plugins->push_back(widevine_cdm);
303 skip_widevine_cdm_file_check = true;
306 #endif // defined(WIDEVINE_CDM_AVAILABLE) && defined(ENABLE_PEPPER_CDMS) &&
307 // !defined(WIDEVINE_CDM_IS_COMPONENT)
309 // The Remoting Viewer plugin is built-in.
310 #if defined(ENABLE_REMOTING)
311 content::PepperPluginInfo info;
312 info.is_internal = true;
313 info.is_out_of_process = true;
314 info.name = kRemotingViewerPluginName;
315 info.description = kRemotingViewerPluginDescription;
316 info.path = base::FilePath::FromUTF8Unsafe(
317 ChromeContentClient::kRemotingViewerPluginPath);
318 content::WebPluginMimeType remoting_mime_type(
319 kRemotingViewerPluginMimeType,
320 kRemotingViewerPluginMimeExtension,
321 kRemotingViewerPluginMimeDescription);
322 info.mime_types.push_back(remoting_mime_type);
323 info.internal_entry_points.get_interface = remoting::PPP_GetInterface;
324 info.internal_entry_points.initialize_module =
325 remoting::PPP_InitializeModule;
326 info.internal_entry_points.shutdown_module = remoting::PPP_ShutdownModule;
327 info.permissions = kRemotingViewerPluginPermissions;
329 plugins->push_back(info);
330 #endif
333 content::PepperPluginInfo CreatePepperFlashInfo(const base::FilePath& path,
334 const std::string& version) {
335 content::PepperPluginInfo plugin;
337 plugin.is_out_of_process = true;
338 plugin.name = content::kFlashPluginName;
339 plugin.path = path;
340 plugin.permissions = kPepperFlashPermissions;
342 std::vector<std::string> flash_version_numbers;
343 base::SplitString(version, '.', &flash_version_numbers);
344 if (flash_version_numbers.size() < 1)
345 flash_version_numbers.push_back("11");
346 // |SplitString()| puts in an empty string given an empty string. :(
347 else if (flash_version_numbers[0].empty())
348 flash_version_numbers[0] = "11";
349 if (flash_version_numbers.size() < 2)
350 flash_version_numbers.push_back("2");
351 if (flash_version_numbers.size() < 3)
352 flash_version_numbers.push_back("999");
353 if (flash_version_numbers.size() < 4)
354 flash_version_numbers.push_back("999");
355 // E.g., "Shockwave Flash 10.2 r154":
356 plugin.description = plugin.name + " " + flash_version_numbers[0] + "." +
357 flash_version_numbers[1] + " r" + flash_version_numbers[2];
358 plugin.version = JoinString(flash_version_numbers, '.');
359 content::WebPluginMimeType swf_mime_type(content::kFlashPluginSwfMimeType,
360 content::kFlashPluginSwfExtension,
361 content::kFlashPluginSwfDescription);
362 plugin.mime_types.push_back(swf_mime_type);
363 content::WebPluginMimeType spl_mime_type(content::kFlashPluginSplMimeType,
364 content::kFlashPluginSplExtension,
365 content::kFlashPluginSplDescription);
366 plugin.mime_types.push_back(spl_mime_type);
368 return plugin;
371 void AddPepperFlashFromCommandLine(
372 std::vector<content::PepperPluginInfo>* plugins) {
373 const CommandLine::StringType flash_path =
374 CommandLine::ForCurrentProcess()->GetSwitchValueNative(
375 switches::kPpapiFlashPath);
376 if (flash_path.empty())
377 return;
379 // Also get the version from the command-line. Should be something like 11.2
380 // or 11.2.123.45.
381 std::string flash_version =
382 CommandLine::ForCurrentProcess()->GetSwitchValueASCII(
383 switches::kPpapiFlashVersion);
385 plugins->push_back(
386 CreatePepperFlashInfo(base::FilePath(flash_path), flash_version));
389 bool GetBundledPepperFlash(content::PepperPluginInfo* plugin) {
390 #if defined(FLAPPER_AVAILABLE)
391 CommandLine* command_line = CommandLine::ForCurrentProcess();
393 // Ignore bundled Pepper Flash if there is Pepper Flash specified from the
394 // command-line.
395 if (command_line->HasSwitch(switches::kPpapiFlashPath))
396 return false;
398 bool force_disable =
399 command_line->HasSwitch(switches::kDisableBundledPpapiFlash);
400 if (force_disable)
401 return false;
403 // For Linux ia32, Flapper requires SSE2.
404 #if defined(OS_LINUX) && defined(ARCH_CPU_X86)
405 if (!base::CPU().has_sse2())
406 return false;
407 #endif // ARCH_CPU_X86
409 base::FilePath flash_path;
410 if (!PathService::Get(chrome::FILE_PEPPER_FLASH_PLUGIN, &flash_path))
411 return false;
413 *plugin = CreatePepperFlashInfo(flash_path, FLAPPER_VERSION_STRING);
414 return true;
415 #else
416 return false;
417 #endif // FLAPPER_AVAILABLE
420 std::string GetProduct() {
421 chrome::VersionInfo version_info;
422 return version_info.is_valid() ?
423 version_info.ProductNameAndVersionForUserAgent() : std::string();
426 } // namespace
428 std::string GetUserAgent() {
429 CommandLine* command_line = CommandLine::ForCurrentProcess();
430 if (command_line->HasSwitch(switches::kUserAgent))
431 return command_line->GetSwitchValueASCII(switches::kUserAgent);
433 std::string product = GetProduct();
434 #if defined(OS_ANDROID)
435 if (command_line->HasSwitch(switches::kUseMobileUserAgent))
436 product += " Mobile";
437 #endif
438 return content::BuildUserAgentFromProduct(product);
441 void ChromeContentClient::SetActiveURL(const GURL& url) {
442 base::debug::SetCrashKeyValue(crash_keys::kActiveURL,
443 url.possibly_invalid_spec());
446 void ChromeContentClient::SetGpuInfo(const gpu::GPUInfo& gpu_info) {
447 #if !defined(OS_ANDROID)
448 base::debug::SetCrashKeyValue(crash_keys::kGPUVendorID,
449 base::StringPrintf("0x%04x", gpu_info.gpu.vendor_id));
450 base::debug::SetCrashKeyValue(crash_keys::kGPUDeviceID,
451 base::StringPrintf("0x%04x", gpu_info.gpu.device_id));
452 #endif
453 base::debug::SetCrashKeyValue(crash_keys::kGPUDriverVersion,
454 gpu_info.driver_version);
455 base::debug::SetCrashKeyValue(crash_keys::kGPUPixelShaderVersion,
456 gpu_info.pixel_shader_version);
457 base::debug::SetCrashKeyValue(crash_keys::kGPUVertexShaderVersion,
458 gpu_info.vertex_shader_version);
459 #if defined(OS_MACOSX)
460 base::debug::SetCrashKeyValue(crash_keys::kGPUGLVersion, gpu_info.gl_version);
461 #elif defined(OS_POSIX)
462 base::debug::SetCrashKeyValue(crash_keys::kGPUVendor, gpu_info.gl_vendor);
463 base::debug::SetCrashKeyValue(crash_keys::kGPURenderer, gpu_info.gl_renderer);
464 #endif
467 void ChromeContentClient::AddPepperPlugins(
468 std::vector<content::PepperPluginInfo>* plugins) {
469 ComputeBuiltInPlugins(plugins);
470 AddPepperFlashFromCommandLine(plugins);
472 content::PepperPluginInfo plugin;
473 if (GetBundledPepperFlash(&plugin))
474 plugins->push_back(plugin);
477 void ChromeContentClient::AddAdditionalSchemes(
478 std::vector<std::string>* standard_schemes,
479 std::vector<std::string>* savable_schemes) {
480 standard_schemes->push_back(extensions::kExtensionScheme);
481 savable_schemes->push_back(extensions::kExtensionScheme);
482 standard_schemes->push_back(chrome::kChromeNativeScheme);
483 standard_schemes->push_back(extensions::kExtensionResourceScheme);
484 savable_schemes->push_back(extensions::kExtensionResourceScheme);
485 standard_schemes->push_back(chrome::kChromeSearchScheme);
486 savable_schemes->push_back(chrome::kChromeSearchScheme);
487 standard_schemes->push_back(chrome::kDomDistillerScheme);
488 savable_schemes->push_back(chrome::kDomDistillerScheme);
489 #if defined(OS_CHROMEOS)
490 standard_schemes->push_back(chrome::kCrosScheme);
491 #endif
494 bool ChromeContentClient::CanHandleWhileSwappedOut(
495 const IPC::Message& msg) {
496 // Any Chrome-specific messages (apart from those listed in
497 // CanSendWhileSwappedOut) that must be handled by the browser when sent from
498 // swapped out renderers.
499 return false;
502 std::string ChromeContentClient::GetProduct() const {
503 return ::GetProduct();
506 std::string ChromeContentClient::GetUserAgent() const {
507 return ::GetUserAgent();
510 base::string16 ChromeContentClient::GetLocalizedString(int message_id) const {
511 return l10n_util::GetStringUTF16(message_id);
514 base::StringPiece ChromeContentClient::GetDataResource(
515 int resource_id,
516 ui::ScaleFactor scale_factor) const {
517 return ResourceBundle::GetSharedInstance().GetRawDataResourceForScale(
518 resource_id, scale_factor);
521 base::RefCountedStaticMemory* ChromeContentClient::GetDataResourceBytes(
522 int resource_id) const {
523 return ResourceBundle::GetSharedInstance().LoadDataResourceBytes(resource_id);
526 gfx::Image& ChromeContentClient::GetNativeImageNamed(int resource_id) const {
527 return ResourceBundle::GetSharedInstance().GetNativeImageNamed(resource_id);
530 std::string ChromeContentClient::GetProcessTypeNameInEnglish(int type) {
531 switch (type) {
532 case PROCESS_TYPE_NACL_LOADER:
533 return "Native Client module";
534 case PROCESS_TYPE_NACL_BROKER:
535 return "Native Client broker";
538 DCHECK(false) << "Unknown child process type!";
539 return "Unknown";
542 #if defined(OS_MACOSX) && !defined(OS_IOS)
543 bool ChromeContentClient::GetSandboxProfileForSandboxType(
544 int sandbox_type,
545 int* sandbox_profile_resource_id) const {
546 DCHECK(sandbox_profile_resource_id);
547 if (sandbox_type == NACL_SANDBOX_TYPE_NACL_LOADER) {
548 *sandbox_profile_resource_id = IDR_NACL_SANDBOX_PROFILE;
549 return true;
551 return false;
554 std::string ChromeContentClient::GetCarbonInterposePath() const {
555 return std::string(kInterposeLibraryPath);
557 #endif