Skip to content
This repository was archived by the owner on Feb 12, 2025. It is now read-only.

[SECURITY] Verify LZW code fits in 12 bits before we use it#8

Merged
ctrlcctrlv merged 1 commit intomasterfrom
CVE_2020_19668
Jun 9, 2021
Merged

[SECURITY] Verify LZW code fits in 12 bits before we use it#8
ctrlcctrlv merged 1 commit intomasterfrom
CVE_2020_19668

Conversation

@ctrlcctrlv
Copy link
Copy Markdown
Collaborator

The type unsigned short, which is the type of the LZW code, is much
larger than the max of an LZW code, causing a wild pointer.

That causes an array overflow. Long term, this library should jettison
this unnecessary GIF code, and use a better maintained library for it.
In the meantime, however, the issue is simple enough to solve, so I've
done so.

Resolves CVE-2020-19668.
Closes saitoha#136.
Closes #7.

The type `unsigned short`, which is the type of the LZW code, is much
larger than the max of an LZW code, causing a wild pointer.

That causes an array overflow. Long term, this library should jettison
this unnecessary GIF code, and use a better maintained library for it.
In the meantime, however, the issue is simple enough to solve, so I've
done so.

Resolves CVE-2020-19668.
Closes saitoha#136.
Closes #7.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

1 participant