Skip to content

Commit 1ff8826

Browse files
committed
syz-cluster: log possible findings at the end of fuzzing
It does happen that we detect a bug that was introduced in the patch series, but we don't report it becase no reliable reproducer was found. Let's at least log such cases to better understand the scale of the problem. 10 is an arbitrary cut-off value.
1 parent 807a3b6 commit 1ff8826

File tree

1 file changed

+15
-1
lines changed
  • syz-cluster/workflow/fuzz-step

1 file changed

+15
-1
lines changed

syz-cluster/workflow/fuzz-step/main.go

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,12 +76,26 @@ func main() {
7676
status = api.TestError
7777
}
7878
log.Logf(0, "fuzzing is finished")
79-
log.Logf(0, "status at the end:\n%s", store.PlainTextDump())
79+
logFinalState(store)
8080
if err := reportStatus(ctx, client, status, store); err != nil {
8181
app.Fatalf("failed to update the test: %v", err)
8282
}
8383
}
8484

85+
func logFinalState(store *manager.DiffFuzzerStore) {
86+
log.Logf(0, "status at the end:\n%s", store.PlainTextDump())
87+
88+
// There can be findings that we did not report only because we failed
89+
// to come up with a reproducer.
90+
// Let's log such cases so that it's easier to find and manually review them.
91+
const countCutOff = 10
92+
for _, bug := range store.List() {
93+
if bug.Base.Crashes == 0 && bug.Patched.Crashes >= countCutOff {
94+
log.Logf(0, "possibly patched-only: %s", bug.Title)
95+
}
96+
}
97+
}
98+
8599
var errSkipFuzzing = errors.New("skip")
86100

87101
func run(baseCtx context.Context, client *api.Client, timeout time.Duration,

0 commit comments

Comments
 (0)