Repository navigation
Commit 04a4b26
[CVE-2022-40303] Fix integer overflows with XML_PARSE_HUGE
Also impose size limits when XML_PARSE_HUGE is set. Limit size of names
to XML_MAX_TEXT_LENGTH (10 million bytes) and other content to
XML_MAX_HUGE_LENGTH (1 billion bytes).
Move some the length checks to the end of the respective loop to make
them strict.
xmlParseEntityValue didn't have a length limitation at all. But without
XML_PARSE_HUGE, this should eventually trigger an error in xmlGROW.
Thanks to Maddie Stone working with Google Project Zero for the report!
(cherry picked from commit c846986356fc149915a74972bf198abc266bc2c0)1 parent 8641fca commit 04a4b26
1 file changed
Lines changed: 121 additions & 112 deletions
0 commit comments