Skip to content
Snippets Groups Projects
Commit a3a7c6dc authored by Alan Coopersmith's avatar Alan Coopersmith
Browse files

Fix CVE-2022-46285: Infinite loop on unclosed comments


When reading XPM images from a file with libXpm 3.5.14 or older, if a
comment in the file is not closed (i.e. a C-style comment starts with
"/*" and is missing the closing "*/"), the ParseComment() function will
loop forever calling getc() to try to read the rest of the comment,
failing to notice that it has returned EOF, which may cause a denial of
service to the calling program.

Reported-by: default avatarMarco Ivaldi <raptor@0xdeadbeef.info>
Signed-off-by: default avatarAlan Coopersmith <alan.coopersmith@oracle.com>
parent f7a167a4
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment