cpython/Modules/expat
Sebastian Pipping fc9da96274
[3.11] gh-115398: Expose Expat >=2.6.0 reparse deferral API (CVE-2023-52425) (GH-115623) (#116268)
Allow controlling Expat >=2.6.0 reparse deferral (CVE-2023-52425) by adding five new methods:

- `xml.etree.ElementTree.XMLParser.flush`
- `xml.etree.ElementTree.XMLPullParser.flush`
- `xml.parsers.expat.xmlparser.GetReparseDeferralEnabled`
- `xml.parsers.expat.xmlparser.SetReparseDeferralEnabled`
- `xml.sax.expatreader.ExpatParser.flush`

Based on the "flush" idea from #115138 (comment) .

- Please treat as a security fix related to CVE-2023-52425.

(cherry picked from commit 6a95676)
(cherry picked from commit 73807eb)
(cherry picked from commit eda2963)

---------

Includes code suggested-by: Snild Dolkow <snild@sony.com>
and by core dev Serhiy Storchaka.
Co-authored-by: Gregory P. Smith <greg@krypto.org>
2024-03-06 14:17:02 -08:00
..
ascii.h bpo-44394: Update libexpat copy to 2.4.1 (GH-26945) 2021-08-29 16:08:24 +02:00
asciitab.h bpo-44394: Update libexpat copy to 2.4.1 (GH-26945) 2021-08-29 16:08:24 +02:00
COPYING gh-97005: Update libexpat from 2.4.7 to 2.4.9 (gh-97006) 2022-09-22 06:00:52 -07:00
expat.h [3.11] Upgrade bundled libexpat to 2.6.0 (GH-115399) (GH-115468) 2024-02-14 18:29:27 +01:00
expat_config.h [3.11] Upgrade bundled libexpat to 2.6.0 (GH-115399) (GH-115468) 2024-02-14 18:29:27 +01:00
expat_external.h bpo-44394: Update libexpat copy to 2.4.1 (GH-26945) 2021-08-29 16:08:24 +02:00
iasciitab.h bpo-44394: Update libexpat copy to 2.4.1 (GH-26945) 2021-08-29 16:08:24 +02:00
internal.h [3.11] Upgrade bundled libexpat to 2.6.0 (GH-115399) (GH-115468) 2024-02-14 18:29:27 +01:00
latin1tab.h bpo-44394: Update libexpat copy to 2.4.1 (GH-26945) 2021-08-29 16:08:24 +02:00
nametab.h bpo-44394: Update libexpat copy to 2.4.1 (GH-26945) 2021-08-29 16:08:24 +02:00
pyexpatns.h [3.11] gh-115398: Expose Expat >=2.6.0 reparse deferral API (CVE-2023-52425) (GH-115623) (#116268) 2024-03-06 14:17:02 -08:00
siphash.h [3.11] Upgrade bundled libexpat to 2.6.0 (GH-115399) (GH-115468) 2024-02-14 18:29:27 +01:00
utf8tab.h bpo-44394: Update libexpat copy to 2.4.1 (GH-26945) 2021-08-29 16:08:24 +02:00
winconfig.h [3.11] Upgrade bundled libexpat to 2.6.0 (GH-115399) (GH-115468) 2024-02-14 18:29:27 +01:00
xmlparse.c [3.11] Upgrade bundled libexpat to 2.6.0 (GH-115399) (GH-115468) 2024-02-14 18:29:27 +01:00
xmlrole.c [3.11] Upgrade bundled libexpat to 2.6.0 (GH-115399) (GH-115468) 2024-02-14 18:29:27 +01:00
xmlrole.h [3.11] Upgrade bundled libexpat to 2.6.0 (GH-115399) (GH-115468) 2024-02-14 18:29:27 +01:00
xmltok.c [3.11] Upgrade bundled libexpat to 2.6.0 (GH-115399) (GH-115468) 2024-02-14 18:29:27 +01:00
xmltok.h [3.11] Upgrade bundled libexpat to 2.6.0 (GH-115399) (GH-115468) 2024-02-14 18:29:27 +01:00
xmltok_impl.c [3.11] Upgrade bundled libexpat to 2.6.0 (GH-115399) (GH-115468) 2024-02-14 18:29:27 +01:00
xmltok_impl.h gh-98739: Update libexpat from 2.4.9 to 2.5.0 (GH-98742) 2022-10-27 14:21:35 -07:00
xmltok_ns.c bpo-46400: Update libexpat from 2.4.1 to 2.4.4 (GH-31022) 2022-02-13 00:29:41 +09:00