[Python-checkins] r77680 - in python/trunk: Misc/NEWS Modules/expat/xmlparse.c

matthias.klose python-checkins at python.org
Fri Jan 22 01:39:05 CET 2010


Author: matthias.klose
Date: Fri Jan 22 01:39:04 2010
New Revision: 77680

Log:
- Expat: Fix DoS via XML document with malformed UTF-8 sequences 
  (CVE_2009_3560).


Modified:
   python/trunk/Misc/NEWS
   python/trunk/Modules/expat/xmlparse.c

Modified: python/trunk/Misc/NEWS
==============================================================================
--- python/trunk/Misc/NEWS	(original)
+++ python/trunk/Misc/NEWS	Fri Jan 22 01:39:04 2010
@@ -66,6 +66,12 @@
   Extension extra options may change the output without changing the .c
   file). Initial patch by Collin Winter.
 
+Extension Modules
+-----------------
+
+- Expat: Fix DoS via XML document with malformed UTF-8 sequences
+  (CVE_2009_3560).
+
 Build
 -----
 

Modified: python/trunk/Modules/expat/xmlparse.c
==============================================================================
--- python/trunk/Modules/expat/xmlparse.c	(original)
+++ python/trunk/Modules/expat/xmlparse.c	Fri Jan 22 01:39:04 2010
@@ -3682,6 +3682,9 @@
         return XML_ERROR_UNCLOSED_TOKEN;
       case XML_TOK_PARTIAL_CHAR:
         return XML_ERROR_PARTIAL_CHAR;
+      case -XML_TOK_PROLOG_S:
+        tok = -tok;
+        break;
       case XML_TOK_NONE:
 #ifdef XML_DTD
         /* for internal PE NOT referenced between declarations */


More information about the Python-checkins mailing list