Fix decoding of 16-bit *chown and [gs]et*[gu]id syscalls
Define two sets of parsers on architectures that support (either directly or via multiarch) 16-bit and 32-bit uid/gid syscalls simultaneously. Since the code in these two sets is essentially the same and the key difference between them is the size of uid_t, implement it by parametrizing uid_t and names of parser functions. * defs.h (NEED_UID16_PARSERS): New macro. * linux/syscall.h [NEED_UID16_PARSERS] (sys_chown16, sys_fchown16, sys_getresuid16, sys_getuid16, sys_setfsuid16, sys_setresuid16, sys_setreuid16, sys_setuid16): New prototypes. * linux/dummy.h (sys_geteuid16): Alias to sys_getuid16. (sys_getegid16, sys_getgid16, sys_getresgid16, sys_setfsgid16, sys_setgid16, sys_setregid16, sys_setresgid16): Alias to corresponding sys_*uid16 functions. * uid.c: Stop including <asm/posix_types.h>. Parametrize uid_t and names of all exported functions. (get_print_uid): New function. (sys_getresuid): Use it. (printuid): Check for (uid_t) -1. * uid16.c: New file. * Makefile.am (strace_SOURCES): Add it. * linux/arm/syscallent.h: Use sys_chown16, sys_fchown16, sys_getegid16, sys_geteuid16, sys_getgid16, sys_getresgid16, sys_getresuid16, sys_getuid16, sys_setfsgid16, sys_setfsuid16, sys_setgid16, sys_setregid16, sys_setresgid16, sys_setresuid16, sys_setreuid16, and sys_setuid16 parsers for *chown and [gs]et*[gu]id syscall entries. * linux/bfin/syscallent.h: Likewise. * linux/i386/syscallent.h: Likewise. * linux/m68k/syscallent.h: Likewise. * linux/microblaze/syscallent.h: Likewise. * linux/s390/syscallent.h: Likewise. * linux/sparc/syscallent.h: Likewise. * linux/sh/syscallent.h: Likewise. * linux/sh64/syscallent.h: Likewise. * tests/uid16.c: New file. * tests/uid16.test: New test. * tests/Makefile.am (CHECK_PROGRAMS): Add uid16. (TESTS): Add uid16.test. * tests/.gitignore: Add uid16.
This commit is contained in:
parent
d535b8bd51
commit
80f7db1fed
@ -94,6 +94,7 @@ strace_SOURCES = \
|
||||
time.c \
|
||||
truncate.c \
|
||||
uid.c \
|
||||
uid16.c \
|
||||
umask.c \
|
||||
umount.c \
|
||||
uname.c \
|
||||
|
14
defs.h
14
defs.h
@ -549,6 +549,20 @@ extern const struct xlat whence_codes[];
|
||||
#define STACKTRACE_INVALIDATE_CACHE 0400 /* Trigger proc/maps cache updating */
|
||||
#define STACKTRACE_CAPTURE_ON_ENTER 01000 /* Capture stacktrace on "entering" stage */
|
||||
|
||||
#if defined(ARM) || defined(AARCH64) \
|
||||
|| defined(I386) || defined(X32) || defined(X86_64) \
|
||||
|| defined(BFIN) \
|
||||
|| defined(M68K) \
|
||||
|| defined(MICROBLAZE) \
|
||||
|| defined(S390) \
|
||||
|| defined(SH) || defined(SH64) \
|
||||
|| defined(SPARC) || defined(SPARC64) \
|
||||
/**/
|
||||
# define NEED_UID16_PARSERS 1
|
||||
#else
|
||||
# define NEED_UID16_PARSERS 0
|
||||
#endif
|
||||
|
||||
typedef enum {
|
||||
CFLAG_NONE = 0,
|
||||
CFLAG_ONLY_STATS,
|
||||
|
@ -42,15 +42,15 @@
|
||||
{ 1, 0, sys_time, "time" }, /* 13 */
|
||||
{ 3, TF, sys_mknod, "mknod" }, /* 14 */
|
||||
{ 2, TF, sys_chmod, "chmod" }, /* 15 */
|
||||
{ 3, TF, sys_chown, "lchown" }, /* 16 */
|
||||
{ 3, TF, sys_chown16, "lchown" }, /* 16 */
|
||||
{ 0, TM, sys_break, "break" }, /* 17 */
|
||||
{ 2, TF, sys_oldstat, "oldstat" }, /* 18 */
|
||||
{ 3, TD, sys_lseek, "lseek" }, /* 19 */
|
||||
{ 0, 0, sys_getpid, "getpid" }, /* 20 */
|
||||
{ 5, TF, sys_mount, "mount" }, /* 21 */
|
||||
{ 1, TF, sys_umount, "oldumount" }, /* 22 */
|
||||
{ 1, 0, sys_setuid, "setuid" }, /* 23 */
|
||||
{ 0, NF, sys_getuid, "getuid" }, /* 24 */
|
||||
{ 1, 0, sys_setuid16, "setuid" }, /* 23 */
|
||||
{ 0, NF, sys_getuid16, "getuid" }, /* 24 */
|
||||
{ 1, 0, sys_stime, "stime" }, /* 25 */
|
||||
{ 4, 0, sys_ptrace, "ptrace" }, /* 26 */
|
||||
{ 1, 0, sys_alarm, "alarm" }, /* 27 */
|
||||
@ -72,11 +72,11 @@
|
||||
{ 1, 0, sys_times, "times" }, /* 43 */
|
||||
{ 0, 0, sys_prof, "prof" }, /* 44 */
|
||||
{ 1, TM|SI, sys_brk, "brk" }, /* 45 */
|
||||
{ 1, 0, sys_setgid, "setgid" }, /* 46 */
|
||||
{ 0, NF, sys_getgid, "getgid" }, /* 47 */
|
||||
{ 1, 0, sys_setgid16, "setgid" }, /* 46 */
|
||||
{ 0, NF, sys_getgid16, "getgid" }, /* 47 */
|
||||
{ 3, TS, sys_signal, "signal" }, /* 48 */
|
||||
{ 0, NF, sys_geteuid, "geteuid" }, /* 49 */
|
||||
{ 0, NF, sys_getegid, "getegid" }, /* 50 */
|
||||
{ 0, NF, sys_geteuid16, "geteuid" }, /* 49 */
|
||||
{ 0, NF, sys_getegid16, "getegid" }, /* 50 */
|
||||
{ 1, TF, sys_acct, "acct" }, /* 51 */
|
||||
{ 2, TF, sys_umount2, "umount" }, /* 52 */
|
||||
{ 0, 0, sys_lock, "lock" }, /* 53 */
|
||||
@ -96,8 +96,8 @@
|
||||
{ 3, TS, sys_sigaction, "sigaction" }, /* 67 */
|
||||
{ 0, TS, sys_siggetmask, "sgetmask" }, /* 68 */
|
||||
{ 1, TS, sys_sigsetmask, "ssetmask" }, /* 69 */
|
||||
{ 2, 0, sys_setreuid, "setreuid" }, /* 70 */
|
||||
{ 2, 0, sys_setregid, "setregid" }, /* 71 */
|
||||
{ 2, 0, sys_setreuid16, "setreuid" }, /* 70 */
|
||||
{ 2, 0, sys_setregid16, "setregid" }, /* 71 */
|
||||
{ 3, TS, sys_sigsuspend, "sigsuspend" }, /* 72 */
|
||||
{ 1, TS, sys_sigpending, "sigpending" }, /* 73 */
|
||||
{ 2, 0, sys_sethostname, "sethostname" }, /* 74 */
|
||||
@ -121,7 +121,7 @@
|
||||
{ 2, TF, sys_truncate, "truncate" }, /* 92 */
|
||||
{ 2, TD, sys_ftruncate, "ftruncate" }, /* 93 */
|
||||
{ 2, TD, sys_fchmod, "fchmod" }, /* 94 */
|
||||
{ 3, TD, sys_fchown, "fchown" }, /* 95 */
|
||||
{ 3, TD, sys_fchown16, "fchown" }, /* 95 */
|
||||
{ 2, 0, sys_getpriority, "getpriority" }, /* 96 */
|
||||
{ 3, 0, sys_setpriority, "setpriority" }, /* 97 */
|
||||
{ 4, 0, sys_profil, "profil" }, /* 98 */
|
||||
@ -164,8 +164,8 @@
|
||||
{ 3, 0, sys_sysfs, "sysfs" }, /* 135 */
|
||||
{ 1, 0, sys_personality, "personality" }, /* 136 */
|
||||
{ 5, 0, sys_afs_syscall, "afs_syscall" }, /* 137 */
|
||||
{ 1, NF, sys_setfsuid, "setfsuid" }, /* 138 */
|
||||
{ 1, NF, sys_setfsgid, "setfsgid" }, /* 139 */
|
||||
{ 1, NF, sys_setfsuid16, "setfsuid" }, /* 138 */
|
||||
{ 1, NF, sys_setfsgid16, "setfsgid" }, /* 139 */
|
||||
{ 5, TD, sys_llseek, "_llseek" }, /* 140 */
|
||||
{ 3, TD, sys_getdents, "getdents" }, /* 141 */
|
||||
{ 5, TD, sys_select, "select" }, /* 142 */
|
||||
@ -190,14 +190,14 @@
|
||||
{ 2, 0, sys_sched_rr_get_interval,"sched_rr_get_interval"}, /* 161 */
|
||||
{ 2, 0, sys_nanosleep, "nanosleep" }, /* 162 */
|
||||
{ 5, TM|SI, sys_mremap, "mremap" }, /* 163 */
|
||||
{ 3, 0, sys_setresuid, "setresuid" }, /* 164 */
|
||||
{ 3, 0, sys_getresuid, "getresuid" }, /* 165 */
|
||||
{ 3, 0, sys_setresuid16, "setresuid" }, /* 164 */
|
||||
{ 3, 0, sys_getresuid16, "getresuid" }, /* 165 */
|
||||
{ 5, 0, sys_vm86, "vm86" }, /* 166 */
|
||||
{ 5, 0, sys_query_module, "query_module" }, /* 167 */
|
||||
{ 3, TD, sys_poll, "poll" }, /* 168 */
|
||||
{ 3, 0, sys_nfsservctl, "nfsservctl" }, /* 169 */
|
||||
{ 3, 0, sys_setresgid, "setresgid" }, /* 170 */
|
||||
{ 3, 0, sys_getresgid, "getresgid" }, /* 171 */
|
||||
{ 3, 0, sys_setresgid16, "setresgid" }, /* 170 */
|
||||
{ 3, 0, sys_getresgid16, "getresgid" }, /* 171 */
|
||||
{ 5, 0, sys_prctl, "prctl" }, /* 172 */
|
||||
{ 0, TS, sys_rt_sigreturn, "rt_sigreturn" }, /* 173 */
|
||||
{ 4, TS, sys_rt_sigaction, "rt_sigaction" }, /* 174 */
|
||||
@ -209,7 +209,7 @@
|
||||
|
||||
{ 6, TD, sys_pread, "pread" }, /* 180 */
|
||||
{ 6, TD, sys_pwrite, "pwrite" }, /* 181 */
|
||||
{ 3, TF, sys_chown, "chown" }, /* 182 */
|
||||
{ 3, TF, sys_chown16, "chown" }, /* 182 */
|
||||
{ 2, TF, sys_getcwd, "getcwd" }, /* 183 */
|
||||
{ 2, 0, sys_capget, "capget" }, /* 184 */
|
||||
{ 2, 0, sys_capset, "capset" }, /* 185 */
|
||||
|
@ -42,15 +42,15 @@
|
||||
{ 1, 0, sys_time, "time" }, /* 13 */
|
||||
{ 3, TF, sys_mknod, "mknod" }, /* 14 */
|
||||
{ 2, TF, sys_chmod, "chmod" }, /* 15 */
|
||||
{ 3, TF, sys_chown, "chown" }, /* 16 */
|
||||
{ 3, TF, sys_chown16, "chown" }, /* 16 */
|
||||
{ 0, TM, sys_break, "break" }, /* 17 */
|
||||
{ 2, TF, sys_oldstat, "oldstat" }, /* 18 */
|
||||
{ 3, TD, sys_lseek, "lseek" }, /* 19 */
|
||||
{ 0, 0, sys_getpid, "getpid" }, /* 20 */
|
||||
{ 5, TF, sys_mount, "mount" }, /* 21 */
|
||||
{ 1, TF, sys_umount, "oldumount" }, /* 22 */
|
||||
{ 1, 0, sys_setuid, "setuid" }, /* 23 */
|
||||
{ 0, NF, sys_getuid, "getuid" }, /* 24 */
|
||||
{ 1, 0, sys_setuid16, "setuid" }, /* 23 */
|
||||
{ 0, NF, sys_getuid16, "getuid" }, /* 24 */
|
||||
{ 1, 0, sys_stime, "stime" }, /* 25 */
|
||||
{ 4, 0, sys_ptrace, "ptrace" }, /* 26 */
|
||||
{ 1, 0, sys_alarm, "alarm" }, /* 27 */
|
||||
@ -72,11 +72,11 @@
|
||||
{ 1, 0, sys_times, "times" }, /* 43 */
|
||||
{ 0, 0, sys_prof, "prof" }, /* 44 */
|
||||
{ 1, TM|SI, sys_brk, "brk" }, /* 45 */
|
||||
{ 1, 0, sys_setgid, "setgid" }, /* 46 */
|
||||
{ 0, NF, sys_getgid, "getgid" }, /* 47 */
|
||||
{ 1, 0, sys_setgid16, "setgid" }, /* 46 */
|
||||
{ 0, NF, sys_getgid16, "getgid" }, /* 47 */
|
||||
{ 3, TS, sys_signal, "signal" }, /* 48 */
|
||||
{ 0, NF, sys_geteuid, "geteuid" }, /* 49 */
|
||||
{ 0, NF, sys_getegid, "getegid" }, /* 50 */
|
||||
{ 0, NF, sys_geteuid16, "geteuid" }, /* 49 */
|
||||
{ 0, NF, sys_getegid16, "getegid" }, /* 50 */
|
||||
{ 1, TF, sys_acct, "acct" }, /* 51 */
|
||||
{ 2, TF, sys_umount2, "umount" }, /* 52 */
|
||||
{ 0, 0, sys_lock, "lock" }, /* 53 */
|
||||
@ -96,8 +96,8 @@
|
||||
{ 3, TS, sys_sigaction, "sigaction" }, /* 67 */
|
||||
{ 0, TS, sys_siggetmask, "sgetmask" }, /* 68 */
|
||||
{ 1, TS, sys_sigsetmask, "ssetmask" }, /* 69 */
|
||||
{ 2, 0, sys_setreuid, "setreuid" }, /* 70 */
|
||||
{ 2, 0, sys_setregid, "setregid" }, /* 71 */
|
||||
{ 2, 0, sys_setreuid16, "setreuid" }, /* 70 */
|
||||
{ 2, 0, sys_setregid16, "setregid" }, /* 71 */
|
||||
{ 3, TS, sys_sigsuspend, "sigsuspend" }, /* 72 */
|
||||
{ 1, TS, sys_sigpending, "sigpending" }, /* 73 */
|
||||
{ 2, 0, sys_sethostname, "sethostname" }, /* 74 */
|
||||
@ -121,7 +121,7 @@
|
||||
{ 2, TF, sys_truncate, "truncate" }, /* 92 */
|
||||
{ 2, TD, sys_ftruncate, "ftruncate" }, /* 93 */
|
||||
{ 2, TD, sys_fchmod, "fchmod" }, /* 94 */
|
||||
{ 3, TD, sys_fchown, "fchown" }, /* 95 */
|
||||
{ 3, TD, sys_fchown16, "fchown" }, /* 95 */
|
||||
{ 2, 0, sys_getpriority, "getpriority" }, /* 96 */
|
||||
{ 3, 0, sys_setpriority, "setpriority" }, /* 97 */
|
||||
{ 4, 0, sys_profil, "profil" }, /* 98 */
|
||||
@ -164,8 +164,8 @@
|
||||
{ 3, 0, sys_sysfs, "sysfs" }, /* 135 */
|
||||
{ 1, 0, sys_personality, "personality" }, /* 136 */
|
||||
{ 5, 0, sys_afs_syscall, "afs_syscall" }, /* 137 */
|
||||
{ 1, NF, sys_setfsuid, "setfsuid" }, /* 138 */
|
||||
{ 1, NF, sys_setfsgid, "setfsgid" }, /* 139 */
|
||||
{ 1, NF, sys_setfsuid16, "setfsuid" }, /* 138 */
|
||||
{ 1, NF, sys_setfsgid16, "setfsgid" }, /* 139 */
|
||||
{ 5, TD, sys_llseek, "_llseek" }, /* 140 */
|
||||
{ 3, TD, sys_getdents, "getdents" }, /* 141 */
|
||||
{ 5, TD, sys_select, "select" }, /* 142 */
|
||||
@ -190,14 +190,14 @@
|
||||
{ 2, 0, sys_sched_rr_get_interval, "sched_rr_get_interval" }, /* 161 */
|
||||
{ 2, 0, sys_nanosleep, "nanosleep" }, /* 162 */
|
||||
{ 5, TM|SI, sys_mremap, "mremap" }, /* 163 */
|
||||
{ 3, 0, sys_setresuid, "setresuid" }, /* 164 */
|
||||
{ 3, 0, sys_getresuid, "getresuid" }, /* 165 */
|
||||
{ 3, 0, sys_setresuid16, "setresuid" }, /* 164 */
|
||||
{ 3, 0, sys_getresuid16, "getresuid" }, /* 165 */
|
||||
{ 5, 0, sys_vm86, "vm86" }, /* 166 */
|
||||
{ 5, 0, sys_query_module, "query_module" }, /* 167 */
|
||||
{ 3, TD, sys_poll, "poll" }, /* 168 */
|
||||
{ 3, 0, sys_nfsservctl, "nfsservctl" }, /* 169 */
|
||||
{ 3, 0, sys_setresgid, "setresgid" }, /* 170 */
|
||||
{ 3, 0, sys_getresgid, "getresgid" }, /* 171 */
|
||||
{ 3, 0, sys_setresgid16, "setresgid" }, /* 170 */
|
||||
{ 3, 0, sys_getresgid16, "getresgid" }, /* 171 */
|
||||
{ 5, 0, sys_prctl, "prctl" }, /* 172 */
|
||||
{ 0, TS, sys_rt_sigreturn, "rt_sigreturn" }, /* 173 */
|
||||
{ 4, TS, sys_rt_sigaction, "rt_sigaction" }, /* 174 */
|
||||
@ -208,7 +208,7 @@
|
||||
{ 2, TS, sys_rt_sigsuspend, "rt_sigsuspend" }, /* 179 */
|
||||
{ 5, TD, sys_pread, "pread" }, /* 180 */
|
||||
{ 5, TD, sys_pwrite, "pwrite" }, /* 181 */
|
||||
{ 3, TF, sys_chown, "lchown" }, /* 182 */
|
||||
{ 3, TF, sys_chown16, "lchown" }, /* 182 */
|
||||
{ 2, TF, sys_getcwd, "getcwd" }, /* 183 */
|
||||
{ 2, 0, sys_capget, "capget" }, /* 184 */
|
||||
{ 2, 0, sys_capset, "capset" }, /* 185 */
|
||||
|
@ -63,10 +63,14 @@
|
||||
#define sys_fdatasync sys_close
|
||||
#define sys_fsync sys_close
|
||||
#define sys_getegid sys_getuid
|
||||
#define sys_getegid16 sys_geteuid16
|
||||
#define sys_geteuid sys_getuid
|
||||
#define sys_geteuid16 sys_getuid16
|
||||
#define sys_getgid sys_getuid
|
||||
#define sys_getgid16 sys_getuid16
|
||||
#define sys_getpeername sys_getsockname
|
||||
#define sys_getresgid sys_getresuid
|
||||
#define sys_getresgid16 sys_getresuid16
|
||||
#define sys_lstat sys_stat
|
||||
#define sys_lstat64 sys_stat64
|
||||
#define sys_mkdir sys_chmod
|
||||
@ -82,9 +86,13 @@
|
||||
#define sys_set_robust_list sys_munmap
|
||||
#define sys_setdomainname sys_sethostname
|
||||
#define sys_setfsgid sys_setfsuid
|
||||
#define sys_setfsgid16 sys_setfsuid16
|
||||
#define sys_setgid sys_setuid
|
||||
#define sys_setgid16 sys_setuid16
|
||||
#define sys_setregid sys_setreuid
|
||||
#define sys_setregid16 sys_setreuid16
|
||||
#define sys_setresgid sys_setresuid
|
||||
#define sys_setresgid16 sys_setresuid16
|
||||
#define sys_stime sys_time
|
||||
#define sys_swapoff sys_chdir
|
||||
#define sys_symlink sys_link
|
||||
|
@ -42,15 +42,15 @@
|
||||
{ 1, 0, sys_time, "time" }, /* 13 */
|
||||
{ 3, TF, sys_mknod, "mknod" }, /* 14 */
|
||||
{ 2, TF, sys_chmod, "chmod" }, /* 15 */
|
||||
{ 3, TF, sys_chown, "lchown" }, /* 16 */
|
||||
{ 3, TF, sys_chown16, "lchown" }, /* 16 */
|
||||
{ 0, TM, sys_break, "break" }, /* 17 */
|
||||
{ 2, TF, sys_oldstat, "oldstat" }, /* 18 */
|
||||
{ 3, TD, sys_lseek, "lseek" }, /* 19 */
|
||||
{ 0, 0, sys_getpid, "getpid" }, /* 20 */
|
||||
{ 5, TF, sys_mount, "mount" }, /* 21 */
|
||||
{ 1, TF, sys_umount, "oldumount" }, /* 22 */
|
||||
{ 1, 0, sys_setuid, "setuid" }, /* 23 */
|
||||
{ 0, NF, sys_getuid, "getuid" }, /* 24 */
|
||||
{ 1, 0, sys_setuid16, "setuid" }, /* 23 */
|
||||
{ 0, NF, sys_getuid16, "getuid" }, /* 24 */
|
||||
{ 1, 0, sys_stime, "stime" }, /* 25 */
|
||||
{ 4, 0, sys_ptrace, "ptrace" }, /* 26 */
|
||||
{ 1, 0, sys_alarm, "alarm" }, /* 27 */
|
||||
@ -72,11 +72,11 @@
|
||||
{ 1, 0, sys_times, "times" }, /* 43 */
|
||||
{ 0, 0, sys_prof, "prof" }, /* 44 */
|
||||
{ 1, TM|SI, sys_brk, "brk" }, /* 45 */
|
||||
{ 1, 0, sys_setgid, "setgid" }, /* 46 */
|
||||
{ 0, NF, sys_getgid, "getgid" }, /* 47 */
|
||||
{ 1, 0, sys_setgid16, "setgid" }, /* 46 */
|
||||
{ 0, NF, sys_getgid16, "getgid" }, /* 47 */
|
||||
{ 3, TS, sys_signal, "signal" }, /* 48 */
|
||||
{ 0, NF, sys_geteuid, "geteuid" }, /* 49 */
|
||||
{ 0, NF, sys_getegid, "getegid" }, /* 50 */
|
||||
{ 0, NF, sys_geteuid16, "geteuid" }, /* 49 */
|
||||
{ 0, NF, sys_getegid16, "getegid" }, /* 50 */
|
||||
{ 1, TF, sys_acct, "acct" }, /* 51 */
|
||||
{ 2, TF, sys_umount2, "umount" }, /* 52 */
|
||||
{ 0, 0, sys_lock, "lock" }, /* 53 */
|
||||
@ -96,8 +96,8 @@
|
||||
{ 3, TS, sys_sigaction, "sigaction" }, /* 67 */
|
||||
{ 0, TS, sys_siggetmask, "sgetmask" }, /* 68 */
|
||||
{ 1, TS, sys_sigsetmask, "ssetmask" }, /* 69 */
|
||||
{ 2, 0, sys_setreuid, "setreuid" }, /* 70 */
|
||||
{ 2, 0, sys_setregid, "setregid" }, /* 71 */
|
||||
{ 2, 0, sys_setreuid16, "setreuid" }, /* 70 */
|
||||
{ 2, 0, sys_setregid16, "setregid" }, /* 71 */
|
||||
{ 3, TS, sys_sigsuspend, "sigsuspend" }, /* 72 */
|
||||
{ 1, TS, sys_sigpending, "sigpending" }, /* 73 */
|
||||
{ 2, 0, sys_sethostname, "sethostname" }, /* 74 */
|
||||
@ -121,7 +121,7 @@
|
||||
{ 2, TF, sys_truncate, "truncate" }, /* 92 */
|
||||
{ 2, TD, sys_ftruncate, "ftruncate" }, /* 93 */
|
||||
{ 2, TD, sys_fchmod, "fchmod" }, /* 94 */
|
||||
{ 3, TD, sys_fchown, "fchown" }, /* 95 */
|
||||
{ 3, TD, sys_fchown16, "fchown" }, /* 95 */
|
||||
{ 2, 0, sys_getpriority, "getpriority" }, /* 96 */
|
||||
{ 3, 0, sys_setpriority, "setpriority" }, /* 97 */
|
||||
{ 4, 0, sys_profil, "profil" }, /* 98 */
|
||||
@ -164,8 +164,8 @@
|
||||
{ 3, 0, sys_sysfs, "sysfs" }, /* 135 */
|
||||
{ 1, 0, sys_personality, "personality" }, /* 136 */
|
||||
{ 5, 0, sys_afs_syscall, "afs_syscall" }, /* 137 */
|
||||
{ 1, NF, sys_setfsuid, "setfsuid" }, /* 138 */
|
||||
{ 1, NF, sys_setfsgid, "setfsgid" }, /* 139 */
|
||||
{ 1, NF, sys_setfsuid16, "setfsuid" }, /* 138 */
|
||||
{ 1, NF, sys_setfsgid16, "setfsgid" }, /* 139 */
|
||||
{ 5, TD, sys_llseek, "_llseek" }, /* 140 */
|
||||
{ 3, TD, sys_getdents, "getdents" }, /* 141 */
|
||||
{ 5, TD, sys_select, "select" }, /* 142 */
|
||||
@ -190,14 +190,14 @@
|
||||
{ 2, 0, sys_sched_rr_get_interval,"sched_rr_get_interval"}, /* 161 */
|
||||
{ 2, 0, sys_nanosleep, "nanosleep" }, /* 162 */
|
||||
{ 5, TM|SI, sys_mremap, "mremap" }, /* 163 */
|
||||
{ 3, 0, sys_setresuid, "setresuid" }, /* 164 */
|
||||
{ 3, 0, sys_getresuid, "getresuid" }, /* 165 */
|
||||
{ 3, 0, sys_setresuid16, "setresuid" }, /* 164 */
|
||||
{ 3, 0, sys_getresuid16, "getresuid" }, /* 165 */
|
||||
{ 5, 0, sys_vm86, "vm86" }, /* 166 */
|
||||
{ 5, 0, sys_query_module, "query_module" }, /* 167 */
|
||||
{ 3, TD, sys_poll, "poll" }, /* 168 */
|
||||
{ 3, 0, sys_nfsservctl, "nfsservctl" }, /* 169 */
|
||||
{ 3, 0, sys_setresgid, "setresgid" }, /* 170 */
|
||||
{ 3, 0, sys_getresgid, "getresgid" }, /* 171 */
|
||||
{ 3, 0, sys_setresgid16, "setresgid" }, /* 170 */
|
||||
{ 3, 0, sys_getresgid16, "getresgid" }, /* 171 */
|
||||
{ 5, 0, sys_prctl, "prctl" }, /* 172 */
|
||||
{ 0, TS, sys_rt_sigreturn, "rt_sigreturn" }, /* 173 */
|
||||
{ 4, TS, sys_rt_sigaction, "rt_sigaction" }, /* 174 */
|
||||
@ -209,7 +209,7 @@
|
||||
|
||||
{ 5, TD, sys_pread, "pread64" }, /* 180 */
|
||||
{ 5, TD, sys_pwrite, "pwrite64" }, /* 181 */
|
||||
{ 3, TF, sys_chown, "chown" }, /* 182 */
|
||||
{ 3, TF, sys_chown16, "chown" }, /* 182 */
|
||||
{ 2, TF, sys_getcwd, "getcwd" }, /* 183 */
|
||||
{ 2, 0, sys_capget, "capget" }, /* 184 */
|
||||
{ 2, 0, sys_capset, "capset" }, /* 185 */
|
||||
|
@ -42,15 +42,15 @@
|
||||
{ 1, 0, sys_time, "time" }, /* 13 */
|
||||
{ 3, TF, sys_mknod, "mknod" }, /* 14 */
|
||||
{ 2, TF, sys_chmod, "chmod" }, /* 15 */
|
||||
{ 3, TF, sys_chown, "chown" }, /* 16 */
|
||||
{ 3, TF, sys_chown16, "chown" }, /* 16 */
|
||||
{ 0, TM, sys_break, "break" }, /* 17 */
|
||||
{ 2, TF, sys_oldstat, "oldstat" }, /* 18 */
|
||||
{ 3, TD, sys_lseek, "lseek" }, /* 19 */
|
||||
{ 0, 0, sys_getpid, "getpid" }, /* 20 */
|
||||
{ 5, TF, sys_mount, "mount" }, /* 21 */
|
||||
{ 1, TF, sys_umount, "oldumount" }, /* 22 */
|
||||
{ 1, 0, sys_setuid, "setuid" }, /* 23 */
|
||||
{ 0, NF, sys_getuid, "getuid" }, /* 24 */
|
||||
{ 1, 0, sys_setuid16, "setuid" }, /* 23 */
|
||||
{ 0, NF, sys_getuid16, "getuid" }, /* 24 */
|
||||
{ 1, 0, sys_stime, "stime" }, /* 25 */
|
||||
{ 4, 0, sys_ptrace, "ptrace" }, /* 26 */
|
||||
{ 1, 0, sys_alarm, "alarm" }, /* 27 */
|
||||
@ -72,11 +72,11 @@
|
||||
{ 1, 0, sys_times, "times" }, /* 43 */
|
||||
{ 0, 0, sys_prof, "prof" }, /* 44 */
|
||||
{ 1, TM|SI, sys_brk, "brk" }, /* 45 */
|
||||
{ 1, 0, sys_setgid, "setgid" }, /* 46 */
|
||||
{ 0, NF, sys_getgid, "getgid" }, /* 47 */
|
||||
{ 1, 0, sys_setgid16, "setgid" }, /* 46 */
|
||||
{ 0, NF, sys_getgid16, "getgid" }, /* 47 */
|
||||
{ 3, TS, sys_signal, "signal" }, /* 48 */
|
||||
{ 0, NF, sys_geteuid, "geteuid" }, /* 49 */
|
||||
{ 0, NF, sys_getegid, "getegid" }, /* 50 */
|
||||
{ 0, NF, sys_geteuid16, "geteuid" }, /* 49 */
|
||||
{ 0, NF, sys_getegid16, "getegid" }, /* 50 */
|
||||
{ 1, TF, sys_acct, "acct" }, /* 51 */
|
||||
{ 2, TF, sys_umount2, "umount" }, /* 52 */
|
||||
{ 0, 0, sys_lock, "lock" }, /* 53 */
|
||||
@ -96,8 +96,8 @@
|
||||
{ 3, TS, sys_sigaction, "sigaction" }, /* 67 */
|
||||
{ 0, TS, sys_siggetmask, "sgetmask" }, /* 68 */
|
||||
{ 1, TS, sys_sigsetmask, "ssetmask" }, /* 69 */
|
||||
{ 2, 0, sys_setreuid, "setreuid" }, /* 70 */
|
||||
{ 2, 0, sys_setregid, "setregid" }, /* 71 */
|
||||
{ 2, 0, sys_setreuid16, "setreuid" }, /* 70 */
|
||||
{ 2, 0, sys_setregid16, "setregid" }, /* 71 */
|
||||
{ 3, TS, sys_sigsuspend, "sigsuspend" }, /* 72 */
|
||||
{ 1, TS, sys_sigpending, "sigpending" }, /* 73 */
|
||||
{ 2, 0, sys_sethostname, "sethostname" }, /* 74 */
|
||||
@ -121,7 +121,7 @@
|
||||
{ 2, TF, sys_truncate, "truncate" }, /* 92 */
|
||||
{ 2, TD, sys_ftruncate, "ftruncate" }, /* 93 */
|
||||
{ 2, TD, sys_fchmod, "fchmod" }, /* 94 */
|
||||
{ 3, TD, sys_fchown, "fchown" }, /* 95 */
|
||||
{ 3, TD, sys_fchown16, "fchown" }, /* 95 */
|
||||
{ 2, 0, sys_getpriority, "getpriority" }, /* 96 */
|
||||
{ 3, 0, sys_setpriority, "setpriority" }, /* 97 */
|
||||
{ 4, 0, sys_profil, "profil" }, /* 98 */
|
||||
@ -164,8 +164,8 @@
|
||||
{ 3, 0, sys_sysfs, "sysfs" }, /* 135 */
|
||||
{ 1, 0, sys_personality, "personality" }, /* 136 */
|
||||
{ 5, 0, sys_afs_syscall, "afs_syscall" }, /* 137 */
|
||||
{ 1, NF, sys_setfsuid, "setfsuid" }, /* 138 */
|
||||
{ 1, NF, sys_setfsgid, "setfsgid" }, /* 139 */
|
||||
{ 1, NF, sys_setfsuid16, "setfsuid" }, /* 138 */
|
||||
{ 1, NF, sys_setfsgid16, "setfsgid" }, /* 139 */
|
||||
{ 5, TD, sys_llseek, "_llseek" }, /* 140 */
|
||||
{ 3, TD, sys_getdents, "getdents" }, /* 141 */
|
||||
{ 5, TD, sys_select, "select" }, /* 142 */
|
||||
@ -190,14 +190,14 @@
|
||||
{ 2, 0, sys_sched_rr_get_interval,"sched_rr_get_interval"}, /* 161 */
|
||||
{ 2, 0, sys_nanosleep, "nanosleep" }, /* 162 */
|
||||
{ 5, TM|SI, sys_mremap, "mremap" }, /* 163 */
|
||||
{ 3, 0, sys_setresuid, "setresuid" }, /* 164 */
|
||||
{ 3, 0, sys_getresuid, "getresuid" }, /* 165 */
|
||||
{ 3, 0, sys_setresuid16, "setresuid" }, /* 164 */
|
||||
{ 3, 0, sys_getresuid16, "getresuid" }, /* 165 */
|
||||
{ 5, 0, printargs, "getpagesize" }, /* 166 */
|
||||
{ 5, 0, sys_query_module, "query_module" }, /* 167 */
|
||||
{ 3, TD, sys_poll, "poll" }, /* 168 */
|
||||
{ 3, 0, sys_nfsservctl, "nfsservctl" }, /* 169 */
|
||||
{ 3, 0, sys_setresgid, "setresgid" }, /* 170 */
|
||||
{ 3, 0, sys_getresgid, "getresgid" }, /* 171 */
|
||||
{ 3, 0, sys_setresgid16, "setresgid" }, /* 170 */
|
||||
{ 3, 0, sys_getresgid16, "getresgid" }, /* 171 */
|
||||
{ 5, 0, sys_prctl, "prctl" }, /* 172 */
|
||||
{ 0, TS, sys_rt_sigreturn, "rt_sigreturn" }, /* 173 */
|
||||
{ 4, TS, sys_rt_sigaction, "rt_sigaction" }, /* 174 */
|
||||
@ -208,7 +208,7 @@
|
||||
{ 2, TS, sys_rt_sigsuspend, "rt_sigsuspend" }, /* 179 */
|
||||
{ 5, TD, sys_pread, "pread64" }, /* 180 */
|
||||
{ 5, TD, sys_pwrite, "pwrite64" }, /* 181 */
|
||||
{ 3, TF, sys_chown, "lchown" }, /* 182 */
|
||||
{ 3, TF, sys_chown16, "lchown" }, /* 182 */
|
||||
{ 2, TF, sys_getcwd, "getcwd" }, /* 183 */
|
||||
{ 2, 0, sys_capget, "capget" }, /* 184 */
|
||||
{ 2, 0, sys_capset, "capset" }, /* 185 */
|
||||
|
@ -42,15 +42,15 @@
|
||||
{ 1, 0, sys_time, "time" }, /* 13 */
|
||||
{ 3, TF, sys_mknod, "mknod" }, /* 14 */
|
||||
{ 2, TF, sys_chmod, "chmod" }, /* 15 */
|
||||
{ 3, TF, sys_chown, "lchown" }, /* 16 */
|
||||
{ 3, TF, sys_chown16, "lchown" }, /* 16 */
|
||||
{ 0, TM, sys_break, "break" }, /* 17 */
|
||||
{ 2, TF, sys_oldstat, "oldstat" }, /* 18 */
|
||||
{ 3, TD, sys_lseek, "lseek" }, /* 19 */
|
||||
{ 0, 0, sys_getpid, "getpid" }, /* 20 */
|
||||
{ 5, TF, sys_mount, "mount" }, /* 21 */
|
||||
{ 1, TF, sys_umount, "oldumount" }, /* 22 */
|
||||
{ 1, 0, sys_setuid, "setuid" }, /* 23 */
|
||||
{ 0, NF, sys_getuid, "getuid" }, /* 24 */
|
||||
{ 1, 0, sys_setuid16, "setuid" }, /* 23 */
|
||||
{ 0, NF, sys_getuid16, "getuid" }, /* 24 */
|
||||
{ 1, 0, sys_stime, "stime" }, /* 25 */
|
||||
{ 4, 0, sys_ptrace, "ptrace" }, /* 26 */
|
||||
{ 1, 0, sys_alarm, "alarm" }, /* 27 */
|
||||
@ -72,11 +72,11 @@
|
||||
{ 1, 0, sys_times, "times" }, /* 43 */
|
||||
{ 0, 0, sys_prof, "prof" }, /* 44 */
|
||||
{ 1, TM|SI, sys_brk, "brk" }, /* 45 */
|
||||
{ 1, 0, sys_setgid, "setgid" }, /* 46 */
|
||||
{ 0, NF, sys_getgid, "getgid" }, /* 47 */
|
||||
{ 1, 0, sys_setgid16, "setgid" }, /* 46 */
|
||||
{ 0, NF, sys_getgid16, "getgid" }, /* 47 */
|
||||
{ 3, TS, sys_signal, "signal" }, /* 48 */
|
||||
{ 0, NF, sys_geteuid, "geteuid" }, /* 49 */
|
||||
{ 0, NF, sys_getegid, "getegid" }, /* 50 */
|
||||
{ 0, NF, sys_geteuid16, "geteuid" }, /* 49 */
|
||||
{ 0, NF, sys_getegid16, "getegid" }, /* 50 */
|
||||
{ 1, TF, sys_acct, "acct" }, /* 51 */
|
||||
{ 2, TF, sys_umount2, "umount" }, /* 52 */
|
||||
{ 0, 0, sys_lock, "lock" }, /* 53 */
|
||||
@ -96,8 +96,8 @@
|
||||
{ 3, TS, sys_sigaction, "sigaction" }, /* 67 */
|
||||
{ 0, TS, sys_siggetmask, "sgetmask" }, /* 68 */
|
||||
{ 1, TS, sys_sigsetmask, "ssetmask" }, /* 69 */
|
||||
{ 2, 0, sys_setreuid, "setreuid" }, /* 70 */
|
||||
{ 2, 0, sys_setregid, "setregid" }, /* 71 */
|
||||
{ 2, 0, sys_setreuid16, "setreuid" }, /* 70 */
|
||||
{ 2, 0, sys_setregid16, "setregid" }, /* 71 */
|
||||
{ 3, TS, sys_sigsuspend, "sigsuspend" }, /* 72 */
|
||||
{ 1, TS, sys_sigpending, "sigpending" }, /* 73 */
|
||||
{ 2, 0, sys_sethostname, "sethostname" }, /* 74 */
|
||||
@ -121,7 +121,7 @@
|
||||
{ 2, TF, sys_truncate, "truncate" }, /* 92 */
|
||||
{ 2, TD, sys_ftruncate, "ftruncate" }, /* 93 */
|
||||
{ 2, TD, sys_fchmod, "fchmod" }, /* 94 */
|
||||
{ 3, TD, sys_fchown, "fchown" }, /* 95 */
|
||||
{ 3, TD, sys_fchown16, "fchown" }, /* 95 */
|
||||
{ 2, 0, sys_getpriority, "getpriority" }, /* 96 */
|
||||
{ 3, 0, sys_setpriority, "setpriority" }, /* 97 */
|
||||
{ 4, 0, sys_profil, "profil" }, /* 98 */
|
||||
@ -164,8 +164,8 @@
|
||||
{ 3, 0, sys_sysfs, "sysfs" }, /* 135 */
|
||||
{ 1, 0, sys_personality, "personality" }, /* 136 */
|
||||
{ 5, 0, sys_afs_syscall, "afs_syscall" }, /* 137 */
|
||||
{ 1, NF, sys_setfsuid, "setfsuid" }, /* 138 */
|
||||
{ 1, NF, sys_setfsgid, "setfsgid" }, /* 139 */
|
||||
{ 1, NF, sys_setfsuid16, "setfsuid" }, /* 138 */
|
||||
{ 1, NF, sys_setfsgid16, "setfsgid" }, /* 139 */
|
||||
{ 5, TD, sys_llseek, "_llseek" }, /* 140 */
|
||||
{ 3, TD, sys_getdents, "getdents" }, /* 141 */
|
||||
{ 5, TD, sys_select, "select" }, /* 142 */
|
||||
@ -190,14 +190,14 @@
|
||||
{ 2, 0, sys_sched_rr_get_interval,"sched_rr_get_interval"}, /* 161 */
|
||||
{ 2, 0, sys_nanosleep, "nanosleep" }, /* 162 */
|
||||
{ 5, TM|SI, sys_mremap, "mremap" }, /* 163 */
|
||||
{ 3, 0, sys_setresuid, "setresuid" }, /* 164 */
|
||||
{ 3, 0, sys_getresuid, "getresuid" }, /* 165 */
|
||||
{ 3, 0, sys_setresuid16, "setresuid" }, /* 164 */
|
||||
{ 3, 0, sys_getresuid16, "getresuid" }, /* 165 */
|
||||
{ 5, 0, sys_vm86, "vm86" }, /* 166 */
|
||||
{ 5, 0, sys_query_module, "query_module" }, /* 167 */
|
||||
{ 3, TD, sys_poll, "poll" }, /* 168 */
|
||||
{ 3, 0, sys_nfsservctl, "nfsservctl" }, /* 169 */
|
||||
{ 3, 0, sys_setresgid, "setresgid" }, /* 170 */
|
||||
{ 3, 0, sys_getresgid, "getresgid" }, /* 171 */
|
||||
{ 3, 0, sys_setresgid16, "setresgid" }, /* 170 */
|
||||
{ 3, 0, sys_getresgid16, "getresgid" }, /* 171 */
|
||||
{ 5, 0, sys_prctl, "prctl" }, /* 172 */
|
||||
{ 0, TS, sys_rt_sigreturn, "rt_sigreturn" }, /* 173 */
|
||||
{ 4, TS, sys_rt_sigaction, "rt_sigaction" }, /* 174 */
|
||||
@ -208,7 +208,7 @@
|
||||
{ 2, TS, sys_rt_sigsuspend, "rt_sigsuspend" }, /* 179 */
|
||||
{ 5, TD, sys_pread, "pread64" }, /* 180 */
|
||||
{ 5, TD, sys_pwrite, "pwrite64" }, /* 181 */
|
||||
{ 3, TF, sys_chown, "chown" }, /* 182 */
|
||||
{ 3, TF, sys_chown16, "chown" }, /* 182 */
|
||||
{ 2, TF, sys_getcwd, "getcwd" }, /* 183 */
|
||||
{ 2, 0, sys_capget, "capget" }, /* 184 */
|
||||
{ 2, 0, sys_capset, "capset" }, /* 185 */
|
||||
|
@ -44,15 +44,15 @@
|
||||
{ 1, 0, sys_time, "time" }, /* 13 */
|
||||
{ 3, TF, sys_mknod, "mknod" }, /* 14 */
|
||||
{ 2, TF, sys_chmod, "chmod" }, /* 15 */
|
||||
{ 3, TF, sys_chown, "lchown" }, /* 16 */
|
||||
{ 3, TF, sys_chown16, "lchown" }, /* 16 */
|
||||
{ MA, 0, NULL, NULL }, /* 17 */
|
||||
{ MA, 0, NULL, NULL }, /* 18 */
|
||||
{ 3, TD, sys_lseek, "lseek" }, /* 19 */
|
||||
{ 0, 0, sys_getpid, "getpid" }, /* 20 */
|
||||
{ 5, TF, sys_mount, "mount" }, /* 21 */
|
||||
{ 1, TF, sys_umount, "oldumount" }, /* 22 */
|
||||
{ 1, 0, sys_setuid, "setuid" }, /* 23 */
|
||||
{ 0, NF, sys_getuid, "getuid" }, /* 24 */
|
||||
{ 1, 0, sys_setuid16, "setuid" }, /* 23 */
|
||||
{ 0, NF, sys_getuid16, "getuid" }, /* 24 */
|
||||
{ 1, 0, sys_stime, "stime" }, /* 25 */
|
||||
{ 4, 0, sys_ptrace, "ptrace" }, /* 26 */
|
||||
{ 1, 0, sys_alarm, "alarm" }, /* 27 */
|
||||
@ -74,11 +74,11 @@
|
||||
{ 1, 0, sys_times, "times" }, /* 43 */
|
||||
{ MA, 0, NULL, NULL }, /* 44 */
|
||||
{ 1, TM|SI, sys_brk, "brk" }, /* 45 */
|
||||
{ MA, 0, NULL, NULL }, /* 46 */
|
||||
{ MA, 0, NULL, NULL }, /* 47 */
|
||||
{ 1, 0, sys_setgid16, "setgid" }, /* 46 */
|
||||
{ 0, NF, sys_getgid16, "getgid" }, /* 47 */
|
||||
{ 3, TS, sys_signal, "signal" }, /* 48 */
|
||||
{ 0, NF, sys_geteuid, "geteuid" }, /* 49 */
|
||||
{ 0, NF, sys_getegid, "getegid" }, /* 50 */
|
||||
{ 0, NF, sys_geteuid16, "geteuid" }, /* 49 */
|
||||
{ 0, NF, sys_getegid16, "getegid" }, /* 50 */
|
||||
{ 1, TF, sys_acct, "acct" }, /* 51 */
|
||||
{ 2, TF, sys_umount2, "umount" }, /* 52 */
|
||||
{ MA, 0, NULL, NULL }, /* 53 */
|
||||
@ -98,8 +98,8 @@
|
||||
{ 3, TS, sys_sigaction, "sigaction" }, /* 67 */
|
||||
{ MA, 0, NULL, NULL }, /* 68 */
|
||||
{ MA, 0, NULL, NULL }, /* 69 */
|
||||
{ 2, 0, sys_setreuid, "setreuid" }, /* 70 */
|
||||
{ 2, 0, sys_setregid, "setregid" }, /* 71 */
|
||||
{ 2, 0, sys_setreuid16, "setreuid" }, /* 70 */
|
||||
{ 2, 0, sys_setregid16, "setregid" }, /* 71 */
|
||||
{ 3, TS, sys_sigsuspend, "sigsuspend" }, /* 72 */
|
||||
{ 1, TS, sys_sigpending, "sigpending" }, /* 73 */
|
||||
{ 2, 0, sys_sethostname, "sethostname" }, /* 74 */
|
||||
@ -123,7 +123,7 @@
|
||||
{ 2, TF, sys_truncate, "truncate" }, /* 92 */
|
||||
{ 2, TD, sys_ftruncate, "ftruncate" }, /* 93 */
|
||||
{ 2, TD, sys_fchmod, "fchmod" }, /* 94 */
|
||||
{ 3, TD, sys_fchown, "fchown" }, /* 95 */
|
||||
{ 3, TD, sys_fchown16, "fchown" }, /* 95 */
|
||||
{ 2, 0, sys_getpriority, "getpriority" }, /* 96 */
|
||||
{ 3, 0, sys_setpriority, "setpriority" }, /* 97 */
|
||||
{ MA, 0, NULL, NULL }, /* 98 */
|
||||
@ -166,8 +166,8 @@
|
||||
{ 3, 0, sys_sysfs, "sysfs" }, /* 135 */
|
||||
{ 1, 0, sys_personality, "personality" }, /* 136 */
|
||||
{ 5, 0, sys_afs_syscall, "afs_syscall" }, /* 137 */
|
||||
{ 1, NF, sys_setfsuid, "setfsuid" }, /* 138 */
|
||||
{ 1, NF, sys_setfsgid, "setfsgid" }, /* 139 */
|
||||
{ 1, NF, sys_setfsuid16, "setfsuid" }, /* 138 */
|
||||
{ 1, NF, sys_setfsgid16, "setfsgid" }, /* 139 */
|
||||
{ 5, TD, sys_llseek, "_llseek" }, /* 140 */
|
||||
{ 3, TD, sys_getdents, "getdents" }, /* 141 */
|
||||
{ 5, TD, sys_select, "select" }, /* 142 */
|
||||
@ -192,14 +192,14 @@
|
||||
{ 2, 0, sys_sched_rr_get_interval,"sched_rr_get_interval"}, /* 161 */
|
||||
{ 2, 0, sys_nanosleep, "nanosleep" }, /* 162 */
|
||||
{ 5, TM|SI, sys_mremap, "mremap" }, /* 163 */
|
||||
{ 3, 0, sys_setresuid, "setresuid" }, /* 164 */
|
||||
{ 3, 0, sys_getresuid, "getresuid" }, /* 165 */
|
||||
{ 3, 0, sys_setresuid16, "setresuid" }, /* 164 */
|
||||
{ 3, 0, sys_getresuid16, "getresuid" }, /* 165 */
|
||||
{ MA, 0, NULL, NULL }, /* 166 */
|
||||
{ 5, 0, sys_query_module, "query_module" }, /* 167 */
|
||||
{ 3, TD, sys_poll, "poll" }, /* 168 */
|
||||
{ 3, 0, sys_nfsservctl, "nfsservctl" }, /* 169 */
|
||||
{ 3, 0, sys_setresgid, "setresgid" }, /* 170 */
|
||||
{ 3, 0, sys_getresgid, "getresgid" }, /* 171 */
|
||||
{ 3, 0, sys_setresgid16, "setresgid" }, /* 170 */
|
||||
{ 3, 0, sys_getresgid16, "getresgid" }, /* 171 */
|
||||
{ 5, 0, sys_prctl, "prctl" }, /* 172 */
|
||||
{ 0, TS, sys_sigreturn, "rt_sigreturn" }, /* 173 */
|
||||
{ 4, TS, sys_rt_sigaction, "rt_sigaction" }, /* 174 */
|
||||
@ -210,7 +210,7 @@
|
||||
{ 2, TS, sys_rt_sigsuspend, "rt_sigsuspend" }, /* 179 */
|
||||
{ 5, TD, sys_pread, "pread" }, /* 180 */
|
||||
{ 5, TD, sys_pwrite, "pwrite" }, /* 181 */
|
||||
{ 3, TF, sys_chown, "lchown" }, /* 182 */
|
||||
{ 3, TF, sys_chown16, "chown" }, /* 182 */
|
||||
{ 2, TF, sys_getcwd, "getcwd" }, /* 183 */
|
||||
{ 2, 0, sys_capget, "capget" }, /* 184 */
|
||||
{ 2, 0, sys_capset, "capset" }, /* 185 */
|
||||
|
@ -44,15 +44,15 @@
|
||||
{ 1, 0, sys_time, "time" }, /* 13 */
|
||||
{ 3, TF, sys_mknod, "mknod" }, /* 14 */
|
||||
{ 2, TF, sys_chmod, "chmod" }, /* 15 */
|
||||
{ 3, TF, sys_chown, "lchown" }, /* 16 */
|
||||
{ 3, TF, sys_chown16, "lchown" }, /* 16 */
|
||||
{ 0, TM, sys_break, "break" }, /* 17 */
|
||||
{ 2, TF, sys_oldstat, "oldstat" }, /* 18 */
|
||||
{ 3, TD, sys_lseek, "lseek" }, /* 19 */
|
||||
{ 0, 0, sys_getpid, "getpid" }, /* 20 */
|
||||
{ 5, TF, sys_mount, "mount" }, /* 21 */
|
||||
{ 1, TF, sys_umount, "oldumount" }, /* 22 */
|
||||
{ 1, 0, sys_setuid, "setuid" }, /* 23 */
|
||||
{ 0, NF, sys_getuid, "getuid" }, /* 24 */
|
||||
{ 1, 0, sys_setuid16, "setuid" }, /* 23 */
|
||||
{ 0, NF, sys_getuid16, "getuid" }, /* 24 */
|
||||
{ 1, 0, sys_stime, "stime" }, /* 25 */
|
||||
{ 4, 0, sys_ptrace, "ptrace" }, /* 26 */
|
||||
{ 1, 0, sys_alarm, "alarm" }, /* 27 */
|
||||
@ -74,11 +74,11 @@
|
||||
{ 1, 0, sys_times, "times" }, /* 43 */
|
||||
{ 0, 0, sys_prof, "prof" }, /* 44 */
|
||||
{ 1, TM|SI, sys_brk, "brk" }, /* 45 */
|
||||
{ 1, 0, sys_setgid, "setgid" }, /* 46 */
|
||||
{ 0, NF, sys_getgid, "getgid" }, /* 47 */
|
||||
{ 1, 0, sys_setgid16, "setgid" }, /* 46 */
|
||||
{ 0, NF, sys_getgid16, "getgid" }, /* 47 */
|
||||
{ 3, TS, sys_signal, "signal" }, /* 48 */
|
||||
{ 0, NF, sys_geteuid, "geteuid" }, /* 49 */
|
||||
{ 0, NF, sys_getegid, "getegid" }, /* 50 */
|
||||
{ 0, NF, sys_geteuid16, "geteuid" }, /* 49 */
|
||||
{ 0, NF, sys_getegid16, "getegid" }, /* 50 */
|
||||
{ 1, TF, sys_acct, "acct" }, /* 51 */
|
||||
{ 2, TF, sys_umount2, "umount" }, /* 52 */
|
||||
{ 0, 0, sys_lock, "lock" }, /* 53 */
|
||||
@ -98,8 +98,8 @@
|
||||
{ 3, TS, sys_sigaction, "sigaction" }, /* 67 */
|
||||
{ 0, TS, sys_siggetmask, "sgetmask" }, /* 68 */
|
||||
{ 1, TS, sys_sigsetmask, "ssetmask" }, /* 69 */
|
||||
{ 2, 0, sys_setreuid, "setreuid" }, /* 70 */
|
||||
{ 2, 0, sys_setregid, "setregid" }, /* 71 */
|
||||
{ 2, 0, sys_setreuid16, "setreuid" }, /* 70 */
|
||||
{ 2, 0, sys_setregid16, "setregid" }, /* 71 */
|
||||
{ 3, TS, sys_sigsuspend, "sigsuspend" }, /* 72 */
|
||||
{ 1, TS, sys_sigpending, "sigpending" }, /* 73 */
|
||||
{ 2, 0, sys_sethostname, "sethostname" }, /* 74 */
|
||||
@ -123,7 +123,7 @@
|
||||
{ 2, TF, sys_truncate, "truncate" }, /* 92 */
|
||||
{ 2, TD, sys_ftruncate, "ftruncate" }, /* 93 */
|
||||
{ 2, TD, sys_fchmod, "fchmod" }, /* 94 */
|
||||
{ 3, TD, sys_fchown, "fchown" }, /* 95 */
|
||||
{ 3, TD, sys_fchown16, "fchown" }, /* 95 */
|
||||
{ 2, 0, sys_getpriority, "getpriority" }, /* 96 */
|
||||
{ 3, 0, sys_setpriority, "setpriority" }, /* 97 */
|
||||
{ 4, 0, sys_profil, "profil" }, /* 98 */
|
||||
@ -166,8 +166,8 @@
|
||||
{ 3, 0, sys_sysfs, "sysfs" }, /* 135 */
|
||||
{ 1, 0, sys_personality, "personality" }, /* 136 */
|
||||
{ 5, 0, sys_afs_syscall, "afs_syscall" }, /* 137 */
|
||||
{ 1, NF, sys_setfsuid, "setfsuid" }, /* 138 */
|
||||
{ 1, NF, sys_setfsgid, "setfsgid" }, /* 139 */
|
||||
{ 1, NF, sys_setfsuid16, "setfsuid" }, /* 138 */
|
||||
{ 1, NF, sys_setfsgid16, "setfsgid" }, /* 139 */
|
||||
{ 5, TD, sys_llseek, "_llseek" }, /* 140 */
|
||||
{ 3, TD, sys_getdents, "getdents" }, /* 141 */
|
||||
{ 5, TD, sys_select, "select" }, /* 142 */
|
||||
@ -192,14 +192,14 @@
|
||||
{ 2, 0, sys_sched_rr_get_interval,"sched_rr_get_interval"}, /* 161 */
|
||||
{ 2, 0, sys_nanosleep, "nanosleep" }, /* 162 */
|
||||
{ 5, TM|SI, sys_mremap, "mremap" }, /* 163 */
|
||||
{ 3, 0, sys_setresuid, "setresuid" }, /* 164 */
|
||||
{ 3, 0, sys_getresuid, "getresuid" }, /* 165 */
|
||||
{ 3, 0, sys_setresuid16, "setresuid" }, /* 164 */
|
||||
{ 3, 0, sys_getresuid16, "getresuid" }, /* 165 */
|
||||
{ 5, 0, sys_vm86, "vm86" }, /* 166 */
|
||||
{ 5, 0, sys_query_module, "query_module" }, /* 167 */
|
||||
{ 3, TD, sys_poll, "poll" }, /* 168 */
|
||||
{ 3, 0, sys_nfsservctl, "nfsservctl" }, /* 169 */
|
||||
{ 3, 0, sys_setresgid, "setresgid" }, /* 170 */
|
||||
{ 3, 0, sys_getresgid, "getresgid" }, /* 171 */
|
||||
{ 3, 0, sys_setresgid16, "setresgid" }, /* 170 */
|
||||
{ 3, 0, sys_getresgid16, "getresgid" }, /* 171 */
|
||||
{ 5, 0, sys_prctl, "prctl" }, /* 172 */
|
||||
{ 0, TS, sys_rt_sigreturn, "rt_sigreturn" }, /* 173 */
|
||||
{ 4, TS, sys_rt_sigaction, "rt_sigaction" }, /* 174 */
|
||||
@ -208,10 +208,9 @@
|
||||
{ 4, TS, sys_rt_sigtimedwait, "rt_sigtimedwait"}, /* 177 */
|
||||
{ 3, TS, sys_rt_sigqueueinfo, "rt_sigqueueinfo"}, /* 178 */
|
||||
{ 2, TS, sys_rt_sigsuspend, "rt_sigsuspend" }, /* 179 */
|
||||
|
||||
{ 6, TD, sys_pread, "pread" }, /* 180 */
|
||||
{ 6, TD, sys_pwrite, "pwrite" }, /* 181 */
|
||||
{ 3, TF, sys_chown, "chown" }, /* 182 */
|
||||
{ 3, TF, sys_chown16, "chown" }, /* 182 */
|
||||
{ 2, TF, sys_getcwd, "getcwd" }, /* 183 */
|
||||
{ 2, 0, sys_capget, "capget" }, /* 184 */
|
||||
{ 2, 0, sys_capset, "capset" }, /* 185 */
|
||||
|
@ -42,15 +42,15 @@
|
||||
{ 1, 0, sys_time, "time" }, /* 13 */
|
||||
{ 3, TF, sys_mknod, "mknod" }, /* 14 */
|
||||
{ 2, TF, sys_chmod, "chmod" }, /* 15 */
|
||||
{ 3, TF, sys_chown, "lchown" }, /* 16 */
|
||||
{ 3, TF, sys_chown16, "lchown" }, /* 16 */
|
||||
{ 0, TM, sys_break, "break" }, /* 17 */
|
||||
{ 2, TF, sys_oldstat, "oldstat" }, /* 18 */
|
||||
{ 3, TD, sys_lseek, "lseek" }, /* 19 */
|
||||
{ 0, 0, sys_getpid, "getpid" }, /* 20 */
|
||||
{ 5, TF, sys_mount, "mount" }, /* 21 */
|
||||
{ 1, TF, sys_umount, "oldumount" }, /* 22 */
|
||||
{ 1, 0, sys_setuid, "setuid" }, /* 23 */
|
||||
{ 0, NF, sys_getuid, "getuid" }, /* 24 */
|
||||
{ 1, 0, sys_setuid16, "setuid" }, /* 23 */
|
||||
{ 0, NF, sys_getuid16, "getuid" }, /* 24 */
|
||||
{ 1, 0, sys_stime, "stime" }, /* 25 */
|
||||
{ 4, 0, sys_ptrace, "ptrace" }, /* 26 */
|
||||
{ 1, 0, sys_alarm, "alarm" }, /* 27 */
|
||||
@ -72,11 +72,11 @@
|
||||
{ 1, 0, sys_times, "times" }, /* 43 */
|
||||
{ 0, 0, sys_prof, "prof" }, /* 44 */
|
||||
{ 1, TM|SI, sys_brk, "brk" }, /* 45 */
|
||||
{ 1, 0, sys_setgid, "setgid" }, /* 46 */
|
||||
{ 0, NF, sys_getgid, "getgid" }, /* 47 */
|
||||
{ 1, 0, sys_setgid16, "setgid" }, /* 46 */
|
||||
{ 0, NF, sys_getgid16, "getgid" }, /* 47 */
|
||||
{ 3, TS, sys_signal, "signal" }, /* 48 */
|
||||
{ 0, NF, sys_geteuid, "geteuid" }, /* 49 */
|
||||
{ 0, NF, sys_getegid, "getegid" }, /* 50 */
|
||||
{ 0, NF, sys_geteuid16, "geteuid" }, /* 49 */
|
||||
{ 0, NF, sys_getegid16, "getegid" }, /* 50 */
|
||||
{ 1, TF, sys_acct, "acct" }, /* 51 */
|
||||
{ 2, TF, sys_umount2, "umount" }, /* 52 */
|
||||
{ 0, 0, sys_lock, "lock" }, /* 53 */
|
||||
@ -96,8 +96,8 @@
|
||||
{ 3, TS, sys_sigaction, "sigaction" }, /* 67 */
|
||||
{ 0, TS, sys_siggetmask, "sgetmask" }, /* 68 */
|
||||
{ 1, TS, sys_sigsetmask, "ssetmask" }, /* 69 */
|
||||
{ 2, 0, sys_setreuid, "setreuid" }, /* 70 */
|
||||
{ 2, 0, sys_setregid, "setregid" }, /* 71 */
|
||||
{ 2, 0, sys_setreuid16, "setreuid" }, /* 70 */
|
||||
{ 2, 0, sys_setregid16, "setregid" }, /* 71 */
|
||||
{ 3, TS, sys_sigsuspend, "sigsuspend" }, /* 72 */
|
||||
{ 1, TS, sys_sigpending, "sigpending" }, /* 73 */
|
||||
{ 2, 0, sys_sethostname, "sethostname" }, /* 74 */
|
||||
@ -121,7 +121,7 @@
|
||||
{ 2, TF, sys_truncate, "truncate" }, /* 92 */
|
||||
{ 2, TD, sys_ftruncate, "ftruncate" }, /* 93 */
|
||||
{ 2, TD, sys_fchmod, "fchmod" }, /* 94 */
|
||||
{ 3, TD, sys_fchown, "fchown" }, /* 95 */
|
||||
{ 3, TD, sys_fchown16, "fchown" }, /* 95 */
|
||||
{ 2, 0, sys_getpriority, "getpriority" }, /* 96 */
|
||||
{ 3, 0, sys_setpriority, "setpriority" }, /* 97 */
|
||||
{ 4, 0, sys_profil, "profil" }, /* 98 */
|
||||
@ -164,8 +164,8 @@
|
||||
{ 3, 0, sys_sysfs, "sysfs" }, /* 135 */
|
||||
{ 1, 0, sys_personality, "personality" }, /* 136 */
|
||||
{ 5, 0, sys_afs_syscall, "afs_syscall" }, /* 137 */
|
||||
{ 1, NF, sys_setfsuid, "setfsuid" }, /* 138 */
|
||||
{ 1, NF, sys_setfsgid, "setfsgid" }, /* 139 */
|
||||
{ 1, NF, sys_setfsuid16, "setfsuid" }, /* 138 */
|
||||
{ 1, NF, sys_setfsgid16, "setfsgid" }, /* 139 */
|
||||
{ 5, TD, sys_llseek, "_llseek" }, /* 140 */
|
||||
{ 3, TD, sys_getdents, "getdents" }, /* 141 */
|
||||
{ 5, TD, sys_select, "select" }, /* 142 */
|
||||
@ -190,14 +190,14 @@
|
||||
{ 2, 0, sys_sched_rr_get_interval,"sched_rr_get_interval"}, /* 161 */
|
||||
{ 2, 0, sys_nanosleep, "nanosleep" }, /* 162 */
|
||||
{ 5, TM|SI, sys_mremap, "mremap" }, /* 163 */
|
||||
{ 3, 0, sys_setresuid, "setresuid" }, /* 164 */
|
||||
{ 3, 0, sys_getresuid, "getresuid" }, /* 165 */
|
||||
{ 3, 0, sys_setresuid16, "setresuid" }, /* 164 */
|
||||
{ 3, 0, sys_getresuid16, "getresuid" }, /* 165 */
|
||||
{ 5, 0, NULL, NULL }, /* 166 */
|
||||
{ 5, 0, sys_query_module, "query_module" }, /* 167 */
|
||||
{ 3, TD, sys_poll, "poll" }, /* 168 */
|
||||
{ 3, 0, sys_nfsservctl, "nfsservctl" }, /* 169 */
|
||||
{ 3, 0, sys_setresgid, "setresgid" }, /* 170 */
|
||||
{ 3, 0, sys_getresgid, "getresgid" }, /* 171 */
|
||||
{ 3, 0, sys_setresgid16, "setresgid" }, /* 170 */
|
||||
{ 3, 0, sys_getresgid16, "getresgid" }, /* 171 */
|
||||
{ 5, 0, sys_prctl, "prctl" }, /* 172 */
|
||||
{ 0, TS, sys_rt_sigreturn, "rt_sigreturn" }, /* 173 */
|
||||
{ 4, TS, sys_rt_sigaction, "rt_sigaction" }, /* 174 */
|
||||
@ -208,7 +208,7 @@
|
||||
{ 2, TS, sys_rt_sigsuspend, "rt_sigsuspend" }, /* 179 */
|
||||
{ 4, TD, sys_pread, "pread" }, /* 180 */
|
||||
{ 4, TD, sys_pwrite, "pwrite" }, /* 181 */
|
||||
{ 3, TF, sys_chown, "chown" }, /* 182 */
|
||||
{ 3, TF, sys_chown16, "chown" }, /* 182 */
|
||||
{ 2, TF, sys_getcwd, "getcwd" }, /* 183 */
|
||||
{ 2, 0, sys_capget, "capget" }, /* 184 */
|
||||
{ 2, 0, sys_capset, "capset" }, /* 185 */
|
||||
|
@ -11,18 +11,18 @@
|
||||
{ 1, TF, sys_unlink, "unlink" }, /* 10 */
|
||||
{ 2, TF|TP|SE|SI, sys_execv, "execv" }, /* 11 */
|
||||
{ 1, TF, sys_chdir, "chdir" }, /* 12 */
|
||||
{ 3, TF, sys_chown, "chown"}, /* 13 */
|
||||
{ 3, TF, sys_chown16, "chown"}, /* 13 */
|
||||
{ 3, TF, sys_mknod, "mknod" }, /* 14 */
|
||||
{ 2, TF, sys_chmod, "chmod" }, /* 15 */
|
||||
{ 3, TF, sys_chown, "lchown" }, /* 16 */
|
||||
{ 3, TF, sys_chown16, "lchown" }, /* 16 */
|
||||
{ 1, TM|SI, sys_brk, "brk" }, /* 17 */
|
||||
{ 4, 0, printargs, "perfctr" }, /* 18 */
|
||||
{ 3, TD, sys_lseek, "lseek" }, /* 19 */
|
||||
{ 0, 0, sys_getpid, "getpid" }, /* 20 */
|
||||
{ 2, 0, sys_capget, "capget" }, /* 21 */
|
||||
{ 2, 0, sys_capset, "capset" }, /* 22 */
|
||||
{ 1, 0, sys_setuid, "setuid" }, /* 23 */
|
||||
{ 0, NF, sys_getuid, "getuid" }, /* 24 */
|
||||
{ 1, 0, sys_setuid16, "setuid" }, /* 23 */
|
||||
{ 0, NF, sys_getuid16, "getuid" }, /* 24 */
|
||||
{ 1, 0, sys_time, "time" }, /* 25 */
|
||||
{ 5, 0, sys_ptrace, "ptrace" }, /* 26 */
|
||||
{ 1, 0, sys_alarm, "alarm" }, /* 27 */
|
||||
@ -44,11 +44,11 @@
|
||||
{ 1, 0, sys_times, "times" }, /* 43 */
|
||||
{ 0, NF, sys_getuid, "getuid32" }, /* 44 */
|
||||
{ 2, TF, sys_umount2, "umount" }, /* 45 */
|
||||
{ 1, 0, sys_setgid, "setgid" }, /* 46 */
|
||||
{ 0, NF, sys_getgid, "getgid" }, /* 47 */
|
||||
{ 1, 0, sys_setgid16, "setgid" }, /* 46 */
|
||||
{ 0, NF, sys_getgid16, "getgid" }, /* 47 */
|
||||
{ 3, TS, sys_signal, "signal" }, /* 48 */
|
||||
{ 0, NF, sys_geteuid, "geteuid" }, /* 49 */
|
||||
{ 0, NF, sys_getegid, "getegid" }, /* 50 */
|
||||
{ 0, NF, sys_geteuid16, "geteuid" }, /* 49 */
|
||||
{ 0, NF, sys_getegid16, "getegid" }, /* 50 */
|
||||
{ 1, TF, sys_acct, "acct" }, /* 51 */
|
||||
{ 2, 0, printargs, "memory_ordering" }, /* 52 */
|
||||
{ 0, NF, sys_getgid, "getgid32" }, /* 53 */
|
||||
@ -121,11 +121,11 @@
|
||||
{ 3, TD, sys_readv, "readv" }, /* 120 */
|
||||
{ 3, TD, sys_writev, "writev" }, /* 121 */
|
||||
{ 2, 0, sys_settimeofday,"settimeofday" }, /* 122 */
|
||||
{ 3, TD, sys_fchown, "fchown" }, /* 123 */
|
||||
{ 3, TD, sys_fchown16, "fchown" }, /* 123 */
|
||||
{ 2, TD, sys_fchmod, "fchmod" }, /* 124 */
|
||||
{ 6, TN, sys_recvfrom, "recvfrom" }, /* 125 */
|
||||
{ 2, 0, sys_setreuid, "setreuid" }, /* 126 */
|
||||
{ 2, 0, sys_setregid, "setregid" }, /* 127 */
|
||||
{ 2, 0, sys_setreuid16, "setreuid" }, /* 126 */
|
||||
{ 2, 0, sys_setregid16, "setregid" }, /* 127 */
|
||||
{ 2, TF, sys_rename, "rename" }, /* 128 */
|
||||
{ 2, TF, sys_truncate, "truncate" }, /* 129 */
|
||||
{ 2, TD, sys_ftruncate, "ftruncate" }, /* 130 */
|
||||
@ -226,8 +226,8 @@
|
||||
{ 0, 0, sys_bdflush, "bdflush" }, /* 225 */
|
||||
{ 3, 0, sys_sysfs, "sysfs" }, /* 226 */
|
||||
{ 5, 0, sys_afs_syscall,"afs_syscall" }, /* 227 */
|
||||
{ 1, NF, sys_setfsuid, "setfsuid" }, /* 228 */
|
||||
{ 1, NF, sys_setfsgid, "setfsgid" }, /* 229 */
|
||||
{ 1, NF, sys_setfsuid16, "setfsuid" }, /* 228 */
|
||||
{ 1, NF, sys_setfsgid16, "setfsgid" }, /* 229 */
|
||||
{ 5, TD, sys_select, "select" }, /* 230 */
|
||||
{ 1, 0, sys_time, "time" }, /* 231 */
|
||||
{ 2, TF, sys_stat, "stat" }, /* 232 */
|
||||
|
@ -353,3 +353,14 @@ int sys_execv();
|
||||
int sys_getmsg();
|
||||
int sys_putmsg();
|
||||
#endif
|
||||
|
||||
#if NEED_UID16_PARSERS
|
||||
int sys_chown16();
|
||||
int sys_fchown16();
|
||||
int sys_getresuid16();
|
||||
int sys_getuid16();
|
||||
int sys_setfsuid16();
|
||||
int sys_setresuid16();
|
||||
int sys_setreuid16();
|
||||
int sys_setuid16();
|
||||
#endif
|
||||
|
1
tests/.gitignore
vendored
1
tests/.gitignore
vendored
@ -9,6 +9,7 @@ sigaction
|
||||
stack-fcall
|
||||
statfs
|
||||
uid
|
||||
uid16
|
||||
uid32
|
||||
uio
|
||||
*.log
|
||||
|
@ -14,6 +14,7 @@ check_PROGRAMS = \
|
||||
stack-fcall \
|
||||
statfs \
|
||||
uid \
|
||||
uid16 \
|
||||
uid32 \
|
||||
uio
|
||||
|
||||
@ -37,6 +38,7 @@ TESTS = \
|
||||
net-fd.test \
|
||||
net-yy.test \
|
||||
uid.test \
|
||||
uid16.test \
|
||||
uid32.test \
|
||||
uio.test \
|
||||
count.test \
|
||||
|
44
tests/uid16.c
Normal file
44
tests/uid16.c
Normal file
@ -0,0 +1,44 @@
|
||||
#ifdef HAVE_CONFIG_H
|
||||
# include "config.h"
|
||||
#endif
|
||||
#include <assert.h>
|
||||
#include <unistd.h>
|
||||
#include <sys/syscall.h>
|
||||
|
||||
int
|
||||
main(void)
|
||||
{
|
||||
#if defined(__NR_getuid) \
|
||||
&& defined(__NR_setuid) \
|
||||
&& defined(__NR_getresuid) \
|
||||
&& defined(__NR_setreuid) \
|
||||
&& defined(__NR_setresuid) \
|
||||
&& defined(__NR_chown) \
|
||||
\
|
||||
&& defined(__NR_getuid32) \
|
||||
&& defined(__NR_setuid32) \
|
||||
&& defined(__NR_getresuid32) \
|
||||
&& defined(__NR_setreuid32) \
|
||||
&& defined(__NR_setresuid32) \
|
||||
&& defined(__NR_chown32) \
|
||||
\
|
||||
&& __NR_getuid != __NR_getuid32 \
|
||||
&& __NR_setuid != __NR_setuid32 \
|
||||
&& __NR_getresuid != __NR_getresuid32 \
|
||||
&& __NR_setreuid != __NR_setreuid32 \
|
||||
&& __NR_setresuid != __NR_setresuid32 \
|
||||
&& __NR_chown != __NR_chown32 \
|
||||
/**/
|
||||
uid_t r, e, s;
|
||||
|
||||
e = syscall(__NR_getuid);
|
||||
assert(syscall(__NR_setuid, e) == 0);
|
||||
assert(syscall(__NR_getresuid, &r, &e, &s) == 0);
|
||||
assert(syscall(__NR_setreuid, -1, 0xffff) == 0);
|
||||
assert(syscall(__NR_setresuid, -1, e, 0xffff) == 0);
|
||||
assert(syscall(__NR_chown, ".", -1, 0xffff) == 0);
|
||||
return 0;
|
||||
#else
|
||||
return 77;
|
||||
#endif
|
||||
}
|
7
tests/uid16.test
Executable file
7
tests/uid16.test
Executable file
@ -0,0 +1,7 @@
|
||||
#!/bin/sh
|
||||
|
||||
# Check uid16_t decoding.
|
||||
|
||||
uid_t_size=16
|
||||
|
||||
. "${srcdir=.}/uid.test"
|
70
uid.c
70
uid.c
@ -1,6 +1,39 @@
|
||||
#ifdef STRACE_UID_SIZE
|
||||
# if STRACE_UID_SIZE != 16
|
||||
# error invalid STRACE_UID_SIZE
|
||||
# endif
|
||||
|
||||
# define SIZEIFY(x) SIZEIFY_(x,STRACE_UID_SIZE)
|
||||
# define SIZEIFY_(x,size) SIZEIFY__(x,size)
|
||||
# define SIZEIFY__(x,size) x ## size
|
||||
|
||||
# define sys_getuid SIZEIFY(sys_getuid)
|
||||
# define sys_setfsuid SIZEIFY(sys_setfsuid)
|
||||
# define sys_setuid SIZEIFY(sys_setuid)
|
||||
# define sys_getresuid SIZEIFY(sys_getresuid)
|
||||
# define sys_setreuid SIZEIFY(sys_setreuid)
|
||||
# define sys_setresuid SIZEIFY(sys_setresuid)
|
||||
# define sys_chown SIZEIFY(sys_chown)
|
||||
# define sys_fchown SIZEIFY(sys_fchown)
|
||||
# define printuid SIZEIFY(printuid)
|
||||
#endif /* STRACE_UID_SIZE */
|
||||
|
||||
#include "defs.h"
|
||||
|
||||
#include <asm/posix_types.h>
|
||||
#ifdef STRACE_UID_SIZE
|
||||
# if !NEED_UID16_PARSERS
|
||||
# undef STRACE_UID_SIZE
|
||||
# endif
|
||||
#else
|
||||
# define STRACE_UID_SIZE 32
|
||||
#endif
|
||||
|
||||
#ifdef STRACE_UID_SIZE
|
||||
|
||||
# undef uid_t
|
||||
# define uid_t uid_t_(STRACE_UID_SIZE)
|
||||
# define uid_t_(size) uid_t__(size)
|
||||
# define uid_t__(size) uint ## size ## _t
|
||||
|
||||
int
|
||||
sys_getuid(struct tcb *tcp)
|
||||
@ -29,27 +62,28 @@ sys_setuid(struct tcb *tcp)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void
|
||||
get_print_uid(struct tcb *tcp, const char *prefix, const long addr)
|
||||
{
|
||||
uid_t uid;
|
||||
|
||||
if (umove(tcp, addr, &uid) < 0)
|
||||
tprintf("%s%#lx", prefix, addr);
|
||||
else
|
||||
tprintf("%s[%u]", prefix, uid);
|
||||
}
|
||||
|
||||
int
|
||||
sys_getresuid(struct tcb *tcp)
|
||||
{
|
||||
if (exiting(tcp)) {
|
||||
__kernel_uid_t uid;
|
||||
if (syserror(tcp))
|
||||
if (syserror(tcp)) {
|
||||
tprintf("%#lx, %#lx, %#lx", tcp->u_arg[0],
|
||||
tcp->u_arg[1], tcp->u_arg[2]);
|
||||
else {
|
||||
if (umove(tcp, tcp->u_arg[0], &uid) < 0)
|
||||
tprintf("%#lx, ", tcp->u_arg[0]);
|
||||
else
|
||||
tprintf("[%lu], ", (unsigned long) uid);
|
||||
if (umove(tcp, tcp->u_arg[1], &uid) < 0)
|
||||
tprintf("%#lx, ", tcp->u_arg[1]);
|
||||
else
|
||||
tprintf("[%lu], ", (unsigned long) uid);
|
||||
if (umove(tcp, tcp->u_arg[2], &uid) < 0)
|
||||
tprintf("%#lx", tcp->u_arg[2]);
|
||||
else
|
||||
tprintf("[%lu]", (unsigned long) uid);
|
||||
} else {
|
||||
get_print_uid(tcp, "", tcp->u_arg[0]);
|
||||
get_print_uid(tcp, ", ", tcp->u_arg[1]);
|
||||
get_print_uid(tcp, ", ", tcp->u_arg[2]);
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
@ -101,8 +135,10 @@ sys_fchown(struct tcb *tcp)
|
||||
void
|
||||
printuid(const char *text, const unsigned int uid)
|
||||
{
|
||||
if ((unsigned int) -1 == uid)
|
||||
if ((unsigned int) -1 == uid || (uid_t) -1 == uid)
|
||||
tprintf("%s-1", text);
|
||||
else
|
||||
tprintf("%s%u", text, uid);
|
||||
}
|
||||
|
||||
#endif /* STRACE_UID_SIZE */
|
||||
|
Loading…
Reference in New Issue
Block a user