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

Fix tag count overflow causing huge memory allocs #5

Merged
merged 1 commit into from
Mar 3, 2020

Conversation

csmith
Copy link
Member

@csmith csmith commented Mar 3, 2020

If the tag count is something silly like 2^16, when it's
multiplied by the size of the field it is very likely
to overflow.

This can result in reading a small number of bytes
successfully, but then later on trying to allocate
a massive slice to hold all the tags.

Closes #1

If the tag count is something silly like 2^16, when it's
multiplied by the size of the field it is very likely
to overflow.

This can result in reading a small number of bytes
successfully, but then later on trying to allocate
a massive slice to hold all the tags.

Closes cutlerydrawer#1
@csmith csmith added the automerge PR should be automatically merged when approved label Mar 3, 2020
@csmith csmith merged commit e9598fd into cutlerydrawer:master Mar 3, 2020
@csmith csmith deleted the tag-count-overflow branch March 3, 2020 12:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
automerge PR should be automatically merged when approved
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Fuzz: tiff.(*Tag).convertVals tries to allocate multi-gig slice
1 participant