Skip to content

A better fuzzing seed corpus collection #3067

Open
@quasilyte

Description

What should be done?

Right now we're using ./tmp/records that are created by the integration tests to increase the fuzzing corpus of sjson.

This is sub-optimal, because it seems like most of the documents are not "valid" data documents. The sjson fuzzing applies some document validation, so invalid documents are skipped.

After 35mins of integration testing, I got 3348 .bin entries in the ./tmp/records folder. 3 repetitive runs of fuzzing report 0 documents being added to the corpus. I double-checked that this is due to the fact that these documents can't pass the validation.

if doc.ValidateData() != nil {
	continue
}

We could try finding a better way to generate a corpus for sjson fuzzing purposes.

This is a separate issue from #1273, so it can be planned, analyzed, and estimated separately.

Where?

sjson package + something new that provides that new corpus.

Definition of Done

  • all handlers updated;
  • unit tests added/updated;
  • integration/compatibility tests added/updated;
  • spot refactorings done;
  • user documentation updated or an issue to create documentation created;
  • something else?

Metadata

Assignees

Labels

area/fuzzIssues about fuzzing and smithingarea/typesIssues about data types, BSON, wire protocol, etccode/choreCode maintenance improvementsnot readyIssues that are not ready to be worked on; PRs that should skip CI

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions