Home | History | Annotate | Download | only in seccomp-bpf-helpers

Lines Matching full:sysno

41 bool IsBaselinePolicyAllowed(int sysno) {
42 return SyscallSets::IsAllowedAddressSpaceAccess(sysno) ||
43 SyscallSets::IsAllowedBasicScheduler(sysno) ||
44 SyscallSets::IsAllowedEpoll(sysno) ||
45 SyscallSets::IsAllowedFileSystemAccessViaFd(sysno) ||
46 SyscallSets::IsAllowedFutex(sysno) ||
47 SyscallSets::IsAllowedGeneralIo(sysno) ||
48 SyscallSets::IsAllowedGetOrModifySocket(sysno) ||
49 SyscallSets::IsAllowedGettime(sysno) ||
50 SyscallSets::IsAllowedProcessStartOrDeath(sysno) ||
51 SyscallSets::IsAllowedSignalHandling(sysno) ||
52 SyscallSets::IsGetSimpleId(sysno) ||
53 SyscallSets::IsKernelInternalApi(sysno) ||
55 SyscallSets::IsArmPrivate(sysno) ||
58 SyscallSets::IsMipsPrivate(sysno) ||
60 SyscallSets::IsAllowedOperationOnFd(sysno);
64 bool IsBaselinePolicyWatched(int sysno) {
65 return SyscallSets::IsAdminOperation(sysno) ||
66 SyscallSets::IsAdvancedScheduler(sysno) ||
67 SyscallSets::IsAdvancedTimer(sysno) ||
68 SyscallSets::IsAsyncIo(sysno) ||
69 SyscallSets::IsDebug(sysno) ||
70 SyscallSets::IsEventFd(sysno) ||
71 SyscallSets::IsExtendedAttributes(sysno) ||
72 SyscallSets::IsFaNotify(sysno) ||
73 SyscallSets::IsFsControl(sysno) ||
74 SyscallSets::IsGlobalFSViewChange(sysno) ||
75 SyscallSets::IsGlobalProcessEnvironment(sysno) ||
76 SyscallSets::IsGlobalSystemStatus(sysno) ||
77 SyscallSets::IsInotify(sysno) ||
78 SyscallSets::IsKernelModule(sysno) ||
79 SyscallSets::IsKeyManagement(sysno) ||
80 SyscallSets::IsKill(sysno) ||
81 SyscallSets::IsMessageQueue(sysno) ||
82 SyscallSets::IsMisc(sysno) ||
84 SyscallSets::IsNetworkSocketInformation(sysno) ||
86 SyscallSets::IsNuma(sysno) ||
87 SyscallSets::IsPrctl(sysno) ||
88 SyscallSets::IsProcessGroupOrSession(sysno) ||
90 SyscallSets::IsSocketCall(sysno) ||
93 SyscallSets::IsArmPciConfig(sysno) ||
96 SyscallSets::IsMipsMisc(sysno) ||
98 SyscallSets::IsTimer(sysno);
104 int sysno) {
108 if (sysno == __NR_ioctl) {
112 if (sysno == __NR_sched_getaffinity) {
117 if (sysno == __NR_getrusage) {
121 if (sysno == __NR_sigaltstack) {
129 if (IsBaselinePolicyAllowed(sysno)) {
135 if (sysno == __NR_sigaltstack)
139 if (sysno == __NR_clock_gettime) {
143 if (sysno == __NR_clone) {
147 if (sysno == __NR_fcntl)
151 if (sysno == __NR_fcntl64)
158 if (sysno == __NR_fork) {
163 if (sysno == __NR_futex)
166 if (sysno == __NR_set_robust_list)
169 if (sysno == __NR_getpriority || sysno ==__NR_setpriority)
172 if (sysno == __NR_madvise) {
180 if (sysno == __NR_mmap)
185 if (sysno == __NR_mmap2)
189 if (sysno == __NR_mprotect)
192 if (sysno == __NR_prctl)
197 if (sysno == __NR_socketpair) {
206 if (SyscallSets::IsKill(sysno)) {
207 return RestrictKillTarget(current_pid, sysno);
210 if (SyscallSets::IsFileSystem(sysno) ||
211 SyscallSets::IsCurrentDirectory(sysno)) {
215 if (SyscallSets::IsSeccomp(sysno))
218 if (SyscallSets::IsAnySystemV(sysno)) {
222 if (SyscallSets::IsUmask(sysno) ||
223 SyscallSets::IsDeniedFileSystemAccessViaFd(sysno) ||
224 SyscallSets::IsDeniedGetOrModifySocket(sysno) ||
225 SyscallSets::IsProcessPrivilegeChange(sysno)) {
230 if (SyscallSets::IsSocketCall(sysno))
235 if (sysno == __NR_getsockopt || sysno ==__NR_setsockopt) {
244 if (IsBaselinePolicyWatched(sysno)) {
270 ResultExpr BaselinePolicy::EvaluateSyscall(int sysno) const {
272 DCHECK(SandboxBPF::IsValidSyscallNumber(sysno));
274 if (1 == sysno) {
277 return EvaluateSyscallImpl(fs_denied_errno_, policy_pid_, sysno);