rpms/kdelibs/F-11 kdelibs-4.2.4-cve-2009-2537-select-length.patch, NONE, 1.1 kdelibs.spec, 1.484, 1.485

Jaroslav Reznik jreznik at fedoraproject.org
Thu Jul 23 10:12:02 UTC 2009


Author: jreznik

Update of /cvs/pkgs/rpms/kdelibs/F-11
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv5190

Modified Files:
	kdelibs.spec 
Added Files:
	kdelibs-4.2.4-cve-2009-2537-select-length.patch 
Log Message:
* Thu Jul 23 2009 Jaroslav Reznik <jreznik at redhat.com> - 4.2.4-5
> - CVE-2009-2537 - select length DoS
> - correct fixPopupForPlasmaboard.patch


kdelibs-4.2.4-cve-2009-2537-select-length.patch:
 kjs_html.cpp |    9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

--- NEW FILE kdelibs-4.2.4-cve-2009-2537-select-length.patch ---
diff -up kdelibs-4.2.4/khtml/ecma/kjs_html.cpp.cve-2009-2537-select-length kdelibs-4.2.4/khtml/ecma/kjs_html.cpp
--- kdelibs-4.2.4/khtml/ecma/kjs_html.cpp.cve-2009-2537-select-length	2009-03-26 15:44:13.000000000 +0100
+++ kdelibs-4.2.4/khtml/ecma/kjs_html.cpp	2009-07-23 10:35:55.908865609 +0200
@@ -69,6 +69,9 @@
 #include <QtCore/QList>
 #include <QtCore/QHash>
 
+// CVE-2009-2537 (vendors agreed on max 10000 elements)
+#define MAX_SELECT_LENGTH 10000
+
 using namespace DOM;
 
 namespace KJS {
@@ -2428,8 +2431,12 @@ void KJS::HTMLElement::putValueProperty(
       case SelectValue:           { select.setValue(str.implementation()); return; }
       case SelectLength:          { // read-only according to the NS spec, but webpages need it writeable
                                          JSObject *coll = getSelectHTMLCollection(exec, select.options(), &select)->getObject();
+
                                          if ( coll )
-                                           coll->put(exec,"length",value);
+                                           if (value->toInteger(exec) >= MAX_SELECT_LENGTH)
+                                             setDOMException(exec, DOMException::INDEX_SIZE_ERR);
+                                           else
+                                             coll->put(exec, "length", value);
                                          return;
                                        }
       // read-only: form


Index: kdelibs.spec
===================================================================
RCS file: /cvs/pkgs/rpms/kdelibs/F-11/kdelibs.spec,v
retrieving revision 1.484
retrieving revision 1.485
diff -u -p -r1.484 -r1.485
--- kdelibs.spec	8 Jul 2009 15:22:31 -0000	1.484
+++ kdelibs.spec	23 Jul 2009 10:12:02 -0000	1.485
@@ -1,6 +1,6 @@
 Summary: K Desktop Environment 4 - Libraries
 Version: 4.2.4
-Release: 4%{?dist}
+Release: 5%{?dist}
 
 %if 0%{?fedora} > 8
 Name: kdelibs
@@ -81,11 +81,14 @@ Patch20: kdelibs-4.1.70-cmake.patch
 Patch22: kdelibs-4.1.96-cmake.patch
 
 # upstreamable
-Patch50: kdelibs-4.2.4-fixPopupForPlasmaboard.patch
+Patch50: kdelibs-4.2.3-fixPopupForPlasmaboard.patch
 
 # upstream
 # 4.2 branch
 
+# security
+Patch100: kdelibs-4.2.4-cve-2009-2537-select-length.patch
+
 # 4.3 branch
 Patch200: kdelibs-4.1.96-AllowExternalPaths.patch
 
@@ -221,6 +224,8 @@ sed -i -e "s|@@VERSION_RELEASE@@|%{versi
 
 %patch50 -p1 -b .fixPopupForPlasmaboard
 
+%patch100 -p1 -b .cve-2009-2537-select-length
+
 # upstream patches
 # 4.2
 
@@ -408,6 +413,10 @@ rm -rf %{buildroot}
 
 
 %changelog
+* Thu Jul 23 2009 Jaroslav Reznik <jreznik at redhat.com> - 4.2.4-5
+- CVE-2009-2537 - select length DoS
+- correct fixPopupForPlasmaboard.patch
+
 * Wed Jul 08 2009 Kevin Kofler <Kevin at tigcc.ticalc.org> - 4.2.4-4
 - fix CMake dependency in parallel_devel patch (#510259, CHIKAMA Masaki)
 




More information about the fedora-extras-commits mailing list