Skip to content

Instantly share code, notes, and snippets.

@stek29
Created August 6, 2018 08:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save stek29/08ca323506bcae78673de2e564e105d1 to your computer and use it in GitHub Desktop.
Save stek29/08ca323506bcae78673de2e564e105d1 to your computer and use it in GitHub Desktop.

public domain but no liability blah blah

exit=0x80,0x1,1,
fork=0x80,0x2,0,
read=0x80,0x3,3,
write=0x80,0x4,3,
open=0x80,0x5,3,
close=0x80,0x6,1,
wait4=0x80,0x7,4,
link=0x80,0x9,2,
unlink=0x80,0xa,1,
chdir=0x80,0xc,1,
fchdir=0x80,0xd,1,
mknod=0x80,0xe,3,
chmod=0x80,0xf,2,
chown=0x80,0x10,3,
getfsstat=0x80,0x12,3,
getpid=0x80,0x14,0,
setuid=0x80,0x17,1,
getuid=0x80,0x18,0,
geteuid=0x80,0x19,0,
ptrace=0x80,0x1a,4,
recvmsg=0x80,0x1b,3,
sendmsg=0x80,0x1c,3,
recvfrom=0x80,0x1d,6,
accept=0x80,0x1e,3,
getpeername=0x80,0x1f,3,
getsockname=0x80,0x20,3,
access=0x80,0x21,2,
chflags=0x80,0x22,2,
fchflags=0x80,0x23,2,
sync=0x80,0x24,0,
kill=0x80,0x25,3,
getppid=0x80,0x27,0,
dup=0x80,0x29,1,
pipe=0x80,0x2a,0,
getegid=0x80,0x2b,0,
sigaction=0x80,0x2e,3,
getgid=0x80,0x2f,0,
sigprocmask=0x80,0x30,3,
getlogin=0x80,0x31,2,
setlogin=0x80,0x32,1,
acct=0x80,0x33,1,
sigpending=0x80,0x34,1,
sigaltstack=0x80,0x35,2,
ioctl=0x80,0x36,3,
reboot=0x80,0x37,2,
revoke=0x80,0x38,1,
symlink=0x80,0x39,2,
readlink=0x80,0x3a,3,
execve=0x80,0x3b,3,
umask=0x80,0x3c,1,
chroot=0x80,0x3d,1,
msync=0x80,0x41,3,
vfork=0x80,0x42,0,
munmap=0x80,0x49,2,
mprotect=0x80,0x4a,3,
madvise=0x80,0x4b,3,
mincore=0x80,0x4e,3,
getgroups=0x80,0x4f,2,
setgroups=0x80,0x50,2,
getpgrp=0x80,0x51,0,
setpgid=0x80,0x52,2,
setitimer=0x80,0x53,3,
swapon=0x80,0x55,0,
getitimer=0x80,0x56,2,
getdtablesize=0x80,0x59,0,
dup2=0x80,0x5a,2,
fcntl=0x80,0x5c,3,
select=0x80,0x5d,5,
fsync=0x80,0x5f,1,
setpriority=0x80,0x60,3,
socket=0x80,0x61,3,
connect=0x80,0x62,3,
getpriority=0x80,0x64,2,
bind=0x80,0x68,3,
setsockopt=0x80,0x69,5,
listen=0x80,0x6a,2,
sigsuspend=0x80,0x6f,1,
gettimeofday=0x80,0x74,3,
getrusage=0x80,0x75,2,
getsockopt=0x80,0x76,5,
readv=0x80,0x78,3,
writev=0x80,0x79,3,
settimeofday=0x80,0x7a,2,
fchown=0x80,0x7b,3,
fchmod=0x80,0x7c,2,
setreuid=0x80,0x7e,2,
setregid=0x80,0x7f,2,
rename=0x80,0x80,2,
flock=0x80,0x83,2,
mkfifo=0x80,0x84,2,
sendto=0x80,0x85,6,
shutdown=0x80,0x86,2,
socketpair=0x80,0x87,4,
mkdir=0x80,0x88,2,
rmdir=0x80,0x89,1,
utimes=0x80,0x8a,2,
futimes=0x80,0x8b,2,
adjtime=0x80,0x8c,2,
gethostuuid=0x80,0x8e,3,
setsid=0x80,0x93,0,
getpgid=0x80,0x97,1,
setprivexec=0x80,0x98,1,
pread=0x80,0x99,4,
pwrite=0x80,0x9a,4,
nfssvc=0x80,0x9b,2,
statfs=0x80,0x9d,2,
fstatfs=0x80,0x9e,2,
unmount=0x80,0x9f,2,
getfh=0x80,0xa1,2,
quotactl=0x80,0xa5,4,
mount=0x80,0xa7,4,
csops=0x80,0xa9,4,
csops_audittoken=0x80,0xaa,5,
waitid=0x80,0xad,4,
kdebug_typefilter=0x80,0xb1,2,
kdebug_trace_string=0x80,0xb2,3,
kdebug_trace64=0x80,0xb3,5,
kdebug_trace=0x80,0xb4,5,
setgid=0x80,0xb5,1,
setegid=0x80,0xb6,1,
seteuid=0x80,0xb7,1,
sigreturn=0x80,0xb8,2,
thread_selfcounts=0x80,0xba,3,
fdatasync=0x80,0xbb,1,
stat=0x80,0xbc,2,
fstat=0x80,0xbd,2,
lstat=0x80,0xbe,2,
pathconf=0x80,0xbf,2,
fpathconf=0x80,0xc0,2,
getrlimit=0x80,0xc2,2,
setrlimit=0x80,0xc3,2,
getdirentries=0x80,0xc4,4,
mmap=0x80,0xc5,6,
lseek=0x80,0xc7,3,
truncate=0x80,0xc8,2,
ftruncate=0x80,0xc9,2,
sysctl=0x80,0xca,6,
mlock=0x80,0xcb,2,
munlock=0x80,0xcc,2,
undelete=0x80,0xcd,1,
open_dprotected_np=0x80,0xd8,5,
getattrlist=0x80,0xdc,5,
setattrlist=0x80,0xdd,5,
getdirentriesattr=0x80,0xde,8,
exchangedata=0x80,0xdf,3,
searchfs=0x80,0xe1,6,
delete=0x80,0xe2,1,
copyfile=0x80,0xe3,4,
fgetattrlist=0x80,0xe4,5,
fsetattrlist=0x80,0xe5,5,
poll=0x80,0xe6,3,
watchevent=0x80,0xe7,2,
waitevent=0x80,0xe8,2,
modwatch=0x80,0xe9,2,
getxattr=0x80,0xea,6,
fgetxattr=0x80,0xeb,6,
setxattr=0x80,0xec,6,
fsetxattr=0x80,0xed,6,
removexattr=0x80,0xee,3,
fremovexattr=0x80,0xef,3,
listxattr=0x80,0xf0,4,
flistxattr=0x80,0xf1,4,
fsctl=0x80,0xf2,4,
initgroups=0x80,0xf3,3,
posix_spawn=0x80,0xf4,5,
ffsctl=0x80,0xf5,4,
nfsclnt=0x80,0xf7,2,
fhopen=0x80,0xf8,2,
minherit=0x80,0xfa,3,
semsys=0x80,0xfb,5,
msgsys=0x80,0xfc,5,
shmsys=0x80,0xfd,4,
semctl=0x80,0xfe,4,
semget=0x80,0xff,3,
semop=0x80,0x100,3,
msgctl=0x80,0x102,3,
msgget=0x80,0x103,2,
msgsnd=0x80,0x104,4,
msgrcv=0x80,0x105,5,
shmat=0x80,0x106,3,
shmctl=0x80,0x107,3,
shmdt=0x80,0x108,1,
shmget=0x80,0x109,3,
shm_open=0x80,0x10a,3,
shm_unlink=0x80,0x10b,1,
sem_open=0x80,0x10c,4,
sem_close=0x80,0x10d,1,
sem_unlink=0x80,0x10e,1,
sem_wait=0x80,0x10f,1,
sem_trywait=0x80,0x110,1,
sem_post=0x80,0x111,1,
sysctlbyname=0x80,0x112,6,
open_extended=0x80,0x115,6,
umask_extended=0x80,0x116,2,
stat_extended=0x80,0x117,4,
lstat_extended=0x80,0x118,4,
fstat_extended=0x80,0x119,4,
chmod_extended=0x80,0x11a,5,
fchmod_extended=0x80,0x11b,5,
access_extended=0x80,0x11c,4,
settid=0x80,0x11d,2,
gettid=0x80,0x11e,2,
setsgroups=0x80,0x11f,2,
getsgroups=0x80,0x120,2,
setwgroups=0x80,0x121,2,
getwgroups=0x80,0x122,2,
mkfifo_extended=0x80,0x123,5,
mkdir_extended=0x80,0x124,5,
identitysvc=0x80,0x125,2,
shared_region_check_np=0x80,0x126,1,
vm_pressure_monitor=0x80,0x128,3,
psynch_rw_longrdlock=0x80,0x129,5,
psynch_rw_yieldwrlock=0x80,0x12a,5,
psynch_rw_downgrade=0x80,0x12b,5,
psynch_rw_upgrade=0x80,0x12c,5,
psynch_mutexwait=0x80,0x12d,5,
psynch_mutexdrop=0x80,0x12e,5,
psynch_cvbroad=0x80,0x12f,7,
psynch_cvsignal=0x80,0x130,8,
psynch_cvwait=0x80,0x131,8,
psynch_rw_rdlock=0x80,0x132,5,
psynch_rw_wrlock=0x80,0x133,5,
psynch_rw_unlock=0x80,0x134,5,
psynch_rw_unlock2=0x80,0x135,5,
getsid=0x80,0x136,1,
settid_with_pid=0x80,0x137,2,
psynch_cvclrprepost=0x80,0x138,7,
aio_fsync=0x80,0x139,2,
aio_return=0x80,0x13a,1,
aio_suspend=0x80,0x13b,3,
aio_cancel=0x80,0x13c,2,
aio_error=0x80,0x13d,1,
aio_read=0x80,0x13e,1,
aio_write=0x80,0x13f,1,
lio_listio=0x80,0x140,4,
iopolicysys=0x80,0x142,2,
process_policy=0x80,0x143,7,
mlockall=0x80,0x144,1,
munlockall=0x80,0x145,1,
issetugid=0x80,0x147,0,
__pthread_kill=0x80,0x148,2,
__pthread_sigmask=0x80,0x149,3,
__sigwait=0x80,0x14a,2,
__disable_threadsignal=0x80,0x14b,1,
__pthread_markcancel=0x80,0x14c,1,
__pthread_canceled=0x80,0x14d,1,
__semwait_signal=0x80,0x14e,6,
proc_info=0x80,0x150,6,
sendfile=0x80,0x151,6,
stat64=0x80,0x152,2,
fstat64=0x80,0x153,2,
lstat64=0x80,0x154,2,
stat64_extended=0x80,0x155,4,
lstat64_extended=0x80,0x156,4,
fstat64_extended=0x80,0x157,4,
getdirentries64=0x80,0x158,4,
statfs64=0x80,0x159,2,
fstatfs64=0x80,0x15a,2,
getfsstat64=0x80,0x15b,3,
__pthread_chdir=0x80,0x15c,1,
__pthread_fchdir=0x80,0x15d,1,
audit=0x80,0x15e,2,
auditon=0x80,0x15f,3,
getauid=0x80,0x161,1,
setauid=0x80,0x162,1,
getaudit_addr=0x80,0x165,2,
setaudit_addr=0x80,0x166,2,
auditctl=0x80,0x167,1,
bsdthread_create=0x80,0x168,5,
bsdthread_terminate=0x80,0x169,4,
kqueue=0x80,0x16a,0,
kevent=0x80,0x16b,6,
lchown=0x80,0x16c,3,
bsdthread_register=0x80,0x16e,7,
workq_open=0x80,0x16f,0,
workq_kernreturn=0x80,0x170,4,
kevent64=0x80,0x171,7,
__old_semwait_signal=0x80,0x172,5,
__old_semwait_signal_nocancel=0x80,0x173,5,
thread_selfid=0x80,0x174,0,
ledger=0x80,0x175,4,
kevent_qos=0x80,0x176,8,
kevent_id=0x80,0x177,8,
__mac_execve=0x80,0x17c,4,
__mac_syscall=0x80,0x17d,3,
__mac_get_file=0x80,0x17e,2,
__mac_set_file=0x80,0x17f,2,
__mac_get_link=0x80,0x180,2,
__mac_set_link=0x80,0x181,2,
__mac_get_proc=0x80,0x182,1,
__mac_set_proc=0x80,0x183,1,
__mac_get_fd=0x80,0x184,2,
__mac_set_fd=0x80,0x185,2,
__mac_get_pid=0x80,0x186,2,
pselect=0x80,0x18a,6,
pselect_nocancel=0x80,0x18b,6,
read_nocancel=0x80,0x18c,3,
write_nocancel=0x80,0x18d,3,
open_nocancel=0x80,0x18e,3,
close_nocancel=0x80,0x18f,1,
wait4_nocancel=0x80,0x190,4,
recvmsg_nocancel=0x80,0x191,3,
sendmsg_nocancel=0x80,0x192,3,
recvfrom_nocancel=0x80,0x193,6,
accept_nocancel=0x80,0x194,3,
msync_nocancel=0x80,0x195,3,
fcntl_nocancel=0x80,0x196,3,
select_nocancel=0x80,0x197,5,
fsync_nocancel=0x80,0x198,1,
connect_nocancel=0x80,0x199,3,
sigsuspend_nocancel=0x80,0x19a,1,
readv_nocancel=0x80,0x19b,3,
writev_nocancel=0x80,0x19c,3,
sendto_nocancel=0x80,0x19d,6,
pread_nocancel=0x80,0x19e,4,
pwrite_nocancel=0x80,0x19f,4,
waitid_nocancel=0x80,0x1a0,4,
poll_nocancel=0x80,0x1a1,3,
msgsnd_nocancel=0x80,0x1a2,4,
msgrcv_nocancel=0x80,0x1a3,5,
sem_wait_nocancel=0x80,0x1a4,1,
aio_suspend_nocancel=0x80,0x1a5,3,
__sigwait_nocancel=0x80,0x1a6,2,
__semwait_signal_nocancel=0x80,0x1a7,6,
__mac_mount=0x80,0x1a8,5,
__mac_get_mount=0x80,0x1a9,2,
__mac_getfsstat=0x80,0x1aa,5,
fsgetpath=0x80,0x1ab,4,
audit_session_self=0x80,0x1ac,0,
audit_session_join=0x80,0x1ad,1,
fileport_makeport=0x80,0x1ae,2,
fileport_makefd=0x80,0x1af,1,
audit_session_port=0x80,0x1b0,2,
pid_suspend=0x80,0x1b1,1,
pid_resume=0x80,0x1b2,1,
pid_hibernate=0x80,0x1b3,1,
pid_shutdown_sockets=0x80,0x1b4,2,
shared_region_map_and_slide_np=0x80,0x1b6,6,
kas_info=0x80,0x1b7,3,
memorystatus_control=0x80,0x1b8,5,
guarded_open_np=0x80,0x1b9,5,
guarded_close_np=0x80,0x1ba,2,
guarded_kqueue_np=0x80,0x1bb,2,
change_fdguard_np=0x80,0x1bc,6,
usrctl=0x80,0x1bd,1,
proc_rlimit_control=0x80,0x1be,3,
connectx=0x80,0x1bf,8,
disconnectx=0x80,0x1c0,3,
peeloff=0x80,0x1c1,2,
socket_delegate=0x80,0x1c2,4,
telemetry=0x80,0x1c3,6,
proc_uuid_policy=0x80,0x1c4,4,
memorystatus_get_level=0x80,0x1c5,1,
system_override=0x80,0x1c6,2,
vfs_purge=0x80,0x1c7,0,
sfi_ctl=0x80,0x1c8,4,
sfi_pidctl=0x80,0x1c9,4,
coalition=0x80,0x1ca,3,
coalition_info=0x80,0x1cb,4,
necp_match_policy=0x80,0x1cc,3,
getattrlistbulk=0x80,0x1cd,5,
clonefileat=0x80,0x1ce,5,
openat=0x80,0x1cf,4,
openat_nocancel=0x80,0x1d0,4,
renameat=0x80,0x1d1,4,
faccessat=0x80,0x1d2,4,
fchmodat=0x80,0x1d3,4,
fchownat=0x80,0x1d4,5,
fstatat=0x80,0x1d5,4,
fstatat64=0x80,0x1d6,4,
linkat=0x80,0x1d7,5,
unlinkat=0x80,0x1d8,3,
readlinkat=0x80,0x1d9,4,
symlinkat=0x80,0x1da,3,
mkdirat=0x80,0x1db,3,
getattrlistat=0x80,0x1dc,6,
proc_trace_log=0x80,0x1dd,2,
bsdthread_ctl=0x80,0x1de,4,
openbyid_np=0x80,0x1df,3,
recvmsg_x=0x80,0x1e0,4,
sendmsg_x=0x80,0x1e1,4,
thread_selfusage=0x80,0x1e2,0,
csrctl=0x80,0x1e3,3,
guarded_open_dprotected_np=0x80,0x1e4,7,
guarded_write_np=0x80,0x1e5,4,
guarded_pwrite_np=0x80,0x1e6,5,
guarded_writev_np=0x80,0x1e7,4,
renameatx_np=0x80,0x1e8,5,
mremap_encrypted=0x80,0x1e9,5,
netagent_trigger=0x80,0x1ea,2,
stack_snapshot_with_config=0x80,0x1eb,3,
microstackshot=0x80,0x1ec,3,
grab_pgo_data=0x80,0x1ed,4,
persona=0x80,0x1ee,5,
work_interval_ctl=0x80,0x1f3,4,
getentropy=0x80,0x1f4,2,
necp_open=0x80,0x1f5,1,
necp_client_action=0x80,0x1f6,6,
ulock_wait=0x80,0x203,4,
ulock_wake=0x80,0x204,3,
fclonefileat=0x80,0x205,4,
fs_snapshot=0x80,0x206,6,
terminate_with_payload=0x80,0x208,7,
abort_with_payload=0x80,0x209,6,
necp_session_open=0x80,0x20a,1,
necp_session_action=0x80,0x20b,6,
setattrlistat=0x80,0x20c,6,
net_qos_guideline=0x80,0x20d,2,
fmount=0x80,0x20e,4,
ntp_adjtime=0x80,0x20f,1,
ntp_gettime=0x80,0x210,1,
os_fault_with_payload=0x80,0x211,6,
_kernelrpc_mach_vm_allocate_trap=0x81,0xa,4,
_kernelrpc_mach_vm_purgable_control_trap=0x81,0xb,4,
_kernelrpc_mach_vm_deallocate_trap=0x81,0xc,3,
_kernelrpc_mach_vm_protect_trap=0x81,0xe,5,
_kernelrpc_mach_vm_map_trap=0x81,0xf,6,
_kernelrpc_mach_port_allocate_trap=0x81,0x10,3,
_kernelrpc_mach_port_destroy_trap=0x81,0x11,2,
_kernelrpc_mach_port_deallocate_trap=0x81,0x12,2,
_kernelrpc_mach_port_mod_refs_trap=0x81,0x13,4,
_kernelrpc_mach_port_move_member_trap=0x81,0x14,3,
_kernelrpc_mach_port_insert_right_trap=0x81,0x15,4,
_kernelrpc_mach_port_insert_member_trap=0x81,0x16,3,
_kernelrpc_mach_port_extract_member_trap=0x81,0x17,3,
_kernelrpc_mach_port_construct_trap=0x81,0x18,4,
_kernelrpc_mach_port_destruct_trap=0x81,0x19,4,
mach_reply_port=0x81,0x1a,0,
thread_self_trap=0x81,0x1b,0,
task_self_trap=0x81,0x1c,0,
host_self_trap=0x81,0x1d,0,
mach_msg_trap=0x81,0x1f,7,
mach_msg_overwrite_trap=0x81,0x20,8,
semaphore_signal_trap=0x81,0x21,1,
semaphore_signal_all_trap=0x81,0x22,1,
semaphore_signal_thread_trap=0x81,0x23,2,
semaphore_wait_trap=0x81,0x24,1,
semaphore_wait_signal_trap=0x81,0x25,2,
semaphore_timedwait_trap=0x81,0x26,3,
semaphore_timedwait_signal_trap=0x81,0x27,4,
_kernelrpc_mach_port_guard_trap=0x81,0x29,4,
_kernelrpc_mach_port_unguard_trap=0x81,0x2a,3,
mach_generate_activity_id=0x81,0x2b,3,
task_name_for_pid=0x81,0x2c,3,
task_for_pid=0x81,0x2d,3,
pid_for_task=0x81,0x2e,2,
macx_swapon=0x81,0x30,4,
macx_swapoff=0x81,0x31,2,
thread_get_special_reply_port=0x81,0x32,0,
macx_triggers=0x81,0x33,4,
macx_backing_store_suspend=0x81,0x34,1,
macx_backing_store_recovery=0x81,0x35,1,
pfz_exit=0x81,0x3a,0,
swtch_pri=0x81,0x3b,0,
swtch=0x81,0x3c,0,
thread_switch=0x81,0x3d,3,
clock_sleep_trap=0x81,0x3e,5,
host_create_mach_voucher_trap=0x81,0x46,4,
mach_voucher_extract_attr_recipe_trap=0x81,0x48,4,
mach_timebase_info_trap=0x81,0x59,1,
mach_wait_until_trap=0x81,0x5a,1,
mk_timer_create_trap=0x81,0x5b,0,
mk_timer_destroy_trap=0x81,0x5c,1,
mk_timer_arm_trap=0x81,0x5d,2,
mk_timer_cancel_trap=0x81,0x5e,2,
mk_timer_arm_leeway_trap=0x81,0x5f,4,
iokit_user_client_trap=0x81,0x64,8,
exit=0x80,0x2000001,1,
fork=0x80,0x2000002,0,
read=0x80,0x2000003,3,
write=0x80,0x2000004,3,
open=0x80,0x2000005,3,
close=0x80,0x2000006,1,
wait4=0x80,0x2000007,4,
link=0x80,0x2000009,2,
unlink=0x80,0x200000a,1,
chdir=0x80,0x200000c,1,
fchdir=0x80,0x200000d,1,
mknod=0x80,0x200000e,3,
chmod=0x80,0x200000f,2,
chown=0x80,0x2000010,3,
getfsstat=0x80,0x2000012,3,
getpid=0x80,0x2000014,0,
setuid=0x80,0x2000017,1,
getuid=0x80,0x2000018,0,
geteuid=0x80,0x2000019,0,
ptrace=0x80,0x200001a,4,
recvmsg=0x80,0x200001b,3,
sendmsg=0x80,0x200001c,3,
recvfrom=0x80,0x200001d,6,
accept=0x80,0x200001e,3,
getpeername=0x80,0x200001f,3,
getsockname=0x80,0x2000020,3,
access=0x80,0x2000021,2,
chflags=0x80,0x2000022,2,
fchflags=0x80,0x2000023,2,
sync=0x80,0x2000024,0,
kill=0x80,0x2000025,3,
getppid=0x80,0x2000027,0,
dup=0x80,0x2000029,1,
pipe=0x80,0x200002a,0,
getegid=0x80,0x200002b,0,
sigaction=0x80,0x200002e,3,
getgid=0x80,0x200002f,0,
sigprocmask=0x80,0x2000030,3,
getlogin=0x80,0x2000031,2,
setlogin=0x80,0x2000032,1,
acct=0x80,0x2000033,1,
sigpending=0x80,0x2000034,1,
sigaltstack=0x80,0x2000035,2,
ioctl=0x80,0x2000036,3,
reboot=0x80,0x2000037,2,
revoke=0x80,0x2000038,1,
symlink=0x80,0x2000039,2,
readlink=0x80,0x200003a,3,
execve=0x80,0x200003b,3,
umask=0x80,0x200003c,1,
chroot=0x80,0x200003d,1,
msync=0x80,0x2000041,3,
vfork=0x80,0x2000042,0,
munmap=0x80,0x2000049,2,
mprotect=0x80,0x200004a,3,
madvise=0x80,0x200004b,3,
mincore=0x80,0x200004e,3,
getgroups=0x80,0x200004f,2,
setgroups=0x80,0x2000050,2,
getpgrp=0x80,0x2000051,0,
setpgid=0x80,0x2000052,2,
setitimer=0x80,0x2000053,3,
swapon=0x80,0x2000055,0,
getitimer=0x80,0x2000056,2,
getdtablesize=0x80,0x2000059,0,
dup2=0x80,0x200005a,2,
fcntl=0x80,0x200005c,3,
select=0x80,0x200005d,5,
fsync=0x80,0x200005f,1,
setpriority=0x80,0x2000060,3,
socket=0x80,0x2000061,3,
connect=0x80,0x2000062,3,
getpriority=0x80,0x2000064,2,
bind=0x80,0x2000068,3,
setsockopt=0x80,0x2000069,5,
listen=0x80,0x200006a,2,
sigsuspend=0x80,0x200006f,1,
gettimeofday=0x80,0x2000074,3,
getrusage=0x80,0x2000075,2,
getsockopt=0x80,0x2000076,5,
readv=0x80,0x2000078,3,
writev=0x80,0x2000079,3,
settimeofday=0x80,0x200007a,2,
fchown=0x80,0x200007b,3,
fchmod=0x80,0x200007c,2,
setreuid=0x80,0x200007e,2,
setregid=0x80,0x200007f,2,
rename=0x80,0x2000080,2,
flock=0x80,0x2000083,2,
mkfifo=0x80,0x2000084,2,
sendto=0x80,0x2000085,6,
shutdown=0x80,0x2000086,2,
socketpair=0x80,0x2000087,4,
mkdir=0x80,0x2000088,2,
rmdir=0x80,0x2000089,1,
utimes=0x80,0x200008a,2,
futimes=0x80,0x200008b,2,
adjtime=0x80,0x200008c,2,
gethostuuid=0x80,0x200008e,3,
setsid=0x80,0x2000093,0,
getpgid=0x80,0x2000097,1,
setprivexec=0x80,0x2000098,1,
pread=0x80,0x2000099,4,
pwrite=0x80,0x200009a,4,
nfssvc=0x80,0x200009b,2,
statfs=0x80,0x200009d,2,
fstatfs=0x80,0x200009e,2,
unmount=0x80,0x200009f,2,
getfh=0x80,0x20000a1,2,
quotactl=0x80,0x20000a5,4,
mount=0x80,0x20000a7,4,
csops=0x80,0x20000a9,4,
csops_audittoken=0x80,0x20000aa,5,
waitid=0x80,0x20000ad,4,
kdebug_typefilter=0x80,0x20000b1,2,
kdebug_trace_string=0x80,0x20000b2,3,
kdebug_trace64=0x80,0x20000b3,5,
kdebug_trace=0x80,0x20000b4,5,
setgid=0x80,0x20000b5,1,
setegid=0x80,0x20000b6,1,
seteuid=0x80,0x20000b7,1,
sigreturn=0x80,0x20000b8,2,
thread_selfcounts=0x80,0x20000ba,3,
fdatasync=0x80,0x20000bb,1,
stat=0x80,0x20000bc,2,
fstat=0x80,0x20000bd,2,
lstat=0x80,0x20000be,2,
pathconf=0x80,0x20000bf,2,
fpathconf=0x80,0x20000c0,2,
getrlimit=0x80,0x20000c2,2,
setrlimit=0x80,0x20000c3,2,
getdirentries=0x80,0x20000c4,4,
mmap=0x80,0x20000c5,6,
lseek=0x80,0x20000c7,3,
truncate=0x80,0x20000c8,2,
ftruncate=0x80,0x20000c9,2,
sysctl=0x80,0x20000ca,6,
mlock=0x80,0x20000cb,2,
munlock=0x80,0x20000cc,2,
undelete=0x80,0x20000cd,1,
open_dprotected_np=0x80,0x20000d8,5,
getattrlist=0x80,0x20000dc,5,
setattrlist=0x80,0x20000dd,5,
getdirentriesattr=0x80,0x20000de,8,
exchangedata=0x80,0x20000df,3,
searchfs=0x80,0x20000e1,6,
delete=0x80,0x20000e2,1,
copyfile=0x80,0x20000e3,4,
fgetattrlist=0x80,0x20000e4,5,
fsetattrlist=0x80,0x20000e5,5,
poll=0x80,0x20000e6,3,
watchevent=0x80,0x20000e7,2,
waitevent=0x80,0x20000e8,2,
modwatch=0x80,0x20000e9,2,
getxattr=0x80,0x20000ea,6,
fgetxattr=0x80,0x20000eb,6,
setxattr=0x80,0x20000ec,6,
fsetxattr=0x80,0x20000ed,6,
removexattr=0x80,0x20000ee,3,
fremovexattr=0x80,0x20000ef,3,
listxattr=0x80,0x20000f0,4,
flistxattr=0x80,0x20000f1,4,
fsctl=0x80,0x20000f2,4,
initgroups=0x80,0x20000f3,3,
posix_spawn=0x80,0x20000f4,5,
ffsctl=0x80,0x20000f5,4,
nfsclnt=0x80,0x20000f7,2,
fhopen=0x80,0x20000f8,2,
minherit=0x80,0x20000fa,3,
semsys=0x80,0x20000fb,5,
msgsys=0x80,0x20000fc,5,
shmsys=0x80,0x20000fd,4,
semctl=0x80,0x20000fe,4,
semget=0x80,0x20000ff,3,
semop=0x80,0x2000100,3,
msgctl=0x80,0x2000102,3,
msgget=0x80,0x2000103,2,
msgsnd=0x80,0x2000104,4,
msgrcv=0x80,0x2000105,5,
shmat=0x80,0x2000106,3,
shmctl=0x80,0x2000107,3,
shmdt=0x80,0x2000108,1,
shmget=0x80,0x2000109,3,
shm_open=0x80,0x200010a,3,
shm_unlink=0x80,0x200010b,1,
sem_open=0x80,0x200010c,4,
sem_close=0x80,0x200010d,1,
sem_unlink=0x80,0x200010e,1,
sem_wait=0x80,0x200010f,1,
sem_trywait=0x80,0x2000110,1,
sem_post=0x80,0x2000111,1,
sysctlbyname=0x80,0x2000112,6,
open_extended=0x80,0x2000115,6,
umask_extended=0x80,0x2000116,2,
stat_extended=0x80,0x2000117,4,
lstat_extended=0x80,0x2000118,4,
fstat_extended=0x80,0x2000119,4,
chmod_extended=0x80,0x200011a,5,
fchmod_extended=0x80,0x200011b,5,
access_extended=0x80,0x200011c,4,
settid=0x80,0x200011d,2,
gettid=0x80,0x200011e,2,
setsgroups=0x80,0x200011f,2,
getsgroups=0x80,0x2000120,2,
setwgroups=0x80,0x2000121,2,
getwgroups=0x80,0x2000122,2,
mkfifo_extended=0x80,0x2000123,5,
mkdir_extended=0x80,0x2000124,5,
identitysvc=0x80,0x2000125,2,
shared_region_check_np=0x80,0x2000126,1,
vm_pressure_monitor=0x80,0x2000128,3,
psynch_rw_longrdlock=0x80,0x2000129,5,
psynch_rw_yieldwrlock=0x80,0x200012a,5,
psynch_rw_downgrade=0x80,0x200012b,5,
psynch_rw_upgrade=0x80,0x200012c,5,
psynch_mutexwait=0x80,0x200012d,5,
psynch_mutexdrop=0x80,0x200012e,5,
psynch_cvbroad=0x80,0x200012f,7,
psynch_cvsignal=0x80,0x2000130,8,
psynch_cvwait=0x80,0x2000131,8,
psynch_rw_rdlock=0x80,0x2000132,5,
psynch_rw_wrlock=0x80,0x2000133,5,
psynch_rw_unlock=0x80,0x2000134,5,
psynch_rw_unlock2=0x80,0x2000135,5,
getsid=0x80,0x2000136,1,
settid_with_pid=0x80,0x2000137,2,
psynch_cvclrprepost=0x80,0x2000138,7,
aio_fsync=0x80,0x2000139,2,
aio_return=0x80,0x200013a,1,
aio_suspend=0x80,0x200013b,3,
aio_cancel=0x80,0x200013c,2,
aio_error=0x80,0x200013d,1,
aio_read=0x80,0x200013e,1,
aio_write=0x80,0x200013f,1,
lio_listio=0x80,0x2000140,4,
iopolicysys=0x80,0x2000142,2,
process_policy=0x80,0x2000143,7,
mlockall=0x80,0x2000144,1,
munlockall=0x80,0x2000145,1,
issetugid=0x80,0x2000147,0,
__pthread_kill=0x80,0x2000148,2,
__pthread_sigmask=0x80,0x2000149,3,
__sigwait=0x80,0x200014a,2,
__disable_threadsignal=0x80,0x200014b,1,
__pthread_markcancel=0x80,0x200014c,1,
__pthread_canceled=0x80,0x200014d,1,
__semwait_signal=0x80,0x200014e,6,
proc_info=0x80,0x2000150,6,
sendfile=0x80,0x2000151,6,
stat64=0x80,0x2000152,2,
fstat64=0x80,0x2000153,2,
lstat64=0x80,0x2000154,2,
stat64_extended=0x80,0x2000155,4,
lstat64_extended=0x80,0x2000156,4,
fstat64_extended=0x80,0x2000157,4,
getdirentries64=0x80,0x2000158,4,
statfs64=0x80,0x2000159,2,
fstatfs64=0x80,0x200015a,2,
getfsstat64=0x80,0x200015b,3,
__pthread_chdir=0x80,0x200015c,1,
__pthread_fchdir=0x80,0x200015d,1,
audit=0x80,0x200015e,2,
auditon=0x80,0x200015f,3,
getauid=0x80,0x2000161,1,
setauid=0x80,0x2000162,1,
getaudit_addr=0x80,0x2000165,2,
setaudit_addr=0x80,0x2000166,2,
auditctl=0x80,0x2000167,1,
bsdthread_create=0x80,0x2000168,5,
bsdthread_terminate=0x80,0x2000169,4,
kqueue=0x80,0x200016a,0,
kevent=0x80,0x200016b,6,
lchown=0x80,0x200016c,3,
bsdthread_register=0x80,0x200016e,7,
workq_open=0x80,0x200016f,0,
workq_kernreturn=0x80,0x2000170,4,
kevent64=0x80,0x2000171,7,
__old_semwait_signal=0x80,0x2000172,5,
__old_semwait_signal_nocancel=0x80,0x2000173,5,
thread_selfid=0x80,0x2000174,0,
ledger=0x80,0x2000175,4,
kevent_qos=0x80,0x2000176,8,
kevent_id=0x80,0x2000177,8,
__mac_execve=0x80,0x200017c,4,
__mac_syscall=0x80,0x200017d,3,
__mac_get_file=0x80,0x200017e,2,
__mac_set_file=0x80,0x200017f,2,
__mac_get_link=0x80,0x2000180,2,
__mac_set_link=0x80,0x2000181,2,
__mac_get_proc=0x80,0x2000182,1,
__mac_set_proc=0x80,0x2000183,1,
__mac_get_fd=0x80,0x2000184,2,
__mac_set_fd=0x80,0x2000185,2,
__mac_get_pid=0x80,0x2000186,2,
pselect=0x80,0x200018a,6,
pselect_nocancel=0x80,0x200018b,6,
read_nocancel=0x80,0x200018c,3,
write_nocancel=0x80,0x200018d,3,
open_nocancel=0x80,0x200018e,3,
close_nocancel=0x80,0x200018f,1,
wait4_nocancel=0x80,0x2000190,4,
recvmsg_nocancel=0x80,0x2000191,3,
sendmsg_nocancel=0x80,0x2000192,3,
recvfrom_nocancel=0x80,0x2000193,6,
accept_nocancel=0x80,0x2000194,3,
msync_nocancel=0x80,0x2000195,3,
fcntl_nocancel=0x80,0x2000196,3,
select_nocancel=0x80,0x2000197,5,
fsync_nocancel=0x80,0x2000198,1,
connect_nocancel=0x80,0x2000199,3,
sigsuspend_nocancel=0x80,0x200019a,1,
readv_nocancel=0x80,0x200019b,3,
writev_nocancel=0x80,0x200019c,3,
sendto_nocancel=0x80,0x200019d,6,
pread_nocancel=0x80,0x200019e,4,
pwrite_nocancel=0x80,0x200019f,4,
waitid_nocancel=0x80,0x20001a0,4,
poll_nocancel=0x80,0x20001a1,3,
msgsnd_nocancel=0x80,0x20001a2,4,
msgrcv_nocancel=0x80,0x20001a3,5,
sem_wait_nocancel=0x80,0x20001a4,1,
aio_suspend_nocancel=0x80,0x20001a5,3,
__sigwait_nocancel=0x80,0x20001a6,2,
__semwait_signal_nocancel=0x80,0x20001a7,6,
__mac_mount=0x80,0x20001a8,5,
__mac_get_mount=0x80,0x20001a9,2,
__mac_getfsstat=0x80,0x20001aa,5,
fsgetpath=0x80,0x20001ab,4,
audit_session_self=0x80,0x20001ac,0,
audit_session_join=0x80,0x20001ad,1,
fileport_makeport=0x80,0x20001ae,2,
fileport_makefd=0x80,0x20001af,1,
audit_session_port=0x80,0x20001b0,2,
pid_suspend=0x80,0x20001b1,1,
pid_resume=0x80,0x20001b2,1,
pid_hibernate=0x80,0x20001b3,1,
pid_shutdown_sockets=0x80,0x20001b4,2,
shared_region_map_and_slide_np=0x80,0x20001b6,6,
kas_info=0x80,0x20001b7,3,
memorystatus_control=0x80,0x20001b8,5,
guarded_open_np=0x80,0x20001b9,5,
guarded_close_np=0x80,0x20001ba,2,
guarded_kqueue_np=0x80,0x20001bb,2,
change_fdguard_np=0x80,0x20001bc,6,
usrctl=0x80,0x20001bd,1,
proc_rlimit_control=0x80,0x20001be,3,
connectx=0x80,0x20001bf,8,
disconnectx=0x80,0x20001c0,3,
peeloff=0x80,0x20001c1,2,
socket_delegate=0x80,0x20001c2,4,
telemetry=0x80,0x20001c3,6,
proc_uuid_policy=0x80,0x20001c4,4,
memorystatus_get_level=0x80,0x20001c5,1,
system_override=0x80,0x20001c6,2,
vfs_purge=0x80,0x20001c7,0,
sfi_ctl=0x80,0x20001c8,4,
sfi_pidctl=0x80,0x20001c9,4,
coalition=0x80,0x20001ca,3,
coalition_info=0x80,0x20001cb,4,
necp_match_policy=0x80,0x20001cc,3,
getattrlistbulk=0x80,0x20001cd,5,
clonefileat=0x80,0x20001ce,5,
openat=0x80,0x20001cf,4,
openat_nocancel=0x80,0x20001d0,4,
renameat=0x80,0x20001d1,4,
faccessat=0x80,0x20001d2,4,
fchmodat=0x80,0x20001d3,4,
fchownat=0x80,0x20001d4,5,
fstatat=0x80,0x20001d5,4,
fstatat64=0x80,0x20001d6,4,
linkat=0x80,0x20001d7,5,
unlinkat=0x80,0x20001d8,3,
readlinkat=0x80,0x20001d9,4,
symlinkat=0x80,0x20001da,3,
mkdirat=0x80,0x20001db,3,
getattrlistat=0x80,0x20001dc,6,
proc_trace_log=0x80,0x20001dd,2,
bsdthread_ctl=0x80,0x20001de,4,
openbyid_np=0x80,0x20001df,3,
recvmsg_x=0x80,0x20001e0,4,
sendmsg_x=0x80,0x20001e1,4,
thread_selfusage=0x80,0x20001e2,0,
csrctl=0x80,0x20001e3,3,
guarded_open_dprotected_np=0x80,0x20001e4,7,
guarded_write_np=0x80,0x20001e5,4,
guarded_pwrite_np=0x80,0x20001e6,5,
guarded_writev_np=0x80,0x20001e7,4,
renameatx_np=0x80,0x20001e8,5,
mremap_encrypted=0x80,0x20001e9,5,
netagent_trigger=0x80,0x20001ea,2,
stack_snapshot_with_config=0x80,0x20001eb,3,
microstackshot=0x80,0x20001ec,3,
grab_pgo_data=0x80,0x20001ed,4,
persona=0x80,0x20001ee,5,
work_interval_ctl=0x80,0x20001f3,4,
getentropy=0x80,0x20001f4,2,
necp_open=0x80,0x20001f5,1,
necp_client_action=0x80,0x20001f6,6,
ulock_wait=0x80,0x2000203,4,
ulock_wake=0x80,0x2000204,3,
fclonefileat=0x80,0x2000205,4,
fs_snapshot=0x80,0x2000206,6,
terminate_with_payload=0x80,0x2000208,7,
abort_with_payload=0x80,0x2000209,6,
necp_session_open=0x80,0x200020a,1,
necp_session_action=0x80,0x200020b,6,
setattrlistat=0x80,0x200020c,6,
net_qos_guideline=0x80,0x200020d,2,
fmount=0x80,0x200020e,4,
ntp_adjtime=0x80,0x200020f,1,
ntp_gettime=0x80,0x2000210,1,
os_fault_with_payload=0x80,0x2000211,6,
_kernelrpc_mach_vm_allocate_trap=0x81,0x100000a,4,
_kernelrpc_mach_vm_purgable_control_trap=0x81,0x100000b,4,
_kernelrpc_mach_vm_deallocate_trap=0x81,0x100000c,3,
_kernelrpc_mach_vm_protect_trap=0x81,0x100000e,5,
_kernelrpc_mach_vm_map_trap=0x81,0x100000f,6,
_kernelrpc_mach_port_allocate_trap=0x81,0x1000010,3,
_kernelrpc_mach_port_destroy_trap=0x81,0x1000011,2,
_kernelrpc_mach_port_deallocate_trap=0x81,0x1000012,2,
_kernelrpc_mach_port_mod_refs_trap=0x81,0x1000013,4,
_kernelrpc_mach_port_move_member_trap=0x81,0x1000014,3,
_kernelrpc_mach_port_insert_right_trap=0x81,0x1000015,4,
_kernelrpc_mach_port_insert_member_trap=0x81,0x1000016,3,
_kernelrpc_mach_port_extract_member_trap=0x81,0x1000017,3,
_kernelrpc_mach_port_construct_trap=0x81,0x1000018,4,
_kernelrpc_mach_port_destruct_trap=0x81,0x1000019,4,
mach_reply_port=0x81,0x100001a,0,
thread_self_trap=0x81,0x100001b,0,
task_self_trap=0x81,0x100001c,0,
host_self_trap=0x81,0x100001d,0,
mach_msg_trap=0x81,0x100001f,7,
mach_msg_overwrite_trap=0x81,0x1000020,8,
semaphore_signal_trap=0x81,0x1000021,1,
semaphore_signal_all_trap=0x81,0x1000022,1,
semaphore_signal_thread_trap=0x81,0x1000023,2,
semaphore_wait_trap=0x81,0x1000024,1,
semaphore_wait_signal_trap=0x81,0x1000025,2,
semaphore_timedwait_trap=0x81,0x1000026,3,
semaphore_timedwait_signal_trap=0x81,0x1000027,4,
_kernelrpc_mach_port_guard_trap=0x81,0x1000029,4,
_kernelrpc_mach_port_unguard_trap=0x81,0x100002a,3,
mach_generate_activity_id=0x81,0x100002b,3,
task_name_for_pid=0x81,0x100002c,3,
task_for_pid=0x81,0x100002d,3,
pid_for_task=0x81,0x100002e,2,
macx_swapon=0x81,0x1000030,4,
macx_swapoff=0x81,0x1000031,2,
thread_get_special_reply_port=0x81,0x1000032,0,
macx_triggers=0x81,0x1000033,4,
macx_backing_store_suspend=0x81,0x1000034,1,
macx_backing_store_recovery=0x81,0x1000035,1,
pfz_exit=0x81,0x100003a,0,
swtch_pri=0x81,0x100003b,0,
swtch=0x81,0x100003c,0,
thread_switch=0x81,0x100003d,3,
clock_sleep_trap=0x81,0x100003e,5,
host_create_mach_voucher_trap=0x81,0x1000046,4,
mach_voucher_extract_attr_recipe_trap=0x81,0x1000048,4,
mach_timebase_info_trap=0x81,0x1000059,1,
mach_wait_until_trap=0x81,0x100005a,1,
mk_timer_create_trap=0x81,0x100005b,0,
mk_timer_destroy_trap=0x81,0x100005c,1,
mk_timer_arm_trap=0x81,0x100005d,2,
mk_timer_cancel_trap=0x81,0x100005e,2,
mk_timer_arm_leeway_trap=0x81,0x100005f,4,
iokit_user_client_trap=0x81,0x1000064,8,
import requests
def get_bsd_syscall_list():
return requests.get('https://sigsegv.pl/osx-bsd-syscalls/osx-bsd-syscalls.json').json()
def get_mach_traps_list():
return requests.get('https://sigsegv.pl/osx-mach-traps/osx-mach-traps.json').json()
sc_list = []
for sc in get_bsd_syscall_list():
if sc[0][0] == '#': # #if/#else
continue
name = sc[2]
if 'nosys' in name:
continue
number = int(sc[0])
arg_cnt = int(sc[3])
sc_list.append([0, name, number, arg_cnt, ''])
for sc in get_mach_traps_list():
name = sc[2]
if name == 'kern_invalid':
continue
number = int(sc[0])
arg_cnt = int(sc[3])
sc_list.append([1, name, number, arg_cnt, ''])
with open('darwin-x86-32.sdb.txt', 'w') as f:
for s in sc_list:
f.write('{}=0x{:x},0x{:x},{},{}\n'.format(
s[1],
0x80 + s[0],
s[2],
s[3],
s[4]
))
with open('darwin-x86-64.sdb.txt', 'w') as f:
for s in sc_list:
f.write('{}=0x{:x},0x{:x},{},{}\n'.format(
s[1],
0x80 + s[0],
s[2] + (0x2000000 if s[0] == 0 else 0x1000000),
s[3],
s[4]
))
@jacobrosenthal
Copy link

Head up, Ive found radare wont catch these machs because theyre not on 0x80. ( all the interrupts get looked up in get_swi as -1 which turns then turns them into 0x80) so Im going to have to patch upstream all the 0x81 to 80.

@jacobrosenthal
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment