Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(225)

Side by Side Diff: content/common/sandbox_seccomp_bpf_linux.h

Issue 10843042: Create a class for seccomp-bpf sandboxing in content. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Correct typo. Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
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.
4
5 #ifndef CONTENT_COMMON_SANDBOX_SECCOMP_BPF_LINUX_H_
6 #define CONTENT_COMMON_SANDBOX_SECCOMP_BPF_LINUX_H_
7
8 #include "base/basictypes.h"
9
10 namespace content {
11
12 class SandboxSeccompBpf {
13 public:
14 // Is the sandbox globally enabled, can anything use it at all ?
15 static bool IsSeccompBpfDesired();
16 // Should the sandbox be enabled for process_type ?
17 static bool ShouldEnableSeccompBpf(const std::string& process_type);
18 // Check if the kernel supports this sandbox. It's useful to "prewarm"
19 // this, part of the result will be cached.
20 static bool SupportsSandbox();
21 // Start the sandbox and apply the policy for process_type.
22 static bool StartSandbox(const std::string& process_type);
23
24 private:
25 DISALLOW_IMPLICIT_CONSTRUCTORS(SandboxSeccompBpf);
26 };
27
28 } // namespace content
29
30 #endif // CONTENT_COMMON_SANDBOX_SECCOMP_BPF_LINUX_H_
31
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698