From 3fddc7194573e00eabde07dbb8ff17b025eb5c75 Mon Sep 17 00:00:00 2001 From: Hrutvik Kanabar Date: Tue, 20 Sep 2022 14:43:25 +0000 Subject: pkg/mgrconfig, prog, syz-fuzzer: manager-configurable syscall mutation Allow manager configuration to specify that certain syscalls should not be mutated. This is expected to be useful when mutating certain syscalls is unlikely to produce interesting executions. For example, mutating a `syz_mount_image` call will likely produce a corrupt image. Some implementation details: - Add a `no_mutate_syscalls` manager config entry, with the same format as `enable_syscalls`. Ensure this is parsed and stored in the config as a set of syscall IDs. - Send this set to fuzzers when they connect to their managers via RPC. Ensure each fuzzer stores a copy of the set. - When mutating arguments of a syscall, check first whether it has been specified as non-mutatable. - For all mutations not managed by a `syz-manager`, retain previous behaviour by ensuring that no syscalls are considered non-mutable. --- prog/test/fuzz.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'prog/test') diff --git a/prog/test/fuzz.go b/prog/test/fuzz.go index 0d2807f7f..5857ff98d 100644 --- a/prog/test/fuzz.go +++ b/prog/test/fuzz.go @@ -53,7 +53,7 @@ func FuzzDeserialize(data []byte) int { panic(err) } } - p3.Mutate(rand.NewSource(0), 3, fuzzChoiceTable, nil) + p3.Mutate(rand.NewSource(0), 3, fuzzChoiceTable, nil, nil) return 0 } -- cgit mrf-deployment