Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add fuzzing by way of ClusterFuzzLite #120

Merged
merged 1 commit into from
Jan 15, 2024

Conversation

DavidKorczynski
Copy link
Contributor

This adds fuzzing by way of
ClusterFuzzLite, which is a GitHub action that will perform a short amount of fuzzing for new PRs. The goal is to use fuzzing to catch bugs that may be introduced by new PRs.

This adds fuzzing by way of
[ClusterFuzzLite](https://google.github.io/clusterfuzzlite/), which is a
GitHub action that will perform a short amount of fuzzing for new PRs.
The goal is to use fuzzing to catch bugs that may be introduced by new
PRs.

Signed-off-by: David Korczynski <david@adalogics.com>
DavidKorczynski added a commit to DavidKorczynski/HdrHistogram_c that referenced this pull request Jan 14, 2024
This was found by the fuzzer added in
HdrHistogram#120

Signed-off-by: David Korczynski <david@adalogics.com>
DavidKorczynski added a commit to DavidKorczynski/HdrHistogram_c that referenced this pull request Jan 14, 2024
The fuzzer from HdrHistogram#120
found some leaks when the `hdr_decode_compressed*` functions call
`hdr_init` but later fails and cleans up `h` by way of `hdr_free(h)`.
The problem is that the `counts` field on the histogram is leaked, which
is allocated
https://github.com/HdrHistogram/HdrHistogram_c/blob/8dcce8f68512fca460b171bccc3a5afce0048779/src/hdr_histogram.c#L424
and assigned to the `counts` field here:
https://github.com/HdrHistogram/HdrHistogram_c/blob/8dcce8f68512fca460b171bccc3a5afce0048779/src/hdr_histogram.c#L437

Signed-off-by: David Korczynski <david@adalogics.com>
@DavidKorczynski
Copy link
Contributor Author

The leak blocking the fuzzer is addressed in #122

mikeb01 pushed a commit that referenced this pull request Jan 15, 2024
This was found by the fuzzer added in
#120

Signed-off-by: David Korczynski <david@adalogics.com>
mikeb01 pushed a commit that referenced this pull request Jan 15, 2024
The fuzzer from #120
found some leaks when the `hdr_decode_compressed*` functions call
`hdr_init` but later fails and cleans up `h` by way of `hdr_free(h)`.
The problem is that the `counts` field on the histogram is leaked, which
is allocated
https://github.com/HdrHistogram/HdrHistogram_c/blob/8dcce8f68512fca460b171bccc3a5afce0048779/src/hdr_histogram.c#L424
and assigned to the `counts` field here:
https://github.com/HdrHistogram/HdrHistogram_c/blob/8dcce8f68512fca460b171bccc3a5afce0048779/src/hdr_histogram.c#L437

Signed-off-by: David Korczynski <david@adalogics.com>
@mikeb01 mikeb01 merged commit c818722 into HdrHistogram:main Jan 15, 2024
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants