summary refs log tree commit diff
path: root/pkgs/applications/networking/browsers/kwebkitpart/CVE-2014-8600.diff
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/applications/networking/browsers/kwebkitpart/CVE-2014-8600.diff')
-rw-r--r--pkgs/applications/networking/browsers/kwebkitpart/CVE-2014-8600.diff33
1 files changed, 33 insertions, 0 deletions
diff --git a/pkgs/applications/networking/browsers/kwebkitpart/CVE-2014-8600.diff b/pkgs/applications/networking/browsers/kwebkitpart/CVE-2014-8600.diff
new file mode 100644
index 00000000000..0c65e68f216
--- /dev/null
+++ b/pkgs/applications/networking/browsers/kwebkitpart/CVE-2014-8600.diff
@@ -0,0 +1,33 @@
+--- a/src/webpage.cpp
++++ b/src/webpage.cpp
+@@ -226,23 +226,26 @@
+     doc += QL1S( "<h3>" );
+     doc += i18n( "Details of the Request:" );
+     doc += QL1S( "</h3><ul><li>" );
+-    doc += i18n( "URL: %1", reqUrl.url() );
++    // escape URL twice: once for i18n, and once for HTML.
++    doc += i18n( "URL: %1", Qt::escape( Qt::escape( reqUrl.prettyUrl() ) ) );
+     doc += QL1S( "</li><li>" );
+ 
+     const QString protocol (reqUrl.protocol());
+     if ( !protocol.isNull() ) {
+-        doc += i18n( "Protocol: %1", protocol );
++        // escape protocol twice: once for i18n, and once for HTML.
++        doc += i18n( "Protocol: %1", Qt::escape( Qt::escape( protocol ) ) );
+         doc += QL1S( "</li><li>" );
+     }
+ 
+     doc += i18n( "Date and Time: %1",
+                  KGlobal::locale()->formatDateTime(QDateTime::currentDateTime(), KLocale::LongDate) );
+     doc += QL1S( "</li><li>" );
+-    doc += i18n( "Additional Information: %1" ,  text );
++    // escape text twice: once for i18n, and once for HTML.
++    doc += i18n( "Additional Information: %1", Qt::escape( Qt::escape( text ) ) );
+     doc += QL1S( "</li></ul><h3>" );
+     doc += i18n( "Description:" );
+     doc += QL1S( "</h3><p>" );
+-    doc += description;
++    doc += Qt::escape( description );
+     doc += QL1S( "</p>" );
+ 
+     if ( causes.count() ) {