diff options
| author | Aleksandr Nogikh <nogikh@google.com> | 2024-01-22 12:09:32 +0100 |
|---|---|---|
| committer | Aleksandr Nogikh <nogikh@google.com> | 2024-01-22 18:19:36 +0000 |
| commit | ef01311589507ea3919e3804f43781eeb0ca9777 (patch) | |
| tree | c55a9742423f78afcaaf6af2eeb37d8f75830804 /pkg/instance | |
| parent | 9bd8dcda8c7c494d59bd3132a668f4784ea835c6 (diff) | |
all: refactor pprof endpoint configuration
In some cases (e.g. gVisor instances using host's network namespace)
attempts to bind() all syz-fuzzer processes to the same port result in
conflicts and fuzzing breakages.
Refactor the code to enable custom pprof configuration depending on the
vm type.
For now, just disable pprof endpoints for gVisor VMs. Once we actually
need the feature there, we can generate custom ports for every gVisor
VM.
Diffstat (limited to 'pkg/instance')
| -rw-r--r-- | pkg/instance/instance.go | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/pkg/instance/instance.go b/pkg/instance/instance.go index 7696a945d..2f48cdbc7 100644 --- a/pkg/instance/instance.go +++ b/pkg/instance/instance.go @@ -459,6 +459,7 @@ type OptionalFuzzerArgs struct { Slowdown int RawCover bool SandboxArg int + PprofPort int } type FuzzerCmdArgs struct { @@ -500,6 +501,7 @@ func FuzzerCmd(args *FuzzerCmdArgs) string { {Name: "slowdown", Value: fmt.Sprint(args.Optional.Slowdown)}, {Name: "raw_cover", Value: fmt.Sprint(args.Optional.RawCover)}, {Name: "sandbox_arg", Value: fmt.Sprint(args.Optional.SandboxArg)}, + {Name: "pprof_port", Value: fmt.Sprint(args.Optional.PprofPort)}, } optionalArg = " " + tool.OptionalFlags(flags) } |
