aboutsummaryrefslogtreecommitdiffstats
path: root/executor
Commit message (Collapse)AuthorAgeFilesLines
* sys/linux: add trusty supportDmitry Vyukov2019-01-142-5/+80
| | | | | | Add support for trusty tipc devices and several trusty app ports. Update #933
* sys/linux: Add syscalls to read from sockets for crypto operationsZubin Mithra2019-01-142-5/+10
| | | | | | sockaddr_alg with salg_type as "skcipher", "aead", "hash" and "rng" support for reading from these sockets. Add read descriptions to socket_alg.txt.
* executor: adapt switching to user nobody to be more portable on BSDsKamil Rytarowski2019-01-141-5/+10
| | | | | | | | | NetBSD uses different uid/gid than FreeBSD/OpenBSD for the user nobody. Instead of hardcoding the values, retrieve it from the password entry database. While there, switch to setuid(2) and setgid(2) calls as they are good enough and portable. setresgid(2) and setresuid(2) aren't available on NetBSD.
* executor: do not call setrlimit(2) for RLIMIT_AS for NetBSDKamil Rytarowski2019-01-141-2/+4
| | | Setting the limit caused abnormal failure during early init on NetBSD.
* executor: update KCOV support for FreeBSDMichael Tuexen2019-01-141-17/+4
| | | | | | KCOV support has been added to FreeBSD in r342962. Use the header file and update the code to latest changes introduced in the review process.
* executor: disable gen.go for NetBSDKamil Rytarowski2019-01-101-1/+1
| | | kvm is Linux specific.
* tools/syz-trace2syz/proggen/proggen_test.go: test ipv6 address conversionShankara Pailoor2019-01-101-5/+5
|
* sys/linux: add rand_addr option to ipv6_addr unionShankara Pailoor2019-01-101-5/+5
| | | | | | | rand_addr option is the first option for the ipv6_addr union and is just an array of 16 bytes. This option makes it easy for trace2syz to convert ipv6 address as strace decodes the ipv6 address as a hex string.
* executor: adapt os_init() to NetBSD with PaX MPROTECTKamil Rytarowski2019-01-091-0/+3
| | | | | | Initialize syz data segment with protection allowed by PaX MPROTECT. PROT_MPROTECT() registers future potential protection that is allowed to be enabled in future.
* sys/linux: prohibit SNAPSHOT_FREEZEDmitry Vyukov2019-01-061-5/+5
| | | | SNAPSHOT_FREEZE freezes all processes and leaves the machine dead.
* sys/linux: add /dev/ppp descriptionsDmitry Vyukov2019-01-042-5/+105
|
* sys/linux: detail ifla_vf_policy/ifla_port_policy/ifla_xdp_policyDmitry Vyukov2018-12-301-5/+5
|
* sys/linux: add can routesDmitry Vyukov2018-12-301-5/+5
|
* sys/linux: add AF_RXRPC descriptionsDmitry Vyukov2018-12-302-5/+55
|
* sys/linux: add /dev/mISDNtimerDmitry Vyukov2018-12-302-5/+20
|
* sys/linux: open more of /dev/ filesDmitry Vyukov2018-12-302-5/+25
| | | | | | | /dev/vfio/vfio /dev/btrfs-control /dev/ubi_ctrl /dev/cachefiles
* executor: fix linux includesDmitry Vyukov2018-12-291-9/+10
| | | | | | | | | | | Builds in one distro, but another says: In file included from <stdin>:39:0: /usr/powerpc64le-linux-gnu/include/linux/if.h:143:8: error: redefinition of ‘struct ifmap’ /usr/powerpc64le-linux-gnu/include/net/if.h:111:8: note: originally defined here Mess. Try to fix it. Not sure what's the right solution and it it even exists.
* sys/linux: add AF_ISDN descriptionsDmitry Vyukov2018-12-292-5/+155
|
* sys/linux: describe /dev/vhci interfaceDmitry Vyukov2018-12-292-5/+10
|
* sys/linux: misc assorted improvementsDmitry Vyukov2018-12-292-5/+10
| | | | | | Add new bpf consts/commands. Refine bluetooth descriptions. Remove removed crypto consts.
* executor: use netlink instead of ip command to setup net devicesDmitry Vyukov2018-12-291-151/+386
| | | | | | | | | | | | | | | ip command caused several problems: 1. It is installed in different locations or not installed at all in different distros. 2. It does not support latest kernel devices, e.g. setup of hsr currently fails because our ip does not understand its custom prose. 3. ip command is slow, unbearably slow in emulator (full setup takes tens of seconds). This change reduces setup from ~2s to ~400ms. 4. ip is not present in gvisor, but it will support netlink. Use netlink directly to solve all these problems.
* executor: log failure in write_fileDmitry Vyukov2018-12-291-41/+15
| | | | | | Almost all callers of write_file just log the failure. Log the failure in write_file directly to remove lots of "error handling" code.
* executor: Fix FreeBSD such all platforms use same number of entriesMichael Tuexen2018-12-291-1/+2
| | | | | | | FreeBSD sets the kcov buffer as number of bytes instead of number of entries. This also fixes the mmap() call, which was failing due to inconsistent sizes. The failing was hidden due to wrong error handling.
* executor: fix error handling of mmap()Michael Tuexen2018-12-291-6/+5
| | | | | mmap() returns MAP_FAILED, which is (void *)(-1), in case of an error. This is different from NULL.
* executor: add clarifying comment for FreeBSD.Michael Tuexen2018-12-291-0/+6
|
* executor: add a clarifying commentMichael Tuexen2018-12-291-0/+2
|
* executor: use function argument instead of global variable.Michael Tuexen2018-12-291-1/+1
|
* sys/linux: refine few types in NETLINK_ROUTEDmitry Vyukov2018-12-291-5/+5
|
* executor: improve kcov compatibility with upcoming supportMichael Tuexen2018-12-281-3/+8
| | | | | Get ioctl() definitions and usage in sync with the upcoming support reviewed in https://reviews.freebsd.org/D14599.
* executor: KIOENABLE accepts a mode argument on OpenBSDAnton Lindqvist2018-12-281-5/+3
|
* pkg/csource: use 0 for missing syscall argsDmitry Vyukov2018-12-273-13/+55
| | | | | | | | | | | | | | We don't specify trailing unused args for some syscalls (e.g. ioctl that does not use its arg). Executor always filled tailing unsed args with 0's but pkg/csource didn't. Some such syscalls actually check that the unsed arg is 0 and as the result failed with C repro. We could statically check and eliminate all such cases, but it turns out the warning fires in 1500+ cases: https://gist.githubusercontent.com/dvyukov/e59ba1d9a211ee32fa0ba94fab86a943/raw/a3ace5a63f7281f0298f51ea9842ead1e4713418/gistfile1.txt So instead fill such args with 0's in pkg/csource too.
* executor: include sys/kcov.h on OpenBSDAnton Lindqvist2018-12-271-3/+6
| | | | Since we no longer cross-compile, there's no need to repeat the defines.
* executor: fix max number of syscall argsDmitry Vyukov2018-12-261-1/+1
| | | | De-hardcode max number (wrong) of syscall args.
* executor: create more net devices on linuxDmitry Vyukov2018-12-263-27/+63
|
* executor: restrict ipc resource usageDmitry Vyukov2018-12-261-1/+25
| | | | | For context see: https://groups.google.com/d/msg/syzkaller-bugs/ZaBzAJbn6i8/Py9FVlAqDQAJ
* sys/linux: add network drop monitor supportDmitry Vyukov2018-12-242-5/+20
|
* sys/linux: add udmabuf descriptionsDmitry Vyukov2018-12-242-5/+20
|
* sys/linux: add basic AF_CAIF descriptionsDmitry Vyukov2018-12-242-5/+30
|
* sys/linux: add basic X25 descriptionsDmitry Vyukov2018-12-242-5/+120
|
* sys/linux: extend AX25/ROSE/NETROM descriptionsDmitry Vyukov2018-12-244-67/+233
|
* sys/linux: add CRYPTO_MSG_GETSTATDmitry Vyukov2018-12-221-5/+5
|
* sys/linux: add RTM_NEWNSID/RTM_GETNSIDDmitry Vyukov2018-12-221-5/+5
|
* sys/linux: add fs-verity ioctlsVictor Hsieh2018-12-182-5/+15
| | | | | | | | This adds 2 ioctls and an argument type: - FS_IOC_ENABLE_VERITY - FS_IOC_MEASURE_VERITY - struct fsverity_digest Note fs-verity on-disk structs are not yet added.
* prog, pkg/csource: more readable serialization for stringsDmitry Vyukov2018-12-153-4/+7
| | | | | | | Always serialize strings in readable format (non-hex). Serialize binary data in readable format in more cases. Fixes #792
* executor: move setrlimit from setup_control_pipes to bsd os_initDmitry Vyukov2018-12-142-6/+5
| | | | This broke fuchsia build. We need setrlimit only for bsd.
* pkg/csource: support tun and setuid repros on {free,open}bsdGreg Steuck2018-12-132-2/+8
| | | | | | * expose procid on BSD for tun, always declare loop() * deal with terrible bsd includes * replicate loop() declaration
* sys/linux: add basic tipc testDmitry Vyukov2018-12-121-1/+2
|
* executor: reapply setuid sandbox for bsdGreg Steuck2018-12-113-19/+80
| | | | | | | | | | * Revert "Revert "executor: add setuid sandbox for openbsd"" The problem is the low file descriptor limit. This reverts commit 4093e33b1338f274ae0062f555de9d6af8640d61. * executor/executor make sure the file descriptor limit is sufficient
* Revert "executor: add setuid sandbox for openbsd"Greg Steuck2018-12-102-74/+19
| | | | This reverts commit 6565f24da9f4eb36702339ba290213995fcc902f.
* prog: support AUTO args in programsDmitry Vyukov2018-12-102-4/+5
| | | | | | | | | | | | | | | AUTO arguments can be used for: - consts - lens - pointers For const's and len's AUTO is replaced with the natural value, addresses for AUTO pointers are allocated linearly. This greatly simplifies writing test programs by hand as most of the time we want these natural values. Update tests to use AUTO.