aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRaphael Kubo da Costa <rakuco@FreeBSD.org>2017-03-13 10:03:17 +0000
committerRaphael Kubo da Costa <rakuco@FreeBSD.org>2017-03-13 10:03:17 +0000
commit99c6adc8ee3eca3e08137ae40e1c362c0cfd3d6a (patch)
tree731dbe0948636d4f2669e3a500154f7e97259293
parent5f408ec3e36929ee7dbe3402c3afb763cf558523 (diff)
downloadports-99c6adc8ee3eca3e08137ae40e1c362c0cfd3d6a.tar.gz
ports-99c6adc8ee3eca3e08137ae40e1c362c0cfd3d6a.zip
MFH: r435966
Add patch for CVE-2016-7787 in kdesu. Security: 41fe4724-06a2-11e7-8e3e-5453ed2e2b49 Approved by: ports-secteam (junovitch)
Notes
Notes: svn path=/branches/2017Q1/; revision=436048
-rw-r--r--x11/kde4-runtime/Makefile2
-rw-r--r--x11/kde4-runtime/files/patch-kdesu_kdesu_kdesu.cpp27
2 files changed, 28 insertions, 1 deletions
diff --git a/x11/kde4-runtime/Makefile b/x11/kde4-runtime/Makefile
index 357860de5b46..904f9037ac19 100644
--- a/x11/kde4-runtime/Makefile
+++ b/x11/kde4-runtime/Makefile
@@ -2,7 +2,7 @@
PORTNAME= kde-runtime
PORTVERSION= ${KDE4_VERSION}
-PORTREVISION= 4
+PORTREVISION= 5
CATEGORIES= x11 kde kde-kde4
MAINTAINER= kde@FreeBSD.org
diff --git a/x11/kde4-runtime/files/patch-kdesu_kdesu_kdesu.cpp b/x11/kde4-runtime/files/patch-kdesu_kdesu_kdesu.cpp
new file mode 100644
index 000000000000..2b0b1754bedc
--- /dev/null
+++ b/x11/kde4-runtime/files/patch-kdesu_kdesu_kdesu.cpp
@@ -0,0 +1,27 @@
+Fix for https://www.kde.org/info/security/advisory-20160930-1.txt
+--- kdesu/kdesu/kdesu.cpp.orig 2014-10-30 23:50:20 UTC
++++ kdesu/kdesu/kdesu.cpp
+@@ -141,6 +141,10 @@ int main(int argc, char *argv[])
+ {
+ KMessageBox::sorry(0, i18n("Cannot execute command '%1'.", QString::fromLocal8Bit(command)));
+ }
++ if (result == -2)
++ {
++ KMessageBox::sorry(0, i18n("Cannot execute command '%1'. It contains invalid characters.", QString::fromLocal8Bit(command)));
++ }
+
+ return result;
+ }
+@@ -367,6 +371,12 @@ static int startApp()
+ kDebug() << "Don't need password!!\n";
+ }
+
++ for (const QChar character : QString::fromLocal8Bit(command)) {
++ if (!character.isPrint() && character.category() != QChar::Other_Surrogate) {
++ return -2;
++ }
++ }
++
+ // Start the dialog
+ QString password;
+ if (needpw)