diff options
| author | Aleksandr Nogikh <nogikh@google.com> | 2024-01-05 17:58:50 +0100 |
|---|---|---|
| committer | Aleksandr Nogikh <nogikh@google.com> | 2024-01-05 17:28:48 +0000 |
| commit | 397c964fceb327fe12c6f42334b879e1887412fc (patch) | |
| tree | 93920e35277d433e0cc9eb11eaf4a48fe4a8ad78 /pkg/csource | |
| parent | ed58bbb9537b28097e0d75fd34a70b40beebd481 (diff) | |
executor: prevent netlink_send_ext with dofail=true
This should never be happening during fuzzing. Otherwise we let
syz-executor silently crash and restart insane number of times.
Diffstat (limited to 'pkg/csource')
| -rw-r--r-- | pkg/csource/generated.go | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/pkg/csource/generated.go b/pkg/csource/generated.go index 95820779a..dbb18a811 100644 --- a/pkg/csource/generated.go +++ b/pkg/csource/generated.go @@ -2909,6 +2909,11 @@ static void find_vf_interface(void) static int netlink_send_ext(struct nlmsg* nlmsg, int sock, uint16 reply_type, int* reply_len, bool dofail) { +#if SYZ_EXECUTOR + if (in_execute_one && dofail) { + failmsg("invalid netlink_send_ext arguments", "dofail is true during syscall execution"); + } +#endif if (nlmsg->pos > nlmsg->buf + sizeof(nlmsg->buf) || nlmsg->nesting) fail("nlmsg overflow/bad nesting"); struct nlmsghdr* hdr = (struct nlmsghdr*)nlmsg->buf; |
