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

Unified Diff: sandbox/linux/seccomp-bpf-helpers/baseline_policy.h

Issue 590213003: Linux sandbox: Allow restricting sched_* on other processes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: sandbox/linux/seccomp-bpf-helpers/baseline_policy.h
diff --git a/sandbox/linux/seccomp-bpf-helpers/baseline_policy.h b/sandbox/linux/seccomp-bpf-helpers/baseline_policy.h
index 8f842f09fdd9826dcbbbb05a7656313a9c6d8e6b..24e13dce767bd6d415e59d34b4cf0f5052b43f09 100644
--- a/sandbox/linux/seccomp-bpf-helpers/baseline_policy.h
+++ b/sandbox/linux/seccomp-bpf-helpers/baseline_policy.h
@@ -32,6 +32,8 @@ class SANDBOX_EXPORT BaselinePolicy : public bpf_dsl::SandboxBPFDSLPolicy {
virtual bpf_dsl::ResultExpr EvaluateSyscall(
int system_call_number) const OVERRIDE;
virtual bpf_dsl::ResultExpr InvalidSyscall() const OVERRIDE;
+ // Returns the pid of the process being sandboxed.
+ pid_t GetCurrentPid() const;
jln (very slow on Chromium) 2014/09/22 21:56:44 As per style-guide, this can just be current_pid()
rickyz (no longer on Chrome) 2014/09/23 06:03:20 Good to know, removed this for now and will reintr
private:
int fs_denied_errno_;

Powered by Google App Engine
This is Rietveld 408576698