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

Unified Diff: sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc

Issue 566083002: Linux sandbox: restrict clock_gettime() and clock_getres() (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
« no previous file with comments | « sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
diff --git a/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc b/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
index c0a720a3b6fb0bf86d2c6c1fdf6e1b4c086530ba..de6ba24f1e5c2de2c1ad66235ae1ca2849fea877 100644
--- a/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
+++ b/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc
@@ -27,7 +27,6 @@ bool SyscallSets::IsKill(int sysno) {
bool SyscallSets::IsAllowedGettime(int sysno) {
switch (sysno) {
- case __NR_clock_gettime:
case __NR_gettimeofday:
#if defined(__i386__) || defined(__x86_64__) || defined(__mips__)
case __NR_time:
@@ -36,6 +35,7 @@ bool SyscallSets::IsAllowedGettime(int sysno) {
case __NR_adjtimex: // Privileged.
case __NR_clock_adjtime: // Privileged.
case __NR_clock_getres: // Could be allowed.
+ case __NR_clock_gettime:
case __NR_clock_nanosleep: // Could be allowed.
case __NR_clock_settime: // Privileged.
#if defined(__i386__) || defined(__mips__)
« no previous file with comments | « sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698