From c6bab976907ab5dfe2fd50eafcc50ede1bf9ca79 Mon Sep 17 00:00:00 2001 From: Sandboxed API Team Date: Tue, 5 Mar 2024 11:06:15 -0800 Subject: [PATCH] Added more descriptive Syscall argument types, and an API for introspecting arguments. PiperOrigin-RevId: 612904089 Change-Id: Ia0ef7b0559f7eed923981b13fa8224bc891e8c37 --- sandboxed_api/sandbox2/BUILD.bazel | 3 + sandboxed_api/sandbox2/CMakeLists.txt | 5 +- sandboxed_api/sandbox2/syscall.cc | 4 + sandboxed_api/sandbox2/syscall.h | 3 +- sandboxed_api/sandbox2/syscall_defs.cc | 3049 ++++++++++++------------ sandboxed_api/sandbox2/syscall_defs.h | 194 +- sandboxed_api/sandbox2/util.cc | 108 +- sandboxed_api/sandbox2/util.h | 10 + 8 files changed, 1855 insertions(+), 1521 deletions(-) diff --git a/sandboxed_api/sandbox2/BUILD.bazel b/sandboxed_api/sandbox2/BUILD.bazel index 3b08b55..1f93d74 100644 --- a/sandboxed_api/sandbox2/BUILD.bazel +++ b/sandboxed_api/sandbox2/BUILD.bazel @@ -136,6 +136,7 @@ cc_library( deps = [ ":util", "//sandboxed_api:config", + "//sandboxed_api/util:status", "@com_google_absl//absl/algorithm:container", "@com_google_absl//absl/status", "@com_google_absl//absl/status:statusor", @@ -799,6 +800,8 @@ cc_library( "//sandboxed_api/util:file_helpers", "//sandboxed_api/util:fileops", "//sandboxed_api/util:raw_logging", + "//sandboxed_api/util:status", + "@com_google_absl//absl/algorithm:container", "@com_google_absl//absl/base:core_headers", "@com_google_absl//absl/status", "@com_google_absl//absl/status:statusor", diff --git a/sandboxed_api/sandbox2/CMakeLists.txt b/sandboxed_api/sandbox2/CMakeLists.txt index b01c4d9..9fb174d 100644 --- a/sandboxed_api/sandbox2/CMakeLists.txt +++ b/sandboxed_api/sandbox2/CMakeLists.txt @@ -90,6 +90,7 @@ target_link_libraries(sandbox2_syscall absl::strings sandbox2::util sapi::base + sapi::status PUBLIC absl::log ) @@ -687,7 +688,8 @@ add_library(sandbox2_util ${SAPI_LIB_TYPE} ) add_library(sandbox2::util ALIAS sandbox2_util) target_link_libraries(sandbox2_util - PRIVATE absl::core_headers + PRIVATE absl::algorithm_container + absl::core_headers absl::str_format absl::strings sapi::config @@ -696,6 +698,7 @@ target_link_libraries(sandbox2_util sapi::fileops sapi::base sapi::raw_logging + sapi::status PUBLIC absl::status absl::statusor ) diff --git a/sandboxed_api/sandbox2/syscall.cc b/sandboxed_api/sandbox2/syscall.cc index 57ca819..bd42f64 100644 --- a/sandboxed_api/sandbox2/syscall.cc +++ b/sandboxed_api/sandbox2/syscall.cc @@ -74,6 +74,10 @@ std::string Syscall::GetName() const { return absl::StrFormat("UNKNOWN[%d/0x%x]", nr_, nr_); } +std::vector Syscall::GetArgumentsData() const { + return SyscallTable::get(arch_).GetArgumentsData(nr_, args_.data(), pid_); +} + std::vector Syscall::GetArgumentsDescription() const { return SyscallTable::get(arch_).GetArgumentsDescription(nr_, args_.data(), pid_); diff --git a/sandboxed_api/sandbox2/syscall.h b/sandboxed_api/sandbox2/syscall.h index b4e5bd0..23d2015 100644 --- a/sandboxed_api/sandbox2/syscall.h +++ b/sandboxed_api/sandbox2/syscall.h @@ -27,6 +27,7 @@ #include #include "sandboxed_api/config.h" // IWYU pragma: export +#include "sandboxed_api/sandbox2/syscall_defs.h" namespace sandbox2 { @@ -59,7 +60,7 @@ class Syscall { uint64_t instruction_pointer() const { return ip_; } std::string GetName() const; - + std::vector GetArgumentsData() const; std::vector GetArgumentsDescription() const; std::string GetDescription() const; diff --git a/sandboxed_api/sandbox2/syscall_defs.cc b/sandboxed_api/sandbox2/syscall_defs.cc index a7b41ed..b53de8a 100644 --- a/sandboxed_api/sandbox2/syscall_defs.cc +++ b/sandboxed_api/sandbox2/syscall_defs.cc @@ -1,10 +1,21 @@ #include "sandboxed_api/sandbox2/syscall_defs.h" +#include +#include +#include +#include +#include +#include +#include +#include #include +#include #include #include +#include #include +#include #include #include "absl/algorithm/container.h" @@ -14,38 +25,79 @@ #include "absl/strings/str_cat.h" #include "absl/strings/str_format.h" #include "absl/strings/string_view.h" +#include "absl/types/span.h" #include "sandboxed_api/config.h" #include "sandboxed_api/sandbox2/util.h" +#include "sandboxed_api/util/status_macros.h" namespace sandbox2 { -std::string SyscallTable::Entry::GetArgumentDescription(uint64_t value, - syscalls::ArgType type, - pid_t pid) { - std::string ret = absl::StrFormat("%#x", value); - switch (type) { - case syscalls::kOct: - absl::StrAppendFormat(&ret, " [\\0%o]", value); +namespace syscalls { + +absl::StatusOr syscalls::ArgData::GetDescriptionImpl() const { + std::string formatted; + switch (type_) { + case kPath: { + SAPI_ASSIGN_OR_RETURN(std::string str, ReadAsString()); + formatted = absl::StrFormat("'%s'", absl::CHexEscape(str)); break; - case syscalls::kPath: - if (auto path_or = util::ReadCPathFromPid(pid, value); path_or.ok()) { - absl::StrAppendFormat(&ret, " ['%s']", - absl::CHexEscape(path_or.value())); - } else { - absl::StrAppend(&ret, " [unreadable path]"); - } + } + case kString: { + SAPI_ASSIGN_OR_RETURN(std::string str, ReadAsString()); + formatted = absl::StrFormat("\"%s\"", absl::CHexEscape(str)); break; - case syscalls::kInt: - absl::StrAppendFormat(&ret, " [%d]", value); + } + case kFlags: + formatted = absl::StrFormat("\\0%o", value_); + break; + case kSignal: + formatted = util::GetSignalName(value_); + break; + case kAddressFamily: + formatted = util::GetAddressFamily(value_); + break; + case kInt: + case kResource: + case kIpcResource: + case kPid: + case kGid: + case kUid: + case kLen0: + case kLen1: + case kLen2: + case kLen3: + case kLen4: + case kLen5: + formatted = absl::StrCat(value_); + break; + case kPollFdArray: + case kSockaddr: + case kGen: + case kStruct: + case kPtr: + case kArray: + case kSharedAddress: + case kGidArray: break; default: - break; + return absl::InternalError("Unable to format invalid type"); } - return ret; + + if (formatted.empty()) { + return absl::StrFormat("%#x", value_); + } + return absl::StrFormat("%#x [%s]", value_, formatted); } +std::string ArgData::GetDescription() const { + return GetDescriptionImpl().value_or( + absl::StrFormat("%#x [unavailable]", value_)); +} + +} // namespace syscalls + absl::string_view SyscallTable::GetName(int syscall) const { - auto entry = GetEntry(syscall); + absl::StatusOr entry = GetEntry(syscall); if (!entry.ok()) { return ""; } @@ -100,23 +152,48 @@ absl::StatusOr SyscallTable::GetEntry( } } -std::vector SyscallTable::GetArgumentsDescription( +constexpr SyscallTable::Entry kInvalidEntry = + MakeEntry(-1, "unknown_syscall", UnknownArguments()); + +std::vector SyscallTable::GetArgumentsData( int syscall, const uint64_t values[], pid_t pid) const { - static SyscallTable::Entry kInvalidEntry = - MakeEntry(-1, "", UnknownArguments()); - auto entry = GetEntry(syscall); - if (!entry.ok()) { - entry = kInvalidEntry; + SyscallTable::Entry entry = GetEntry(syscall).value_or(kInvalidEntry); + // First do a length scan. + std::array, syscalls::kMaxArgs> lengths; + for (int i = 0; i < entry.GetNumArgs(); ++i) { + syscalls::ArgType type = entry.arg_types[i]; + if (type == syscalls::kLen0) { + lengths[0] = values[i]; + } else if (type == syscalls::kLen1) { + lengths[1] = values[i]; + } else if (type == syscalls::kLen2) { + lengths[2] = values[i]; + } else if (type == syscalls::kLen3) { + lengths[3] = values[i]; + } else if (type == syscalls::kLen4) { + lengths[4] = values[i]; + } else if (type == syscalls::kLen5) { + lengths[5] = values[i]; + } } - int num_args = entry->GetNumArgs(); - std::vector rv; - rv.reserve(num_args); - for (int i = 0; i < num_args; ++i) { - rv.push_back(SyscallTable::Entry::GetArgumentDescription( - values[i], entry->arg_types[i], pid)); + // Then get all verbose descriptions, passing the correct lengths where used. + std::vector args; + for (int i = 0; i < entry.GetNumArgs(); ++i) { + const syscalls::ArgType type = entry.arg_types[i]; + args.push_back(syscalls::ArgData(type, pid, values[i], lengths[i])); } - return rv; + + return args; +} + +std::vector SyscallTable::GetArgumentsDescription( + int syscall, const uint64_t values[], pid_t pid) const { + std::vector descriptions; + for (const syscalls::ArgData& arg : GetArgumentsData(syscall, values, pid)) { + descriptions.push_back(arg.GetDescription()); + } + return descriptions; } namespace syscalls { @@ -142,351 +219,354 @@ constexpr bool IsSorted(const Container& container, Compare comp) { // Syscall description table for Linux x86_64 constexpr std::array kSyscallDataX8664 = { // clang-format off - MakeEntry(0, "read", kInt, kHex, kInt), - MakeEntry(1, "write", kInt, kHex, kInt), - MakeEntry(2, "open", kPath, kHex, kOct), - MakeEntry(3, "close", kInt), - MakeEntry(4, "stat", kPath, kGen), - MakeEntry(5, "fstat", kInt, kHex), - MakeEntry(6, "lstat", kPath, kGen), - MakeEntry(7, "poll", kGen, kInt, kInt), - MakeEntry(8, "lseek", kInt, kInt, kInt), - MakeEntry(9, "mmap", kHex, kInt, kHex, kHex, kInt, kInt), - MakeEntry(10, "mprotect", kHex, kInt, kHex), - MakeEntry(11, "munmap", kHex, kInt), + + MakeEntry(0, "read", kResource, kArray, kLen1), + MakeEntry(1, "write", kResource, kArray, kLen1), + MakeEntry(2, "open", kPath, kFlags, kFlags), + MakeEntry(3, "close", kResource), + MakeEntry(4, "stat", kPath, kPtr), + MakeEntry(5, "fstat", kResource, kPtr), + MakeEntry(6, "lstat", kPath, kPtr), + MakeEntry(7, "poll", kPollFdArray, kLen0, kInt), + MakeEntry(8, "lseek", kResource, kInt, kFlags), + MakeEntry(9, "mmap", kPtr, kLen0, kFlags, kFlags, kResource, kInt), + MakeEntry(10, "mprotect", kPtr, kLen0, kFlags), + MakeEntry(11, "munmap", kPtr, kLen0), MakeEntry(12, "brk", kInt), - MakeEntry(13, "rt_sigaction", kSignal, kHex, kHex, kInt), - MakeEntry(14, "rt_sigprocmask", kInt, kHex, kHex, kInt), + MakeEntry(13, "rt_sigaction", kSignal, kPtr, kPtr, kLen4, kPtr), + MakeEntry(14, "rt_sigprocmask", kFlags, kPtr, kPtr, kLen1), MakeEntry(15, "rt_sigreturn"), - MakeEntry(16, "ioctl", kInt, kInt, kHex), - MakeEntry(17, "pread64", kInt, kHex, kInt, kInt), - MakeEntry(18, "pwrite64", kInt, kHex, kInt, kInt), - MakeEntry(19, "readv", kInt, kHex, kInt), - MakeEntry(20, "writev", kInt, kHex, kInt), - MakeEntry(21, "access", kPath, kOct), - MakeEntry(22, "pipe", kHex), - MakeEntry(23, "select", kInt, kHex, kHex, kHex, kHex), + MakeEntry(16, "ioctl", kResource, kInt, kArray), + MakeEntry(17, "pread64", kResource, kArray, kLen1, kInt), + MakeEntry(18, "pwrite64", kResource, kArray, kLen1, kInt), + MakeEntry(19, "readv", kResource, kArray, kLen1), + MakeEntry(20, "writev", kResource, kArray, kLen1), + MakeEntry(21, "access", kPath, kFlags), + MakeEntry(22, "pipe", kPtr), + MakeEntry(23, "select", kLen1, kPtr, kPtr, kPtr, kPtr), MakeEntry(24, "sched_yield"), - MakeEntry(25, "mremap", kHex, kInt, kInt, kInt, kHex), - MakeEntry(26, "msync", kHex, kInt, kInt), - MakeEntry(27, "mincore", kHex, kInt, kHex), - MakeEntry(28, "madvise", kHex, kInt, kInt), - MakeEntry(29, "shmget", kInt, kInt, kHex), - MakeEntry(30, "shmat", kInt, kHex, kHex), - MakeEntry(31, "shmctl", kInt, kInt, kHex), - MakeEntry(32, "dup", kInt), - MakeEntry(33, "dup2", kInt, kInt), + MakeEntry(25, "mremap", kPtr, kLen0, kLen4, kFlags, kPtr), + MakeEntry(26, "msync", kPtr, kLen0, kFlags), + MakeEntry(27, "mincore", kPtr, kLen0, kArray), + MakeEntry(28, "madvise", kPtr, kLen0, kFlags), + MakeEntry(29, "shmget", kInt, kLen3, kFlags, kPtr), + MakeEntry(30, "shmat", kIpcResource, kPtr, kFlags), + MakeEntry(31, "shmctl", kIpcResource, kInt, kArray), + MakeEntry(32, "dup", kResource), + MakeEntry(33, "dup2", kResource, kResource), MakeEntry(34, "pause"), - MakeEntry(35, "nanosleep", kHex, kHex), - MakeEntry(36, "getitimer", kInt, kHex), + MakeEntry(35, "nanosleep", kPtr, kPtr), + MakeEntry(36, "getitimer", kFlags, kPtr), MakeEntry(37, "alarm", kInt), - MakeEntry(38, "setitimer", kInt, kHex, kHex), + MakeEntry(38, "setitimer", kFlags, kPtr, kPtr), MakeEntry(39, "getpid"), - MakeEntry(40, "sendfile", kInt, kInt, kHex, kInt), - MakeEntry(41, "socket", kAddressFamily, kInt, kInt), - MakeEntry(42, "connect", kInt, kSockaddr, kInt), - MakeEntry(43, "accept", kInt, kSockaddr, kHex), - MakeEntry(44, "sendto", kInt, kHex, kInt, kHex, kSockaddr, kInt), - MakeEntry(45, "recvfrom", kInt, kHex, kInt, kHex, kSockaddr, kHex), - MakeEntry(46, "sendmsg", kInt, kSockmsghdr, kHex), - MakeEntry(47, "recvmsg", kInt, kHex, kInt), - MakeEntry(48, "shutdown", kInt, kInt), - MakeEntry(49, "bind", kInt, kSockaddr, kInt), - MakeEntry(50, "listen", kInt, kInt), - MakeEntry(51, "getsockname", kInt, kSockaddr, kHex), - MakeEntry(52, "getpeername", kInt, kSockaddr, kHex), - MakeEntry(53, "socketpair", kAddressFamily, kInt, kInt, kHex), - MakeEntry(54, "setsockopt", kInt, kInt, kInt, kHex, kHex), - MakeEntry(55, "getsockopt", kInt, kInt, kInt, kHex, kInt), - MakeEntry(56, "clone", kCloneFlag, kHex, kHex, kHex, kHex), + MakeEntry(40, "sendfile", kResource, kResource, kPtr, kInt), + MakeEntry(41, "socket", kFlags, kFlags, kInt), + MakeEntry(42, "connect", kResource, kSockaddr, kLen1), + MakeEntry(43, "accept", kResource, kPtr, kPtr), + MakeEntry(44, "sendto", kResource, kArray, kLen1, kFlags, kSockaddr, kLen4), + MakeEntry(45, "recvfrom", kResource, kArray, kLen1, kFlags, kSockaddr, + kLen4), + MakeEntry(46, "sendmsg", kResource, kPtr, kFlags), + MakeEntry(47, "recvmsg", kResource, kPtr, kFlags), + MakeEntry(48, "shutdown", kResource, kFlags), + MakeEntry(49, "bind", kResource, kSockaddr, kLen1), + MakeEntry(50, "listen", kResource, kInt), + MakeEntry(51, "getsockname", kResource, kPtr, kPtr), + MakeEntry(52, "getpeername", kResource, kPtr, kPtr), + MakeEntry(53, "socketpair", kFlags, kFlags, kInt, kPtr), + MakeEntry(54, "setsockopt", kResource, kInt, kInt, kArray, kLen3), + MakeEntry(55, "getsockopt", kResource, kInt, kInt, kArray, kPtr), + MakeEntry(56, "clone", kFlags, kArray, kPtr, kPtr, kArray), MakeEntry(57, "fork"), MakeEntry(58, "vfork"), - MakeEntry(59, "execve", kPath, kHex, kHex), + MakeEntry(59, "execve", kPath, kArray, kArray), MakeEntry(60, "exit", kInt), - MakeEntry(61, "wait4", kInt, kHex, kHex, kHex), - MakeEntry(62, "kill", kInt, kSignal), - MakeEntry(63, "uname", kInt), - MakeEntry(64, "semget", kInt, kInt, kHex), - MakeEntry(65, "semop", kInt, kHex, kInt), - MakeEntry(66, "semctl", kInt, kInt, kInt, kHex), - MakeEntry(67, "shmdt", kHex), - MakeEntry(68, "msgget", kInt, kHex), - MakeEntry(69, "msgsnd", kInt, kHex, kInt, kHex), - MakeEntry(70, "msgrcv", kInt, kHex, kInt, kInt, kHex), - MakeEntry(71, "msgctl", kInt, kInt, kHex), - MakeEntry(72, "fcntl", kInt, kInt, kHex), - MakeEntry(73, "flock", kInt, kInt), - MakeEntry(74, "fsync", kInt), - MakeEntry(75, "fdatasync", kInt), + MakeEntry(61, "wait4", kPid, kPtr, kFlags, kPtr), + MakeEntry(62, "kill", kPid, kSignal), + MakeEntry(63, "uname", kArray), + MakeEntry(64, "semget", kIpcResource, kFlags, kFlags), + MakeEntry(65, "semop", kIpcResource, kArray, kLen1), + MakeEntry(66, "semctl", kIpcResource, kFlags, kInt, kArray), + MakeEntry(67, "shmdt", kSharedAddress), + MakeEntry(68, "msgget", kIpcResource, kFlags), + MakeEntry(69, "msgsnd", kIpcResource, kPtr, kLen1, kFlags), + MakeEntry(70, "msgrcv", kIpcResource, kPtr, kLen1, kFlags, kFlags), + MakeEntry(71, "msgctl", kIpcResource, kInt, kArray), + MakeEntry(72, "fcntl", kResource, kFlags, kResource), + MakeEntry(73, "flock", kResource, kFlags), + MakeEntry(74, "fsync", kResource), + MakeEntry(75, "fdatasync", kResource), MakeEntry(76, "truncate", kPath, kInt), - MakeEntry(77, "ftruncate", kInt, kInt), - MakeEntry(78, "getdents", kInt, kHex, kInt), - MakeEntry(79, "getcwd", kHex, kInt), + MakeEntry(77, "ftruncate", kResource, kInt), + MakeEntry(78, "getdents", kResource, kArray, kLen1), + MakeEntry(79, "getcwd", kArray, kLen0), MakeEntry(80, "chdir", kPath), - MakeEntry(81, "fchdir", kInt), + MakeEntry(81, "fchdir", kResource), MakeEntry(82, "rename", kPath, kPath), - MakeEntry(83, "mkdir", kPath, kOct), + MakeEntry(83, "mkdir", kPath, kFlags), MakeEntry(84, "rmdir", kPath), - MakeEntry(85, "creat", kPath, kOct), + MakeEntry(85, "creat", kPath, kFlags), MakeEntry(86, "link", kPath, kPath), MakeEntry(87, "unlink", kPath), MakeEntry(88, "symlink", kPath, kPath), - MakeEntry(89, "readlink", kPath, kHex, kInt), - MakeEntry(90, "chmod", kPath, kOct), - MakeEntry(91, "fchmod", kInt, kOct), - MakeEntry(92, "chown", kPath, kInt, kInt), - MakeEntry(93, "fchown", kInt, kInt, kInt), - MakeEntry(94, "lchown", kPath, kInt, kInt), - MakeEntry(95, "umask", kHex), - MakeEntry(96, "gettimeofday", kHex, kHex), - MakeEntry(97, "getrlimit", kInt, kHex), - MakeEntry(98, "getrusage", kInt, kHex), - MakeEntry(99, "sysinfo", kHex), - MakeEntry(100, "times", kHex), - MakeEntry(101, "ptrace", kInt, kInt, kHex, kHex), + MakeEntry(89, "readlink", kPath, kArray, kLen1), + MakeEntry(90, "chmod", kPath, kFlags), + MakeEntry(91, "fchmod", kResource, kFlags), + MakeEntry(92, "chown", kPath, kUid, kGid), + MakeEntry(93, "fchown", kResource, kUid, kGid), + MakeEntry(94, "lchown", kPath, kUid, kGid), + MakeEntry(95, "umask", kFlags), + MakeEntry(96, "gettimeofday", kPtr, kPtr), + MakeEntry(97, "getrlimit", kFlags, kPtr), + MakeEntry(98, "getrusage", kFlags, kPtr), + MakeEntry(99, "sysinfo", kArray), + MakeEntry(100, "times", kPtr), + MakeEntry(101, "ptrace", kFlags, kPid), MakeEntry(102, "getuid"), - MakeEntry(103, "syslog", kInt, kHex, kInt), + MakeEntry(103, "syslog", kFlags, kArray, kLen1), MakeEntry(104, "getgid"), - MakeEntry(105, "setuid", kInt), - MakeEntry(106, "setgid", kInt), + MakeEntry(105, "setuid", kUid), + MakeEntry(106, "setgid", kGid), MakeEntry(107, "geteuid"), MakeEntry(108, "getegid"), - MakeEntry(109, "setpgid", kInt, kInt), + MakeEntry(109, "setpgid", kPid, kPid), MakeEntry(110, "getppid"), - MakeEntry(111, "getpgrp"), + MakeEntry(111, "getpgrp", kPid), MakeEntry(112, "setsid"), - MakeEntry(113, "setreuid", kInt, kInt), - MakeEntry(114, "setregid", kInt, kInt), - MakeEntry(115, "getgroups", kInt, kHex), - MakeEntry(116, "setgroups", kInt, kHex), - MakeEntry(117, "setresuid", kInt, kInt, kInt), - MakeEntry(118, "getresuid", kHex, kHex, kHex), - MakeEntry(119, "setresgid", kInt, kInt, kInt), - MakeEntry(120, "getresgid", kHex, kHex, kHex), - MakeEntry(121, "getpgid", kInt), - MakeEntry(122, "setfsuid", kInt), - MakeEntry(123, "setfsgid", kInt), - MakeEntry(124, "getsid", kInt), - MakeEntry(125, "capget", kHex, kHex), - MakeEntry(126, "capset", kHex, kHex), - MakeEntry(127, "rt_sigpending", kHex, kInt), - MakeEntry(128, "rt_sigtimedwait", kHex, kHex, kHex, kInt), - MakeEntry(129, "rt_sigqueueinfo", kInt, kSignal, kHex), - MakeEntry(130, "rt_sigsuspend", kHex, kInt), - MakeEntry(131, "sigaltstack", kHex, kHex), - MakeEntry(132, "utime", kPath, kHex), - MakeEntry(133, "mknod", kPath, kOct, kHex), + MakeEntry(113, "setreuid", kUid, kUid), + MakeEntry(114, "setregid", kGid, kGid), + MakeEntry(115, "getgroups", kLen1, kGidArray), + MakeEntry(116, "setgroups", kLen1, kGidArray), + MakeEntry(117, "setresuid", kUid, kUid, kUid), + MakeEntry(118, "getresuid", kPtr, kPtr, kPtr), + MakeEntry(119, "setresgid", kGid, kGid, kGid), + MakeEntry(120, "getresgid", kPtr, kPtr, kPtr), + MakeEntry(121, "getpgid", kPid), + MakeEntry(122, "setfsuid", kUid), + MakeEntry(123, "setfsgid", kGid), + MakeEntry(124, "getsid", kPid), + MakeEntry(125, "capget", kPtr, kPtr), + MakeEntry(126, "capset", kPtr, kPtr), + MakeEntry(127, "rt_sigpending", kPtr, kLen0), + MakeEntry(128, "rt_sigtimedwait", kPtr, kPtr, kPtr, kLen0), + MakeEntry(129, "rt_sigqueueinfo", kPid, kSignal, kPtr), + MakeEntry(130, "rt_sigsuspend", kPtr, kLen0), + MakeEntry(131, "sigaltstack", kPtr, kPtr), + MakeEntry(132, "utime", kPath, kPtr), + MakeEntry(133, "mknod", kPath, kFlags, kInt), MakeEntry(134, "uselib", kPath), - MakeEntry(135, "personality", kHex), - MakeEntry(136, "ustat", kHex, kHex), - MakeEntry(137, "statfs", kPath, kHex), - MakeEntry(138, "fstatfs", kInt, kHex), - MakeEntry(139, "sysfs", kInt, kInt, kInt), - MakeEntry(140, "getpriority", kInt, kInt), - MakeEntry(141, "setpriority", kInt, kInt, kInt), - MakeEntry(142, "sched_setparam", kInt, kHex), - MakeEntry(143, "sched_getparam", kInt, kHex), - MakeEntry(144, "sched_setscheduler", kInt, kInt, kHex), - MakeEntry(145, "sched_getscheduler", kInt), + MakeEntry(135, "personality", kFlags), + MakeEntry(136, "ustat", kInt, kPtr), + MakeEntry(137, "statfs", kPath, kArray), + MakeEntry(138, "fstatfs", kResource, kArray), + MakeEntry(139, "sysfs", kInt, kString), + MakeEntry(140, "getpriority", kFlags, kPid), + MakeEntry(141, "setpriority", kFlags, kPid, kInt), + MakeEntry(142, "sched_setparam", kPid, kPtr), + MakeEntry(143, "sched_getparam", kPid, kPtr), + MakeEntry(144, "sched_setscheduler", kPid, kFlags, kPtr), + MakeEntry(145, "sched_getscheduler", kPid), MakeEntry(146, "sched_get_priority_max", kInt), MakeEntry(147, "sched_get_priority_min", kInt), - MakeEntry(148, "sched_rr_get_interval", kInt, kHex), - MakeEntry(149, "mlock", kInt, kInt), - MakeEntry(150, "munlock", kInt, kInt), - MakeEntry(151, "mlockall", kHex), + MakeEntry(148, "sched_rr_get_interval", kPid, kPtr), + MakeEntry(149, "mlock", kPtr, kLen0), + MakeEntry(150, "munlock", kPtr, kLen0), + MakeEntry(151, "mlockall", kFlags), MakeEntry(152, "munlockall"), MakeEntry(153, "vhangup"), - MakeEntry(154, "modify_ldt", kInt, kHex, kInt), + MakeEntry(154, "modify_ldt", kInt, kPtr, kLen1), MakeEntry(155, "pivot_root", kPath, kPath), - MakeEntry(156, "_sysctl", kHex), - MakeEntry(157, "prctl", kInt, kHex, kHex, kHex, kHex), - MakeEntry(158, "arch_prctl", kInt, kHex), - MakeEntry(159, "adjtimex", kHex), - MakeEntry(160, "setrlimit", kInt, kHex), + MakeEntry(156, "_sysctl", kPtr), + MakeEntry(157, "prctl", kInt, kInt, kInt, kInt, kInt), + MakeEntry(158, "arch_prctl", kInt, kInt), + MakeEntry(159, "adjtimex", kArray), + MakeEntry(160, "setrlimit", kFlags, kPtr), MakeEntry(161, "chroot", kPath), MakeEntry(162, "sync"), MakeEntry(163, "acct", kPath), - MakeEntry(164, "settimeofday", kHex, kHex), - MakeEntry(165, "mount", kPath, kPath, kString, kHex, kGen), - MakeEntry(166, "umount2", kPath, kHex), - MakeEntry(167, "swapon", kPath, kHex), + MakeEntry(164, "settimeofday", kPtr, kPtr), + MakeEntry(165, "mount", kPtr, kPath, kString, kFlags, kString), + MakeEntry(166, "umount2", kPath, kFlags), + MakeEntry(167, "swapon", kPath, kFlags), MakeEntry(168, "swapoff", kPath), - MakeEntry(169, "reboot", kInt, kHex, kHex, kGen), - MakeEntry(170, "sethostname", kString, kInt), - MakeEntry(171, "setdomainname", kString, kInt), + MakeEntry(169, "reboot", kInt, kInt, kInt, kPtr), + MakeEntry(170, "sethostname", kString, kLen0), + MakeEntry(171, "setdomainname", kString, kLen0), MakeEntry(172, "iopl", kInt), MakeEntry(173, "ioperm", kInt, kInt, kInt), MakeEntry(174, "create_module", kString, kInt), - MakeEntry(175, "init_module", kGen, kInt, kString), - MakeEntry(176, "delete_module", kString, kHex), - MakeEntry(177, "get_kernel_syms", kHex), + MakeEntry(175, "init_module", kString, kLen0, kString), + MakeEntry(176, "delete_module", kString, kFlags), + MakeEntry(177, "get_kernel_syms", kInt), MakeEntry(178, "query_module", kString, kInt, kGen, kInt, kGen), MakeEntry(179, "quotactl", kInt, kPath, kInt, kGen), - MakeEntry(180, "nfsservctl", kInt, kGen, kGen), + MakeEntry(180, "nfsservctl", kInt, kPtr, kPtr), MakeEntry(181, "getpmsg", UnknownArguments()), MakeEntry(182, "putpmsg", UnknownArguments()), MakeEntry(183, "afs_syscall", UnknownArguments()), MakeEntry(184, "tuxcall", UnknownArguments()), MakeEntry(185, "security", UnknownArguments()), MakeEntry(186, "gettid"), - MakeEntry(187, "readahead", kInt, kInt, kInt), - MakeEntry(188, "setxattr", kPath, kString, kGen, kInt, kHex), - MakeEntry(189, "lsetxattr", kPath, kString, kGen, kInt, kHex), - MakeEntry(190, "fsetxattr", kInt, kString, kGen, kInt, kHex), - MakeEntry(191, "getxattr", kPath, kString, kGen, kInt), - MakeEntry(192, "lgetxattr", kPath, kString, kGen, kInt), - MakeEntry(193, "fgetxattr", kInt, kString, kGen, kInt), - MakeEntry(194, "listxattr", kPath, kGen, kInt), - MakeEntry(195, "llistxattr", kPath, kGen, kInt), - MakeEntry(196, "flistxattr", kInt, kGen, kInt), - MakeEntry(197, "removexattr", kPath, kString), - MakeEntry(198, "lremovexattr", kPath, kString), - MakeEntry(199, "fremovexattr", kInt, kString), - MakeEntry(200, "tkill", kInt, kSignal), - MakeEntry(201, "time", kHex), - MakeEntry(202, "futex", kGen, kInt, kInt, kGen, kGen, kInt), - MakeEntry(203, "sched_setaffinity", kInt, kInt, kHex), - MakeEntry(204, "sched_getaffinity", kInt, kInt, kHex), - MakeEntry(205, "set_thread_area", kHex), - MakeEntry(206, "io_setup", kInt, kHex), - MakeEntry(207, "io_destroy", kInt), - MakeEntry(208, "io_getevents", kInt, kInt, kInt, kHex, kHex), - MakeEntry(209, "io_submit", kInt, kInt, kHex), - MakeEntry(210, "io_cancel", kInt, kHex, kHex), - MakeEntry(211, "get_thread_area", kHex), - MakeEntry(212, "lookup_dcookie", kInt, kString, kInt), + MakeEntry(187, "readahead", kResource, kInt, kInt), + MakeEntry(188, "setxattr", kPath, kPtr, kString, kLen2, kFlags), + MakeEntry(189, "lsetxattr", kPath, kPtr, kString, kLen2, kFlags), + MakeEntry(190, "fsetxattr", kResource, kPtr, kString, kLen2, kFlags), + MakeEntry(191, "getxattr", kPath, kPtr, kArray, kLen2), + MakeEntry(192, "lgetxattr", kPath, kPtr, kArray, kLen2), + MakeEntry(193, "fgetxattr", kResource, kPtr, kArray, kLen2), + MakeEntry(194, "listxattr", kPath, kArray, kLen1), + MakeEntry(195, "llistxattr", kPath, kArray, kLen1), + MakeEntry(196, "flistxattr", kResource, kArray, kLen1), + MakeEntry(197, "removexattr", kPath, kPtr), + MakeEntry(198, "lremovexattr", kPath, kPtr), + MakeEntry(199, "fremovexattr", kResource, kPtr), + MakeEntry(200, "tkill", kPid, kSignal), + MakeEntry(201, "time", kPtr), + MakeEntry(202, "futex", kPtr, kFlags, kInt, kPtr, kPtr, kInt), + MakeEntry(203, "sched_setaffinity", kPid, kLen2, kPtr), + MakeEntry(204, "sched_getaffinity", kPid, kLen2, kPtr), + MakeEntry(205, "set_thread_area", kPtr), + MakeEntry(206, "io_setup", kInt, kPtr), + MakeEntry(207, "io_destroy", kStruct), + MakeEntry(208, "io_getevents", kStruct, kInt, kLen3, kArray, kPtr), + MakeEntry(209, "io_submit", kStruct, kLen2, kArray), + MakeEntry(210, "io_cancel", kStruct, kPtr, kPtr), + MakeEntry(211, "get_thread_area", kPtr), + MakeEntry(212, "lookup_dcookie", kInt, kArray, kLen1), MakeEntry(213, "epoll_create", kInt), MakeEntry(214, "epoll_ctl_old", UnknownArguments()), MakeEntry(215, "epoll_wait_old", UnknownArguments()), - MakeEntry(216, "remap_file_pages", kGen, kInt, kInt, kInt, kHex), - MakeEntry(217, "getdents64", kInt, kHex, kInt), - MakeEntry(218, "set_tid_address", kHex), + MakeEntry(216, "remap_file_pages", kPtr, kLen0, kFlags, kInt, kFlags), + MakeEntry(217, "getdents64", kResource, kArray, kLen1), + MakeEntry(218, "set_tid_address", kPtr), MakeEntry(219, "restart_syscall"), - MakeEntry(220, "semtimedop", kInt, kHex, kInt, kHex), - MakeEntry(221, "fadvise64", kInt, kInt, kInt, kInt), - MakeEntry(222, "timer_create", kInt, kHex, kHex), - MakeEntry(223, "timer_settime", kInt, kHex, kHex, kHex), - MakeEntry(224, "timer_gettime", kInt, kHex), - MakeEntry(225, "timer_getoverrun", kInt), - MakeEntry(226, "timer_delete", kInt), - MakeEntry(227, "clock_settime", kInt, kHex), - MakeEntry(228, "clock_gettime", kInt, kHex), - MakeEntry(229, "clock_getres", kInt, kHex), - MakeEntry(230, "clock_nanosleep", kInt, kHex, kHex, kHex), + MakeEntry(220, "semtimedop", kIpcResource, kArray, kLen1, kPtr), + MakeEntry(221, "fadvise64", kResource, kInt, kInt, kFlags), + MakeEntry(222, "timer_create", kFlags, kPtr, kPtr), + MakeEntry(223, "timer_settime", kStruct, kFlags, kPtr, kPtr), + MakeEntry(224, "timer_gettime", kStruct, kPtr), + MakeEntry(225, "timer_getoverrun", kStruct), + MakeEntry(226, "timer_delete", kStruct), + MakeEntry(227, "clock_settime", kFlags, kPtr), + MakeEntry(228, "clock_gettime", kFlags, kPtr), + MakeEntry(229, "clock_getres", kFlags, kPtr), + MakeEntry(230, "clock_nanosleep", kFlags, kFlags, kPtr, kPtr), MakeEntry(231, "exit_group", kInt), - MakeEntry(232, "epoll_wait", kInt, kHex, kInt, kInt), - MakeEntry(233, "epoll_ctl", kInt, kInt, kInt, kHex), - MakeEntry(234, "tgkill", kInt, kInt, kSignal), - MakeEntry(235, "utimes", kPath, kHex), + MakeEntry(232, "epoll_wait", kResource, kArray, kLen1, kInt), + MakeEntry(233, "epoll_ctl", kResource, kInt, kResource, kPtr), + MakeEntry(234, "tgkill", kPid, kPid, kSignal), + MakeEntry(235, "utimes", kPath, kPtr), MakeEntry(236, "vserver", UnknownArguments()), - MakeEntry(237, "mbind", kGen, kInt, kInt, kHex, kInt, kHex), - MakeEntry(238, "set_mempolicy", kInt, kHex, kInt), - MakeEntry(239, "get_mempolicy", kInt, kHex, kInt, kInt, kHex), - MakeEntry(240, "mq_open", kString, kHex, kOct, kHex), + MakeEntry(237, "mbind", kPtr, kLen0, kFlags, kPtr, kInt, kFlags), + MakeEntry(238, "set_mempolicy", kFlags, kPtr, kInt), + MakeEntry(239, "get_mempolicy", kPtr, kPtr, kInt, kPtr, kFlags), + MakeEntry(240, "mq_open", kString, kFlags, kFlags, kPtr), MakeEntry(241, "mq_unlink", kString), - MakeEntry(242, "mq_timedsend", kHex, kHex, kInt, kInt, kHex), - MakeEntry(243, "mq_timedreceive", kHex, kHex, kInt, kHex, kHex), - MakeEntry(244, "mq_notify", kHex, kHex), - MakeEntry(245, "mq_getsetattr", kHex, kHex, kHex), - MakeEntry(246, "kexec_load", kHex, kInt, kHex, kHex), - MakeEntry(247, "waitid", kInt, kInt, kHex, kInt, kHex), - MakeEntry(248, "add_key", kString, kString, kGen, kInt, kInt), - MakeEntry(249, "request_key", kString, kString, kHex, kInt), + MakeEntry(242, "mq_timedsend", kResource, kArray, kLen1, kInt, kPtr), + MakeEntry(243, "mq_timedreceive", kResource, kArray, kLen1, kInt, kPtr), + MakeEntry(244, "mq_notify", kResource, kPtr), + MakeEntry(245, "mq_getsetattr", kResource, kPtr, kPtr), + MakeEntry(246, "kexec_load", kInt, kLen2, kArray, kFlags), + MakeEntry(247, "waitid", kFlags, kPid, kPtr, kFlags, kPtr), + MakeEntry(248, "add_key", kString, kPtr, kArray, kLen2, kStruct), + MakeEntry(249, "request_key", kString, kPtr, kString, kStruct), MakeEntry(250, "keyctl", kInt, kInt, kInt, kInt, kInt), - MakeEntry(251, "ioprio_set", kInt, kInt, kInt), - MakeEntry(252, "ioprio_get", kInt, kInt), + MakeEntry(251, "ioprio_set", kFlags, kPid, kFlags), + MakeEntry(252, "ioprio_get", kFlags, kUid), MakeEntry(253, "inotify_init"), - MakeEntry(254, "inotify_add_watch", kInt, kPath, kHex), - MakeEntry(255, "inotify_rm_watch", kInt, kInt), - MakeEntry(256, "migrate_pages", kInt, kInt, kHex, kHex), - MakeEntry(257, "openat", kInt, kPath, kHex, kOct), - MakeEntry(258, "mkdirat", kInt, kPath, kOct), - MakeEntry(259, "mknodat", kInt, kPath, kOct, kHex), - MakeEntry(260, "fchownat", kInt, kPath, kInt, kInt, kHex), - MakeEntry(261, "futimesat", kInt, kPath, kHex), - MakeEntry(262, "newfstatat", kInt, kPath, kHex, kHex), - MakeEntry(263, "unlinkat", kInt, kPath, kHex), - MakeEntry(264, "renameat", kInt, kPath, kInt, kPath), - MakeEntry(265, "linkat", kInt, kPath, kInt, kPath, kHex), - MakeEntry(266, "symlinkat", kPath, kInt, kPath), - MakeEntry(267, "readlinkat", kInt, kPath, kHex, kInt), - MakeEntry(268, "fchmodat", kInt, kPath, kOct), - MakeEntry(269, "faccessat", kInt, kPath, kInt, kHex), - MakeEntry(270, "pselect6", kInt, kHex, kHex, kHex, kHex), - MakeEntry(271, "ppoll", kHex, kInt, kHex, kHex, kInt), - MakeEntry(272, "unshare", kHex), - MakeEntry(273, "set_robust_list", kHex, kInt), - MakeEntry(274, "get_robust_list", kInt, kHex, kHex), - MakeEntry(275, "splice", kInt, kHex, kInt, kHex, kInt, kHex), - MakeEntry(276, "tee", kInt, kInt, kInt, kHex), - MakeEntry(277, "sync_file_range", kInt, kInt, kInt, kHex), - MakeEntry(278, "vmsplice", kInt, kHex, kInt, kInt), - MakeEntry(279, "move_pages", kInt, kInt, kHex, kHex, kHex, kHex), - MakeEntry(280, "utimensat", kInt, kPath, kHex, kHex), - MakeEntry(281, "epoll_pwait", kInt, kHex, kInt, kInt, kHex, kInt), - MakeEntry(282, "signalfd", kInt, kHex, kHex), - MakeEntry(283, "timerfd_create", kInt, kHex), + MakeEntry(254, "inotify_add_watch", kResource, kPath, kFlags), + MakeEntry(255, "inotify_rm_watch", kResource, kResource), + MakeEntry(256, "migrate_pages", kPid, kInt, kPtr, kPtr), + MakeEntry(257, "openat", kResource, kPath, kFlags, kFlags), + MakeEntry(258, "mkdirat", kResource, kPath, kFlags), + MakeEntry(259, "mknodat", kResource, kPath, kFlags, kInt), + MakeEntry(260, "fchownat", kResource, kPath, kUid, kGid, kFlags), + MakeEntry(261, "futimesat", kResource, kPath, kPtr), + MakeEntry(262, "newfstatat", kInt, kPath, kPtr, kFlags), + MakeEntry(263, "unlinkat", kResource, kPath, kFlags), + MakeEntry(264, "renameat", kResource, kPath, kResource, kPath), + MakeEntry(265, "linkat", kResource, kPath, kResource, kPath, kFlags), + MakeEntry(266, "symlinkat", kPath, kResource, kPath), + MakeEntry(267, "readlinkat", kResource, kPath, kArray, kLen2), + MakeEntry(268, "fchmodat", kResource, kPath, kFlags), + MakeEntry(269, "faccessat", kResource, kPath, kFlags), + MakeEntry(270, "pselect6", kLen1, kPtr, kPtr, kPtr, kPtr, kPtr), + MakeEntry(271, "ppoll", kPollFdArray, kLen0, kPtr, kPtr, kLen3), + MakeEntry(272, "unshare", kFlags), + MakeEntry(273, "set_robust_list", kPtr, kLen0), + MakeEntry(274, "get_robust_list", kPid, kPtr, kPtr), + MakeEntry(275, "splice", kResource, kPtr, kResource, kPtr, kInt, kFlags), + MakeEntry(276, "tee", kResource, kResource, kInt, kFlags), + MakeEntry(277, "sync_file_range", kResource, kInt, kInt, kFlags), + MakeEntry(278, "vmsplice", kResource, kArray, kLen1, kFlags), + MakeEntry(279, "move_pages", kPid, kLen2, kArray, kArray, kArray, kFlags), + MakeEntry(280, "utimensat", kResource, kPath, kPtr, kFlags), + MakeEntry(281, "epoll_pwait", kResource, kArray, kLen1, kInt, kPtr, kLen4), + MakeEntry(282, "signalfd", kResource, kPtr, kLen1), + MakeEntry(283, "timerfd_create", kFlags, kFlags), MakeEntry(284, "eventfd", kInt), - MakeEntry(285, "fallocate", kInt, kOct, kInt, kInt), - MakeEntry(286, "timerfd_settime", kInt, kHex, kHex, kHex), - MakeEntry(287, "timerfd_gettime", kInt, kHex), - MakeEntry(288, "accept4", kInt, kHex, kHex, kInt), - MakeEntry(289, "signalfd4", kInt, kHex, kHex, kHex), - MakeEntry(290, "eventfd2", kInt, kHex), - MakeEntry(291, "epoll_create1", kHex), - MakeEntry(292, "dup3", kInt, kInt, kHex), - MakeEntry(293, "pipe2", kHex, kHex), - MakeEntry(294, "inotify_init1", kHex), - MakeEntry(295, "preadv", kInt, kHex, kInt, kInt, kInt), - MakeEntry(296, "pwritev", kInt, kHex, kInt, kInt, kInt), - MakeEntry(297, "rt_tgsigqueueinfo", kInt, kInt, kInt, kHex), - MakeEntry(298, "perf_event_open", kHex, kInt, kInt, kInt, kHex), - MakeEntry(299, "recvmmsg", kInt, kHex, kInt, kHex, kHex), - MakeEntry(300, "fanotify_init", kHex, kHex), - MakeEntry(301, "fanotify_mark", kInt, kHex, kHex, kInt, kPath), - MakeEntry(302, "prlimit64", kInt, kInt, kHex, kHex), - MakeEntry(303, "name_to_handle_at", kInt, kPath, kHex, kHex, kHex), - MakeEntry(304, "open_by_handle_at", kInt, kHex, kHex), - MakeEntry(305, "clock_adjtime", kInt, kHex), - MakeEntry(306, "syncfs", kInt), - MakeEntry(307, "sendmmsg", kInt, kHex, kInt, kHex), - MakeEntry(308, "setns", kInt, kHex), - MakeEntry(309, "getcpu", kHex, kHex, kHex), - MakeEntry(310, "process_vm_readv", kInt, kHex, kInt, kHex, kInt, + MakeEntry(285, "fallocate", kResource, kFlags, kInt, kInt), + MakeEntry(286, "timerfd_settime", kResource, kFlags, kPtr, kPtr), + MakeEntry(287, "timerfd_gettime", kResource, kPtr), + MakeEntry(288, "accept4", kResource, kPtr, kPtr, kFlags), + MakeEntry(289, "signalfd4", kResource, kPtr, kLen1, kFlags), + MakeEntry(290, "eventfd2", kInt, kFlags), + MakeEntry(291, "epoll_create1", kFlags), + MakeEntry(292, "dup3", kResource, kResource, kFlags), + MakeEntry(293, "pipe2", kPtr, kFlags), + MakeEntry(294, "inotify_init1", kFlags), + MakeEntry(295, "preadv", kResource, kArray, kLen1, kInt, kInt), + MakeEntry(296, "pwritev", kResource, kArray, kLen1, kInt, kInt), + MakeEntry(297, "rt_tgsigqueueinfo", kPid, kPid, kSignal, kPtr), + MakeEntry(298, "perf_event_open", kPtr, kPid, kInt, kResource, kFlags), + MakeEntry(299, "recvmmsg", kResource, kArray, kLen1, kFlags, kPtr), + MakeEntry(300, "fanotify_init", kFlags, kFlags), + MakeEntry(301, "fanotify_mark", kResource, kFlags, kFlags, kResource, + kPath), + MakeEntry(302, "prlimit64", kPid, kFlags, kPtr, kPtr), + MakeEntry(303, "name_to_handle_at", kResource, kPath, kPtr, kPtr, kFlags), + MakeEntry(304, "open_by_handle_at", kResource, kPtr, kFlags), + MakeEntry(305, "clock_adjtime", kFlags, kPtr), + MakeEntry(306, "syncfs", kResource), + MakeEntry(307, "sendmmsg", kResource, kArray, kLen1, kFlags), + MakeEntry(308, "setns", kResource, kFlags), + MakeEntry(309, "getcpu", kPtr, kPtr), + MakeEntry(310, "process_vm_readv", kPid, kArray, kLen1, kArray, kLen3, kInt), - MakeEntry(311, "process_vm_writev", kInt, kHex, kInt, kHex, kInt, + MakeEntry(311, "process_vm_writev", kPid, kArray, kLen1, kArray, kLen3, kInt), - MakeEntry(312, "kcmp", kInt, kInt, kInt, kInt, kInt), - MakeEntry(313, "finit_module", kInt, kString, kHex), - MakeEntry(314, "sched_setattr", kInt, kHex, kHex), - MakeEntry(315, "sched_getattr", kInt, kHex, kInt, kHex), - MakeEntry(316, "renameat2", kInt, kPath, kInt, kPath, kHex), - MakeEntry(317, "seccomp", kInt, kHex, kHex), - MakeEntry(318, "getrandom", kGen, kInt, kHex), - MakeEntry(319, "memfd_create", kString, kHex), - MakeEntry(320, "kexec_file_load", kInt, kInt, kInt, kString, kHex), - MakeEntry(321, "bpf", kInt, kHex, kInt), - MakeEntry(322, "execveat", kInt, kPath, kHex, kHex, kHex), - MakeEntry(323, "userfaultfd", kHex), - MakeEntry(324, "membarrier", kInt, kHex), - MakeEntry(325, "mlock2", kHex, kInt, kHex), - MakeEntry(326, "copy_file_range", kInt, kHex, kInt, kHex, kInt, - kHex), - MakeEntry(327, "preadv2", kInt, kHex, kInt, kInt, kInt, kHex), - MakeEntry(328, "pwritev2", kInt, kHex, kInt, kInt, kInt, kHex), - MakeEntry(329, "pkey_mprotect", kInt, kInt, kHex, kInt), - MakeEntry(330, "pkey_alloc", kInt, kInt), + MakeEntry(312, "kcmp", kPid, kPid, kFlags, kResource, kResource), + MakeEntry(313, "finit_module", kResource, kString, kFlags), + MakeEntry(314, "sched_setattr", kPid, kPtr, kInt), + MakeEntry(315, "sched_getattr", kPid, kPtr, kLen1, kInt), + MakeEntry(316, "renameat2", kResource, kPath, kResource, kPath, kFlags), + MakeEntry(317, "seccomp", kInt, kFlags, kPtr), + MakeEntry(318, "getrandom", kArray, kLen0, kFlags), + MakeEntry(319, "memfd_create", kString, kFlags), + MakeEntry(320, "kexec_file_load", kInt, kInt, kInt, kString, kInt), + MakeEntry(321, "bpf", kInt, kPtr, kLen1), + MakeEntry(322, "execveat", kResource, kPath, kArray, kArray, kFlags), + MakeEntry(323, "userfaultfd", kFlags), + MakeEntry(324, "membarrier", kFlags, kInt), + MakeEntry(325, "mlock2", kPtr, kLen0, kFlags), + MakeEntry(326, "copy_file_range", kResource, kPtr, kResource, kPtr, kInt, + kFlags), + MakeEntry(327, "preadv2", kResource, kArray, kLen1, kInt, kInt, kFlags), + MakeEntry(328, "pwritev2", kResource, kArray, kLen1, kInt, kInt, kFlags), + MakeEntry(329, "pkey_mprotect", kPtr, kLen0, kFlags, kInt), + MakeEntry(330, "pkey_alloc", kInt, kFlags), MakeEntry(331, "pkey_free", kInt), - MakeEntry(332, "statx", kInt, kPath, kHex, kHex, kHex), - MakeEntry(333, "io_pgetevents", UnknownArguments()), - MakeEntry(334, "rseq", kHex, kInt, kHex, kHex), - MakeEntry(435, "clone3", kHex, kInt), - MakeEntry(436, "close_range", kInt, kInt, kHex), - MakeEntry(437, "openat2", kInt, kPath, kHex, kInt), + MakeEntry(332, "statx", kResource, kPath, kFlags, kFlags, kPtr), + MakeEntry(333, "io_pgetevents", kStruct, kInt, kLen3, kArray, kPtr, kPtr), + MakeEntry(334, "rseq", kPtr, kLen0, kFlags, kInt), + MakeEntry(435, "clone3", kPtr, kLen0), + MakeEntry(436, "close_range", kInt, kInt, kInt), + MakeEntry(437, "openat2", kInt, kPath, kInt, kInt), MakeEntry(438, "pidfd_getfd", UnknownArguments()), - MakeEntry(439, "faccessat2", kInt, kPath, kHex, kHex), + MakeEntry(439, "faccessat2", kInt, kPath, kInt, kInt), MakeEntry(440, "process_madvise", UnknownArguments()), - MakeEntry(441, "epoll_pwait2", UnknownArguments()), + MakeEntry(441, "epoll_pwait2", kResource, kArray, kLen1, kPtr, kPtr, kLen4), MakeEntry(442, "mount_setattr", UnknownArguments()), MakeEntry(443, "quotactl_fd", UnknownArguments()), MakeEntry(444, "landlock_create_ruleset", UnknownArguments()), @@ -497,7 +577,7 @@ constexpr std::array kSyscallDataX8664 = { MakeEntry(449, "futex_waitv", UnknownArguments()), MakeEntry(450, "set_mempolicy_home_node", UnknownArguments()), MakeEntry(451, "cachestat", UnknownArguments()), - MakeEntry(452, "fchmodat2", kInt, kPath, kHex, kHex), + MakeEntry(452, "fchmodat2", kInt, kPath, kInt, kInt), MakeEntry(453, "map_shadow_stack", UnknownArguments()), MakeEntry(454, "futex_wake", UnknownArguments()), MakeEntry(455, "futex_wait", UnknownArguments()), @@ -518,201 +598,201 @@ constexpr std::array kSyscallDataX8632 = { MakeEntry(0, "restart_syscall"), MakeEntry(1, "exit", kInt), MakeEntry(2, "fork"), - MakeEntry(3, "read", kInt, kHex, kInt), - MakeEntry(4, "write", kInt, kHex, kInt), - MakeEntry(5, "open", kPath, kHex, kOct), - MakeEntry(6, "close", kInt), - MakeEntry(7, "waitpid", kInt, kHex, kHex), - MakeEntry(8, "creat", kPath, kOct), + MakeEntry(3, "read", kResource, kArray, kLen1), + MakeEntry(4, "write", kResource, kArray, kLen1), + MakeEntry(5, "open", kPath, kFlags, kFlags), + MakeEntry(6, "close", kResource), + MakeEntry(7, "waitpid", kInt, kInt, kInt), + MakeEntry(8, "creat", kPath, kFlags), MakeEntry(9, "link", kPath, kPath), MakeEntry(10, "unlink", kPath), - MakeEntry(11, "execve", kPath, kHex, kHex), + MakeEntry(11, "execve", kPath, kArray, kArray), MakeEntry(12, "chdir", kPath), - MakeEntry(13, "time", kHex), - MakeEntry(14, "mknod", kPath, kOct, kHex), - MakeEntry(15, "chmod", kPath, kOct), - MakeEntry(16, "lchown", kPath, kInt, kInt), + MakeEntry(13, "time", kPtr), + MakeEntry(14, "mknod", kPath, kFlags, kInt), + MakeEntry(15, "chmod", kPath, kFlags), + MakeEntry(16, "lchown", kPath, kUid, kGid), MakeEntry(17, "break", UnknownArguments()), MakeEntry(18, "oldstat", UnknownArguments()), - MakeEntry(19, "lseek", kInt, kInt, kInt), + MakeEntry(19, "lseek", kResource, kInt, kFlags), MakeEntry(20, "getpid"), - MakeEntry(21, "mount", kPath, kPath, kString, kHex, kGen), + MakeEntry(21, "mount", kPtr, kPath, kString, kFlags, kString), MakeEntry(22, "umount", UnknownArguments()), - MakeEntry(23, "setuid", kInt), + MakeEntry(23, "setuid", kUid), MakeEntry(24, "getuid"), MakeEntry(25, "stime", UnknownArguments()), - MakeEntry(26, "ptrace", kHex, kHex, kHex, kHex), + MakeEntry(26, "ptrace", kFlags, kPid), MakeEntry(27, "alarm", kInt), MakeEntry(28, "oldfstat", UnknownArguments()), MakeEntry(29, "pause"), - MakeEntry(30, "utime", kPath, kHex), + MakeEntry(30, "utime", kPath, kPtr), MakeEntry(31, "stty", UnknownArguments()), MakeEntry(32, "gtty", UnknownArguments()), - MakeEntry(33, "access", kPath, kHex), + MakeEntry(33, "access", kPath, kInt), MakeEntry(34, "nice", UnknownArguments()), MakeEntry(35, "ftime", UnknownArguments()), MakeEntry(36, "sync"), - MakeEntry(37, "kill", kInt, kSignal), + MakeEntry(37, "kill", kPid, kSignal), MakeEntry(38, "rename", kPath, kPath), - MakeEntry(39, "mkdir", kPath, kOct), + MakeEntry(39, "mkdir", kPath, kFlags), MakeEntry(40, "rmdir", kPath), - MakeEntry(41, "dup", kInt), - MakeEntry(42, "pipe", kHex), - MakeEntry(43, "times", kHex), + MakeEntry(41, "dup", kResource), + MakeEntry(42, "pipe", kPtr), + MakeEntry(43, "times", kPtr), MakeEntry(44, "prof", UnknownArguments()), MakeEntry(45, "brk", kInt), - MakeEntry(46, "setgid", kInt), + MakeEntry(46, "setgid", kGid), MakeEntry(47, "getgid"), MakeEntry(48, "signal", UnknownArguments()), MakeEntry(49, "geteuid"), MakeEntry(50, "getegid"), MakeEntry(51, "acct", kPath), - MakeEntry(52, "umount2", kPath, kHex), + MakeEntry(52, "umount2", kPath, kFlags), MakeEntry(53, "lock", UnknownArguments()), - MakeEntry(54, "ioctl", kInt, kInt, kHex), - MakeEntry(55, "fcntl", kInt, kInt, kHex), + MakeEntry(54, "ioctl", kResource, kInt, kArray), + MakeEntry(55, "fcntl", kResource, kFlags, kResource), MakeEntry(56, "mpx", UnknownArguments()), - MakeEntry(57, "setpgid", kInt, kInt), + MakeEntry(57, "setpgid", kPid, kPid), MakeEntry(58, "ulimit", UnknownArguments()), MakeEntry(59, "oldolduname", UnknownArguments()), - MakeEntry(60, "umask", kHex), + MakeEntry(60, "umask", kFlags), MakeEntry(61, "chroot", kPath), - MakeEntry(62, "ustat", kHex, kHex), - MakeEntry(63, "dup2", kInt, kInt), + MakeEntry(62, "ustat", kInt, kPtr), + MakeEntry(63, "dup2", kResource, kResource), MakeEntry(64, "getppid"), - MakeEntry(65, "getpgrp"), + MakeEntry(65, "getpgrp", kPid), MakeEntry(66, "setsid"), MakeEntry(67, "sigaction", UnknownArguments()), MakeEntry(68, "sgetmask", UnknownArguments()), MakeEntry(69, "ssetmask", UnknownArguments()), - MakeEntry(70, "setreuid", kInt, kInt), - MakeEntry(71, "setregid", kInt, kInt), + MakeEntry(70, "setreuid", kUid, kUid), + MakeEntry(71, "setregid", kGid, kGid), MakeEntry(72, "sigsuspend", UnknownArguments()), MakeEntry(73, "sigpending", UnknownArguments()), - MakeEntry(74, "sethostname", kString, kInt), - MakeEntry(75, "setrlimit", kInt, kHex), - MakeEntry(76, "getrlimit", kInt, kHex), - MakeEntry(77, "getrusage", kInt, kHex), - MakeEntry(78, "gettimeofday", kHex, kHex), - MakeEntry(79, "settimeofday", kHex, kHex), - MakeEntry(80, "getgroups", kInt, kHex), - MakeEntry(81, "setgroups", kInt, kHex), - MakeEntry(82, "select", kInt, kHex, kHex, kHex, kHex), + MakeEntry(74, "sethostname", kString, kLen0), + MakeEntry(75, "setrlimit", kFlags, kPtr), + MakeEntry(76, "getrlimit", kFlags, kPtr), + MakeEntry(77, "getrusage", kFlags, kPtr), + MakeEntry(78, "gettimeofday", kPtr, kPtr), + MakeEntry(79, "settimeofday", kPtr, kPtr), + MakeEntry(80, "getgroups", kLen1, kGidArray), + MakeEntry(81, "setgroups", kLen1, kGidArray), + MakeEntry(82, "select", kLen1, kPtr, kPtr, kPtr, kPtr), MakeEntry(83, "symlink", kPath, kPath), MakeEntry(84, "oldlstat", UnknownArguments()), - MakeEntry(85, "readlink", kPath, kHex, kInt), + MakeEntry(85, "readlink", kPath, kArray, kLen1), MakeEntry(86, "uselib", kPath), - MakeEntry(87, "swapon", kPath, kHex), - MakeEntry(88, "reboot", kInt, kHex, kHex, kGen), + MakeEntry(87, "swapon", kPath, kFlags), + MakeEntry(88, "reboot", kInt, kInt, kInt, kPtr), MakeEntry(89, "readdir", UnknownArguments()), - MakeEntry(90, "mmap", kHex, kInt, kHex, kHex, kInt, kInt), - MakeEntry(91, "munmap", kHex, kInt), + MakeEntry(90, "mmap", kPtr, kLen0, kFlags, kFlags, kResource, kInt), + MakeEntry(91, "munmap", kPtr, kLen0), MakeEntry(92, "truncate", kPath, kInt), - MakeEntry(93, "ftruncate", kInt, kInt), - MakeEntry(94, "fchmod", kInt, kOct), - MakeEntry(95, "fchown", kInt, kInt, kInt), - MakeEntry(96, "getpriority", kInt, kInt), - MakeEntry(97, "setpriority", kInt, kInt, kInt), + MakeEntry(93, "ftruncate", kResource, kInt), + MakeEntry(94, "fchmod", kResource, kFlags), + MakeEntry(95, "fchown", kResource, kUid, kGid), + MakeEntry(96, "getpriority", kFlags, kPid), + MakeEntry(97, "setpriority", kFlags, kPid, kInt), MakeEntry(98, "profil", UnknownArguments()), - MakeEntry(99, "statfs", kPath, kHex), - MakeEntry(100, "fstatfs", kInt, kHex), + MakeEntry(99, "statfs", kPath, kArray), + MakeEntry(100, "fstatfs", kResource, kArray), MakeEntry(101, "ioperm", kInt, kInt, kInt), MakeEntry(102, "socketcall", UnknownArguments()), - MakeEntry(103, "syslog", kInt, kHex, kInt), - MakeEntry(104, "setitimer", kInt, kHex, kHex), - MakeEntry(105, "getitimer", kInt, kHex), - MakeEntry(106, "stat", kPath, kHex), - MakeEntry(107, "lstat", kPath, kHex), - MakeEntry(108, "fstat", kInt, kHex), + MakeEntry(103, "syslog", kFlags, kArray, kLen1), + MakeEntry(104, "setitimer", kFlags, kPtr, kPtr), + MakeEntry(105, "getitimer", kFlags, kPtr), + MakeEntry(106, "stat", kPath, kPtr), + MakeEntry(107, "lstat", kPath, kPtr), + MakeEntry(108, "fstat", kResource, kPtr), MakeEntry(109, "olduname", UnknownArguments()), MakeEntry(110, "iopl", kInt), MakeEntry(111, "vhangup"), MakeEntry(112, "idle", UnknownArguments()), MakeEntry(113, "vm86old", UnknownArguments()), - MakeEntry(114, "wait4", kInt, kHex, kHex, kHex), + MakeEntry(114, "wait4", kPid, kPtr, kFlags, kPtr), MakeEntry(115, "swapoff", kPath), - MakeEntry(116, "sysinfo", kHex), + MakeEntry(116, "sysinfo", kArray), MakeEntry(117, "ipc", UnknownArguments()), - MakeEntry(118, "fsync", kInt), + MakeEntry(118, "fsync", kResource), MakeEntry(119, "sigreturn", UnknownArguments()), - MakeEntry(120, "clone", kCloneFlag, kHex, kHex, kHex, kHex), - MakeEntry(121, "setdomainname", kString, kInt), - MakeEntry(122, "uname", kInt), - MakeEntry(123, "modify_ldt", kInt, kHex, kInt), - MakeEntry(124, "adjtimex", kHex), - MakeEntry(125, "mprotect", kHex, kInt, kHex), + MakeEntry(120, "clone", kFlags, kArray, kPtr, kPtr, kArray), + MakeEntry(121, "setdomainname", kString, kLen0), + MakeEntry(122, "uname", kArray), + MakeEntry(123, "modify_ldt", kInt, kPtr, kLen1), + MakeEntry(124, "adjtimex", kArray), + MakeEntry(125, "mprotect", kPtr, kLen0, kFlags), MakeEntry(126, "sigprocmask", UnknownArguments()), MakeEntry(127, "create_module", kString, kInt), - MakeEntry(128, "init_module", kGen, kInt, kString), - MakeEntry(129, "delete_module", kString, kHex), - MakeEntry(130, "get_kernel_syms", kHex), + MakeEntry(128, "init_module", kString, kLen0, kString), + MakeEntry(129, "delete_module", kString, kFlags), + MakeEntry(130, "get_kernel_syms", kInt), MakeEntry(131, "quotactl", kInt, kPath, kInt, kGen), - MakeEntry(132, "getpgid", kInt), - MakeEntry(133, "fchdir", kInt), + MakeEntry(132, "getpgid", kPid), + MakeEntry(133, "fchdir", kResource), MakeEntry(134, "bdflush", UnknownArguments()), - MakeEntry(135, "sysfs", kInt, kInt, kInt), - MakeEntry(136, "personality", kHex), + MakeEntry(135, "sysfs", kInt, kString), + MakeEntry(136, "personality", kFlags), MakeEntry(137, "afs_syscall", UnknownArguments()), - MakeEntry(138, "setfsuid", kInt), - MakeEntry(139, "setfsgid", kInt), + MakeEntry(138, "setfsuid", kUid), + MakeEntry(139, "setfsgid", kGid), MakeEntry(140, "_llseek", UnknownArguments()), - MakeEntry(141, "getdents", kInt, kHex, kInt), + MakeEntry(141, "getdents", kResource, kArray, kLen1), MakeEntry(142, "_newselect", UnknownArguments()), - MakeEntry(143, "flock", kInt, kInt), - MakeEntry(144, "msync", kHex, kInt, kInt), - MakeEntry(145, "readv", kInt, kHex, kInt), - MakeEntry(146, "writev", kInt, kHex, kInt), - MakeEntry(147, "getsid", kInt), - MakeEntry(148, "fdatasync", kInt), - MakeEntry(149, "_sysctl", kHex), - MakeEntry(150, "mlock", kInt, kInt), - MakeEntry(151, "munlock", kInt, kInt), - MakeEntry(152, "mlockall", kHex), + MakeEntry(143, "flock", kResource, kFlags), + MakeEntry(144, "msync", kPtr, kLen0, kFlags), + MakeEntry(145, "readv", kResource, kArray, kLen1), + MakeEntry(146, "writev", kResource, kArray, kLen1), + MakeEntry(147, "getsid", kPid), + MakeEntry(148, "fdatasync", kResource), + MakeEntry(149, "_sysctl", kPtr), + MakeEntry(150, "mlock", kPtr, kLen0), + MakeEntry(151, "munlock", kPtr, kLen0), + MakeEntry(152, "mlockall", kFlags), MakeEntry(153, "munlockall"), - MakeEntry(154, "sched_setparam", kInt, kHex), - MakeEntry(155, "sched_getparam", kInt, kHex), - MakeEntry(156, "sched_setscheduler", kInt, kInt, kHex), - MakeEntry(157, "sched_getscheduler", kInt), + MakeEntry(154, "sched_setparam", kPid, kPtr), + MakeEntry(155, "sched_getparam", kPid, kPtr), + MakeEntry(156, "sched_setscheduler", kPid, kFlags, kPtr), + MakeEntry(157, "sched_getscheduler", kPid), MakeEntry(158, "sched_yield"), - MakeEntry(159, "sched_get_priority_max", kHex), - MakeEntry(160, "sched_get_priority_min", kHex), - MakeEntry(161, "sched_rr_get_interval", kInt, kHex), - MakeEntry(162, "nanosleep", kHex, kHex), - MakeEntry(163, "mremap", kHex, kInt, kInt, kInt, kHex), - MakeEntry(164, "setresuid", kInt, kInt, kInt), - MakeEntry(165, "getresuid", kHex, kHex, kHex), + MakeEntry(159, "sched_get_priority_max", kInt), + MakeEntry(160, "sched_get_priority_min", kInt), + MakeEntry(161, "sched_rr_get_interval", kPid, kPtr), + MakeEntry(162, "nanosleep", kPtr, kPtr), + MakeEntry(163, "mremap", kPtr, kLen0, kLen4, kFlags, kPtr), + MakeEntry(164, "setresuid", kUid, kUid, kUid), + MakeEntry(165, "getresuid", kPtr, kPtr, kPtr), MakeEntry(166, "vm86", UnknownArguments()), MakeEntry(167, "query_module", kString, kInt, kGen, kInt, kGen), - MakeEntry(168, "poll", kGen, kInt, kInt), - MakeEntry(169, "nfsservctl", kInt, kGen, kGen), - MakeEntry(170, "setresgid", kInt, kInt, kInt), - MakeEntry(171, "getresgid", kHex, kHex, kHex), - MakeEntry(172, "prctl", kInt, kHex, kHex, kHex, kHex), + MakeEntry(168, "poll", kPollFdArray, kLen0, kInt), + MakeEntry(169, "nfsservctl", kInt, kPtr, kPtr), + MakeEntry(170, "setresgid", kGid, kGid, kGid), + MakeEntry(171, "getresgid", kPtr, kPtr, kPtr), + MakeEntry(172, "prctl", kInt, kInt, kInt, kInt, kInt), MakeEntry(173, "rt_sigreturn"), - MakeEntry(174, "rt_sigaction", kSignal, kHex, kHex, kInt), - MakeEntry(175, "rt_sigprocmask", kInt, kHex, kHex, kInt), - MakeEntry(176, "rt_sigpending", kHex, kInt), - MakeEntry(177, "rt_sigtimedwait", kHex, kHex, kHex, kInt), - MakeEntry(178, "rt_sigqueueinfo", kInt, kSignal, kHex), - MakeEntry(179, "rt_sigsuspend", kHex, kInt), - MakeEntry(180, "pread64", kInt, kHex, kInt, kInt), - MakeEntry(181, "pwrite64", kInt, kHex, kInt, kInt), - MakeEntry(182, "chown", kPath, kInt, kInt), - MakeEntry(183, "getcwd", kHex, kInt), - MakeEntry(184, "capget", kHex, kHex), - MakeEntry(185, "capset", kHex, kHex), - MakeEntry(186, "sigaltstack", kHex, kHex), - MakeEntry(187, "sendfile", kInt, kInt, kHex, kInt), + MakeEntry(174, "rt_sigaction", kSignal, kPtr, kPtr, kLen4, kPtr), + MakeEntry(175, "rt_sigprocmask", kFlags, kPtr, kPtr, kLen1), + MakeEntry(176, "rt_sigpending", kPtr, kLen0), + MakeEntry(177, "rt_sigtimedwait", kPtr, kPtr, kPtr, kLen0), + MakeEntry(178, "rt_sigqueueinfo", kPid, kSignal, kPtr), + MakeEntry(179, "rt_sigsuspend", kPtr, kLen0), + MakeEntry(180, "pread64", kResource, kArray, kLen1, kInt), + MakeEntry(181, "pwrite64", kResource, kArray, kLen1, kInt), + MakeEntry(182, "chown", kPath, kUid, kGid), + MakeEntry(183, "getcwd", kArray, kLen0), + MakeEntry(184, "capget", kPtr, kPtr), + MakeEntry(185, "capset", kPtr, kPtr), + MakeEntry(186, "sigaltstack", kPtr, kPtr), + MakeEntry(187, "sendfile", kResource, kResource, kPtr, kInt), MakeEntry(188, "getpmsg", UnknownArguments()), MakeEntry(189, "putpmsg", UnknownArguments()), MakeEntry(190, "vfork"), MakeEntry(191, "ugetrlimit", UnknownArguments()), MakeEntry(192, "mmap2", UnknownArguments()), - MakeEntry(193, "truncate64", kPath, kHex), - MakeEntry(194, "ftruncate64", kInt, kHex), - MakeEntry(195, "stat64", kPath, kHex), - MakeEntry(196, "lstat64", kPath, kHex), - MakeEntry(197, "fstat64", kInt, kHex), + MakeEntry(193, "truncate64", kPath, kInt), + MakeEntry(194, "ftruncate64", kInt, kInt), + MakeEntry(195, "stat64", kPath, kPtr), + MakeEntry(196, "lstat64", kPath, kPtr), + MakeEntry(197, "fstat64", kResource, kPtr), MakeEntry(198, "lchown32", kPath, kInt, kInt), MakeEntry(199, "getuid32", UnknownArguments()), MakeEntry(200, "getgid32", UnknownArguments()), @@ -733,165 +813,168 @@ constexpr std::array kSyscallDataX8632 = { MakeEntry(215, "setfsuid32", UnknownArguments()), MakeEntry(216, "setfsgid32", UnknownArguments()), MakeEntry(217, "pivot_root", kPath, kPath), - MakeEntry(218, "mincore", kHex, kInt, kHex), - MakeEntry(219, "madvise", kHex, kInt, kInt), - MakeEntry(220, "getdents64", kInt, kHex, kInt), + MakeEntry(218, "mincore", kPtr, kLen0, kArray), + MakeEntry(219, "madvise", kPtr, kLen0, kFlags), + MakeEntry(220, "getdents64", kResource, kArray, kLen1), MakeEntry(221, "fcntl64", UnknownArguments()), MakeEntry(222, "unused1-222", UnknownArguments()), MakeEntry(223, "unused2-223", UnknownArguments()), MakeEntry(224, "gettid"), - MakeEntry(225, "readahead", kInt, kInt, kInt), - MakeEntry(226, "setxattr", kPath, kString, kGen, kInt, kHex), - MakeEntry(227, "lsetxattr", kPath, kString, kGen, kInt, kHex), - MakeEntry(228, "fsetxattr", kInt, kString, kGen, kInt, kHex), - MakeEntry(229, "getxattr", kPath, kString, kGen, kInt), - MakeEntry(230, "lgetxattr", kPath, kString, kGen, kInt), - MakeEntry(231, "fgetxattr", kInt, kString, kGen, kInt), - MakeEntry(232, "listxattr", kPath, kGen, kInt), - MakeEntry(233, "llistxattr", kPath, kGen, kInt), - MakeEntry(234, "flistxattr", kInt, kGen, kInt), - MakeEntry(235, "removexattr", kPath, kString), - MakeEntry(236, "lremovexattr", kPath, kString), - MakeEntry(237, "fremovexattr", kInt, kString), - MakeEntry(238, "tkill", kInt, kSignal), - MakeEntry(239, "sendfile64", UnknownArguments()), - MakeEntry(240, "futex", kGen, kInt, kInt, kGen, kGen, kInt), - MakeEntry(241, "sched_setaffinity", kInt, kInt, kHex), - MakeEntry(242, "sched_getaffinity", kInt, kInt, kHex), - MakeEntry(243, "set_thread_area", kHex), - MakeEntry(244, "get_thread_area", kHex), - MakeEntry(245, "io_setup", kInt, kHex), - MakeEntry(246, "io_destroy", kInt), - MakeEntry(247, "io_getevents", kInt, kInt, kInt, kHex, kHex), - MakeEntry(248, "io_submit", kInt, kInt, kHex), - MakeEntry(249, "io_cancel", kInt, kHex, kHex), - MakeEntry(250, "fadvise64", kInt, kInt, kInt, kInt), + MakeEntry(225, "readahead", kResource, kInt, kInt), + MakeEntry(226, "setxattr", kPath, kPtr, kString, kLen2, kFlags), + MakeEntry(227, "lsetxattr", kPath, kPtr, kString, kLen2, kFlags), + MakeEntry(228, "fsetxattr", kResource, kPtr, kString, kLen2, kFlags), + MakeEntry(229, "getxattr", kPath, kPtr, kArray, kLen2), + MakeEntry(230, "lgetxattr", kPath, kPtr, kArray, kLen2), + MakeEntry(231, "fgetxattr", kResource, kPtr, kArray, kLen2), + MakeEntry(232, "listxattr", kPath, kArray, kLen1), + MakeEntry(233, "llistxattr", kPath, kArray, kLen1), + MakeEntry(234, "flistxattr", kResource, kArray, kLen1), + MakeEntry(235, "removexattr", kPath, kPtr), + MakeEntry(236, "lremovexattr", kPath, kPtr), + MakeEntry(237, "fremovexattr", kResource, kPtr), + MakeEntry(238, "tkill", kPid, kSignal), + MakeEntry(239, "sendfile64", kResource, kResource, kPtr, kInt), + MakeEntry(240, "futex", kPtr, kFlags, kInt, kPtr, kPtr, kInt), + MakeEntry(241, "sched_setaffinity", kPid, kLen2, kPtr), + MakeEntry(242, "sched_getaffinity", kPid, kLen2, kPtr), + MakeEntry(243, "set_thread_area", kPtr), + MakeEntry(244, "get_thread_area", kPtr), + MakeEntry(245, "io_setup", kInt, kPtr), + MakeEntry(246, "io_destroy", kStruct), + MakeEntry(247, "io_getevents", kStruct, kInt, kLen3, kArray, kPtr), + MakeEntry(248, "io_submit", kStruct, kLen2, kArray), + MakeEntry(249, "io_cancel", kStruct, kPtr, kPtr), + MakeEntry(250, "fadvise64", kResource, kInt, kInt, kFlags), MakeEntry(251, "251-old_sys_set_zone_reclaim", UnknownArguments()), MakeEntry(252, "exit_group", kInt), - MakeEntry(253, "lookup_dcookie", kInt, kString, kInt), + MakeEntry(253, "lookup_dcookie", kInt, kArray, kLen1), MakeEntry(254, "epoll_create", kInt), - MakeEntry(255, "epoll_ctl", kInt, kInt, kInt, kHex), - MakeEntry(256, "epoll_wait", kInt, kHex, kInt, kInt), - MakeEntry(257, "remap_file_pages", kGen, kInt, kInt, kInt, kHex), - MakeEntry(258, "set_tid_address", kHex), - MakeEntry(259, "timer_create", kInt, kHex, kHex), - MakeEntry(260, "timer_settime", kInt, kHex, kHex, kHex), - MakeEntry(261, "timer_gettime", kInt, kHex), - MakeEntry(262, "timer_getoverrun", kInt), - MakeEntry(263, "timer_delete", kInt), - MakeEntry(264, "clock_settime", kInt, kHex), - MakeEntry(265, "clock_gettime", kInt, kHex), - MakeEntry(266, "clock_getres", kInt, kHex), - MakeEntry(267, "clock_nanosleep", kInt, kHex, kHex, kHex), + MakeEntry(255, "epoll_ctl", kResource, kInt, kResource, kPtr), + MakeEntry(256, "epoll_wait", kResource, kArray, kLen1, kInt), + MakeEntry(257, "remap_file_pages", kPtr, kLen0, kFlags, kInt, kFlags), + MakeEntry(258, "set_tid_address", kPtr), + MakeEntry(259, "timer_create", kFlags, kPtr, kPtr), + MakeEntry(260, "timer_settime", kStruct, kFlags, kPtr, kPtr), + MakeEntry(261, "timer_gettime", kStruct, kPtr), + MakeEntry(262, "timer_getoverrun", kStruct), + MakeEntry(263, "timer_delete", kStruct), + MakeEntry(264, "clock_settime", kFlags, kPtr), + MakeEntry(265, "clock_gettime", kFlags, kPtr), + MakeEntry(266, "clock_getres", kFlags, kPtr), + MakeEntry(267, "clock_nanosleep", kFlags, kFlags, kPtr, kPtr), MakeEntry(268, "statfs64", UnknownArguments()), MakeEntry(269, "fstatfs64", UnknownArguments()), - MakeEntry(270, "tgkill", kInt, kInt, kSignal), - MakeEntry(271, "utimes", kPath, kHex), + MakeEntry(270, "tgkill", kPid, kPid, kSignal), + MakeEntry(271, "utimes", kPath, kPtr), MakeEntry(272, "fadvise64_64", UnknownArguments()), MakeEntry(273, "vserver", UnknownArguments()), - MakeEntry(274, "mbind", kGen, kInt, kInt, kHex, kInt, kHex), - MakeEntry(275, "get_mempolicy", kInt, kHex, kInt, kInt, kHex), - MakeEntry(276, "set_mempolicy", kInt, kHex, kInt), - MakeEntry(277, "mq_open", kString, kHex, kOct, kHex), + MakeEntry(274, "mbind", kPtr, kLen0, kFlags, kPtr, kInt, kFlags), + MakeEntry(275, "get_mempolicy", kPtr, kPtr, kInt, kPtr, kFlags), + MakeEntry(276, "set_mempolicy", kFlags, kPtr, kInt), + MakeEntry(277, "mq_open", kString, kFlags, kFlags, kPtr), MakeEntry(278, "mq_unlink", kString), - MakeEntry(279, "mq_timedsend", kHex, kHex, kInt, kInt, kHex), - MakeEntry(280, "mq_timedreceive", kHex, kHex, kInt, kHex, kHex), - MakeEntry(281, "mq_notify", kHex, kHex), - MakeEntry(282, "mq_getsetattr", kHex, kHex, kHex), - MakeEntry(283, "kexec_load", kHex, kInt, kHex, kHex), - MakeEntry(284, "waitid", kInt, kInt, kHex, kInt, kHex), + MakeEntry(279, "mq_timedsend", kResource, kArray, kLen1, kInt, kPtr), + MakeEntry(280, "mq_timedreceive", kResource, kArray, kLen1, kInt, kPtr), + MakeEntry(281, "mq_notify", kResource, kPtr), + MakeEntry(282, "mq_getsetattr", kResource, kPtr, kPtr), + MakeEntry(283, "kexec_load", kInt, kLen2, kArray, kFlags), + MakeEntry(284, "waitid", kFlags, kPid, kPtr, kFlags, kPtr), MakeEntry(285, "285-old_sys_setaltroot", UnknownArguments()), - MakeEntry(286, "add_key", kString, kString, kGen, kInt, kInt), - MakeEntry(287, "request_key", kString, kString, kHex, kInt), + MakeEntry(286, "add_key", kString, kPtr, kArray, kLen2, kStruct), + MakeEntry(287, "request_key", kString, kPtr, kString, kStruct), MakeEntry(288, "keyctl", kInt, kInt, kInt, kInt, kInt), - MakeEntry(289, "ioprio_set", kInt, kInt, kInt), - MakeEntry(290, "ioprio_get", kInt, kInt), + MakeEntry(289, "ioprio_set", kFlags, kPid, kFlags), + MakeEntry(290, "ioprio_get", kFlags, kUid), MakeEntry(291, "inotify_init"), - MakeEntry(292, "inotify_add_watch", kInt, kPath, kHex), - MakeEntry(293, "inotify_rm_watch", kInt, kInt), - MakeEntry(294, "migrate_pages", kInt, kInt, kHex, kHex), - MakeEntry(295, "openat", kInt, kPath, kOct), - MakeEntry(296, "mkdirat", kInt, kPath, kOct), - MakeEntry(297, "mknodat", kInt, kPath, kOct, kHex), - MakeEntry(298, "fchownat", kInt, kPath, kInt, kInt, kHex), - MakeEntry(299, "futimesat", kInt, kPath, kHex), - MakeEntry(300, "fstatat64", UnknownArguments()), - MakeEntry(301, "unlinkat", kInt, kPath, kHex), - MakeEntry(302, "renameat", kInt, kPath, kInt, kPath), - MakeEntry(303, "linkat", kInt, kPath, kInt, kPath, kHex), - MakeEntry(304, "symlinkat", kPath, kInt, kPath), - MakeEntry(305, "readlinkat", kInt, kPath, kHex, kInt), - MakeEntry(306, "fchmodat", kInt, kPath, kOct, kHex), - MakeEntry(307, "faccessat", kInt, kPath, kHex, kHex), - MakeEntry(308, "pselect6", kInt, kHex, kHex, kHex, kHex), - MakeEntry(309, "ppoll", kHex, kInt, kHex, kHex, kInt), - MakeEntry(310, "unshare", kHex), - MakeEntry(311, "set_robust_list", kHex, kInt), - MakeEntry(312, "get_robust_list", kInt, kHex, kHex), - MakeEntry(313, "splice", kInt, kHex, kInt, kHex, kInt, kHex), - MakeEntry(314, "sync_file_range", kInt, kInt, kInt, kHex), - MakeEntry(315, "tee", kInt, kInt, kInt, kHex), - MakeEntry(316, "vmsplice", kInt, kHex, kInt, kInt), - MakeEntry(317, "move_pages", kInt, kInt, kHex, kHex, kHex, kHex), - MakeEntry(318, "getcpu", kHex, kHex, kHex), - MakeEntry(319, "epoll_pwait", kInt, kHex, kInt, kInt, kHex, kInt), - MakeEntry(320, "utimensat", kInt, kPath, kHex, kHex), - MakeEntry(321, "signalfd", kInt, kHex, kHex), - MakeEntry(322, "timerfd_create", kInt, kHex), + MakeEntry(292, "inotify_add_watch", kResource, kPath, kFlags), + MakeEntry(293, "inotify_rm_watch", kResource, kResource), + MakeEntry(294, "migrate_pages", kPid, kInt, kPtr, kPtr), + MakeEntry(295, "openat", kResource, kPath, kFlags, kFlags), + MakeEntry(296, "mkdirat", kResource, kPath, kFlags), + MakeEntry(297, "mknodat", kResource, kPath, kFlags, kInt), + MakeEntry(298, "fchownat", kResource, kPath, kUid, kGid, kFlags), + MakeEntry(299, "futimesat", kResource, kPath, kPtr), + MakeEntry(300, "fstatat64", kInt, kPath, kPtr, kFlags), + MakeEntry(301, "unlinkat", kResource, kPath, kFlags), + MakeEntry(302, "renameat", kResource, kPath, kResource, kPath), + MakeEntry(303, "linkat", kResource, kPath, kResource, kPath, kFlags), + MakeEntry(304, "symlinkat", kPath, kResource, kPath), + MakeEntry(305, "readlinkat", kResource, kPath, kArray, kLen2), + MakeEntry(306, "fchmodat", kResource, kPath, kFlags), + MakeEntry(307, "faccessat", kResource, kPath, kFlags), + MakeEntry(308, "pselect6", kLen1, kPtr, kPtr, kPtr, kPtr, kPtr), + MakeEntry(309, "ppoll", kPollFdArray, kLen0, kPtr, kPtr, kLen3), + MakeEntry(310, "unshare", kFlags), + MakeEntry(311, "set_robust_list", kPtr, kLen0), + MakeEntry(312, "get_robust_list", kPid, kPtr, kPtr), + MakeEntry(313, "splice", kResource, kPtr, kResource, kPtr, kInt, kFlags), + MakeEntry(314, "sync_file_range", kResource, kInt, kInt, kFlags), + MakeEntry(315, "tee", kResource, kResource, kInt, kFlags), + MakeEntry(316, "vmsplice", kResource, kArray, kLen1, kFlags), + MakeEntry(317, "move_pages", kPid, kLen2, kArray, kArray, kArray, kFlags), + MakeEntry(318, "getcpu", kPtr, kPtr), + MakeEntry(319, "epoll_pwait", kResource, kArray, kLen1, kInt, kPtr, kLen4), + MakeEntry(320, "utimensat", kResource, kPath, kPtr, kFlags), + MakeEntry(321, "signalfd", kResource, kPtr, kLen1), + MakeEntry(322, "timerfd_create", kFlags, kFlags), MakeEntry(323, "eventfd", kInt), - MakeEntry(324, "fallocate", kInt, kOct, kInt, kInt), - MakeEntry(325, "timerfd_settime", kInt, kHex, kHex, kHex), - MakeEntry(326, "timerfd_gettime", kInt, kHex), - MakeEntry(327, "signalfd4", kInt, kHex, kHex, kHex), - MakeEntry(328, "eventfd2", kInt, kHex), - MakeEntry(329, "epoll_create1", kHex), - MakeEntry(330, "dup3", kInt, kInt, kHex), - MakeEntry(331, "pipe2", kHex, kHex), - MakeEntry(332, "inotify_init1", kHex), - MakeEntry(333, "preadv", kInt, kHex, kInt, kInt, kInt), - MakeEntry(334, "pwritev", kInt, kHex, kInt, kInt, kInt), - MakeEntry(335, "rt_tgsigqueueinfo", kInt, kInt, kInt, kHex), - MakeEntry(336, "perf_event_open", kHex, kInt, kInt, kInt, kHex), - MakeEntry(337, "recvmmsg", kInt, kHex, kInt, kHex, kHex), - MakeEntry(338, "fanotify_init", kHex, kHex), - MakeEntry(339, "fanotify_mark", kInt, kHex, kHex, kInt, kPath), - MakeEntry(340, "prlimit64", kInt, kInt, kHex, kHex), - MakeEntry(341, "name_to_handle_at", kInt, kPath, kHex, kHex, kHex), - MakeEntry(342, "open_by_handle_at", kInt, kHex, kHex), - MakeEntry(343, "clock_adjtime", kInt, kHex), - MakeEntry(344, "syncfs", kInt), - MakeEntry(345, "sendmmsg", kInt, kHex, kInt, kHex), - MakeEntry(346, "setns", kInt, kHex), - MakeEntry(347, "process_vm_readv", kInt, kHex, kInt, kHex, kInt, kInt), - MakeEntry(348, "process_vm_writev", kInt, kHex, kInt, kHex, kInt, kInt), - MakeEntry(349, "kcmp", kInt, kInt, kInt, kInt, kInt), - MakeEntry(350, "finit_module", kInt, kString, kHex), - MakeEntry(351, "sched_setattr", kInt, kHex, kHex), - MakeEntry(352, "sched_getattr", kInt, kHex, kInt, kHex), - MakeEntry(353, "renameat2", kHex, kPath, kHex, kPath, kHex, kHex), - MakeEntry(354, "seccomp", kInt, kHex, kHex), - MakeEntry(355, "getrandom", kGen, kInt, kHex), - MakeEntry(356, "memfd_create", kString, kHex), - MakeEntry(357, "bpf", kInt, kHex, kInt), - MakeEntry(435, "clone3", kHex, kInt), - MakeEntry(436, "close_range", kInt, kInt, kHex), - MakeEntry(437, "openat2", kInt, kPath, kHex, kInt), - MakeEntry(438, "pidfd_getfd", UnknownArguments()), - MakeEntry(439, "faccessat2", kInt, kPath, kHex, kHex), - MakeEntry(440, "process_madvise", UnknownArguments()), - MakeEntry(441, "epoll_pwait2", UnknownArguments()), - MakeEntry(442, "mount_setattr", UnknownArguments()), + MakeEntry(324, "fallocate", kResource, kFlags, kInt, kInt), + MakeEntry(325, "timerfd_settime", kResource, kFlags, kPtr, kPtr), + MakeEntry(326, "timerfd_gettime", kResource, kPtr), + MakeEntry(327, "signalfd4", kResource, kPtr, kLen1, kFlags), + MakeEntry(328, "eventfd2", kInt, kFlags), + MakeEntry(329, "epoll_create1", kFlags), + MakeEntry(330, "dup3", kResource, kResource, kFlags), + MakeEntry(331, "pipe2", kPtr, kFlags), + MakeEntry(332, "inotify_init1", kFlags), + MakeEntry(333, "preadv", kResource, kArray, kLen1, kInt, kInt), + MakeEntry(334, "pwritev", kResource, kArray, kLen1, kInt, kInt), + MakeEntry(335, "rt_tgsigqueueinfo", kPid, kPid, kSignal, kPtr), + MakeEntry(336, "perf_event_open", kPtr, kPid, kInt, kResource, kFlags), + MakeEntry(337, "recvmmsg", kResource, kArray, kLen1, kFlags, kPtr), + MakeEntry(338, "fanotify_init", kFlags, kFlags), + MakeEntry(339, "fanotify_mark", kResource, kFlags, kFlags, kResource, + kPath), + MakeEntry(340, "prlimit64", kPid, kFlags, kPtr, kPtr), + MakeEntry(341, "name_to_handle_at", kResource, kPath, kPtr, kPtr, kFlags), + MakeEntry(342, "open_by_handle_at", kResource, kPtr, kFlags), + MakeEntry(343, "clock_adjtime", kFlags, kPtr), + MakeEntry(344, "syncfs", kResource), + MakeEntry(345, "sendmmsg", kResource, kArray, kLen1, kFlags), + MakeEntry(346, "setns", kResource, kFlags), + MakeEntry(347, "process_vm_readv", kPid, kArray, kLen1, kArray, kLen3, + kInt), + MakeEntry(348, "process_vm_writev", kPid, kArray, kLen1, kArray, kLen3, + kInt), + MakeEntry(349, "kcmp", kPid, kPid, kFlags, kResource, kResource), + MakeEntry(350, "finit_module", kResource, kString, kFlags), + MakeEntry(351, "sched_setattr", kPid, kPtr, kInt), + MakeEntry(352, "sched_getattr", kPid, kPtr, kLen1, kInt), + MakeEntry(353, "renameat2", kResource, kPath, kResource, kPath, kFlags), + MakeEntry(354, "seccomp", kInt, kFlags, kPtr), + MakeEntry(355, "getrandom", kArray, kLen0, kFlags), + MakeEntry(356, "memfd_create", kString, kFlags), + MakeEntry(357, "bpf", kInt, kPtr, kLen1), + MakeEntry(435, "clone3", kPtr, kLen0), + MakeEntry(436, "close_range", kResource, kResource, kFlags), + MakeEntry(437, "openat2", kResource, kPath, kPtr, kLen2), + MakeEntry(438, "pidfd_getfd", kResource, kResource, kInt), + MakeEntry(439, "faccessat2", kResource, kPath, kFlags, kFlags), + MakeEntry(440, "process_madvise", kResource, kArray, kLen1, kFlags, kInt), + MakeEntry(441, "epoll_pwait2", kResource, kArray, kLen1, kPtr, kPtr, kLen4), + MakeEntry(442, "mount_setattr", kResource, kPath, kFlags, kPtr, kLen3), MakeEntry(443, "quotactl_fd", UnknownArguments()), - MakeEntry(444, "landlock_create_ruleset", UnknownArguments()), - MakeEntry(445, "landlock_add_rule", UnknownArguments()), - MakeEntry(446, "landlock_restrict_self", UnknownArguments()), - MakeEntry(447, "memfd_secret", UnknownArguments()), - MakeEntry(448, "process_mrelease", UnknownArguments()), - MakeEntry(449, "futex_waitv", UnknownArguments()), - MakeEntry(450, "set_mempolicy_home_node", UnknownArguments()), - MakeEntry(451, "cachestat", UnknownArguments()), - MakeEntry(452, "fchmodat2", kInt, kPath, kHex, kHex), - MakeEntry(453, "map_shadow_stack", UnknownArguments()), + MakeEntry(444, "landlock_create_ruleset", kPtr, kLen0, kInt), + MakeEntry(445, "landlock_add_rule", kResource, kInt, kPtr, kInt), + MakeEntry(446, "landlock_restrict_self", kResource, kInt), + MakeEntry(447, "memfd_secret", kFlags), + MakeEntry(448, "process_mrelease", kResource, kInt), + MakeEntry(449, "futex_waitv", kArray, kLen0, kInt, kPtr, kFlags), + MakeEntry(450, "set_mempolicy_home_node", kPtr, kLen0, kInt, kInt), + MakeEntry(451, "cachestat", kResource, kPtr, kPtr, kInt), + MakeEntry(452, "fchmodat2", kInt, kPath, kInt, kInt), + MakeEntry(453, "map_shadow_stack", kPtr, kLen0, kFlags), MakeEntry(454, "futex_wake", UnknownArguments()), MakeEntry(455, "futex_wait", UnknownArguments()), MakeEntry(456, "futex_requeue", UnknownArguments()), @@ -914,389 +997,395 @@ constexpr std::array kSyscallDataPPC64LE = { MakeEntry(0, "restart_syscall"), MakeEntry(1, "exit", kInt), MakeEntry(2, "fork"), - MakeEntry(3, "read", kInt, kHex, kInt), - MakeEntry(4, "write", kInt, kHex, kInt), - MakeEntry(5, "open", kPath, kHex, kOct), - MakeEntry(6, "close", kInt), - MakeEntry(7, "waitpid", kInt, kHex, kHex), - MakeEntry(8, "creat", kPath, kOct), + MakeEntry(3, "read", kResource, kArray, kLen1), + MakeEntry(4, "write", kResource, kArray, kLen1), + MakeEntry(5, "open", kPath, kFlags, kFlags), + MakeEntry(6, "close", kResource), + MakeEntry(7, "waitpid", kInt, kInt, kInt), + MakeEntry(8, "creat", kPath, kFlags), MakeEntry(9, "link", kPath, kPath), MakeEntry(10, "unlink", kPath), - MakeEntry(11, "execve", kPath, kHex, kHex), + MakeEntry(11, "execve", kPath, kArray, kArray), MakeEntry(12, "chdir", kPath), - MakeEntry(13, "time", kHex), - MakeEntry(14, "mknod", kPath, kOct, kHex), - MakeEntry(15, "chmod", kPath, kOct), - MakeEntry(16, "lchown", kPath, kInt, kInt), + MakeEntry(13, "time", kPtr), + MakeEntry(14, "mknod", kPath, kFlags, kInt), + MakeEntry(15, "chmod", kPath, kFlags), + MakeEntry(16, "lchown", kPath, kUid, kGid), MakeEntry(17, "break", UnknownArguments()), MakeEntry(18, "oldstat", UnknownArguments()), - MakeEntry(19, "lseek", kInt, kInt, kInt), + MakeEntry(19, "lseek", kResource, kInt, kFlags), MakeEntry(20, "getpid"), - MakeEntry(21, "mount", kPath, kPath, kString, kHex, kGen), + MakeEntry(21, "mount", kPtr, kPath, kString, kFlags, kString), MakeEntry(22, "umount", UnknownArguments()), - MakeEntry(23, "setuid", kInt), + MakeEntry(23, "setuid", kUid), MakeEntry(24, "getuid"), MakeEntry(25, "stime", UnknownArguments()), - MakeEntry(26, "ptrace", kInt, kInt, kHex, kHex), + MakeEntry(26, "ptrace", kFlags, kPid), MakeEntry(27, "alarm", kInt), MakeEntry(28, "oldfstat", UnknownArguments()), MakeEntry(29, "pause"), - MakeEntry(30, "utime", kPath, kHex), + MakeEntry(30, "utime", kPath, kPtr), MakeEntry(31, "stty", UnknownArguments()), MakeEntry(32, "gtty", UnknownArguments()), - MakeEntry(33, "access", kPath, kOct), + MakeEntry(33, "access", kPath, kFlags), MakeEntry(34, "nice", UnknownArguments()), MakeEntry(35, "ftime", UnknownArguments()), MakeEntry(36, "sync"), - MakeEntry(37, "kill", kInt, kSignal), + MakeEntry(37, "kill", kPid, kSignal), MakeEntry(38, "rename", kPath, kPath), - MakeEntry(39, "mkdir", kPath, kOct), + MakeEntry(39, "mkdir", kPath, kFlags), MakeEntry(40, "rmdir", kPath), - MakeEntry(41, "dup", kInt), - MakeEntry(42, "pipe", kHex), - MakeEntry(43, "times", kHex), + MakeEntry(41, "dup", kResource), + MakeEntry(42, "pipe", kPtr), + MakeEntry(43, "times", kPtr), MakeEntry(44, "prof", UnknownArguments()), MakeEntry(45, "brk", kInt), - MakeEntry(46, "setgid", kInt), + MakeEntry(46, "setgid", kGid), MakeEntry(47, "getgid"), MakeEntry(48, "signal", UnknownArguments()), MakeEntry(49, "geteuid"), MakeEntry(50, "getegid"), MakeEntry(51, "acct", kPath), - MakeEntry(52, "umount2", kPath, kHex), + MakeEntry(52, "umount2", kPath, kFlags), MakeEntry(53, "lock", UnknownArguments()), - MakeEntry(54, "ioctl", kInt, kInt, kHex), - MakeEntry(55, "fcntl", kInt, kInt, kHex), + MakeEntry(54, "ioctl", kResource, kInt, kArray), + MakeEntry(55, "fcntl", kResource, kFlags, kResource), MakeEntry(56, "mpx", UnknownArguments()), - MakeEntry(57, "setpgid", kInt, kInt), + MakeEntry(57, "setpgid", kPid, kPid), MakeEntry(58, "ulimit", UnknownArguments()), MakeEntry(59, "oldolduname", UnknownArguments()), - MakeEntry(60, "umask", kHex), + MakeEntry(60, "umask", kFlags), MakeEntry(61, "chroot", kPath), - MakeEntry(62, "ustat", kHex, kHex), - MakeEntry(63, "dup2", kInt, kInt), + MakeEntry(62, "ustat", kInt, kPtr), + MakeEntry(63, "dup2", kResource, kResource), MakeEntry(64, "getppid"), - MakeEntry(65, "getpgrp"), + MakeEntry(65, "getpgrp", kPid), MakeEntry(66, "setsid"), MakeEntry(67, "sigaction", UnknownArguments()), MakeEntry(68, "sgetmask", UnknownArguments()), MakeEntry(69, "ssetmask", UnknownArguments()), - MakeEntry(70, "setreuid", kInt, kInt), - MakeEntry(71, "setregid", kInt, kInt), + MakeEntry(70, "setreuid", kUid, kUid), + MakeEntry(71, "setregid", kGid, kGid), MakeEntry(72, "sigsuspend", UnknownArguments()), MakeEntry(73, "sigpending", UnknownArguments()), - MakeEntry(74, "sethostname", kString, kInt), - MakeEntry(75, "setrlimit", kInt, kHex), - MakeEntry(76, "getrlimit", kInt, kHex), - MakeEntry(77, "getrusage", kInt, kHex), - MakeEntry(78, "gettimeofday", kHex, kHex), - MakeEntry(79, "settimeofday", kHex, kHex), - MakeEntry(80, "getgroups", kInt, kHex), - MakeEntry(81, "setgroups", kInt, kHex), - MakeEntry(82, "select", kInt, kHex, kHex, kHex, kHex), + MakeEntry(74, "sethostname", kString, kLen0), + MakeEntry(75, "setrlimit", kFlags, kPtr), + MakeEntry(76, "getrlimit", kFlags, kPtr), + MakeEntry(77, "getrusage", kFlags, kPtr), + MakeEntry(78, "gettimeofday", kPtr, kPtr), + MakeEntry(79, "settimeofday", kPtr, kPtr), + MakeEntry(80, "getgroups", kLen1, kGidArray), + MakeEntry(81, "setgroups", kLen1, kGidArray), + MakeEntry(82, "select", kLen1, kPtr, kPtr, kPtr, kPtr), MakeEntry(83, "symlink", kPath, kPath), MakeEntry(84, "oldlstat", UnknownArguments()), - MakeEntry(85, "readlink", kPath, kHex, kInt), + MakeEntry(85, "readlink", kPath, kArray, kLen1), MakeEntry(86, "uselib", kPath), - MakeEntry(87, "swapon", kPath, kHex), - MakeEntry(88, "reboot", kInt, kHex, kHex, kGen), + MakeEntry(87, "swapon", kPath, kFlags), + MakeEntry(88, "reboot", kInt, kInt, kInt, kPtr), MakeEntry(89, "readdir", UnknownArguments()), - MakeEntry(90, "mmap", kHex, kInt, kHex, kHex, kInt, kInt), - MakeEntry(91, "munmap", kHex, kInt), + MakeEntry(90, "mmap", kPtr, kLen0, kFlags, kFlags, kResource, kInt), + MakeEntry(91, "munmap", kPtr, kLen0), MakeEntry(92, "truncate", kPath, kInt), - MakeEntry(93, "ftruncate", kInt, kInt), - MakeEntry(94, "fchmod", kInt, kOct), - MakeEntry(95, "fchown", kInt, kInt, kInt), - MakeEntry(96, "getpriority", kInt, kInt), - MakeEntry(97, "setpriority", kInt, kInt, kInt), + MakeEntry(93, "ftruncate", kResource, kInt), + MakeEntry(94, "fchmod", kResource, kFlags), + MakeEntry(95, "fchown", kResource, kUid, kGid), + MakeEntry(96, "getpriority", kFlags, kPid), + MakeEntry(97, "setpriority", kFlags, kPid, kInt), MakeEntry(98, "profil", UnknownArguments()), - MakeEntry(99, "statfs", kPath, kHex), - MakeEntry(100, "fstatfs", kInt, kHex), + MakeEntry(99, "statfs", kPath, kArray), + MakeEntry(100, "fstatfs", kResource, kArray), MakeEntry(101, "ioperm", kInt, kInt, kInt), MakeEntry(102, "socketcall", UnknownArguments()), - MakeEntry(103, "syslog", kInt, kHex, kInt), - MakeEntry(104, "setitimer", kInt, kHex, kHex), - MakeEntry(105, "getitimer", kInt, kHex), - MakeEntry(106, "stat", kPath, kGen), - MakeEntry(107, "lstat", kPath, kGen), - MakeEntry(108, "fstat", kInt, kHex), + MakeEntry(103, "syslog", kFlags, kArray, kLen1), + MakeEntry(104, "setitimer", kFlags, kPtr, kPtr), + MakeEntry(105, "getitimer", kFlags, kPtr), + MakeEntry(106, "stat", kPath, kPtr), + MakeEntry(107, "lstat", kPath, kPtr), + MakeEntry(108, "fstat", kResource, kPtr), MakeEntry(109, "olduname", UnknownArguments()), MakeEntry(110, "iopl", kInt), MakeEntry(111, "vhangup"), MakeEntry(112, "idle", UnknownArguments()), MakeEntry(113, "vm86", UnknownArguments()), - MakeEntry(114, "wait4", kInt, kHex, kHex, kHex), + MakeEntry(114, "wait4", kPid, kPtr, kFlags, kPtr), MakeEntry(115, "swapoff", kPath), - MakeEntry(116, "sysinfo", kHex), + MakeEntry(116, "sysinfo", kArray), MakeEntry(117, "ipc", UnknownArguments()), - MakeEntry(118, "fsync", kInt), + MakeEntry(118, "fsync", kResource), MakeEntry(119, "sigreturn", UnknownArguments()), - MakeEntry(120, "clone", kCloneFlag, kHex, kHex, kHex, kHex), - MakeEntry(121, "setdomainname", kString, kInt), - MakeEntry(122, "uname", kInt), - MakeEntry(123, "modify_ldt", kInt, kHex, kInt), - MakeEntry(124, "adjtimex", kHex), - MakeEntry(125, "mprotect", kHex, kInt, kHex), + MakeEntry(120, "clone", kFlags, kArray, kPtr, kPtr, kArray), + MakeEntry(121, "setdomainname", kString, kLen0), + MakeEntry(122, "uname", kArray), + MakeEntry(123, "modify_ldt", kInt, kPtr, kLen1), + MakeEntry(124, "adjtimex", kArray), + MakeEntry(125, "mprotect", kPtr, kLen0, kFlags), MakeEntry(126, "sigprocmask", UnknownArguments()), MakeEntry(127, "create_module", kString, kInt), - MakeEntry(128, "init_module", kGen, kInt, kString), - MakeEntry(129, "delete_module", kString, kHex), - MakeEntry(130, "get_kernel_syms", kHex), + MakeEntry(128, "init_module", kString, kLen0, kString), + MakeEntry(129, "delete_module", kString, kFlags), + MakeEntry(130, "get_kernel_syms", kInt), MakeEntry(131, "quotactl", kInt, kPath, kInt, kGen), - MakeEntry(132, "getpgid", kInt), - MakeEntry(133, "fchdir", kInt), + MakeEntry(132, "getpgid", kPid), + MakeEntry(133, "fchdir", kResource), MakeEntry(134, "bdflush", UnknownArguments()), - MakeEntry(135, "sysfs", kInt, kInt, kInt), - MakeEntry(136, "personality", kHex), + MakeEntry(135, "sysfs", kInt, kString), + MakeEntry(136, "personality", kFlags), MakeEntry(137, "afs_syscall", UnknownArguments()), - MakeEntry(138, "setfsuid", kInt), - MakeEntry(139, "setfsgid", kInt), + MakeEntry(138, "setfsuid", kUid), + MakeEntry(139, "setfsgid", kGid), MakeEntry(140, "_llseek", UnknownArguments()), - MakeEntry(141, "getdents", kInt, kHex, kInt), + MakeEntry(141, "getdents", kResource, kArray, kLen1), MakeEntry(142, "_newselect", UnknownArguments()), - MakeEntry(143, "flock", kInt, kInt), - MakeEntry(144, "msync", kHex, kInt, kInt), - MakeEntry(145, "readv", kInt, kHex, kInt), - MakeEntry(146, "writev", kInt, kHex, kInt), - MakeEntry(147, "getsid", kInt), - MakeEntry(148, "fdatasync", kInt), - MakeEntry(149, "_sysctl", kHex), - MakeEntry(150, "mlock", kInt, kInt), - MakeEntry(151, "munlock", kInt, kInt), - MakeEntry(152, "mlockall", kHex), + MakeEntry(143, "flock", kResource, kFlags), + MakeEntry(144, "msync", kPtr, kLen0, kFlags), + MakeEntry(145, "readv", kResource, kArray, kLen1), + MakeEntry(146, "writev", kResource, kArray, kLen1), + MakeEntry(147, "getsid", kPid), + MakeEntry(148, "fdatasync", kResource), + MakeEntry(149, "_sysctl", kPtr), + MakeEntry(150, "mlock", kPtr, kLen0), + MakeEntry(151, "munlock", kPtr, kLen0), + MakeEntry(152, "mlockall", kFlags), MakeEntry(153, "munlockall"), - MakeEntry(154, "sched_setparam", kInt, kHex), - MakeEntry(155, "sched_getparam", kInt, kHex), - MakeEntry(156, "sched_setscheduler", kInt, kInt, kHex), - MakeEntry(157, "sched_getscheduler", kInt), + MakeEntry(154, "sched_setparam", kPid, kPtr), + MakeEntry(155, "sched_getparam", kPid, kPtr), + MakeEntry(156, "sched_setscheduler", kPid, kFlags, kPtr), + MakeEntry(157, "sched_getscheduler", kPid), MakeEntry(158, "sched_yield"), MakeEntry(159, "sched_get_priority_max", kInt), MakeEntry(160, "sched_get_priority_min", kInt), - MakeEntry(161, "sched_rr_get_interval", kInt, kHex), - MakeEntry(162, "nanosleep", kHex, kHex), - MakeEntry(163, "mremap", kHex, kInt, kInt, kInt, kHex), - MakeEntry(164, "setresuid", kInt, kInt, kInt), - MakeEntry(165, "getresuid", kHex, kHex, kHex), + MakeEntry(161, "sched_rr_get_interval", kPid, kPtr), + MakeEntry(162, "nanosleep", kPtr, kPtr), + MakeEntry(163, "mremap", kPtr, kLen0, kLen4, kFlags, kPtr), + MakeEntry(164, "setresuid", kUid, kUid, kUid), + MakeEntry(165, "getresuid", kPtr, kPtr, kPtr), MakeEntry(166, "query_module", kString, kInt, kGen, kInt, kGen), - MakeEntry(167, "poll", kGen, kInt, kInt), - MakeEntry(168, "nfsservctl", kInt, kGen, kGen), - MakeEntry(169, "setresgid", kInt, kInt, kInt), - MakeEntry(170, "getresgid", kHex, kHex, kHex), - MakeEntry(171, "prctl", kInt, kHex, kHex, kHex, kHex), + MakeEntry(167, "poll", kPollFdArray, kLen0, kInt), + MakeEntry(168, "nfsservctl", kInt, kPtr, kPtr), + MakeEntry(169, "setresgid", kGid, kGid, kGid), + MakeEntry(170, "getresgid", kPtr, kPtr, kPtr), + MakeEntry(171, "prctl", kInt, kInt, kInt, kInt, kInt), MakeEntry(172, "rt_sigreturn"), - MakeEntry(173, "rt_sigaction", kSignal, kHex, kHex, kInt), - MakeEntry(174, "rt_sigprocmask", kInt, kHex, kHex, kInt), - MakeEntry(175, "rt_sigpending", kHex, kInt), - MakeEntry(176, "rt_sigtimedwait", kHex, kHex, kHex, kInt), - MakeEntry(177, "rt_sigqueueinfo", kInt, kSignal, kHex), - MakeEntry(178, "rt_sigsuspend", kHex, kInt), - MakeEntry(179, "pread64", kInt, kHex, kInt, kInt), - MakeEntry(180, "pwrite64", kInt, kHex, kInt, kInt), - MakeEntry(181, "chown", kPath, kInt, kInt), - MakeEntry(182, "getcwd", kHex, kInt), - MakeEntry(183, "capget", kHex, kHex), - MakeEntry(184, "capset", kHex, kHex), - MakeEntry(185, "sigaltstack", kHex, kHex), - MakeEntry(186, "sendfile", kInt, kInt, kHex, kInt), + MakeEntry(173, "rt_sigaction", kSignal, kPtr, kPtr, kLen4, kPtr), + MakeEntry(174, "rt_sigprocmask", kFlags, kPtr, kPtr, kLen1), + MakeEntry(175, "rt_sigpending", kPtr, kLen0), + MakeEntry(176, "rt_sigtimedwait", kPtr, kPtr, kPtr, kLen0), + MakeEntry(177, "rt_sigqueueinfo", kPid, kSignal, kPtr), + MakeEntry(178, "rt_sigsuspend", kPtr, kLen0), + MakeEntry(179, "pread64", kResource, kArray, kLen1, kInt), + MakeEntry(180, "pwrite64", kResource, kArray, kLen1, kInt), + MakeEntry(181, "chown", kPath, kUid, kGid), + MakeEntry(182, "getcwd", kArray, kLen0), + MakeEntry(183, "capget", kPtr, kPtr), + MakeEntry(184, "capset", kPtr, kPtr), + MakeEntry(185, "sigaltstack", kPtr, kPtr), + MakeEntry(186, "sendfile", kResource, kResource, kPtr, kInt), MakeEntry(187, "getpmsg", UnknownArguments()), MakeEntry(188, "putpmsg", UnknownArguments()), MakeEntry(189, "vfork"), MakeEntry(190, "ugetrlimit", UnknownArguments()), - MakeEntry(191, "readahead", kInt, kInt, kInt), + MakeEntry(191, "readahead", kResource, kInt, kInt), MakeEntry(192, "mmap2", UnknownArguments()), MakeEntry(193, "truncate64", UnknownArguments()), MakeEntry(194, "ftruncate64", UnknownArguments()), - MakeEntry(195, "stat64", UnknownArguments()), - MakeEntry(196, "lstat64", UnknownArguments()), - MakeEntry(197, "fstat64", UnknownArguments()), + MakeEntry(195, "stat64", kPath, kPtr), + MakeEntry(196, "lstat64", kPath, kPtr), + MakeEntry(197, "fstat64", kResource, kPtr), MakeEntry(198, "pciconfig_read", UnknownArguments()), MakeEntry(199, "pciconfig_write", UnknownArguments()), MakeEntry(200, "pciconfig_iobase", UnknownArguments()), MakeEntry(201, "multiplexer", UnknownArguments()), - MakeEntry(202, "getdents64", kInt, kHex, kInt), + MakeEntry(202, "getdents64", kResource, kArray, kLen1), MakeEntry(203, "pivot_root", kPath, kPath), MakeEntry(204, "fcntl64", UnknownArguments()), - MakeEntry(205, "madvise", kHex, kInt, kInt), - MakeEntry(206, "mincore", kHex, kInt, kHex), + MakeEntry(205, "madvise", kPtr, kLen0, kFlags), + MakeEntry(206, "mincore", kPtr, kLen0, kArray), MakeEntry(207, "gettid"), - MakeEntry(208, "tkill", kInt, kSignal), - MakeEntry(209, "setxattr", kPath, kString, kGen, kInt, kHex), - MakeEntry(210, "lsetxattr", kPath, kString, kGen, kInt, kHex), - MakeEntry(211, "fsetxattr", kInt, kString, kGen, kInt, kHex), - MakeEntry(212, "getxattr", kPath, kString, kGen, kInt), - MakeEntry(213, "lgetxattr", kPath, kString, kGen, kInt), - MakeEntry(214, "fgetxattr", kInt, kString, kGen, kInt), - MakeEntry(215, "listxattr", kPath, kGen, kInt), - MakeEntry(216, "llistxattr", kPath, kGen, kInt), - MakeEntry(217, "flistxattr", kInt, kGen, kInt), - MakeEntry(218, "removexattr", kPath, kString), - MakeEntry(219, "lremovexattr", kPath, kString), - MakeEntry(220, "fremovexattr", kInt, kString), - MakeEntry(221, "futex", kGen, kInt, kInt, kGen, kGen, kInt), - MakeEntry(222, "sched_setaffinity", kInt, kInt, kHex), - MakeEntry(223, "sched_getaffinity", kInt, kInt, kHex), + MakeEntry(208, "tkill", kPid, kSignal), + MakeEntry(209, "setxattr", kPath, kPtr, kString, kLen2, kFlags), + MakeEntry(210, "lsetxattr", kPath, kPtr, kString, kLen2, kFlags), + MakeEntry(211, "fsetxattr", kResource, kPtr, kString, kLen2, kFlags), + MakeEntry(212, "getxattr", kPath, kPtr, kArray, kLen2), + MakeEntry(213, "lgetxattr", kPath, kPtr, kArray, kLen2), + MakeEntry(214, "fgetxattr", kResource, kPtr, kArray, kLen2), + MakeEntry(215, "listxattr", kPath, kArray, kLen1), + MakeEntry(216, "llistxattr", kPath, kArray, kLen1), + MakeEntry(217, "flistxattr", kResource, kArray, kLen1), + MakeEntry(218, "removexattr", kPath, kPtr), + MakeEntry(219, "lremovexattr", kPath, kPtr), + MakeEntry(220, "fremovexattr", kResource, kPtr), + MakeEntry(221, "futex", kPtr, kFlags, kInt, kPtr, kPtr, kInt), + MakeEntry(222, "sched_setaffinity", kPid, kLen2, kPtr), + MakeEntry(223, "sched_getaffinity", kPid, kLen2, kPtr), MakeEntry(225, "tuxcall", UnknownArguments()), - MakeEntry(226, "sendfile64", UnknownArguments()), - MakeEntry(227, "io_setup", kInt, kHex), - MakeEntry(228, "io_destroy", kInt), - MakeEntry(229, "io_getevents", kInt, kInt, kInt, kHex, kHex), - MakeEntry(230, "io_submit", kInt, kInt, kHex), - MakeEntry(231, "io_cancel", kInt, kHex, kHex), - MakeEntry(232, "set_tid_address", kHex), - MakeEntry(233, "fadvise64", kInt, kInt, kInt, kInt), + MakeEntry(226, "sendfile64", kResource, kResource, kPtr, kInt), + MakeEntry(227, "io_setup", kInt, kPtr), + MakeEntry(228, "io_destroy", kStruct), + MakeEntry(229, "io_getevents", kStruct, kInt, kLen3, kArray, kPtr), + MakeEntry(230, "io_submit", kStruct, kLen2, kArray), + MakeEntry(231, "io_cancel", kStruct, kPtr, kPtr), + MakeEntry(232, "set_tid_address", kPtr), + MakeEntry(233, "fadvise64", kResource, kInt, kInt, kFlags), MakeEntry(234, "exit_group", kInt), - MakeEntry(235, "lookup_dcookie", kInt, kString, kInt), + MakeEntry(235, "lookup_dcookie", kInt, kArray, kLen1), MakeEntry(236, "epoll_create", kInt), - MakeEntry(237, "epoll_ctl", kInt, kInt, kInt, kHex), - MakeEntry(238, "epoll_wait", kInt, kHex, kInt, kInt), - MakeEntry(239, "remap_file_pages", kGen, kInt, kInt, kInt, kHex), - MakeEntry(240, "timer_create", kInt, kHex, kHex), - MakeEntry(241, "timer_settime", kInt, kHex, kHex, kHex), - MakeEntry(242, "timer_gettime", kInt, kHex), - MakeEntry(243, "timer_getoverrun", kInt), - MakeEntry(244, "timer_delete", kInt), - MakeEntry(245, "clock_settime", kInt, kHex), - MakeEntry(246, "clock_gettime", kInt, kHex), - MakeEntry(247, "clock_getres", kInt, kHex), - MakeEntry(248, "clock_nanosleep", kInt, kHex, kHex, kHex), + MakeEntry(237, "epoll_ctl", kResource, kInt, kResource, kPtr), + MakeEntry(238, "epoll_wait", kResource, kArray, kLen1, kInt), + MakeEntry(239, "remap_file_pages", kPtr, kLen0, kFlags, kInt, kFlags), + MakeEntry(240, "timer_create", kFlags, kPtr, kPtr), + MakeEntry(241, "timer_settime", kStruct, kFlags, kPtr, kPtr), + MakeEntry(242, "timer_gettime", kStruct, kPtr), + MakeEntry(243, "timer_getoverrun", kStruct), + MakeEntry(244, "timer_delete", kStruct), + MakeEntry(245, "clock_settime", kFlags, kPtr), + MakeEntry(246, "clock_gettime", kFlags, kPtr), + MakeEntry(247, "clock_getres", kFlags, kPtr), + MakeEntry(248, "clock_nanosleep", kFlags, kFlags, kPtr, kPtr), MakeEntry(249, "swapcontext", UnknownArguments()), - MakeEntry(250, "tgkill", kInt, kInt, kSignal), - MakeEntry(251, "utimes", kPath, kHex), + MakeEntry(250, "tgkill", kPid, kPid, kSignal), + MakeEntry(251, "utimes", kPath, kPtr), MakeEntry(252, "statfs64", UnknownArguments()), MakeEntry(253, "fstatfs64", UnknownArguments()), MakeEntry(254, "fadvise64_64", UnknownArguments()), MakeEntry(255, "rtas", UnknownArguments()), - MakeEntry(256, "sys_debug_setcontext", kHex, kHex, kHex, kHex, kHex, kHex), - MakeEntry(258, "migrate_pages", kInt, kInt, kHex, kHex), - MakeEntry(259, "mbind", kGen, kInt, kInt, kHex, kInt, kHex), - MakeEntry(260, "get_mempolicy", kInt, kHex, kInt, kInt, kHex), - MakeEntry(261, "set_mempolicy", kInt, kHex, kInt), - MakeEntry(262, "mq_open", kString, kHex, kOct, kHex), + MakeEntry(256, "sys_debug_setcontext", kInt, kInt, kInt, kInt, kInt, kInt), + MakeEntry(258, "migrate_pages", kPid, kInt, kPtr, kPtr), + MakeEntry(259, "mbind", kPtr, kLen0, kFlags, kPtr, kInt, kFlags), + MakeEntry(260, "get_mempolicy", kPtr, kPtr, kInt, kPtr, kFlags), + MakeEntry(261, "set_mempolicy", kFlags, kPtr, kInt), + MakeEntry(262, "mq_open", kString, kFlags, kFlags, kPtr), MakeEntry(263, "mq_unlink", kString), - MakeEntry(264, "mq_timedsend", kHex, kHex, kInt, kInt, kHex), - MakeEntry(265, "mq_timedreceive", kHex, kHex, kInt, kHex, kHex), - MakeEntry(266, "mq_notify", kHex, kHex), - MakeEntry(267, "mq_getsetattr", kHex, kHex, kHex), - MakeEntry(268, "kexec_load", kHex, kInt, kHex, kHex), - MakeEntry(269, "add_key", kString, kString, kGen, kInt, kInt), - MakeEntry(270, "request_key", kString, kString, kHex, kInt), + MakeEntry(264, "mq_timedsend", kResource, kArray, kLen1, kInt, kPtr), + MakeEntry(265, "mq_timedreceive", kResource, kArray, kLen1, kInt, kPtr), + MakeEntry(266, "mq_notify", kResource, kPtr), + MakeEntry(267, "mq_getsetattr", kResource, kPtr, kPtr), + MakeEntry(268, "kexec_load", kInt, kLen2, kArray, kFlags), + MakeEntry(269, "add_key", kString, kPtr, kArray, kLen2, kStruct), + MakeEntry(270, "request_key", kString, kPtr, kString, kStruct), MakeEntry(271, "keyctl", kInt, kInt, kInt, kInt, kInt), - MakeEntry(272, "waitid", kInt, kInt, kHex, kInt, kHex), - MakeEntry(273, "ioprio_set", kInt, kInt, kInt), - MakeEntry(274, "ioprio_get", kInt, kInt), + MakeEntry(272, "waitid", kFlags, kPid, kPtr, kFlags, kPtr), + MakeEntry(273, "ioprio_set", kFlags, kPid, kFlags), + MakeEntry(274, "ioprio_get", kFlags, kUid), MakeEntry(275, "inotify_init"), - MakeEntry(276, "inotify_add_watch", kInt, kPath, kHex), - MakeEntry(277, "inotify_rm_watch", kInt, kInt), + MakeEntry(276, "inotify_add_watch", kResource, kPath, kFlags), + MakeEntry(277, "inotify_rm_watch", kResource, kResource), MakeEntry(278, "spu_run", UnknownArguments()), MakeEntry(279, "spu_create", UnknownArguments()), - MakeEntry(280, "pselect6", kInt, kHex, kHex, kHex, kHex), - MakeEntry(281, "ppoll", kHex, kInt, kHex, kHex, kInt), - MakeEntry(282, "unshare", kHex), - MakeEntry(283, "splice", kInt, kHex, kInt, kHex, kInt, kHex), - MakeEntry(284, "tee", kInt, kInt, kInt, kHex), - MakeEntry(285, "vmsplice", kInt, kHex, kInt, kInt), - MakeEntry(286, "openat", kInt, kPath, kHex, kOct), - MakeEntry(287, "mkdirat", kInt, kPath, kOct), - MakeEntry(288, "mknodat", kInt, kPath, kOct, kHex), - MakeEntry(289, "fchownat", kInt, kPath, kInt, kInt, kHex), - MakeEntry(290, "futimesat", kInt, kPath, kHex), - MakeEntry(291, "newfstatat", kInt, kPath, kHex, kHex), - MakeEntry(292, "unlinkat", kInt, kPath, kHex), - MakeEntry(293, "renameat", kInt, kPath, kInt, kPath), - MakeEntry(294, "linkat", kInt, kPath, kInt, kPath, kHex), - MakeEntry(295, "symlinkat", kPath, kInt, kPath), - MakeEntry(296, "readlinkat", kInt, kPath, kHex, kInt), - MakeEntry(297, "fchmodat", kInt, kPath, kOct), - MakeEntry(298, "faccessat", kInt, kPath, kInt, kHex), - MakeEntry(299, "get_robust_list", kInt, kHex, kHex), - MakeEntry(300, "set_robust_list", kHex, kInt), - MakeEntry(301, "move_pages", kInt, kInt, kHex, kHex, kHex, kHex), - MakeEntry(302, "getcpu", kHex, kHex, kHex), - MakeEntry(303, "epoll_pwait", kInt, kHex, kInt, kInt, kHex, kInt), - MakeEntry(304, "utimensat", kInt, kPath, kHex, kHex), - MakeEntry(305, "signalfd", kInt, kHex, kHex), - MakeEntry(306, "timerfd_create", kInt, kHex), + MakeEntry(280, "pselect6", kLen1, kPtr, kPtr, kPtr, kPtr, kPtr), + MakeEntry(281, "ppoll", kPollFdArray, kLen0, kPtr, kPtr, kLen3), + MakeEntry(282, "unshare", kFlags), + MakeEntry(283, "splice", kResource, kPtr, kResource, kPtr, kInt, kFlags), + MakeEntry(284, "tee", kResource, kResource, kInt, kFlags), + MakeEntry(285, "vmsplice", kResource, kArray, kLen1, kFlags), + MakeEntry(286, "openat", kResource, kPath, kFlags, kFlags), + MakeEntry(287, "mkdirat", kResource, kPath, kFlags), + MakeEntry(288, "mknodat", kResource, kPath, kFlags, kInt), + MakeEntry(289, "fchownat", kResource, kPath, kUid, kGid, kFlags), + MakeEntry(290, "futimesat", kResource, kPath, kPtr), + MakeEntry(291, "newfstatat", kInt, kPath, kPtr, kFlags), + MakeEntry(292, "unlinkat", kResource, kPath, kFlags), + MakeEntry(293, "renameat", kResource, kPath, kResource, kPath), + MakeEntry(294, "linkat", kResource, kPath, kResource, kPath, kFlags), + MakeEntry(295, "symlinkat", kPath, kResource, kPath), + MakeEntry(296, "readlinkat", kResource, kPath, kArray, kLen2), + MakeEntry(297, "fchmodat", kResource, kPath, kFlags), + MakeEntry(298, "faccessat", kResource, kPath, kFlags), + MakeEntry(299, "get_robust_list", kPid, kPtr, kPtr), + MakeEntry(300, "set_robust_list", kPtr, kLen0), + MakeEntry(301, "move_pages", kPid, kLen2, kArray, kArray, kArray, kFlags), + MakeEntry(302, "getcpu", kPtr, kPtr), + MakeEntry(303, "epoll_pwait", kResource, kArray, kLen1, kInt, kPtr, kLen4), + MakeEntry(304, "utimensat", kResource, kPath, kPtr, kFlags), + MakeEntry(305, "signalfd", kResource, kPtr, kLen1), + MakeEntry(306, "timerfd_create", kFlags, kFlags), MakeEntry(307, "eventfd", kInt), MakeEntry(308, "sync_file_range2", UnknownArguments()), - MakeEntry(309, "fallocate", kInt, kOct, kInt, kInt), + MakeEntry(309, "fallocate", kResource, kFlags, kInt, kInt), MakeEntry(310, "subpage_prot", UnknownArguments()), - MakeEntry(311, "timerfd_settime", kInt, kHex, kHex, kHex), - MakeEntry(312, "timerfd_gettime", kInt, kHex), - MakeEntry(313, "signalfd4", kInt, kHex, kHex, kHex), - MakeEntry(314, "eventfd2", kInt, kHex), - MakeEntry(315, "epoll_create1", kHex), - MakeEntry(316, "dup3", kInt, kInt, kHex), - MakeEntry(317, "pipe2", kHex, kHex), - MakeEntry(318, "inotify_init1", kHex), - MakeEntry(319, "perf_event_open", kHex, kInt, kInt, kInt, kHex), - MakeEntry(320, "preadv", kInt, kHex, kInt, kInt, kInt), - MakeEntry(321, "pwritev", kInt, kHex, kInt, kInt, kInt), - MakeEntry(322, "rt_tgsigqueueinfo", kInt, kInt, kInt, kHex), - MakeEntry(323, "fanotify_init", kHex, kHex, kInt, kGen, kGen, kGen), - MakeEntry(324, "fanotify_mark", kInt, kHex, kHex, kInt, kPath), - MakeEntry(325, "prlimit64", kInt, kInt, kHex, kHex), - MakeEntry(326, "socket", kAddressFamily, kInt, kInt), - MakeEntry(327, "bind", kInt, kSockaddr, kInt), - MakeEntry(328, "connect", kInt, kSockaddr, kInt), - MakeEntry(329, "listen", kInt, kInt), - MakeEntry(330, "accept", kInt, kSockaddr, kHex), - MakeEntry(331, "getsockname", kInt, kSockaddr, kHex), - MakeEntry(332, "getpeername", kInt, kSockaddr, kHex), - MakeEntry(333, "socketpair", kAddressFamily, kInt, kInt, kHex), + MakeEntry(311, "timerfd_settime", kResource, kFlags, kPtr, kPtr), + MakeEntry(312, "timerfd_gettime", kResource, kPtr), + MakeEntry(313, "signalfd4", kResource, kPtr, kLen1, kFlags), + MakeEntry(314, "eventfd2", kInt, kFlags), + MakeEntry(315, "epoll_create1", kFlags), + MakeEntry(316, "dup3", kResource, kResource, kFlags), + MakeEntry(317, "pipe2", kPtr, kFlags), + MakeEntry(318, "inotify_init1", kFlags), + MakeEntry(319, "perf_event_open", kPtr, kPid, kInt, kResource, kFlags), + MakeEntry(320, "preadv", kResource, kArray, kLen1, kInt, kInt), + MakeEntry(321, "pwritev", kResource, kArray, kLen1, kInt, kInt), + MakeEntry(322, "rt_tgsigqueueinfo", kPid, kPid, kSignal, kPtr), + MakeEntry(323, "fanotify_init", kFlags, kFlags), + MakeEntry(324, "fanotify_mark", kResource, kFlags, kFlags, kResource, + kPath), + MakeEntry(325, "prlimit64", kPid, kFlags, kPtr, kPtr), + MakeEntry(326, "socket", kFlags, kFlags, kInt), + MakeEntry(327, "bind", kResource, kSockaddr, kLen1), + MakeEntry(328, "connect", kResource, kSockaddr, kLen1), + MakeEntry(329, "listen", kResource, kInt), + MakeEntry(330, "accept", kResource, kPtr, kPtr), + MakeEntry(331, "getsockname", kResource, kPtr, kPtr), + MakeEntry(332, "getpeername", kResource, kPtr, kPtr), + MakeEntry(333, "socketpair", kFlags, kFlags, kInt, kPtr), MakeEntry(334, "send", UnknownArguments()), - MakeEntry(335, "sendto", kInt, kGen, kInt, kHex, kSockaddr, kInt), + MakeEntry(335, "sendto", kResource, kArray, kLen1, kFlags, kSockaddr, + kLen4), MakeEntry(336, "recv", UnknownArguments()), - MakeEntry(337, "recvfrom", kInt, kHex, kInt, kHex, kSockaddr, kHex), - MakeEntry(338, "shutdown", kInt, kInt), - MakeEntry(339, "setsockopt", kInt, kInt, kInt, kHex, kHex), - MakeEntry(340, "getsockopt", kInt, kInt, kInt, kHex, kInt), - MakeEntry(341, "sendmsg", kInt, kSockmsghdr, kHex), - MakeEntry(342, "recvmsg", kInt, kHex, kInt), - MakeEntry(343, "recvmmsg", kInt, kHex, kInt, kHex, kHex), - MakeEntry(344, "accept4", kInt, kHex, kHex, kInt), - MakeEntry(345, "name_to_handle_at", kInt, kPath, kHex, kHex, kHex), - MakeEntry(346, "open_by_handle_at", kInt, kHex, kHex), - MakeEntry(347, "clock_adjtime", kInt, kHex), - MakeEntry(348, "syncfs", kInt), - MakeEntry(349, "sendmmsg", kInt, kHex, kInt, kHex), - MakeEntry(350, "setns", kInt, kHex), - MakeEntry(351, "process_vm_readv", kInt, kHex, kInt, kHex, kInt, kInt), - MakeEntry(352, "process_vm_writev", kInt, kHex, kInt, kHex, kInt, kInt), - MakeEntry(353, "finit_module", kInt, kString, kHex), - MakeEntry(354, "kcmp", kInt, kInt, kInt, kInt, kInt), - MakeEntry(355, "sched_setattr", kInt, kHex, kHex), - MakeEntry(356, "sched_getattr", kInt, kHex, kInt, kHex), - MakeEntry(357, "renameat2", kInt, kPath, kInt, kPath, kHex), - MakeEntry(358, "seccomp", kInt, kHex, kHex), - MakeEntry(359, "getrandom", kGen, kInt, kHex), - MakeEntry(360, "memfd_create", kString, kHex), - MakeEntry(361, "bpf", kInt, kHex, kInt), - MakeEntry(362, "execveat", kInt, kPath, kHex, kHex, kHex), + MakeEntry(337, "recvfrom", kResource, kArray, kLen1, kFlags, kSockaddr, + kLen4), + MakeEntry(338, "shutdown", kResource, kFlags), + MakeEntry(339, "setsockopt", kResource, kInt, kInt, kArray, kLen3), + MakeEntry(340, "getsockopt", kResource, kInt, kInt, kArray, kPtr), + MakeEntry(341, "sendmsg", kResource, kPtr, kFlags), + MakeEntry(342, "recvmsg", kResource, kPtr, kFlags), + MakeEntry(343, "recvmmsg", kResource, kArray, kLen1, kFlags, kPtr), + MakeEntry(344, "accept4", kResource, kPtr, kPtr, kFlags), + MakeEntry(345, "name_to_handle_at", kResource, kPath, kPtr, kPtr, kFlags), + MakeEntry(346, "open_by_handle_at", kResource, kPtr, kFlags), + MakeEntry(347, "clock_adjtime", kFlags, kPtr), + MakeEntry(348, "syncfs", kResource), + MakeEntry(349, "sendmmsg", kResource, kArray, kLen1, kFlags), + MakeEntry(350, "setns", kResource, kFlags), + MakeEntry(351, "process_vm_readv", kPid, kArray, kLen1, kArray, kLen3, + kInt), + MakeEntry(352, "process_vm_writev", kPid, kArray, kLen1, kArray, kLen3, + kInt), + MakeEntry(353, "finit_module", kResource, kString, kFlags), + MakeEntry(354, "kcmp", kPid, kPid, kFlags, kResource, kResource), + MakeEntry(355, "sched_setattr", kPid, kPtr, kInt), + MakeEntry(356, "sched_getattr", kPid, kPtr, kLen1, kInt), + MakeEntry(357, "renameat2", kResource, kPath, kResource, kPath, kFlags), + MakeEntry(358, "seccomp", kInt, kFlags, kPtr), + MakeEntry(359, "getrandom", kArray, kLen0, kFlags), + MakeEntry(360, "memfd_create", kString, kFlags), + MakeEntry(361, "bpf", kInt, kPtr, kLen1), + MakeEntry(362, "execveat", kResource, kPath, kArray, kArray, kFlags), MakeEntry(363, "switch_endian", UnknownArguments()), - MakeEntry(364, "userfaultfd", kHex), - MakeEntry(365, "membarrier", kInt, kHex), - MakeEntry(378, "mlock2", kHex, kInt, kHex), - MakeEntry(379, "copy_file_range", kInt, kHex, kInt, kHex, kInt, kHex), - MakeEntry(380, "preadv2", kInt, kHex, kInt, kInt, kInt, kHex), - MakeEntry(381, "pwritev2", kInt, kHex, kInt, kInt, kInt, kHex), - MakeEntry(435, "clone3", kHex, kInt), - MakeEntry(436, "close_range", kInt, kInt, kHex), - MakeEntry(437, "openat2", kInt, kPath, kHex, kInt), - MakeEntry(438, "pidfd_getfd", UnknownArguments()), - MakeEntry(439, "faccessat2", kInt, kPath, kHex, kHex), - MakeEntry(440, "process_madvise", UnknownArguments()), - MakeEntry(441, "epoll_pwait2", UnknownArguments()), - MakeEntry(442, "mount_setattr", UnknownArguments()), + MakeEntry(364, "userfaultfd", kFlags), + MakeEntry(365, "membarrier", kFlags, kInt), + MakeEntry(378, "mlock2", kPtr, kLen0, kFlags), + MakeEntry(379, "copy_file_range", kResource, kPtr, kResource, kPtr, kInt, + kFlags), + MakeEntry(380, "preadv2", kResource, kArray, kLen1, kInt, kInt, kFlags), + MakeEntry(381, "pwritev2", kResource, kArray, kLen1, kInt, kInt, kFlags), + MakeEntry(435, "clone3", kPtr, kLen0), + MakeEntry(436, "close_range", kResource, kResource, kFlags), + MakeEntry(437, "openat2", kResource, kPath, kPtr, kLen2), + MakeEntry(438, "pidfd_getfd", kResource, kResource, kInt), + MakeEntry(439, "faccessat2", kResource, kPath, kFlags, kFlags), + MakeEntry(440, "process_madvise", kResource, kArray, kLen1, kFlags, kInt), + MakeEntry(441, "epoll_pwait2", kResource, kArray, kLen1, kPtr, kPtr, kLen4), + MakeEntry(442, "mount_setattr", kResource, kPath, kFlags, kPtr, kLen3), MakeEntry(443, "quotactl_fd", UnknownArguments()), - MakeEntry(444, "landlock_create_ruleset", UnknownArguments()), - MakeEntry(445, "landlock_add_rule", UnknownArguments()), - MakeEntry(446, "landlock_restrict_self", UnknownArguments()), - MakeEntry(448, "process_mrelease", UnknownArguments()), - MakeEntry(449, "futex_waitv", UnknownArguments()), - MakeEntry(450, "set_mempolicy_home_node", UnknownArguments()), - MakeEntry(451, "cachestat", UnknownArguments()), - MakeEntry(452, "fchmodat2", kInt, kPath, kHex, kHex), - MakeEntry(453, "map_shadow_stack", UnknownArguments()), + MakeEntry(444, "landlock_create_ruleset", kPtr, kLen0, kInt), + MakeEntry(445, "landlock_add_rule", kResource, kInt, kPtr, kInt), + MakeEntry(446, "landlock_restrict_self", kResource, kInt), + MakeEntry(448, "process_mrelease", kResource, kInt), + MakeEntry(449, "futex_waitv", kArray, kLen0, kInt, kPtr, kFlags), + MakeEntry(450, "set_mempolicy_home_node", kPtr, kLen0, kInt, kInt), + MakeEntry(451, "cachestat", kResource, kPtr, kPtr, kInt), + MakeEntry(452, "fchmodat2", kInt, kPath, kInt, kInt), + MakeEntry(453, "map_shadow_stack", kPtr, kLen0, kFlags), MakeEntry(454, "futex_wake", UnknownArguments()), MakeEntry(455, "futex_wait", UnknownArguments()), MakeEntry(456, "futex_requeue", UnknownArguments()), @@ -1314,178 +1403,178 @@ static_assert(IsSorted(kSyscallDataPPC64LE, SyscallTable::Entry::BySyscallNr), // https://github.com/torvalds/linux/blob/v5.8/include/uapi/asm-generic/unistd.h constexpr std::array kSyscallDataArm64 = { // clang-format off - MakeEntry(0, "io_setup", kInt, kHex), - MakeEntry(1, "io_destroy", kInt), - MakeEntry(2, "io_submit", kInt, kInt, kHex), - MakeEntry(3, "io_cancel", kInt, kHex, kHex), - MakeEntry(4, "io_getevents", kInt, kInt, kInt, kHex, kHex), - MakeEntry(5, "setxattr", kPath, kString, kGen, kInt, kHex), - MakeEntry(6, "lsetxattr", kPath, kString, kGen, kInt, kHex), - MakeEntry(7, "fsetxattr", kInt, kString, kGen, kInt, kHex), - MakeEntry(8, "getxattr", kPath, kString, kGen, kInt), - MakeEntry(9, "lgetxattr", kPath, kString, kGen, kInt), - MakeEntry(10, "fgetxattr", kInt, kString, kGen, kInt), - MakeEntry(11, "listxattr", kPath, kGen, kInt), - MakeEntry(12, "llistxattr", kPath, kGen, kInt), - MakeEntry(13, "flistxattr", kInt, kGen, kInt), - MakeEntry(14, "removexattr", kPath, kString), - MakeEntry(15, "lremovexattr", kPath, kString), - MakeEntry(16, "fremovexattr", kInt, kString), - MakeEntry(17, "getcwd", kHex, kInt), - MakeEntry(18, "lookup_dcookie", kInt, kString, kInt), - MakeEntry(19, "eventfd2", kInt, kHex), - MakeEntry(20, "epoll_create1", kHex), - MakeEntry(21, "epoll_ctl", kInt, kInt, kInt, kHex), - MakeEntry(22, "epoll_pwait", kInt, kHex, kInt, kInt, kHex, kInt), - MakeEntry(23, "dup", kInt), - MakeEntry(24, "dup3", kInt, kInt, kHex), - MakeEntry(25, "fcntl", kInt, kInt, kHex), - MakeEntry(26, "inotify_init1", kHex), - MakeEntry(27, "inotify_add_watch", kInt, kPath, kHex), - MakeEntry(28, "inotify_rm_watch", kInt, kInt), - MakeEntry(29, "ioctl", kInt, kInt, kHex), - MakeEntry(30, "ioprio_set", kInt, kInt, kInt), - MakeEntry(31, "ioprio_get", kInt, kInt), - MakeEntry(32, "flock", kInt, kInt), - MakeEntry(33, "mknodat", kInt, kPath, kOct, kHex), - MakeEntry(34, "mkdirat", kInt, kPath, kOct), - MakeEntry(35, "unlinkat", kInt, kPath, kHex), - MakeEntry(36, "symlinkat", kPath, kInt, kPath), - MakeEntry(37, "linkat", kInt, kPath, kInt, kPath, kHex), - MakeEntry(38, "renameat", kInt, kPath, kInt, kPath), - MakeEntry(39, "umount2", kPath, kHex), - MakeEntry(40, "mount", kPath, kPath, kString, kHex, kGen), + MakeEntry(0, "io_setup", kInt, kPtr), + MakeEntry(1, "io_destroy", kStruct), + MakeEntry(2, "io_submit", kStruct, kLen2, kArray), + MakeEntry(3, "io_cancel", kStruct, kPtr, kPtr), + MakeEntry(4, "io_getevents", kStruct, kInt, kLen3, kArray, kPtr), + MakeEntry(5, "setxattr", kPath, kPtr, kString, kLen2, kFlags), + MakeEntry(6, "lsetxattr", kPath, kPtr, kString, kLen2, kFlags), + MakeEntry(7, "fsetxattr", kResource, kPtr, kString, kLen2, kFlags), + MakeEntry(8, "getxattr", kPath, kPtr, kArray, kLen2), + MakeEntry(9, "lgetxattr", kPath, kPtr, kArray, kLen2), + MakeEntry(10, "fgetxattr", kResource, kPtr, kArray, kLen2), + MakeEntry(11, "listxattr", kPath, kArray, kLen1), + MakeEntry(12, "llistxattr", kPath, kArray, kLen1), + MakeEntry(13, "flistxattr", kResource, kArray, kLen1), + MakeEntry(14, "removexattr", kPath, kPtr), + MakeEntry(15, "lremovexattr", kPath, kPtr), + MakeEntry(16, "fremovexattr", kResource, kPtr), + MakeEntry(17, "getcwd", kArray, kLen0), + MakeEntry(18, "lookup_dcookie", kInt, kArray, kLen1), + MakeEntry(19, "eventfd2", kInt, kFlags), + MakeEntry(20, "epoll_create1", kFlags), + MakeEntry(21, "epoll_ctl", kResource, kInt, kResource, kPtr), + MakeEntry(22, "epoll_pwait", kResource, kArray, kLen1, kInt, kPtr, kLen4), + MakeEntry(23, "dup", kResource), + MakeEntry(24, "dup3", kResource, kResource, kFlags), + MakeEntry(25, "fcntl", kResource, kFlags, kResource), + MakeEntry(26, "inotify_init1", kFlags), + MakeEntry(27, "inotify_add_watch", kResource, kPath, kFlags), + MakeEntry(28, "inotify_rm_watch", kResource, kResource), + MakeEntry(29, "ioctl", kResource, kInt, kArray), + MakeEntry(30, "ioprio_set", kFlags, kPid, kFlags), + MakeEntry(31, "ioprio_get", kFlags, kUid), + MakeEntry(32, "flock", kResource, kFlags), + MakeEntry(33, "mknodat", kResource, kPath, kFlags, kInt), + MakeEntry(34, "mkdirat", kResource, kPath, kFlags), + MakeEntry(35, "unlinkat", kResource, kPath, kFlags), + MakeEntry(36, "symlinkat", kPath, kResource, kPath), + MakeEntry(37, "linkat", kResource, kPath, kResource, kPath, kFlags), + MakeEntry(38, "renameat", kResource, kPath, kResource, kPath), + MakeEntry(39, "umount2", kPath, kFlags), + MakeEntry(40, "mount", kPtr, kPath, kString, kFlags, kString), MakeEntry(41, "pivot_root", kPath, kPath), - MakeEntry(42, "nfsservctl", kInt, kGen, kGen), - MakeEntry(43, "statfs", kPath, kHex), - MakeEntry(44, "fstatfs", kInt, kHex), + MakeEntry(42, "nfsservctl", kInt, kPtr, kPtr), + MakeEntry(43, "statfs", kPath, kArray), + MakeEntry(44, "fstatfs", kResource, kArray), MakeEntry(45, "truncate", kPath, kInt), - MakeEntry(46, "ftruncate", kInt, kInt), - MakeEntry(47, "fallocate", kInt, kOct, kInt, kInt), - MakeEntry(48, "faccessat", kInt, kPath, kHex, kHex), + MakeEntry(46, "ftruncate", kResource, kInt), + MakeEntry(47, "fallocate", kResource, kFlags, kInt, kInt), + MakeEntry(48, "faccessat", kResource, kPath, kFlags), MakeEntry(49, "chdir", kPath), - MakeEntry(50, "fchdir", kInt), + MakeEntry(50, "fchdir", kResource), MakeEntry(51, "chroot", kPath), - MakeEntry(52, "fchmod", kInt, kOct), - MakeEntry(53, "fchmodat", kInt, kPath, kOct, kHex), - MakeEntry(54, "fchownat", kInt, kPath, kInt, kInt, kHex), - MakeEntry(55, "fchown", kInt, kInt, kInt), - MakeEntry(56, "openat", kGen, kPath, kOct, kHex, kGen, kGen), - MakeEntry(57, "close", kInt), + MakeEntry(52, "fchmod", kResource, kFlags), + MakeEntry(53, "fchmodat", kResource, kPath, kFlags), + MakeEntry(54, "fchownat", kResource, kPath, kUid, kGid, kFlags), + MakeEntry(55, "fchown", kResource, kUid, kGid), + MakeEntry(56, "openat", kResource, kPath, kFlags, kFlags), + MakeEntry(57, "close", kResource), MakeEntry(58, "vhangup"), - MakeEntry(59, "pipe2", kHex, kHex), + MakeEntry(59, "pipe2", kPtr, kFlags), MakeEntry(60, "quotactl", kInt, kPath, kInt, kGen), - MakeEntry(61, "getdents64", kInt, kHex, kInt), - MakeEntry(62, "lseek", kInt, kInt, kInt), - MakeEntry(63, "read", kInt, kHex, kInt), - MakeEntry(64, "write", kInt, kHex, kInt), - MakeEntry(65, "readv", kInt, kHex, kInt), - MakeEntry(66, "writev", kInt, kHex, kInt), - MakeEntry(67, "pread64", kInt, kHex, kInt, kInt), - MakeEntry(68, "pwrite64", kInt, kHex, kInt, kInt), - MakeEntry(69, "preadv", kInt, kHex, kInt, kInt, kInt), - MakeEntry(70, "pwritev", kInt, kHex, kInt, kInt, kInt), - MakeEntry(71, "sendfile", kInt, kInt, kHex, kInt), - MakeEntry(72, "pselect6", kInt, kHex, kHex, kHex, kHex), - MakeEntry(73, "ppoll", kHex, kInt, kHex, kHex, kInt), - MakeEntry(74, "signalfd4", kInt, kHex, kHex, kHex), - MakeEntry(75, "vmsplice", kInt, kHex, kInt, kInt), - MakeEntry(76, "splice", kInt, kHex, kInt, kHex, kInt, kHex), - MakeEntry(77, "tee", kInt, kInt, kInt, kHex), - MakeEntry(78, "readlinkat", kInt, kPath, kHex, kInt), - MakeEntry(79, "newfstatat", kInt, kPath, kHex, kHex), - MakeEntry(80, "fstat", kInt, kHex), + MakeEntry(61, "getdents64", kResource, kArray, kLen1), + MakeEntry(62, "lseek", kResource, kInt, kFlags), + MakeEntry(63, "read", kResource, kArray, kLen1), + MakeEntry(64, "write", kResource, kArray, kLen1), + MakeEntry(65, "readv", kResource, kArray, kLen1), + MakeEntry(66, "writev", kResource, kArray, kLen1), + MakeEntry(67, "pread64", kResource, kArray, kLen1, kInt), + MakeEntry(68, "pwrite64", kResource, kArray, kLen1, kInt), + MakeEntry(69, "preadv", kResource, kArray, kLen1, kInt, kInt), + MakeEntry(70, "pwritev", kResource, kArray, kLen1, kInt, kInt), + MakeEntry(71, "sendfile", kResource, kResource, kPtr, kInt), + MakeEntry(72, "pselect6", kLen1, kPtr, kPtr, kPtr, kPtr, kPtr), + MakeEntry(73, "ppoll", kPollFdArray, kLen0, kPtr, kPtr, kLen3), + MakeEntry(74, "signalfd4", kResource, kPtr, kLen1, kFlags), + MakeEntry(75, "vmsplice", kResource, kArray, kLen1, kFlags), + MakeEntry(76, "splice", kResource, kPtr, kResource, kPtr, kInt, kFlags), + MakeEntry(77, "tee", kResource, kResource, kInt, kFlags), + MakeEntry(78, "readlinkat", kResource, kPath, kArray, kLen2), + MakeEntry(79, "newfstatat", kInt, kPath, kPtr, kFlags), + MakeEntry(80, "fstat", kResource, kPtr), MakeEntry(81, "sync"), - MakeEntry(82, "fsync", kInt), - MakeEntry(83, "fdatasync", kInt), - MakeEntry(84, "sync_file_range", kInt, kInt, kInt, kHex), - MakeEntry(85, "timerfd_create", kInt, kHex), - MakeEntry(86, "timerfd_settime", kInt, kHex, kHex, kHex), - MakeEntry(87, "timerfd_gettime", kInt, kHex), - MakeEntry(88, "utimensat", kInt, kPath, kHex, kHex), + MakeEntry(82, "fsync", kResource), + MakeEntry(83, "fdatasync", kResource), + MakeEntry(84, "sync_file_range", kResource, kInt, kInt, kFlags), + MakeEntry(85, "timerfd_create", kFlags, kFlags), + MakeEntry(86, "timerfd_settime", kResource, kFlags, kPtr, kPtr), + MakeEntry(87, "timerfd_gettime", kResource, kPtr), + MakeEntry(88, "utimensat", kResource, kPath, kPtr, kFlags), MakeEntry(89, "acct", kPath), - MakeEntry(90, "capget", kHex, kHex), - MakeEntry(91, "capset", kHex, kHex), - MakeEntry(92, "personality", kHex), + MakeEntry(90, "capget", kPtr, kPtr), + MakeEntry(91, "capset", kPtr, kPtr), + MakeEntry(92, "personality", kFlags), MakeEntry(93, "exit", kInt), MakeEntry(94, "exit_group", kInt), - MakeEntry(95, "waitid", kInt, kInt, kHex, kInt, kHex), - MakeEntry(96, "set_tid_address", kHex), - MakeEntry(97, "unshare", kHex), - MakeEntry(98, "futex", kGen, kInt, kInt, kGen, kGen, kInt), - MakeEntry(99, "set_robust_list", kHex, kInt), - MakeEntry(100, "get_robust_list", kInt, kHex, kHex), - MakeEntry(101, "nanosleep", kHex, kHex), - MakeEntry(102, "getitimer", kInt, kHex), - MakeEntry(103, "setitimer", kInt, kHex, kHex), - MakeEntry(104, "kexec_load", kHex, kInt, kHex, kHex), - MakeEntry(105, "init_module", kGen, kInt, kString), - MakeEntry(106, "delete_module", kString, kHex), - MakeEntry(107, "timer_create", kInt, kHex, kHex), - MakeEntry(108, "timer_gettime", kInt, kHex), - MakeEntry(109, "timer_getoverrun", kInt), - MakeEntry(110, "timer_settime", kInt, kHex, kHex, kHex), - MakeEntry(111, "timer_delete", kInt), - MakeEntry(112, "clock_settime", kInt, kHex), - MakeEntry(113, "clock_gettime", kInt, kHex), - MakeEntry(114, "clock_getres", kInt, kHex), - MakeEntry(115, "clock_nanosleep", kInt, kHex, kHex, kHex), - MakeEntry(116, "syslog", kInt, kHex, kInt), - MakeEntry(117, "ptrace", kHex, kHex, kHex, kHex), - MakeEntry(118, "sched_setparam", kInt, kHex), - MakeEntry(119, "sched_setscheduler", kInt, kInt, kHex), - MakeEntry(120, "sched_getscheduler", kInt), - MakeEntry(121, "sched_getparam", kInt, kHex), - MakeEntry(122, "sched_setaffinity", kInt, kInt, kHex), - MakeEntry(123, "sched_getaffinity", kInt, kInt, kHex), + MakeEntry(95, "waitid", kFlags, kPid, kPtr, kFlags, kPtr), + MakeEntry(96, "set_tid_address", kPtr), + MakeEntry(97, "unshare", kFlags), + MakeEntry(98, "futex", kPtr, kFlags, kInt, kPtr, kPtr, kInt), + MakeEntry(99, "set_robust_list", kPtr, kLen0), + MakeEntry(100, "get_robust_list", kPid, kPtr, kPtr), + MakeEntry(101, "nanosleep", kPtr, kPtr), + MakeEntry(102, "getitimer", kFlags, kPtr), + MakeEntry(103, "setitimer", kFlags, kPtr, kPtr), + MakeEntry(104, "kexec_load", kInt, kLen2, kArray, kFlags), + MakeEntry(105, "init_module", kString, kLen0, kString), + MakeEntry(106, "delete_module", kString, kFlags), + MakeEntry(107, "timer_create", kFlags, kPtr, kPtr), + MakeEntry(108, "timer_gettime", kStruct, kPtr), + MakeEntry(109, "timer_getoverrun", kStruct), + MakeEntry(110, "timer_settime", kStruct, kFlags, kPtr, kPtr), + MakeEntry(111, "timer_delete", kStruct), + MakeEntry(112, "clock_settime", kFlags, kPtr), + MakeEntry(113, "clock_gettime", kFlags, kPtr), + MakeEntry(114, "clock_getres", kFlags, kPtr), + MakeEntry(115, "clock_nanosleep", kFlags, kFlags, kPtr, kPtr), + MakeEntry(116, "syslog", kFlags, kArray, kLen1), + MakeEntry(117, "ptrace", kFlags, kPid), + MakeEntry(118, "sched_setparam", kPid, kPtr), + MakeEntry(119, "sched_setscheduler", kPid, kFlags, kPtr), + MakeEntry(120, "sched_getscheduler", kPid), + MakeEntry(121, "sched_getparam", kPid, kPtr), + MakeEntry(122, "sched_setaffinity", kPid, kLen2, kPtr), + MakeEntry(123, "sched_getaffinity", kPid, kLen2, kPtr), MakeEntry(124, "sched_yield"), - MakeEntry(125, "sched_get_priority_max", kHex), - MakeEntry(126, "sched_get_priority_min", kHex), - MakeEntry(127, "sched_rr_get_interval", kInt, kHex), + MakeEntry(125, "sched_get_priority_max", kInt), + MakeEntry(126, "sched_get_priority_min", kInt), + MakeEntry(127, "sched_rr_get_interval", kPid, kPtr), MakeEntry(128, "restart_syscall"), - MakeEntry(129, "kill", kInt, kSignal), - MakeEntry(130, "tkill", kInt, kSignal), - MakeEntry(131, "tgkill", kInt, kInt, kSignal), - MakeEntry(132, "sigaltstack", kHex, kHex), - MakeEntry(133, "rt_sigsuspend", kHex, kInt), - MakeEntry(134, "rt_sigaction", kSignal, kHex, kHex, kInt), - MakeEntry(135, "rt_sigprocmask", kInt, kHex, kHex, kInt), - MakeEntry(136, "rt_sigpending", kHex, kInt), - MakeEntry(137, "rt_sigtimedwait", kHex, kHex, kHex, kInt), - MakeEntry(138, "rt_sigqueueinfo", kInt, kSignal, kHex), + MakeEntry(129, "kill", kPid, kSignal), + MakeEntry(130, "tkill", kPid, kSignal), + MakeEntry(131, "tgkill", kPid, kPid, kSignal), + MakeEntry(132, "sigaltstack", kPtr, kPtr), + MakeEntry(133, "rt_sigsuspend", kPtr, kLen0), + MakeEntry(134, "rt_sigaction", kSignal, kPtr, kPtr, kLen4, kPtr), + MakeEntry(135, "rt_sigprocmask", kFlags, kPtr, kPtr, kLen1), + MakeEntry(136, "rt_sigpending", kPtr, kLen0), + MakeEntry(137, "rt_sigtimedwait", kPtr, kPtr, kPtr, kLen0), + MakeEntry(138, "rt_sigqueueinfo", kPid, kSignal, kPtr), MakeEntry(139, "rt_sigreturn"), - MakeEntry(140, "setpriority", kInt, kInt, kInt), - MakeEntry(141, "getpriority", kInt, kInt), - MakeEntry(142, "reboot", kInt, kHex, kHex, kGen), - MakeEntry(143, "setregid", kInt, kInt), - MakeEntry(144, "setgid", kInt), - MakeEntry(145, "setreuid", kInt, kInt), - MakeEntry(146, "setuid", kInt), - MakeEntry(147, "setresuid", kInt, kInt, kInt), - MakeEntry(148, "getresuid", kHex, kHex, kHex), - MakeEntry(149, "setresgid", kInt, kInt, kInt), - MakeEntry(150, "getresgid", kHex, kHex, kHex), - MakeEntry(151, "setfsuid", kInt), - MakeEntry(152, "setfsgid", kInt), - MakeEntry(153, "times", kHex), - MakeEntry(154, "setpgid", kInt, kInt), - MakeEntry(155, "getpgid", kInt), - MakeEntry(156, "getsid", kInt), + MakeEntry(140, "setpriority", kFlags, kPid, kInt), + MakeEntry(141, "getpriority", kFlags, kPid), + MakeEntry(142, "reboot", kInt, kInt, kInt, kPtr), + MakeEntry(143, "setregid", kGid, kGid), + MakeEntry(144, "setgid", kGid), + MakeEntry(145, "setreuid", kUid, kUid), + MakeEntry(146, "setuid", kUid), + MakeEntry(147, "setresuid", kUid, kUid, kUid), + MakeEntry(148, "getresuid", kPtr, kPtr, kPtr), + MakeEntry(149, "setresgid", kGid, kGid, kGid), + MakeEntry(150, "getresgid", kPtr, kPtr, kPtr), + MakeEntry(151, "setfsuid", kUid), + MakeEntry(152, "setfsgid", kGid), + MakeEntry(153, "times", kPtr), + MakeEntry(154, "setpgid", kPid, kPid), + MakeEntry(155, "getpgid", kPid), + MakeEntry(156, "getsid", kPid), MakeEntry(157, "setsid"), - MakeEntry(158, "getgroups", kInt, kHex), - MakeEntry(159, "setgroups", kInt, kHex), - MakeEntry(160, "uname", kInt), - MakeEntry(161, "sethostname", kString, kInt), - MakeEntry(162, "setdomainname", kString, kInt), - MakeEntry(163, "getrlimit", kInt, kHex), - MakeEntry(164, "setrlimit", kInt, kHex), - MakeEntry(165, "getrusage", kInt, kHex), - MakeEntry(166, "umask", kHex), - MakeEntry(167, "prctl", kInt, kHex, kHex, kHex, kHex), - MakeEntry(168, "getcpu", kHex, kHex, kHex), - MakeEntry(169, "gettimeofday", kHex, kHex), - MakeEntry(170, "settimeofday", kHex, kHex), - MakeEntry(171, "adjtimex", kHex), + MakeEntry(158, "getgroups", kLen1, kGidArray), + MakeEntry(159, "setgroups", kLen1, kGidArray), + MakeEntry(160, "uname", kArray), + MakeEntry(161, "sethostname", kString, kLen0), + MakeEntry(162, "setdomainname", kString, kLen0), + MakeEntry(163, "getrlimit", kFlags, kPtr), + MakeEntry(164, "setrlimit", kFlags, kPtr), + MakeEntry(165, "getrusage", kFlags, kPtr), + MakeEntry(166, "umask", kFlags), + MakeEntry(167, "prctl", kInt, kInt, kInt, kInt, kInt), + MakeEntry(168, "getcpu", kPtr, kPtr), + MakeEntry(169, "gettimeofday", kPtr, kPtr), + MakeEntry(170, "settimeofday", kPtr, kPtr), + MakeEntry(171, "adjtimex", kArray), MakeEntry(172, "getpid"), MakeEntry(173, "getppid"), MakeEntry(174, "getuid"), @@ -1493,117 +1582,123 @@ constexpr std::array kSyscallDataArm64 = { MakeEntry(176, "getgid"), MakeEntry(177, "getegid"), MakeEntry(178, "gettid"), - MakeEntry(179, "sysinfo", kHex), - MakeEntry(180, "mq_open", kString, kHex, kOct, kHex), + MakeEntry(179, "sysinfo", kArray), + MakeEntry(180, "mq_open", kString, kFlags, kFlags, kPtr), MakeEntry(181, "mq_unlink", kString), - MakeEntry(182, "mq_timedsend", kHex, kHex, kInt, kInt, kHex), - MakeEntry(183, "mq_timedreceive", kHex, kHex, kInt, kHex, kHex), - MakeEntry(184, "mq_notify", kHex, kHex), - MakeEntry(185, "mq_getsetattr", kHex, kHex, kHex), - MakeEntry(186, "msgget", kInt, kHex), - MakeEntry(187, "msgctl", kInt, kInt, kHex), - MakeEntry(188, "msgrcv", kInt, kHex, kInt, kInt, kHex), - MakeEntry(189, "msgsnd", kInt, kHex, kInt, kHex), - MakeEntry(190, "semget", kInt, kInt, kHex), - MakeEntry(191, "semctl", kInt, kInt, kInt, kHex), - MakeEntry(192, "semtimedop", kInt, kHex, kInt, kHex), - MakeEntry(193, "semop", kInt, kHex, kInt), - MakeEntry(194, "shmget", kInt, kInt, kHex), - MakeEntry(195, "shmctl", kInt, kInt, kHex), - MakeEntry(196, "shmat", kInt, kHex, kHex), - MakeEntry(197, "shmdt", kHex), - MakeEntry(198, "socket", kAddressFamily, kInt, kInt), - MakeEntry(199, "socketpair", kAddressFamily, kInt, kInt, kHex), - MakeEntry(200, "bind", kInt, kSockaddr, kInt), - MakeEntry(201, "listen", kInt, kInt), - MakeEntry(202, "accept", kInt, kSockaddr, kHex), - MakeEntry(203, "connect", kInt, kSockaddr, kInt), - MakeEntry(204, "getsockname", kInt, kSockaddr, kHex), - MakeEntry(205, "getpeername", kInt, kSockaddr, kHex), - MakeEntry(206, "sendto", kInt, kGen, kInt, kHex, kSockaddr, kInt), - MakeEntry(207, "recvfrom", kInt, kHex, kInt, kHex, kSockaddr, kHex), - MakeEntry(208, "setsockopt", kInt, kInt, kInt, kHex, kHex), - MakeEntry(209, "getsockopt", kInt, kInt, kInt, kHex, kInt), - MakeEntry(210, "shutdown", kInt, kInt), - MakeEntry(211, "sendmsg", kInt, kSockmsghdr, kHex), - MakeEntry(212, "recvmsg", kInt, kHex, kInt), - MakeEntry(213, "readahead", kInt, kInt, kInt), + MakeEntry(182, "mq_timedsend", kResource, kArray, kLen1, kInt, kPtr), + MakeEntry(183, "mq_timedreceive", kResource, kArray, kLen1, kInt, kPtr), + MakeEntry(184, "mq_notify", kResource, kPtr), + MakeEntry(185, "mq_getsetattr", kResource, kPtr, kPtr), + MakeEntry(186, "msgget", kIpcResource, kFlags), + MakeEntry(187, "msgctl", kIpcResource, kInt, kArray), + MakeEntry(188, "msgrcv", kIpcResource, kPtr, kLen1, kFlags, kFlags), + MakeEntry(189, "msgsnd", kIpcResource, kPtr, kLen1, kFlags), + MakeEntry(190, "semget", kIpcResource, kFlags, kFlags), + MakeEntry(191, "semctl", kIpcResource, kFlags, kInt, kArray), + MakeEntry(192, "semtimedop", kIpcResource, kArray, kLen1, kPtr), + MakeEntry(193, "semop", kIpcResource, kArray, kLen1), + MakeEntry(194, "shmget", kInt, kLen3, kFlags, kPtr), + MakeEntry(195, "shmctl", kIpcResource, kInt, kArray), + MakeEntry(196, "shmat", kIpcResource, kPtr, kFlags), + MakeEntry(197, "shmdt", kSharedAddress), + MakeEntry(198, "socket", kFlags, kFlags, kInt), + MakeEntry(199, "socketpair", kFlags, kFlags, kInt, kPtr), + MakeEntry(200, "bind", kResource, kSockaddr, kLen1), + MakeEntry(201, "listen", kResource, kInt), + MakeEntry(202, "accept", kResource, kPtr, kPtr), + MakeEntry(203, "connect", kResource, kSockaddr, kLen1), + MakeEntry(204, "getsockname", kResource, kPtr, kPtr), + MakeEntry(205, "getpeername", kResource, kPtr, kPtr), + MakeEntry(206, "sendto", kResource, kArray, kLen1, kFlags, kSockaddr, + kLen4), + MakeEntry(207, "recvfrom", kResource, kArray, kLen1, kFlags, kSockaddr, + kLen4), + MakeEntry(208, "setsockopt", kResource, kInt, kInt, kArray, kLen3), + MakeEntry(209, "getsockopt", kResource, kInt, kInt, kArray, kPtr), + MakeEntry(210, "shutdown", kResource, kFlags), + MakeEntry(211, "sendmsg", kResource, kPtr, kFlags), + MakeEntry(212, "recvmsg", kResource, kPtr, kFlags), + MakeEntry(213, "readahead", kResource, kInt, kInt), MakeEntry(214, "brk", kInt), - MakeEntry(215, "munmap", kHex, kInt), - MakeEntry(216, "mremap", kHex, kInt, kInt, kInt, kHex), - MakeEntry(217, "add_key", kString, kString, kGen, kInt, kInt), - MakeEntry(218, "request_key", kString, kString, kHex, kInt), + MakeEntry(215, "munmap", kPtr, kLen0), + MakeEntry(216, "mremap", kPtr, kLen0, kLen4, kFlags, kPtr), + MakeEntry(217, "add_key", kString, kPtr, kArray, kLen2, kStruct), + MakeEntry(218, "request_key", kString, kPtr, kString, kStruct), MakeEntry(219, "keyctl", kInt, kInt, kInt, kInt, kInt), - MakeEntry(220, "clone", kCloneFlag, kHex, kHex, kHex, kHex), - MakeEntry(221, "execve", kPath, kHex, kHex), - MakeEntry(222, "mmap", kHex, kInt, kHex, kHex, kInt, kInt), - MakeEntry(223, "fadvise64", kInt, kInt, kInt, kInt), - MakeEntry(224, "swapon", kPath, kHex), + MakeEntry(220, "clone", kFlags, kArray, kPtr, kPtr, kArray), + MakeEntry(221, "execve", kPath, kArray, kArray), + MakeEntry(222, "mmap", kPtr, kLen0, kFlags, kFlags, kResource, kInt), + MakeEntry(223, "fadvise64", kResource, kInt, kInt, kFlags), + MakeEntry(224, "swapon", kPath, kFlags), MakeEntry(225, "swapoff", kPath), - MakeEntry(226, "mprotect", kHex, kInt, kHex), - MakeEntry(227, "msync", kHex, kInt, kInt), - MakeEntry(228, "mlock", kInt, kInt), - MakeEntry(229, "munlock", kInt, kInt), - MakeEntry(230, "mlockall", kHex), + MakeEntry(226, "mprotect", kPtr, kLen0, kFlags), + MakeEntry(227, "msync", kPtr, kLen0, kFlags), + MakeEntry(228, "mlock", kPtr, kLen0), + MakeEntry(229, "munlock", kPtr, kLen0), + MakeEntry(230, "mlockall", kFlags), MakeEntry(231, "munlockall"), - MakeEntry(232, "mincore", kHex, kInt, kHex), - MakeEntry(233, "madvise", kHex, kInt, kInt), - MakeEntry(234, "remap_file_pages", kGen, kInt, kInt, kInt, kHex), - MakeEntry(235, "mbind", kGen, kInt, kInt, kHex, kInt, kHex), - MakeEntry(236, "get_mempolicy", kInt, kHex, kInt, kInt, kHex), - MakeEntry(237, "set_mempolicy", kInt, kHex, kInt), - MakeEntry(238, "migrate_pages", kInt, kInt, kHex, kHex), - MakeEntry(239, "move_pages", kInt, kInt, kHex, kHex, kHex, kHex), - MakeEntry(240, "rt_tgsigqueueinfo", kInt, kInt, kInt, kHex), - MakeEntry(241, "perf_event_open", kHex, kInt, kInt, kInt, kHex), - MakeEntry(242, "accept4", kInt, kHex, kHex, kInt), - MakeEntry(243, "recvmmsg", kInt, kHex, kInt, kHex, kHex), - MakeEntry(260, "wait4", kInt, kHex, kHex, kHex), - MakeEntry(261, "prlimit64", kInt, kInt, kHex, kHex), - MakeEntry(262, "fanotify_init", kHex, kHex), - MakeEntry(263, "fanotify_mark", kInt, kHex, kHex, kInt, kPath), - MakeEntry(264, "name_to_handle_at", kInt, kPath, kHex, kHex, kHex), - MakeEntry(265, "open_by_handle_at", kInt, kHex, kHex), - MakeEntry(266, "clock_adjtime", kInt, kHex), - MakeEntry(267, "syncfs", kInt), - MakeEntry(268, "setns", kInt, kHex), - MakeEntry(269, "sendmmsg", kInt, kHex, kInt, kHex), - MakeEntry(270, "process_vm_readv", kInt, kHex, kInt, kHex, kInt, kInt), - MakeEntry(271, "process_vm_writev", kInt, kHex, kInt, kHex, kInt, kInt), - MakeEntry(272, "kcmp", kInt, kInt, kInt, kInt, kInt), - MakeEntry(273, "finit_module", kInt, kString, kHex), - MakeEntry(274, "sched_setattr", kInt, kHex, kHex), - MakeEntry(275, "sched_getattr", kInt, kHex, kInt, kHex), - MakeEntry(276, "renameat2", kGen, kPath, kGen, kPath, kGen, kGen), - MakeEntry(277, "seccomp", kInt, kHex, kHex), - MakeEntry(278, "getrandom", kGen, kInt, kHex), - MakeEntry(279, "memfd_create", kString, kHex), - MakeEntry(280, "bpf", kInt, kHex, kInt), - MakeEntry(281, "execveat", kInt, kPath, kHex, kHex, kHex), - MakeEntry(282, "userfaultfd", kHex), - MakeEntry(283, "membarrier", kInt, kHex), - MakeEntry(284, "mlock2", kHex, kInt, kHex), - MakeEntry(285, "copy_file_range", kInt, kHex, kInt, kHex, kInt, kHex), - MakeEntry(286, "preadv2", kInt, kHex, kInt, kInt, kInt, kHex), - MakeEntry(287, "pwritev2", kInt, kHex, kInt, kInt, kInt, kHex), - MakeEntry(435, "clone3", kHex, kInt), - MakeEntry(436, "close_range", kInt, kInt, kHex), - MakeEntry(437, "openat2", kInt, kPath, kHex, kInt), - MakeEntry(438, "pidfd_getfd", UnknownArguments()), - MakeEntry(439, "faccessat2", kInt, kPath, kHex, kHex), - MakeEntry(440, "process_madvise", UnknownArguments()), - MakeEntry(441, "epoll_pwait2", UnknownArguments()), - MakeEntry(442, "mount_setattr", UnknownArguments()), + MakeEntry(232, "mincore", kPtr, kLen0, kArray), + MakeEntry(233, "madvise", kPtr, kLen0, kFlags), + MakeEntry(234, "remap_file_pages", kPtr, kLen0, kFlags, kInt, kFlags), + MakeEntry(235, "mbind", kPtr, kLen0, kFlags, kPtr, kInt, kFlags), + MakeEntry(236, "get_mempolicy", kPtr, kPtr, kInt, kPtr, kFlags), + MakeEntry(237, "set_mempolicy", kFlags, kPtr, kInt), + MakeEntry(238, "migrate_pages", kPid, kInt, kPtr, kPtr), + MakeEntry(239, "move_pages", kPid, kLen2, kArray, kArray, kArray, kFlags), + MakeEntry(240, "rt_tgsigqueueinfo", kPid, kPid, kSignal, kPtr), + MakeEntry(241, "perf_event_open", kPtr, kPid, kInt, kResource, kFlags), + MakeEntry(242, "accept4", kResource, kPtr, kPtr, kFlags), + MakeEntry(243, "recvmmsg", kResource, kArray, kLen1, kFlags, kPtr), + MakeEntry(260, "wait4", kPid, kPtr, kFlags, kPtr), + MakeEntry(261, "prlimit64", kPid, kFlags, kPtr, kPtr), + MakeEntry(262, "fanotify_init", kFlags, kFlags), + MakeEntry(263, "fanotify_mark", kResource, kFlags, kFlags, kResource, + kPath), + MakeEntry(264, "name_to_handle_at", kResource, kPath, kPtr, kPtr, kFlags), + MakeEntry(265, "open_by_handle_at", kResource, kPtr, kFlags), + MakeEntry(266, "clock_adjtime", kFlags, kPtr), + MakeEntry(267, "syncfs", kResource), + MakeEntry(268, "setns", kResource, kFlags), + MakeEntry(269, "sendmmsg", kResource, kArray, kLen1, kFlags), + MakeEntry(270, "process_vm_readv", kPid, kArray, kLen1, kArray, kLen3, + kInt), + MakeEntry(271, "process_vm_writev", kPid, kArray, kLen1, kArray, kLen3, + kInt), + MakeEntry(272, "kcmp", kPid, kPid, kFlags, kResource, kResource), + MakeEntry(273, "finit_module", kResource, kString, kFlags), + MakeEntry(274, "sched_setattr", kPid, kPtr, kInt), + MakeEntry(275, "sched_getattr", kPid, kPtr, kLen1, kInt), + MakeEntry(276, "renameat2", kResource, kPath, kResource, kPath, kFlags), + MakeEntry(277, "seccomp", kInt, kFlags, kPtr), + MakeEntry(278, "getrandom", kArray, kLen0, kFlags), + MakeEntry(279, "memfd_create", kString, kFlags), + MakeEntry(280, "bpf", kInt, kPtr, kLen1), + MakeEntry(281, "execveat", kResource, kPath, kArray, kArray, kFlags), + MakeEntry(282, "userfaultfd", kFlags), + MakeEntry(283, "membarrier", kFlags, kInt), + MakeEntry(284, "mlock2", kPtr, kLen0, kFlags), + MakeEntry(285, "copy_file_range", kResource, kPtr, kResource, kPtr, kInt, + kFlags), + MakeEntry(286, "preadv2", kResource, kArray, kLen1, kInt, kInt, kFlags), + MakeEntry(287, "pwritev2", kResource, kArray, kLen1, kInt, kInt, kFlags), + MakeEntry(435, "clone3", kPtr, kLen0), + MakeEntry(436, "close_range", kResource, kResource, kFlags), + MakeEntry(437, "openat2", kResource, kPath, kPtr, kLen2), + MakeEntry(438, "pidfd_getfd", kResource, kResource, kInt), + MakeEntry(439, "faccessat2", kResource, kPath, kFlags, kFlags), + MakeEntry(440, "process_madvise", kResource, kArray, kLen1, kFlags, kInt), + MakeEntry(441, "epoll_pwait2", kResource, kArray, kLen1, kPtr, kPtr, kLen4), + MakeEntry(442, "mount_setattr", kResource, kPath, kFlags, kPtr, kLen3), MakeEntry(443, "quotactl_fd", UnknownArguments()), - MakeEntry(444, "landlock_create_ruleset", UnknownArguments()), - MakeEntry(445, "landlock_add_rule", UnknownArguments()), - MakeEntry(446, "landlock_restrict_self", UnknownArguments()), - MakeEntry(448, "process_mrelease", UnknownArguments()), - MakeEntry(449, "futex_waitv", UnknownArguments()), - MakeEntry(450, "set_mempolicy_home_node", UnknownArguments()), - MakeEntry(451, "cachestat", UnknownArguments()), - MakeEntry(452, "fchmodat2", kInt, kPath, kHex, kHex), - MakeEntry(453, "map_shadow_stack", UnknownArguments()), + MakeEntry(444, "landlock_create_ruleset", kPtr, kLen0, kInt), + MakeEntry(445, "landlock_add_rule", kResource, kInt, kPtr, kInt), + MakeEntry(446, "landlock_restrict_self", kResource, kInt), + MakeEntry(448, "process_mrelease", kResource, kInt), + MakeEntry(449, "futex_waitv", kArray, kLen0, kInt, kPtr, kFlags), + MakeEntry(450, "set_mempolicy_home_node", kPtr, kLen0, kInt, kInt), + MakeEntry(451, "cachestat", kResource, kPtr, kPtr, kInt), + MakeEntry(452, "fchmodat2", kInt, kPath, kInt, kInt), + MakeEntry(453, "map_shadow_stack", kPtr, kLen0, kFlags), MakeEntry(454, "futex_wake", UnknownArguments()), MakeEntry(455, "futex_wait", UnknownArguments()), MakeEntry(456, "futex_requeue", UnknownArguments()), @@ -1621,372 +1716,378 @@ static_assert(IsSorted(kSyscallDataArm64, SyscallTable::Entry::BySyscallNr), constexpr std::array kSyscallDataArm32 = { // clang-format off MakeEntry(0, "restart_syscall"), - MakeEntry(1, "exit", kHex, kHex, kHex, kHex), + MakeEntry(1, "exit", kInt), MakeEntry(2, "fork"), - MakeEntry(3, "read", kInt, kHex, kInt), - MakeEntry(4, "write", kHex, kHex, kHex, kHex), - MakeEntry(5, "open", kPath, kHex, kOct), - MakeEntry(6, "close", kHex, kHex, kHex, kHex), - MakeEntry(8, "creat", kPath, kHex, kHex, kHex), + MakeEntry(3, "read", kResource, kArray, kLen1), + MakeEntry(4, "write", kResource, kArray, kLen1), + MakeEntry(5, "open", kPath, kFlags, kFlags), + MakeEntry(6, "close", kResource), + MakeEntry(8, "creat", kPath, kFlags), MakeEntry(9, "link", kPath, kPath), MakeEntry(10, "unlink", kPath), - MakeEntry(11, "execve", kPath, kHex, kHex), + MakeEntry(11, "execve", kPath, kArray, kArray), MakeEntry(12, "chdir", kPath), - MakeEntry(14, "mknod", kPath, kOct, kHex), - MakeEntry(15, "chmod", kPath, kOct), - MakeEntry(16, "lchown", kPath, kInt, kInt), - MakeEntry(19, "lseek", kInt, kInt, kInt), + MakeEntry(14, "mknod", kPath, kFlags, kInt), + MakeEntry(15, "chmod", kPath, kFlags), + MakeEntry(16, "lchown", kPath, kUid, kGid), + MakeEntry(19, "lseek", kResource, kInt, kFlags), MakeEntry(20, "getpid"), - MakeEntry(21, "mount", kPath, kPath, kString, kHex, kGen), - MakeEntry(23, "setuid", kInt), + MakeEntry(21, "mount", kPtr, kPath, kString, kFlags, kString), + MakeEntry(23, "setuid", kUid), MakeEntry(24, "getuid"), - MakeEntry(26, "ptrace", kHex, kHex, kHex, kHex), + MakeEntry(26, "ptrace", kFlags, kPid), MakeEntry(29, "pause"), - MakeEntry(33, "access", kPath, kHex), - MakeEntry(34, "nice", kHex, kHex, kHex, kHex), + MakeEntry(33, "access", kPath, kInt), + MakeEntry(34, "nice", kInt, kInt, kInt, kInt), MakeEntry(36, "sync"), - MakeEntry(37, "kill", kHex, kHex, kHex, kHex), + MakeEntry(37, "kill", kPid, kSignal), MakeEntry(38, "rename", kPath, kPath), - MakeEntry(39, "mkdir", kPath, kHex, kHex, kHex), - MakeEntry(40, "rmdir", kHex, kHex, kHex, kHex), - MakeEntry(41, "dup", kInt), - MakeEntry(42, "pipe", kHex), - MakeEntry(43, "times", kHex), - MakeEntry(45, "brk", kHex), - MakeEntry(46, "setgid", kInt), + MakeEntry(39, "mkdir", kPath, kFlags), + MakeEntry(40, "rmdir", kPath), + MakeEntry(41, "dup", kResource), + MakeEntry(42, "pipe", kPtr), + MakeEntry(43, "times", kPtr), + MakeEntry(45, "brk", kInt), + MakeEntry(46, "setgid", kGid), MakeEntry(47, "getgid"), MakeEntry(49, "geteuid"), MakeEntry(50, "getegid"), - MakeEntry(51, "acct", kHex, kHex, kHex, kHex), - MakeEntry(52, "umount2", kHex, kHex, kHex, kHex), - MakeEntry(54, "ioctl", kInt, kInt, kHex), - MakeEntry(55, "fcntl", kInt, kInt, kHex), - MakeEntry(57, "setpgid", kInt, kInt), - MakeEntry(60, "umask", kHex), - MakeEntry(61, "chroot", kHex, kHex, kHex, kHex), - MakeEntry(62, "ustat", kHex, kHex), - MakeEntry(63, "dup2", kGen, kGen), + MakeEntry(51, "acct", kPath), + MakeEntry(52, "umount2", kPath, kFlags), + MakeEntry(54, "ioctl", kResource, kInt, kArray), + MakeEntry(55, "fcntl", kResource, kFlags, kResource), + MakeEntry(57, "setpgid", kPid, kPid), + MakeEntry(60, "umask", kFlags), + MakeEntry(61, "chroot", kPath), + MakeEntry(62, "ustat", kInt, kPtr), + MakeEntry(63, "dup2", kResource, kResource), MakeEntry(64, "getppid"), - MakeEntry(65, "getpgrp"), + MakeEntry(65, "getpgrp", kPid), MakeEntry(66, "setsid"), - MakeEntry(67, "sigaction", kHex, kHex, kHex, kHex), - MakeEntry(70, "setreuid", kInt, kInt), - MakeEntry(71, "setregid", kInt, kInt), - MakeEntry(72, "sigsuspend", kHex, kHex, kHex, kHex), - MakeEntry(73, "sigpending", kHex, kHex, kHex, kHex), - MakeEntry(74, "sethostname", kString, kInt), - MakeEntry(75, "setrlimit", kInt, kHex), - MakeEntry(77, "getrusage", kInt, kHex), - MakeEntry(78, "gettimeofday", kHex, kHex), - MakeEntry(79, "settimeofday", kHex, kHex), - MakeEntry(80, "getgroups", kInt, kHex), - MakeEntry(81, "setgroups", kInt, kHex), + MakeEntry(67, "sigaction", kInt, kInt, kInt, kInt), + MakeEntry(70, "setreuid", kUid, kUid), + MakeEntry(71, "setregid", kGid, kGid), + MakeEntry(72, "sigsuspend", kInt, kInt, kInt, kInt), + MakeEntry(73, "sigpending", kInt, kInt, kInt, kInt), + MakeEntry(74, "sethostname", kString, kLen0), + MakeEntry(75, "setrlimit", kFlags, kPtr), + MakeEntry(77, "getrusage", kFlags, kPtr), + MakeEntry(78, "gettimeofday", kPtr, kPtr), + MakeEntry(79, "settimeofday", kPtr, kPtr), + MakeEntry(80, "getgroups", kLen1, kGidArray), + MakeEntry(81, "setgroups", kLen1, kGidArray), MakeEntry(83, "symlink", kPath, kPath), - MakeEntry(85, "readlink", kPath, kGen, kInt), + MakeEntry(85, "readlink", kPath, kArray, kLen1), MakeEntry(86, "uselib", kPath), - MakeEntry(87, "swapon", kHex, kHex, kHex, kHex), - MakeEntry(88, "reboot", kGen, kGen, kGen, kGen), - MakeEntry(91, "munmap", kHex, kHex), - MakeEntry(92, "truncate", kPath, kHex, kHex, kHex), - MakeEntry(93, "ftruncate", kInt, kInt), - MakeEntry(94, "fchmod", kInt, kOct), - MakeEntry(95, "fchown", kInt, kInt, kInt), - MakeEntry(96, "getpriority", kInt, kInt), - MakeEntry(97, "setpriority", kInt, kInt, kInt), - MakeEntry(99, "statfs", kPath, kHex), - MakeEntry(100, "fstatfs", kInt, kHex), - MakeEntry(103, "syslog", kInt, kHex, kInt), - MakeEntry(104, "setitimer", kInt, kHex, kHex), - MakeEntry(105, "getitimer", kInt, kHex), - MakeEntry(106, "stat", kPath, kGen), - MakeEntry(107, "lstat", kPath, kGen), - MakeEntry(108, "fstat", kHex, kHex, kHex, kHex), + MakeEntry(87, "swapon", kPath, kFlags), + MakeEntry(88, "reboot", kInt, kInt, kInt, kPtr), + MakeEntry(91, "munmap", kPtr, kLen0), + MakeEntry(92, "truncate", kPath, kInt), + MakeEntry(93, "ftruncate", kResource, kInt), + MakeEntry(94, "fchmod", kResource, kFlags), + MakeEntry(95, "fchown", kResource, kUid, kGid), + MakeEntry(96, "getpriority", kFlags, kPid), + MakeEntry(97, "setpriority", kFlags, kPid, kInt), + MakeEntry(99, "statfs", kPath, kArray), + MakeEntry(100, "fstatfs", kResource, kArray), + MakeEntry(103, "syslog", kFlags, kArray, kLen1), + MakeEntry(104, "setitimer", kFlags, kPtr, kPtr), + MakeEntry(105, "getitimer", kFlags, kPtr), + MakeEntry(106, "stat", kPath, kPtr), + MakeEntry(107, "lstat", kPath, kPtr), + MakeEntry(108, "fstat", kResource, kPtr), MakeEntry(111, "vhangup"), - MakeEntry(114, "wait4", kHex, kHex, kHex, kHex), - MakeEntry(115, "swapoff", kHex, kHex, kHex, kHex), - MakeEntry(116, "sysinfo", kHex), - MakeEntry(118, "fsync", kInt), - MakeEntry(119, "sigreturn", kHex, kHex, kHex, kHex), - MakeEntry(120, "clone", kCloneFlag, kHex, kHex, kHex, kHex), - MakeEntry(121, "setdomainname", kString, kInt), - MakeEntry(122, "uname", kInt), - MakeEntry(124, "adjtimex", kHex), - MakeEntry(125, "mprotect", kHex, kHex, kHex), - MakeEntry(126, "sigprocmask", kHex, kHex, kHex, kHex), - MakeEntry(128, "init_module", kGen, kInt, kString), - MakeEntry(129, "delete_module", kString, kHex), - MakeEntry(131, "quotactl", kHex, kHex, kHex, kHex), - MakeEntry(132, "getpgid", kInt), - MakeEntry(133, "fchdir", kInt), - MakeEntry(134, "bdflush", kHex, kHex, kHex, kHex), - MakeEntry(135, "sysfs", kInt, kInt, kInt), - MakeEntry(136, "personality", kHex), - MakeEntry(138, "setfsuid", kInt), - MakeEntry(139, "setfsgid", kInt), - MakeEntry(140, "_llseek", kHex, kHex, kHex, kHex), - MakeEntry(141, "getdents", kInt, kHex, kInt), - MakeEntry(142, "_newselect", kHex, kHex, kHex, kHex), - MakeEntry(143, "flock", kInt, kInt), - MakeEntry(144, "msync", kHex, kInt, kInt), - MakeEntry(145, "readv", kInt, kHex, kInt), - MakeEntry(146, "writev", kInt, kHex, kInt), - MakeEntry(147, "getsid", kInt), - MakeEntry(148, "fdatasync", kInt), - MakeEntry(149, "_sysctl", kHex), - MakeEntry(150, "mlock", kInt, kInt), - MakeEntry(151, "munlock", kInt, kInt), - MakeEntry(152, "mlockall", kHex), + MakeEntry(114, "wait4", kPid, kPtr, kFlags, kPtr), + MakeEntry(115, "swapoff", kPath), + MakeEntry(116, "sysinfo", kArray), + MakeEntry(118, "fsync", kResource), + MakeEntry(119, "sigreturn", kInt, kInt, kInt, kInt), + MakeEntry(120, "clone", kFlags, kArray, kPtr, kPtr, kArray), + MakeEntry(121, "setdomainname", kString, kLen0), + MakeEntry(122, "uname", kArray), + MakeEntry(124, "adjtimex", kArray), + MakeEntry(125, "mprotect", kPtr, kLen0, kFlags), + MakeEntry(126, "sigprocmask", kInt, kInt, kInt, kInt), + MakeEntry(128, "init_module", kString, kLen0, kString), + MakeEntry(129, "delete_module", kString, kFlags), + MakeEntry(131, "quotactl", kInt, kInt, kInt, kInt), + MakeEntry(132, "getpgid", kPid), + MakeEntry(133, "fchdir", kResource), + MakeEntry(134, "bdflush", kInt, kInt, kInt, kInt), + MakeEntry(135, "sysfs", kInt, kString), + MakeEntry(136, "personality", kFlags), + MakeEntry(138, "setfsuid", kUid), + MakeEntry(139, "setfsgid", kGid), + MakeEntry(140, "_llseek", kInt, kInt, kInt, kInt), + MakeEntry(141, "getdents", kResource, kArray, kLen1), + MakeEntry(142, "_newselect", kInt, kInt, kInt, kInt), + MakeEntry(143, "flock", kResource, kFlags), + MakeEntry(144, "msync", kPtr, kLen0, kFlags), + MakeEntry(145, "readv", kResource, kArray, kLen1), + MakeEntry(146, "writev", kResource, kArray, kLen1), + MakeEntry(147, "getsid", kPid), + MakeEntry(148, "fdatasync", kResource), + MakeEntry(149, "_sysctl", kPtr), + MakeEntry(150, "mlock", kPtr, kLen0), + MakeEntry(151, "munlock", kPtr, kLen0), + MakeEntry(152, "mlockall", kFlags), MakeEntry(153, "munlockall"), - MakeEntry(154, "sched_setparam", kInt, kHex), - MakeEntry(155, "sched_getparam", kInt, kHex), - MakeEntry(156, "sched_setscheduler", kInt, kInt, kHex), - MakeEntry(157, "sched_getscheduler", kInt), + MakeEntry(154, "sched_setparam", kPid, kPtr), + MakeEntry(155, "sched_getparam", kPid, kPtr), + MakeEntry(156, "sched_setscheduler", kPid, kFlags, kPtr), + MakeEntry(157, "sched_getscheduler", kPid), MakeEntry(158, "sched_yield"), - MakeEntry(159, "sched_get_priority_max", kHex), - MakeEntry(160, "sched_get_priority_min", kHex), - MakeEntry(161, "sched_rr_get_interval", kInt, kHex), - MakeEntry(162, "nanosleep", kHex, kHex), - MakeEntry(163, "mremap", kHex, kInt, kInt, kInt, kHex), - MakeEntry(164, "setresuid", kInt, kInt, kInt), - MakeEntry(165, "getresuid", kHex, kHex, kHex), - MakeEntry(168, "poll", kGen, kInt, kInt), - MakeEntry(169, "nfsservctl", kInt, kGen, kGen), - MakeEntry(170, "setresgid", kInt, kInt, kInt), - MakeEntry(171, "getresgid", kHex, kHex, kHex), - MakeEntry(172, "prctl", kInt, kHex, kHex, kHex, kHex), + MakeEntry(159, "sched_get_priority_max", kInt), + MakeEntry(160, "sched_get_priority_min", kInt), + MakeEntry(161, "sched_rr_get_interval", kPid, kPtr), + MakeEntry(162, "nanosleep", kPtr, kPtr), + MakeEntry(163, "mremap", kPtr, kLen0, kLen4, kFlags, kPtr), + MakeEntry(164, "setresuid", kUid, kUid, kUid), + MakeEntry(165, "getresuid", kPtr, kPtr, kPtr), + MakeEntry(168, "poll", kPollFdArray, kLen0, kInt), + MakeEntry(169, "nfsservctl", kInt, kPtr, kPtr), + MakeEntry(170, "setresgid", kGid, kGid, kGid), + MakeEntry(171, "getresgid", kPtr, kPtr, kPtr), + MakeEntry(172, "prctl", kInt, kInt, kInt, kInt, kInt), MakeEntry(173, "rt_sigreturn"), - MakeEntry(174, "rt_sigaction", kHex, kHex, kHex, kHex), - MakeEntry(175, "rt_sigprocmask", kGen, kGen, kGen, kGen), - MakeEntry(176, "rt_sigpending", kHex, kInt), - MakeEntry(177, "rt_sigtimedwait", kGen, kGen, kGen, kGen), - MakeEntry(178, "rt_sigqueueinfo", kInt, kSignal, kHex), - MakeEntry(179, "rt_sigsuspend", kHex, kInt), - MakeEntry(180, "pread64", kGen, kGen, kGen, kGen), - MakeEntry(181, "pwrite64", kGen, kGen, kGen, kGen), - MakeEntry(182, "chown", kHex, kHex, kHex, kHex), - MakeEntry(183, "getcwd", kHex, kInt), - MakeEntry(184, "capget", kHex, kHex), - MakeEntry(185, "capset", kHex, kHex), - MakeEntry(186, "sigaltstack", kHex, kHex), - MakeEntry(187, "sendfile", kGen, kGen, kGen, kGen), + MakeEntry(174, "rt_sigaction", kSignal, kPtr, kPtr, kLen4, kPtr), + MakeEntry(175, "rt_sigprocmask", kFlags, kPtr, kPtr, kLen1), + MakeEntry(176, "rt_sigpending", kPtr, kLen0), + MakeEntry(177, "rt_sigtimedwait", kPtr, kPtr, kPtr, kLen0), + MakeEntry(178, "rt_sigqueueinfo", kPid, kSignal, kPtr), + MakeEntry(179, "rt_sigsuspend", kPtr, kLen0), + MakeEntry(180, "pread64", kResource, kArray, kLen1, kInt), + MakeEntry(181, "pwrite64", kResource, kArray, kLen1, kInt), + MakeEntry(182, "chown", kPath, kUid, kGid), + MakeEntry(183, "getcwd", kArray, kLen0), + MakeEntry(184, "capget", kPtr, kPtr), + MakeEntry(185, "capset", kPtr, kPtr), + MakeEntry(186, "sigaltstack", kPtr, kPtr), + MakeEntry(187, "sendfile", kResource, kResource, kPtr, kInt), MakeEntry(190, "vfork"), - MakeEntry(191, "ugetrlimit", kHex, kHex, kHex, kHex), - MakeEntry(192, "mmap2", kHex, kHex, kHex, kHex), - MakeEntry(193, "truncate64", kHex, kHex, kHex, kHex), - MakeEntry(194, "ftruncate64", kHex, kHex, kHex, kHex), - MakeEntry(195, "stat64", kHex, kHex, kHex, kHex), - MakeEntry(196, "lstat64", kHex, kHex, kHex, kHex), - MakeEntry(197, "fstat64", kHex, kHex, kHex, kHex), - MakeEntry(198, "lchown32", kHex, kHex, kHex, kHex), - MakeEntry(199, "getuid32", kHex, kHex, kHex, kHex), - MakeEntry(200, "getgid32", kHex, kHex, kHex, kHex), - MakeEntry(201, "geteuid32", kHex, kHex, kHex, kHex), - MakeEntry(202, "getegid32", kHex, kHex, kHex, kHex), - MakeEntry(203, "setreuid32", kHex, kHex, kHex, kHex), - MakeEntry(204, "setregid32", kHex, kHex, kHex, kHex), - MakeEntry(205, "getgroups32", kHex, kHex, kHex, kHex), - MakeEntry(206, "setgroups32", kHex, kHex, kHex, kHex), - MakeEntry(207, "fchown32", kHex, kHex, kHex, kHex), - MakeEntry(208, "setresuid32", kHex, kHex, kHex, kHex), - MakeEntry(209, "getresuid32", kHex, kHex, kHex, kHex), - MakeEntry(210, "setresgid32", kHex, kHex, kHex, kHex), - MakeEntry(211, "getresgid32", kHex, kHex, kHex, kHex), - MakeEntry(212, "chown32", kHex, kHex, kHex, kHex), - MakeEntry(213, "setuid32", kHex, kHex, kHex, kHex), - MakeEntry(214, "setgid32", kHex, kHex, kHex, kHex), - MakeEntry(215, "setfsuid32", kHex, kHex, kHex, kHex), - MakeEntry(216, "setfsgid32", kHex, kHex, kHex, kHex), - MakeEntry(217, "getdents64", kInt, kHex, kInt), - MakeEntry(218, "pivot_root", kHex, kHex, kHex, kHex), - MakeEntry(219, "mincore", kHex, kInt, kHex), - MakeEntry(220, "madvise", kHex, kInt, kInt), - MakeEntry(221, "fcntl64", kHex, kHex, kHex, kHex), + MakeEntry(191, "ugetrlimit", kInt, kInt, kInt, kInt), + MakeEntry(192, "mmap2", kInt, kInt, kInt, kInt), + MakeEntry(193, "truncate64", kInt, kInt, kInt, kInt), + MakeEntry(194, "ftruncate64", kInt, kInt, kInt, kInt), + MakeEntry(195, "stat64", kPath, kPtr), + MakeEntry(196, "lstat64", kPath, kPtr), + MakeEntry(197, "fstat64", kResource, kPtr), + MakeEntry(198, "lchown32", kInt, kInt, kInt, kInt), + MakeEntry(199, "getuid32", kInt, kInt, kInt, kInt), + MakeEntry(200, "getgid32", kInt, kInt, kInt, kInt), + MakeEntry(201, "geteuid32", kInt, kInt, kInt, kInt), + MakeEntry(202, "getegid32", kInt, kInt, kInt, kInt), + MakeEntry(203, "setreuid32", kInt, kInt, kInt, kInt), + MakeEntry(204, "setregid32", kInt, kInt, kInt, kInt), + MakeEntry(205, "getgroups32", kInt, kInt, kInt, kInt), + MakeEntry(206, "setgroups32", kInt, kInt, kInt, kInt), + MakeEntry(207, "fchown32", kInt, kInt, kInt, kInt), + MakeEntry(208, "setresuid32", kInt, kInt, kInt, kInt), + MakeEntry(209, "getresuid32", kInt, kInt, kInt, kInt), + MakeEntry(210, "setresgid32", kInt, kInt, kInt, kInt), + MakeEntry(211, "getresgid32", kInt, kInt, kInt, kInt), + MakeEntry(212, "chown32", kInt, kInt, kInt, kInt), + MakeEntry(213, "setuid32", kInt, kInt, kInt, kInt), + MakeEntry(214, "setgid32", kInt, kInt, kInt, kInt), + MakeEntry(215, "setfsuid32", kInt, kInt, kInt, kInt), + MakeEntry(216, "setfsgid32", kInt, kInt, kInt, kInt), + MakeEntry(217, "getdents64", kResource, kArray, kLen1), + MakeEntry(218, "pivot_root", kPath, kPath), + MakeEntry(219, "mincore", kPtr, kLen0, kArray), + MakeEntry(220, "madvise", kPtr, kLen0, kFlags), + MakeEntry(221, "fcntl64", kInt, kInt, kInt, kInt), MakeEntry(224, "gettid"), - MakeEntry(225, "readahead", kInt, kInt, kInt), - MakeEntry(226, "setxattr", kPath, kString, kGen, kInt, kHex), - MakeEntry(227, "lsetxattr", kPath, kString, kGen, kInt, kHex), - MakeEntry(228, "fsetxattr", kInt, kString, kGen, kInt, kHex), - MakeEntry(229, "getxattr", kHex, kHex, kHex, kHex), - MakeEntry(230, "lgetxattr", kHex, kHex, kHex, kHex), - MakeEntry(231, "fgetxattr", kGen, kGen, kGen, kGen), - MakeEntry(232, "listxattr", kHex, kHex, kHex, kHex), - MakeEntry(233, "llistxattr", kHex, kHex, kHex, kHex), - MakeEntry(234, "flistxattr", kInt, kGen, kInt), - MakeEntry(235, "removexattr", kHex, kHex, kHex, kHex), - MakeEntry(236, "lremovexattr", kPath, kString), - MakeEntry(237, "fremovexattr", kInt, kString), - MakeEntry(238, "tkill", kHex, kHex, kHex, kHex), - MakeEntry(239, "sendfile64", kHex, kHex, kHex, kHex), - MakeEntry(240, "futex", kGen, kInt, kInt, kGen, kGen, kInt), - MakeEntry(241, "sched_setaffinity", kInt, kInt, kHex), - MakeEntry(242, "sched_getaffinity", kInt, kInt, kHex), - MakeEntry(243, "io_setup", kInt, kHex), - MakeEntry(244, "io_destroy", kInt), - MakeEntry(245, "io_getevents", kInt, kInt, kInt, kHex, kHex), - MakeEntry(246, "io_submit", kInt, kInt, kHex), - MakeEntry(247, "io_cancel", kInt, kHex, kHex), - MakeEntry(248, "exit_group", kHex, kHex, kHex, kHex), - MakeEntry(249, "lookup_dcookie", kInt, kString, kInt), + MakeEntry(225, "readahead", kResource, kInt, kInt), + MakeEntry(226, "setxattr", kPath, kPtr, kString, kLen2, kFlags), + MakeEntry(227, "lsetxattr", kPath, kPtr, kString, kLen2, kFlags), + MakeEntry(228, "fsetxattr", kResource, kPtr, kString, kLen2, kFlags), + MakeEntry(229, "getxattr", kPath, kPtr, kArray, kLen2), + MakeEntry(230, "lgetxattr", kPath, kPtr, kArray, kLen2), + MakeEntry(231, "fgetxattr", kResource, kPtr, kArray, kLen2), + MakeEntry(232, "listxattr", kPath, kArray, kLen1), + MakeEntry(233, "llistxattr", kPath, kArray, kLen1), + MakeEntry(234, "flistxattr", kResource, kArray, kLen1), + MakeEntry(235, "removexattr", kPath, kPtr), + MakeEntry(236, "lremovexattr", kPath, kPtr), + MakeEntry(237, "fremovexattr", kResource, kPtr), + MakeEntry(238, "tkill", kPid, kSignal), + MakeEntry(239, "sendfile64", kResource, kResource, kPtr, kInt), + MakeEntry(240, "futex", kPtr, kFlags, kInt, kPtr, kPtr, kInt), + MakeEntry(241, "sched_setaffinity", kPid, kLen2, kPtr), + MakeEntry(242, "sched_getaffinity", kPid, kLen2, kPtr), + MakeEntry(243, "io_setup", kInt, kPtr), + MakeEntry(244, "io_destroy", kStruct), + MakeEntry(245, "io_getevents", kStruct, kInt, kLen3, kArray, kPtr), + MakeEntry(246, "io_submit", kStruct, kLen2, kArray), + MakeEntry(247, "io_cancel", kStruct, kPtr, kPtr), + MakeEntry(248, "exit_group", kInt), + MakeEntry(249, "lookup_dcookie", kInt, kArray, kLen1), MakeEntry(250, "epoll_create", kInt), - MakeEntry(251, "epoll_ctl", kGen, kGen, kGen, kGen), - MakeEntry(252, "epoll_wait", kGen, kGen, kGen, kGen), - MakeEntry(253, "remap_file_pages", kGen, kInt, kInt, kInt, kHex), - MakeEntry(256, "set_tid_address", kHex), - MakeEntry(257, "timer_create", kInt, kHex, kHex), - MakeEntry(258, "timer_settime", kGen, kGen, kGen, kGen), - MakeEntry(259, "timer_gettime", kInt, kHex), - MakeEntry(260, "timer_getoverrun", kInt), - MakeEntry(261, "timer_delete", kInt), - MakeEntry(262, "clock_settime", kInt, kHex), - MakeEntry(263, "clock_gettime", kInt, kHex), - MakeEntry(264, "clock_getres", kInt, kHex), - MakeEntry(265, "clock_nanosleep", kGen, kGen, kGen, kGen), - MakeEntry(266, "statfs64", kHex, kHex, kHex, kHex), - MakeEntry(267, "fstatfs64", kHex, kHex, kHex, kHex), - MakeEntry(268, "tgkill", kHex, kHex, kHex, kHex), - MakeEntry(269, "utimes", kPath, kHex), - MakeEntry(271, "pciconfig_iobase", kHex, kHex, kHex, kHex), - MakeEntry(272, "pciconfig_read", kHex, kHex, kHex, kHex), - MakeEntry(273, "pciconfig_write", kHex, kHex, kHex, kHex), - MakeEntry(274, "mq_open", kGen, kGen, kGen, kGen), + MakeEntry(251, "epoll_ctl", kResource, kInt, kResource, kPtr), + MakeEntry(252, "epoll_wait", kResource, kArray, kLen1, kInt), + MakeEntry(253, "remap_file_pages", kPtr, kLen0, kFlags, kInt, kFlags), + MakeEntry(256, "set_tid_address", kPtr), + MakeEntry(257, "timer_create", kFlags, kPtr, kPtr), + MakeEntry(258, "timer_settime", kStruct, kFlags, kPtr, kPtr), + MakeEntry(259, "timer_gettime", kStruct, kPtr), + MakeEntry(260, "timer_getoverrun", kStruct), + MakeEntry(261, "timer_delete", kStruct), + MakeEntry(262, "clock_settime", kFlags, kPtr), + MakeEntry(263, "clock_gettime", kFlags, kPtr), + MakeEntry(264, "clock_getres", kFlags, kPtr), + MakeEntry(265, "clock_nanosleep", kFlags, kFlags, kPtr, kPtr), + MakeEntry(266, "statfs64", kInt, kInt, kInt, kInt), + MakeEntry(267, "fstatfs64", kInt, kInt, kInt, kInt), + MakeEntry(268, "tgkill", kPid, kPid, kSignal), + MakeEntry(269, "utimes", kPath, kPtr), + MakeEntry(271, "pciconfig_iobase", kInt, kInt, kInt, kInt), + MakeEntry(272, "pciconfig_read", kInt, kInt, kInt, kInt), + MakeEntry(273, "pciconfig_write", kInt, kInt, kInt, kInt), + MakeEntry(274, "mq_open", kString, kFlags, kFlags, kPtr), MakeEntry(275, "mq_unlink", kString), - MakeEntry(276, "mq_timedsend", kHex, kHex, kInt, kInt, kHex), - MakeEntry(277, "mq_timedreceive", kHex, kHex, kInt, kHex, kHex), - MakeEntry(278, "mq_notify", kHex, kHex), - MakeEntry(279, "mq_getsetattr", kHex, kHex, kHex), - MakeEntry(280, "waitid", kInt, kInt, kHex, kInt, kHex), - MakeEntry(281, "socket", kAddressFamily, kInt, kInt), - MakeEntry(282, "bind", kInt, kSockaddr, kInt), - MakeEntry(283, "connect", kInt, kSockaddr, kInt), - MakeEntry(284, "listen", kInt, kInt), - MakeEntry(285, "accept", kInt, kSockaddr, kHex), - MakeEntry(286, "getsockname", kInt, kSockaddr, kHex), - MakeEntry(287, "getpeername", kInt, kSockaddr, kHex), - MakeEntry(288, "socketpair", kGen, kGen, kGen, kGen), - MakeEntry(289, "send", kHex, kHex, kHex, kHex), - MakeEntry(290, "sendto", kInt, kGen, kInt, kHex, kSockaddr, kInt), - MakeEntry(291, "recv", kHex, kHex, kHex, kHex), - MakeEntry(292, "recvfrom", kInt, kHex, kInt, kHex, kSockaddr, kHex), - MakeEntry(293, "shutdown", kInt, kInt), - MakeEntry(294, "setsockopt", kInt, kInt, kInt, kHex, kHex), - MakeEntry(295, "getsockopt", kInt, kInt, kInt, kHex, kInt), - MakeEntry(296, "sendmsg", kInt, kSockmsghdr, kHex), - MakeEntry(297, "recvmsg", kInt, kHex, kInt), - MakeEntry(298, "semop", kInt, kHex, kInt), - MakeEntry(299, "semget", kInt, kInt, kHex), - MakeEntry(300, "semctl", kInt, kInt, kInt, kHex), - MakeEntry(301, "msgsnd", kInt, kHex, kInt, kHex), - MakeEntry(302, "msgrcv", kInt, kHex, kInt, kInt, kHex), - MakeEntry(303, "msgget", kInt, kHex), - MakeEntry(304, "msgctl", kInt, kInt, kHex), - MakeEntry(305, "shmat", kInt, kHex, kHex), - MakeEntry(306, "shmdt", kHex), - MakeEntry(307, "shmget", kInt, kInt, kHex), - MakeEntry(308, "shmctl", kInt, kInt, kHex), - MakeEntry(309, "add_key", kString, kString, kGen, kInt, kInt), - MakeEntry(310, "request_key", kGen, kGen, kGen, kGen), + MakeEntry(276, "mq_timedsend", kResource, kArray, kLen1, kInt, kPtr), + MakeEntry(277, "mq_timedreceive", kResource, kArray, kLen1, kInt, kPtr), + MakeEntry(278, "mq_notify", kResource, kPtr), + MakeEntry(279, "mq_getsetattr", kResource, kPtr, kPtr), + MakeEntry(280, "waitid", kFlags, kPid, kPtr, kFlags, kPtr), + MakeEntry(281, "socket", kFlags, kFlags, kInt), + MakeEntry(282, "bind", kResource, kSockaddr, kLen1), + MakeEntry(283, "connect", kResource, kSockaddr, kLen1), + MakeEntry(284, "listen", kResource, kInt), + MakeEntry(285, "accept", kResource, kPtr, kPtr), + MakeEntry(286, "getsockname", kResource, kPtr, kPtr), + MakeEntry(287, "getpeername", kResource, kPtr, kPtr), + MakeEntry(288, "socketpair", kFlags, kFlags, kInt, kPtr), + MakeEntry(289, "send", kInt, kInt, kInt, kInt), + MakeEntry(290, "sendto", kResource, kArray, kLen1, kFlags, kSockaddr, + kLen4), + MakeEntry(291, "recv", kInt, kInt, kInt, kInt), + MakeEntry(292, "recvfrom", kResource, kArray, kLen1, kFlags, kSockaddr, + kLen4), + MakeEntry(293, "shutdown", kResource, kFlags), + MakeEntry(294, "setsockopt", kResource, kInt, kInt, kArray, kLen3), + MakeEntry(295, "getsockopt", kResource, kInt, kInt, kArray, kPtr), + MakeEntry(296, "sendmsg", kResource, kPtr, kFlags), + MakeEntry(297, "recvmsg", kResource, kPtr, kFlags), + MakeEntry(298, "semop", kIpcResource, kArray, kLen1), + MakeEntry(299, "semget", kIpcResource, kFlags, kFlags), + MakeEntry(300, "semctl", kIpcResource, kFlags, kInt, kArray), + MakeEntry(301, "msgsnd", kIpcResource, kPtr, kLen1, kFlags), + MakeEntry(302, "msgrcv", kIpcResource, kPtr, kLen1, kFlags, kFlags), + MakeEntry(303, "msgget", kIpcResource, kFlags), + MakeEntry(304, "msgctl", kIpcResource, kInt, kArray), + MakeEntry(305, "shmat", kIpcResource, kPtr, kFlags), + MakeEntry(306, "shmdt", kSharedAddress), + MakeEntry(307, "shmget", kInt, kLen3, kFlags, kPtr), + MakeEntry(308, "shmctl", kIpcResource, kInt, kArray), + MakeEntry(309, "add_key", kString, kPtr, kArray, kLen2, kStruct), + MakeEntry(310, "request_key", kString, kPtr, kString, kStruct), MakeEntry(311, "keyctl", kInt, kInt, kInt, kInt, kInt), - MakeEntry(312, "semtimedop", kInt, kHex, kInt, kHex), - MakeEntry(313, "vserver", kHex, kHex, kHex, kHex), - MakeEntry(314, "ioprio_set", kInt, kInt, kInt), - MakeEntry(315, "ioprio_get", kInt, kInt), + MakeEntry(312, "semtimedop", kIpcResource, kArray, kLen1, kPtr), + MakeEntry(313, "vserver", kInt, kInt, kInt, kInt), + MakeEntry(314, "ioprio_set", kFlags, kPid, kFlags), + MakeEntry(315, "ioprio_get", kFlags, kUid), MakeEntry(316, "inotify_init"), - MakeEntry(317, "inotify_add_watch", kInt, kPath, kHex), - MakeEntry(318, "inotify_rm_watch", kInt, kInt), - MakeEntry(319, "mbind", kGen, kInt, kInt, kHex, kInt, kHex), - MakeEntry(320, "get_mempolicy", kInt, kHex, kInt, kInt, kHex), - MakeEntry(321, "set_mempolicy", kInt, kHex, kInt), - MakeEntry(322, "openat", kGen, kPath, kOct, kHex, kGen, kGen), - MakeEntry(323, "mkdirat", kInt, kPath, kOct), - MakeEntry(324, "mknodat", kInt, kPath, kOct, kHex), - MakeEntry(325, "fchownat", kInt, kPath, kInt, kInt, kHex), - MakeEntry(326, "futimesat", kInt, kPath, kHex), - MakeEntry(327, "fstatat64", kHex, kHex, kHex, kHex), - MakeEntry(328, "unlinkat", kInt, kPath, kHex), - MakeEntry(329, "renameat", kGen, kPath, kGen, kPath), - MakeEntry(330, "linkat", kInt, kPath, kInt, kPath, kHex), - MakeEntry(331, "symlinkat", kPath, kGen, kPath), - MakeEntry(332, "readlinkat", kInt, kPath, kHex, kInt), - MakeEntry(333, "fchmodat", kInt, kPath, kOct, kHex), - MakeEntry(334, "faccessat", kInt, kPath, kHex, kHex), - MakeEntry(335, "pselect6", kInt, kHex, kHex, kHex, kHex), - MakeEntry(336, "ppoll", kHex, kInt, kHex, kHex, kInt), - MakeEntry(337, "unshare", kHex), - MakeEntry(338, "set_robust_list", kGen, kGen), - MakeEntry(339, "get_robust_list", kInt, kHex, kHex), - MakeEntry(340, "splice", kInt, kHex, kInt, kHex, kInt, kHex), - MakeEntry(342, "tee", kGen, kGen, kGen, kGen), - MakeEntry(343, "vmsplice", kGen, kGen, kGen, kGen), - MakeEntry(344, "move_pages", kInt, kInt, kHex, kHex, kHex, kHex), - MakeEntry(345, "getcpu", kHex, kHex, kHex), - MakeEntry(346, "epoll_pwait", kInt, kHex, kInt, kInt, kHex, kInt), - MakeEntry(347, "kexec_load", kGen, kGen, kGen, kGen), - MakeEntry(348, "utimensat", kGen, kGen, kGen, kGen), - MakeEntry(349, "signalfd", kInt, kHex, kHex), - MakeEntry(350, "timerfd_create", kInt, kHex), + MakeEntry(317, "inotify_add_watch", kResource, kPath, kFlags), + MakeEntry(318, "inotify_rm_watch", kResource, kResource), + MakeEntry(319, "mbind", kPtr, kLen0, kFlags, kPtr, kInt, kFlags), + MakeEntry(320, "get_mempolicy", kPtr, kPtr, kInt, kPtr, kFlags), + MakeEntry(321, "set_mempolicy", kFlags, kPtr, kInt), + MakeEntry(322, "openat", kResource, kPath, kFlags, kFlags), + MakeEntry(323, "mkdirat", kResource, kPath, kFlags), + MakeEntry(324, "mknodat", kResource, kPath, kFlags, kInt), + MakeEntry(325, "fchownat", kResource, kPath, kUid, kGid, kFlags), + MakeEntry(326, "futimesat", kResource, kPath, kPtr), + MakeEntry(327, "fstatat64", kInt, kPath, kPtr, kFlags), + MakeEntry(328, "unlinkat", kResource, kPath, kFlags), + MakeEntry(329, "renameat", kResource, kPath, kResource, kPath), + MakeEntry(330, "linkat", kResource, kPath, kResource, kPath, kFlags), + MakeEntry(331, "symlinkat", kPath, kResource, kPath), + MakeEntry(332, "readlinkat", kResource, kPath, kArray, kLen2), + MakeEntry(333, "fchmodat", kResource, kPath, kFlags), + MakeEntry(334, "faccessat", kResource, kPath, kFlags), + MakeEntry(335, "pselect6", kLen1, kPtr, kPtr, kPtr, kPtr, kPtr), + MakeEntry(336, "ppoll", kPollFdArray, kLen0, kPtr, kPtr, kLen3), + MakeEntry(337, "unshare", kFlags), + MakeEntry(338, "set_robust_list", kPtr, kLen0), + MakeEntry(339, "get_robust_list", kPid, kPtr, kPtr), + MakeEntry(340, "splice", kResource, kPtr, kResource, kPtr, kInt, kFlags), + MakeEntry(342, "tee", kResource, kResource, kInt, kFlags), + MakeEntry(343, "vmsplice", kResource, kArray, kLen1, kFlags), + MakeEntry(344, "move_pages", kPid, kLen2, kArray, kArray, kArray, kFlags), + MakeEntry(345, "getcpu", kPtr, kPtr), + MakeEntry(346, "epoll_pwait", kResource, kArray, kLen1, kInt, kPtr, kLen4), + MakeEntry(347, "kexec_load", kInt, kLen2, kArray, kFlags), + MakeEntry(348, "utimensat", kResource, kPath, kPtr, kFlags), + MakeEntry(349, "signalfd", kResource, kPtr, kLen1), + MakeEntry(350, "timerfd_create", kFlags, kFlags), MakeEntry(351, "eventfd", kInt), - MakeEntry(352, "fallocate", kGen, kGen, kGen, kGen), - MakeEntry(353, "timerfd_settime", kGen, kGen, kGen, kGen), - MakeEntry(354, "timerfd_gettime", kInt, kHex), - MakeEntry(355, "signalfd4", kGen, kGen, kGen, kGen), - MakeEntry(356, "eventfd2", kInt, kHex), - MakeEntry(357, "epoll_create1", kHex), - MakeEntry(358, "dup3", kGen, kGen, kGen), - MakeEntry(359, "pipe2", kHex, kHex), - MakeEntry(360, "inotify_init1", kHex), - MakeEntry(361, "preadv", kInt, kHex, kInt, kInt, kInt), - MakeEntry(362, "pwritev", kInt, kHex, kInt, kInt, kInt), - MakeEntry(363, "rt_tgsigqueueinfo", kGen, kGen, kGen, kGen), - MakeEntry(364, "perf_event_open", kHex, kInt, kInt, kInt, kHex), - MakeEntry(365, "recvmmsg", kInt, kHex, kInt, kHex, kHex), - MakeEntry(366, "accept4", kGen, kGen, kGen, kGen), - MakeEntry(367, "fanotify_init", kHex, kHex, kHex, kHex), - MakeEntry(368, "fanotify_mark", kInt, kHex, kHex, kInt, kPath), - MakeEntry(369, "prlimit64", kHex, kHex, kHex, kHex), - MakeEntry(370, "name_to_handle_at", kInt, kPath, kHex, kHex, kHex), - MakeEntry(371, "open_by_handle_at", kHex, kHex, kHex, kHex), - MakeEntry(372, "clock_adjtime", kHex, kHex, kHex, kHex), - MakeEntry(373, "syncfs", kHex, kHex, kHex, kHex), - MakeEntry(374, "sendmmsg", kHex, kHex, kHex, kHex), - MakeEntry(375, "setns", kHex, kHex, kHex, kHex), - MakeEntry(376, "process_vm_readv", kInt, kHex, kInt, kHex, kInt, kInt), - MakeEntry(377, "process_vm_writev", kInt, kHex, kInt, kHex, kInt, kInt), - MakeEntry(378, "kcmp", kInt, kInt, kInt, kInt, kInt), - MakeEntry(379, "finit_module", kHex, kHex, kHex, kHex), - MakeEntry(380, "sched_setattr", kInt, kHex, kHex), - MakeEntry(381, "sched_getattr", kGen, kGen, kGen, kGen), - MakeEntry(382, "renameat2", kGen, kPath, kGen, kPath, kGen, kGen), - MakeEntry(383, "seccomp", kInt, kHex, kHex), - MakeEntry(384, "getrandom", kGen, kInt, kHex), - MakeEntry(385, "memfd_create", kString, kHex), - MakeEntry(386, "bpf", kHex, kHex, kHex, kHex), - MakeEntry(387, "execveat", kInt, kPath, kHex, kHex, kHex), - MakeEntry(388, "userfaultfd", kHex), - MakeEntry(389, "membarrier", kHex, kHex), - MakeEntry(390, "mlock2", kHex, kHex, kHex, kHex), - MakeEntry(391, "copy_file_range", kInt, kHex, kInt, kHex, kInt, kHex), - MakeEntry(392, "preadv2", kInt, kHex, kInt, kInt, kInt, kHex), - MakeEntry(393, "pwritev2", kInt, kHex, kInt, kInt, kInt, kHex), - MakeEntry(400, "migrate_pages", kGen, kGen, kGen, kGen), - MakeEntry(401, "kexec_file_load", kInt, kInt, kInt, kString, kHex), - MakeEntry(435, "clone3", kHex, kInt), - MakeEntry(436, "close_range", kInt, kInt, kHex), - MakeEntry(437, "openat2", kInt, kPath, kHex, kInt), - MakeEntry(438, "pidfd_getfd", UnknownArguments()), - MakeEntry(439, "faccessat2", kInt, kPath, kHex, kHex), - MakeEntry(440, "process_madvise", UnknownArguments()), - MakeEntry(441, "epoll_pwait2", UnknownArguments()), - MakeEntry(442, "mount_setattr", UnknownArguments()), + MakeEntry(352, "fallocate", kResource, kFlags, kInt, kInt), + MakeEntry(353, "timerfd_settime", kResource, kFlags, kPtr, kPtr), + MakeEntry(354, "timerfd_gettime", kResource, kPtr), + MakeEntry(355, "signalfd4", kResource, kPtr, kLen1, kFlags), + MakeEntry(356, "eventfd2", kInt, kFlags), + MakeEntry(357, "epoll_create1", kFlags), + MakeEntry(358, "dup3", kResource, kResource, kFlags), + MakeEntry(359, "pipe2", kPtr, kFlags), + MakeEntry(360, "inotify_init1", kFlags), + MakeEntry(361, "preadv", kResource, kArray, kLen1, kInt, kInt), + MakeEntry(362, "pwritev", kResource, kArray, kLen1, kInt, kInt), + MakeEntry(363, "rt_tgsigqueueinfo", kPid, kPid, kSignal, kPtr), + MakeEntry(364, "perf_event_open", kPtr, kPid, kInt, kResource, kFlags), + MakeEntry(365, "recvmmsg", kResource, kArray, kLen1, kFlags, kPtr), + MakeEntry(366, "accept4", kResource, kPtr, kPtr, kFlags), + MakeEntry(367, "fanotify_init", kFlags, kFlags), + MakeEntry(368, "fanotify_mark", kResource, kFlags, kFlags, kResource, + kPath), + MakeEntry(369, "prlimit64", kPid, kFlags, kPtr, kPtr), + MakeEntry(370, "name_to_handle_at", kResource, kPath, kPtr, kPtr, kFlags), + MakeEntry(371, "open_by_handle_at", kResource, kPtr, kFlags), + MakeEntry(372, "clock_adjtime", kFlags, kPtr), + MakeEntry(373, "syncfs", kResource), + MakeEntry(374, "sendmmsg", kResource, kArray, kLen1, kFlags), + MakeEntry(375, "setns", kResource, kFlags), + MakeEntry(376, "process_vm_readv", kPid, kArray, kLen1, kArray, kLen3, + kInt), + MakeEntry(377, "process_vm_writev", kPid, kArray, kLen1, kArray, kLen3, + kInt), + MakeEntry(378, "kcmp", kPid, kPid, kFlags, kResource, kResource), + MakeEntry(379, "finit_module", kResource, kString, kFlags), + MakeEntry(380, "sched_setattr", kPid, kPtr, kInt), + MakeEntry(381, "sched_getattr", kPid, kPtr, kLen1, kInt), + MakeEntry(382, "renameat2", kResource, kPath, kResource, kPath, kFlags), + MakeEntry(383, "seccomp", kInt, kFlags, kPtr), + MakeEntry(384, "getrandom", kArray, kLen0, kFlags), + MakeEntry(385, "memfd_create", kString, kFlags), + MakeEntry(386, "bpf", kInt, kPtr, kLen1), + MakeEntry(387, "execveat", kResource, kPath, kArray, kArray, kFlags), + MakeEntry(388, "userfaultfd", kFlags), + MakeEntry(389, "membarrier", kFlags, kInt), + MakeEntry(390, "mlock2", kPtr, kLen0, kFlags), + MakeEntry(391, "copy_file_range", kResource, kPtr, kResource, kPtr, kInt, + kFlags), + MakeEntry(392, "preadv2", kResource, kArray, kLen1, kInt, kInt, kFlags), + MakeEntry(393, "pwritev2", kResource, kArray, kLen1, kInt, kInt, kFlags), + MakeEntry(400, "migrate_pages", kPid, kInt, kPtr, kPtr), + MakeEntry(401, "kexec_file_load", kInt, kInt, kInt, kString, kInt), + MakeEntry(435, "clone3", kPtr, kLen0), + MakeEntry(436, "close_range", kResource, kResource, kFlags), + MakeEntry(437, "openat2", kResource, kPath, kPtr, kLen2), + MakeEntry(438, "pidfd_getfd", kResource, kResource, kInt), + MakeEntry(439, "faccessat2", kResource, kPath, kFlags, kFlags), + MakeEntry(440, "process_madvise", kResource, kArray, kLen1, kFlags, kInt), + MakeEntry(441, "epoll_pwait2", kResource, kArray, kLen1, kPtr, kPtr, kLen4), + MakeEntry(442, "mount_setattr", kResource, kPath, kFlags, kPtr, kLen3), MakeEntry(443, "quotactl_fd", UnknownArguments()), - MakeEntry(444, "landlock_create_ruleset", UnknownArguments()), - MakeEntry(445, "landlock_add_rule", UnknownArguments()), - MakeEntry(446, "landlock_restrict_self", UnknownArguments()), - MakeEntry(448, "process_mrelease", UnknownArguments()), - MakeEntry(449, "futex_waitv", UnknownArguments()), - MakeEntry(450, "set_mempolicy_home_node", UnknownArguments()), - MakeEntry(451, "cachestat", UnknownArguments()), - MakeEntry(452, "fchmodat2", kInt, kPath, kHex, kHex), - MakeEntry(453, "map_shadow_stack", UnknownArguments()), + MakeEntry(444, "landlock_create_ruleset", kPtr, kLen0, kInt), + MakeEntry(445, "landlock_add_rule", kResource, kInt, kPtr, kInt), + MakeEntry(446, "landlock_restrict_self", kResource, kInt), + MakeEntry(448, "process_mrelease", kResource, kInt), + MakeEntry(449, "futex_waitv", kArray, kLen0, kInt, kPtr, kFlags), + MakeEntry(450, "set_mempolicy_home_node", kPtr, kLen0, kInt, kInt), + MakeEntry(451, "cachestat", kResource, kPtr, kPtr, kInt), + MakeEntry(452, "fchmodat2", kInt, kPath, kInt, kInt), + MakeEntry(453, "map_shadow_stack", kPtr, kLen0, kFlags), MakeEntry(454, "futex_wake", UnknownArguments()), MakeEntry(455, "futex_wait", UnknownArguments()), MakeEntry(456, "futex_requeue", UnknownArguments()), @@ -1995,11 +2096,11 @@ constexpr std::array kSyscallDataArm32 = { MakeEntry(459, "lsm_get_self_attr", UnknownArguments()), MakeEntry(460, "lsm_set_self_attr", UnknownArguments()), MakeEntry(461, "lsm_list_modules", UnknownArguments()), - MakeEntry(0xf0001, "ARM_breakpoint", kHex, kHex, kHex, kHex), - MakeEntry(0xf0002, "ARM_cacheflush", kHex, kHex, kHex, kHex), - MakeEntry(0xf0003, "ARM_usr26", kHex, kHex, kHex, kHex), - MakeEntry(0xf0004, "ARM_usr32", kHex, kHex, kHex, kHex), - MakeEntry(0xf0005, "ARM_set_tls", kHex, kHex, kHex, kHex), + MakeEntry(0xf0001, "ARM_breakpoint", UnknownArguments()), + MakeEntry(0xf0002, "ARM_cacheflush", UnknownArguments()), + MakeEntry(0xf0003, "ARM_usr26", UnknownArguments()), + MakeEntry(0xf0004, "ARM_usr32", UnknownArguments()), + MakeEntry(0xf0005, "ARM_set_tls", UnknownArguments()), // clang-format on }; diff --git a/sandboxed_api/sandbox2/syscall_defs.h b/sandboxed_api/sandbox2/syscall_defs.h index 1fbf3dc..a6f9cf8 100644 --- a/sandboxed_api/sandbox2/syscall_defs.h +++ b/sandboxed_api/sandbox2/syscall_defs.h @@ -4,36 +4,200 @@ #include #include +#include #include +#include #include +#include #include +#include "absl/status/status.h" #include "absl/status/statusor.h" +#include "absl/strings/str_format.h" #include "absl/strings/string_view.h" #include "absl/types/span.h" #include "sandboxed_api/config.h" -#include "sandboxed_api/sandbox2/syscall.h" +#include "sandboxed_api/sandbox2/util.h" +#include "sandboxed_api/util/status_macros.h" namespace sandbox2 { namespace syscalls { constexpr int kMaxArgs = 6; -// Type of a given syscall argument. Used with argument conversion routines. enum ArgType { - kGen = 1, - kInt, kPath, - kHex, - kOct, - kSocketCall, - kSocketCallPtr, - kSignal, kString, + kGen, + kStruct, + kPtr, + kArray, + kInt, + kFlags, + kResource, + kPid, + kSignal, + kIpcResource, + kSharedAddress, + kGid, + kUid, + // These kLenN types indicate that the argument is a length, and which + // other argument it applies to. I.e., if parameter 3 is type kPollFdArray, + // and parameter 4 has the length, then parameter 4 is of type kLen3. + kLen0, + kLen1, + kLen2, + kLen3, + kLen4, + kLen5, kAddressFamily, + kGidArray, + kPollFdArray, kSockaddr, - kSockmsghdr, - kCloneFlag, +}; + +constexpr absl::string_view ArgTypeToString(ArgType type) { + switch (type) { + case kPath: + return "path"; + case kString: + return "string"; + case kGen: + return "generic type"; + case kStruct: + return "struct"; + case kPtr: + return "pointer"; + case kArray: + return "array"; + case kInt: + return "int"; + case kFlags: + return "flags"; + case kResource: + return "resource"; + case kPid: + return "pid"; + case kSignal: + return "signal"; + case kIpcResource: + return "ipc resource"; + case kSharedAddress: + return "shared address"; + case kGid: + return "gid"; + case kUid: + return "uid"; + case kLen0: + return "length of parameter 0"; + case kLen1: + return "length of parameter 1"; + case kLen2: + return "length of parameter 2"; + case kLen3: + return "length of parameter 3"; + case kLen4: + return "length of parameter 4"; + case kLen5: + return "length of parameter 5"; + case kAddressFamily: + return "address family"; + case kGidArray: + return "gid array"; + case kPollFdArray: + return "poll fd array"; + case kSockaddr: + return "sockaddr struct"; + default: + return "invalid type"; + } +} + +class ArgData { + public: + template + struct StructArray { + std::vector array; + bool truncated; + }; + + ArgData(syscalls::ArgType type, pid_t pid, uint64_t value, + std::optional length = std::nullopt) + : type_(type), pid_(pid), value_(value), length_(length) {} + + ArgType type() const { return type_; } + pid_t pid() const { return pid_; } + uint64_t value() const { return value_; } + std::optional length() const { return length_; } + + std::string GetDescription() const; + + absl::StatusOr ReadAsString() const { + return util::ReadCPathFromPid(pid_, value_); + } + + template + absl::StatusOr ReadAsStruct() const { + if (length_.has_value() && *length_ < sizeof(T)) { + return absl::InternalError(absl::StrFormat( + "specified length [%llu] is not enough for to sizeof(%s) == %llu", + *length_, typeid(T).name(), sizeof(T))); + } + SAPI_ASSIGN_OR_RETURN(std::vector b, + util::ReadBytesFromPid(pid_, value_, sizeof(T))); + return BytesToStruct(b); + } + + template + absl::StatusOr> ReadAsStructArray() const { + static uint64_t kMaxAllowedBytes = 1 << 20; // 1MB + + if (!length_.has_value()) { + return absl::InternalError("length is not set"); + } + + bool truncated = false; + uint64_t length = *length_ * sizeof(T); + if (length > kMaxAllowedBytes) { + truncated = true; + length = (kMaxAllowedBytes / sizeof(T)) * sizeof(T); + } + + SAPI_ASSIGN_OR_RETURN(std::vector b, + util::ReadBytesFromPid(pid_, value_, length)); + absl::Span bytes = absl::MakeSpan(b); + if (bytes.size() < length) { + return absl::InternalError("could not read full struct array"); + } + std::vector ret; + for (size_t i = 0; i < bytes.size(); i += sizeof(T)) { + SAPI_ASSIGN_OR_RETURN(T t, BytesToStruct(bytes.subspan(i, sizeof(T)))); + ret.push_back(t); + } + + return StructArray{std::move(ret), truncated}; + } + + private: + template + static absl::StatusOr BytesToStruct(absl::Span bytes) { + static_assert(std::is_pod(), "Can only cast bytes to POD structs"); + if (bytes.size() < sizeof(T)) { + return absl::InternalError(absl::StrFormat( + "bytes size [%llu] is not equal to sizeof(%s) == %llu", bytes.size(), + typeid(T).name(), sizeof(T))); + } + T t; + memcpy(&t, bytes.data(), sizeof(T)); + return t; + } + + absl::StatusOr GetDescriptionImpl() const; + + syscalls::ArgType type_; + pid_t pid_; + uint64_t value_; + std::optional length_; }; } // namespace syscalls @@ -50,10 +214,6 @@ class SyscallTable { return num_args; } - static std::string GetArgumentDescription(uint64_t value, - syscalls::ArgType type, - pid_t pid); - static constexpr bool BySyscallNr(const SyscallTable::Entry& a, const SyscallTable::Entry& b) { return a.nr < b.nr; @@ -72,6 +232,10 @@ class SyscallTable { absl::string_view GetName(int syscall) const; + std::vector GetArgumentsData(int syscall, + const uint64_t values[], + pid_t pid) const; + std::vector GetArgumentsDescription(int syscall, const uint64_t values[], pid_t pid) const; diff --git a/sandboxed_api/sandbox2/util.cc b/sandboxed_api/sandbox2/util.cc index 2ed22d6..52d3742 100644 --- a/sandboxed_api/sandbox2/util.cc +++ b/sandboxed_api/sandbox2/util.cc @@ -14,15 +14,18 @@ #include "sandboxed_api/sandbox2/util.h" +#include #include #include #include #include +#include #include #include #include #include +#include #include #include #include @@ -33,6 +36,7 @@ #include #include +#include "absl/algorithm/container.h" #include "absl/base/attributes.h" #include "absl/base/macros.h" #include "absl/base/optimization.h" @@ -51,7 +55,7 @@ #include "sandboxed_api/util/fileops.h" #include "sandboxed_api/util/path.h" #include "sandboxed_api/util/raw_logging.h" - +#include "sandboxed_api/util/status_macros.h" namespace sandbox2::util { namespace file = ::sapi::file; @@ -137,6 +141,19 @@ std::string GetProgName(pid_t pid) { return file_util::fileops::Basename(file_util::fileops::ReadLink(fname)); } +absl::StatusOr GetResolvedFdLink(pid_t pid, uint32_t fd) { + // The proc/PID/fd directory contains links for all of that process' file + // descriptors. They'll show up as more informative strings (paths, sockets). + std::string fd_path = absl::StrFormat("/proc/%u/fd/%u", pid, fd); + std::string result(PATH_MAX, '\0'); + ssize_t size = readlink(fd_path.c_str(), &result[0], PATH_MAX); + if (size < 0) { + return absl::ErrnoToStatus(size, "failed to read link"); + } + result.resize(size); + return result; +} + std::string GetCmdLine(pid_t pid) { std::string fname = file::JoinPath("/proc", absl::StrCat(pid), "cmdline"); std::string cmdline; @@ -326,6 +343,29 @@ std::string GetSignalName(int signo) { return absl::StrFormat("%s [%d]", kSignalNames[signo], signo); } +std::string GetAddressFamily(int addr_family) { + // Taken from definitions in `socket.h`. Each family's index in the array is + // also its integer value. + constexpr absl::string_view kAddressFamilies[] = { + "AF_UNSPEC", "AF_UNIX", "AF_INET", "AF_AX25", + "AF_IPX", "AF_APPLETALK", "AF_NETROM", "AF_BRIDGE", + "AF_ATMPVC", "AF_X25", "AF_INET6", "AF_ROSE", + "AF_DECnet", "AF_NETBEUI", "AF_SECURITY", "AF_KEY", + "AF_NETLINK", "AF_PACKET", "AF_ASH", "AF_ECONET", + "AF_ATMSVC", "AF_RDS", "AF_SNA", "AF_IRDA", + "AF_PPPOX", "AF_WANPIPE", "AF_LLC", "AF_IB", + "AF_MPLS", "AF_CAN", "AF_TIPC", "AF_BLUETOOTH", + "AF_IUCV", "AF_RXRPC", "AF_ISDN", "AF_PHONET", + "AF_IEEE802154", "AF_CAIF", "AF_ALG", "AF_NFC", + "AF_VSOCK", "AF_KCM", "AF_QIPCRTR", "AF_SMC", + "AF_XDP", "AF_MCTP"}; + + if (addr_family < 0 && addr_family >= ABSL_ARRAYSIZE(kAddressFamilies)) { + return absl::StrFormat("UNKNOWN_ADDRESS_FAMILY [%d]", addr_family); + } + return std::string(kAddressFamilies[addr_family]); +} + std::string GetRlimitName(int resource) { switch (resource) { case RLIMIT_AS: @@ -370,45 +410,53 @@ std::string GetPtraceEventName(int event) { } } -absl::StatusOr ReadCPathFromPid(pid_t pid, uintptr_t ptr) { - std::string path(PATH_MAX, '\0'); - iovec local_iov[] = {{&path[0], path.size()}}; - +absl::StatusOr> ReadBytesFromPid(pid_t pid, uintptr_t ptr, + uint64_t size) { static const uintptr_t page_size = getpagesize(); - static const uintptr_t page_mask = ~(page_size - 1); - // See 'man process_vm_readv' for details on how to read NUL-terminated - // strings with this syscall. - size_t len1 = ((ptr + page_size) & page_mask) - ptr; - len1 = (len1 > path.size()) ? path.size() : len1; - size_t len2 = (path.size() <= len1) ? 0UL : path.size() - len1; - // Second iov is wrapping around to NULL ptr. - if ((ptr + len1) < ptr) { - len2 = 0UL; + static const uintptr_t page_mask = page_size - 1; + + // Input sanity checks. + if (size == 0) { + return std::vector(); } - iovec remote_iov[] = { - {reinterpret_cast(ptr), len1}, - {reinterpret_cast(ptr + len1), len2}, - }; + // Allocate enough bytes to hold the entire size. + std::vector bytes(size, 0); + iovec local_iov[] = {{bytes.data(), bytes.size()}}; + // Stores all the necessary iovecs to move memory. + std::vector remote_iov; + // Each iovec should be contained to a single page. + size_t consumed = 0; + while (consumed < size) { + // Read till the end of the page, at most the remaining number of bytes. + size_t chunk_size = + std::min(size - consumed, page_size - ((ptr + consumed) & page_mask)); + remote_iov.push_back({reinterpret_cast(ptr + consumed), chunk_size}); + consumed += chunk_size; + } - SAPI_RAW_VLOG(4, "ReadCPathFromPid (iovec): len1: %zu, len2: %zu", len1, - len2); - if (process_vm_readv(pid, local_iov, ABSL_ARRAYSIZE(local_iov), remote_iov, - ABSL_ARRAYSIZE(remote_iov), 0) < 0) { + ssize_t result = process_vm_readv(pid, local_iov, ABSL_ARRAYSIZE(local_iov), + remote_iov.data(), remote_iov.size(), 0); + if (result < 0) { return absl::ErrnoToStatus( errno, absl::StrFormat("process_vm_readv() failed for PID: %d at address: %#x", - pid, reinterpret_cast(ptr))); + pid, ptr)); } + // Ensure only successfully read bytes are returned. + bytes.resize(result); + return bytes; +} - // Check for whether there's a NUL byte in the buffer. If not, it's an - // incorrect path (or >PATH_MAX). - auto pos = path.find('\0'); - if (pos == std::string::npos) { - return absl::FailedPreconditionError(absl::StrCat( - "No NUL-byte inside the C string '", absl::CHexEscape(path), "'")); +absl::StatusOr ReadCPathFromPid(pid_t pid, uintptr_t ptr) { + SAPI_ASSIGN_OR_RETURN(std::vector bytes, + ReadBytesFromPid(pid, ptr, PATH_MAX)); + auto null_pos = absl::c_find(bytes, '\0'); + std::string path(bytes.begin(), null_pos); + if (null_pos == bytes.end()) { + return absl::FailedPreconditionError( + absl::StrFormat("path '%s' is too long", absl::CHexEscape(path))); } - path.resize(pos); return path; } diff --git a/sandboxed_api/sandbox2/util.h b/sandboxed_api/sandbox2/util.h index d171dc9..871b2ef 100644 --- a/sandboxed_api/sandbox2/util.h +++ b/sandboxed_api/sandbox2/util.h @@ -63,6 +63,9 @@ inline void CharPtrArrToVecString(char* const* arr, // Returns the program name (via /proc/self/comm) for a given PID. std::string GetProgName(pid_t pid); +// Given a resource descriptor FD and a PID, returns link of /proc/PID/fds/FD. +absl::StatusOr GetResolvedFdLink(pid_t pid, uint32_t fd); + // Returns the command line (via /proc/self/cmdline) for a given PID. The // argument separators '\0' are converted to spaces. std::string GetCmdLine(pid_t pid); @@ -95,12 +98,19 @@ absl::StatusOr Communicate(const std::vector& argv, // Returns signal description. std::string GetSignalName(int signo); +// Returns the socket address family as a string ("AF_INET", ...) +std::string GetAddressFamily(int addr_family); + // Returns rlimit resource name std::string GetRlimitName(int resource); // Returns ptrace event name std::string GetPtraceEventName(int event); +// Reads `size` bytes from the given `ptr` address, or returns an error. +absl::StatusOr> ReadBytesFromPid(pid_t pid, uintptr_t ptr, + uint64_t size); + // Reads a path string (NUL-terminated, shorter than PATH_MAX) from another // process memory absl::StatusOr ReadCPathFromPid(pid_t pid, uintptr_t ptr);