| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include <dlfcn.h> | 5 #include <dlfcn.h> |
| 6 #include <fcntl.h> | 6 #include <fcntl.h> |
| 7 #include <pthread.h> | 7 #include <pthread.h> |
| 8 #include <sys/epoll.h> | 8 #include <sys/epoll.h> |
| 9 #include <sys/prctl.h> | 9 #include <sys/prctl.h> |
| 10 #include <sys/signal.h> | 10 #include <sys/signal.h> |
| (...skipping 20 matching lines...) Expand all Loading... |
| 31 #include "base/nss_util.h" | 31 #include "base/nss_util.h" |
| 32 #include "base/path_service.h" | 32 #include "base/path_service.h" |
| 33 #include "base/pickle.h" | 33 #include "base/pickle.h" |
| 34 #include "base/process_util.h" | 34 #include "base/process_util.h" |
| 35 #include "base/rand_util.h" | 35 #include "base/rand_util.h" |
| 36 #include "base/scoped_ptr.h" | 36 #include "base/scoped_ptr.h" |
| 37 #include "base/sys_info.h" | 37 #include "base/sys_info.h" |
| 38 #include "build/build_config.h" | 38 #include "build/build_config.h" |
| 39 #include "chrome/common/chrome_descriptors.h" | 39 #include "chrome/common/chrome_descriptors.h" |
| 40 #include "chrome/common/chrome_switches.h" | 40 #include "chrome/common/chrome_switches.h" |
| 41 #include "chrome/common/font_config_ipc_linux.h" | |
| 42 #include "chrome/common/pepper_plugin_registry.h" | 41 #include "chrome/common/pepper_plugin_registry.h" |
| 43 #include "chrome/common/process_watcher.h" | 42 #include "chrome/common/process_watcher.h" |
| 44 #include "chrome/common/result_codes.h" | 43 #include "chrome/common/result_codes.h" |
| 45 #include "chrome/common/sandbox_methods_linux.h" | 44 #include "chrome/common/sandbox_methods_linux.h" |
| 46 #include "chrome/common/set_process_title.h" | 45 #include "chrome/common/set_process_title.h" |
| 47 #include "chrome/common/unix_domain_socket_posix.h" | 46 #include "content/common/font_config_ipc_linux.h" |
| 48 #include "content/common/main_function_params.h" | 47 #include "content/common/main_function_params.h" |
| 48 #include "content/common/unix_domain_socket_posix.h" |
| 49 #include "media/base/media.h" | 49 #include "media/base/media.h" |
| 50 #include "seccompsandbox/sandbox.h" | 50 #include "seccompsandbox/sandbox.h" |
| 51 #include "skia/ext/SkFontHost_fontconfig_control.h" | 51 #include "skia/ext/SkFontHost_fontconfig_control.h" |
| 52 #include "unicode/timezone.h" | 52 #include "unicode/timezone.h" |
| 53 | 53 |
| 54 #if defined(ARCH_CPU_X86_FAMILY) && !defined(CHROMIUM_SELINUX) && \ | 54 #if defined(ARCH_CPU_X86_FAMILY) && !defined(CHROMIUM_SELINUX) && \ |
| 55 !defined(__clang__) | 55 !defined(__clang__) |
| 56 // The seccomp sandbox is enabled on all ia32 and x86-64 processor as long as | 56 // The seccomp sandbox is enabled on all ia32 and x86-64 processor as long as |
| 57 // we aren't using SELinux or clang. | 57 // we aren't using SELinux or clang. |
| 58 #define SECCOMP_SANDBOX | 58 #define SECCOMP_SANDBOX |
| (...skipping 703 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 762 VLOG(1) << "Enabling experimental Seccomp sandbox."; | 762 VLOG(1) << "Enabling experimental Seccomp sandbox."; |
| 763 sandbox_flags |= ZygoteHost::kSandboxSeccomp; | 763 sandbox_flags |= ZygoteHost::kSandboxSeccomp; |
| 764 } | 764 } |
| 765 } | 765 } |
| 766 #endif // SECCOMP_SANDBOX | 766 #endif // SECCOMP_SANDBOX |
| 767 | 767 |
| 768 Zygote zygote(sandbox_flags); | 768 Zygote zygote(sandbox_flags); |
| 769 // This function call can return multiple times, once per fork(). | 769 // This function call can return multiple times, once per fork(). |
| 770 return zygote.ProcessRequests(); | 770 return zygote.ProcessRequests(); |
| 771 } | 771 } |
| OLD | NEW |