OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #ifndef SANDBOX_LINUX_SERVICES_SYSCALL_WRAPPERS_H_ | 5 #ifndef SANDBOX_LINUX_SERVICES_SYSCALL_WRAPPERS_H_ |
6 #define SANDBOX_LINUX_SERVICES_SYSCALL_WRAPPERS_H_ | 6 #define SANDBOX_LINUX_SERVICES_SYSCALL_WRAPPERS_H_ |
7 | 7 |
| 8 #include <signal.h> |
8 #include <stdint.h> | 9 #include <stdint.h> |
9 #include <sys/types.h> | 10 #include <sys/types.h> |
10 | 11 |
11 #include "sandbox/sandbox_export.h" | 12 #include "sandbox/sandbox_export.h" |
12 | 13 |
13 struct sock_fprog; | 14 struct sock_fprog; |
14 struct rlimit64; | 15 struct rlimit64; |
15 struct cap_hdr; | 16 struct cap_hdr; |
16 struct cap_data; | 17 struct cap_data; |
17 | 18 |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
59 // Some libcs do not expose getresuid/getresgid wrappers. | 60 // Some libcs do not expose getresuid/getresgid wrappers. |
60 SANDBOX_EXPORT int sys_getresuid(uid_t* ruid, uid_t* euid, uid_t* suid); | 61 SANDBOX_EXPORT int sys_getresuid(uid_t* ruid, uid_t* euid, uid_t* suid); |
61 SANDBOX_EXPORT int sys_getresgid(gid_t* rgid, gid_t* egid, gid_t* sgid); | 62 SANDBOX_EXPORT int sys_getresgid(gid_t* rgid, gid_t* egid, gid_t* sgid); |
62 | 63 |
63 // Some libcs do not expose a chroot wrapper. | 64 // Some libcs do not expose a chroot wrapper. |
64 SANDBOX_EXPORT int sys_chroot(const char* path); | 65 SANDBOX_EXPORT int sys_chroot(const char* path); |
65 | 66 |
66 // Some libcs do not expose a unshare wrapper. | 67 // Some libcs do not expose a unshare wrapper. |
67 SANDBOX_EXPORT int sys_unshare(int flags); | 68 SANDBOX_EXPORT int sys_unshare(int flags); |
68 | 69 |
| 70 // Some libcs do not expose a sigprocmask. Note that oldset must be a nullptr, |
| 71 // because of some ABI gap between toolchain's and Linux's. |
| 72 SANDBOX_EXPORT int sys_sigprocmask( |
| 73 int how, const sigset_t* set, decltype(nullptr) oldset); |
| 74 |
| 75 // Some libcs do not expose a sigaction(). |
| 76 SANDBOX_EXPORT int sys_sigaction(int signum, const struct sigaction* act, |
| 77 struct sigaction* oldact); |
| 78 |
69 } // namespace sandbox | 79 } // namespace sandbox |
70 | 80 |
71 #endif // SANDBOX_LINUX_SERVICES_SYSCALL_WRAPPERS_H_ | 81 #endif // SANDBOX_LINUX_SERVICES_SYSCALL_WRAPPERS_H_ |
OLD | NEW |