Revert "Add support for parsing of large XML data (>= 10MB)"
Michael Paquier <michael@paquier.xyz>
Revert "Add support for parsing of large XML data (>= 10MB)" This reverts commit 2197d06224a1, following a discussion over a Coverity report where issues like the "Billion laugh attack" could cause the backend to waste CPU and memory even if a client applied checks on the size of the data given in input, and libxml2 does not offer guarantees that input limits are respected under XML_PARSE_HUGE. Discussion: https://postgr.es/m/ZbHlgrPLtBZyr_QW@paquier.xyz
Files
| Path | Change | +/− |
|---|---|---|
| contrib/xml2/xpath.c | modified | +2 −2 |
| contrib/xml2/xslt_proc.c | modified | +2 −2 |
| src/backend/utils/adt/xml.c | modified | +9 −29 |
Discussion
- BUG #18274: Error 'invalid XML content' 16 messages · 2024-01-06 → 2024-01-26