summaryrefslogtreecommitdiff
path: root/kde-apps
diff options
context:
space:
mode:
Diffstat (limited to 'kde-apps')
-rw-r--r--kde-apps/Manifest.gzbin42716 -> 42717 bytes
-rw-r--r--kde-apps/ksmtp/Manifest3
-rw-r--r--kde-apps/ksmtp/files/ksmtp-17.12.0-ehlo-auth-fix.patch108
-rw-r--r--kde-apps/ksmtp/ksmtp-17.12.0-r1.ebuild (renamed from kde-apps/ksmtp/ksmtp-17.12.0.ebuild)2
4 files changed, 112 insertions, 1 deletions
diff --git a/kde-apps/Manifest.gz b/kde-apps/Manifest.gz
index 832a4945b99e..5d663dacfa6b 100644
--- a/kde-apps/Manifest.gz
+++ b/kde-apps/Manifest.gz
Binary files differ
diff --git a/kde-apps/ksmtp/Manifest b/kde-apps/ksmtp/Manifest
index c523fc9f374d..01f3f0867153 100644
--- a/kde-apps/ksmtp/Manifest
+++ b/kde-apps/ksmtp/Manifest
@@ -1,3 +1,4 @@
+AUX ksmtp-17.12.0-ehlo-auth-fix.patch 3283 BLAKE2B 69e1cc31cb31829aca1b24650c8c42e3bf548ecac529f5f12ed0503b17347f515418f108ad029def7d81da51129e5743033ce713466233c7e0f8772c69b6b8a7 SHA512 f7082efb07a3cbcdbe32d1d8a2acad148eb34a66a874b3b9916f51fae048133602f1bd29ba93aec27f6710e4517c4353415d316a719829971851b409bc2edae7
DIST ksmtp-17.12.0.tar.xz 38132 BLAKE2B 8a78e06c02ef2b21c23d3251c3e6b92eeae7d578bbdc34ccd0837f73898efb8e8f3aa4123ccf7892d2e27292128ad74572c8c7d173ce534e9795c8b4e338c297 SHA512 d42dd363086d5d9beec7e759aa7234f33c0c62fab5ae0f2f2e78cc81c9bb053729cde31ad6243e9d46e77d937cec8e7694cded4ce726e8a6583ca9be97ad43eb
-EBUILD ksmtp-17.12.0.ebuild 461 BLAKE2B 3658adb8f00a12cf76884e6e8ef65568651174257f2bc4933dc1b79cc07cf8e5c605a98be44d730e90c8d5226189dc2e7863011dde2cdae7a34cd274455fddd4 SHA512 e6aaa2ceb72abba1fcb19e136ce92d088e3b37ab0068d9d1fdf9f57b48e0adbebbd0cf77aca6191f9ecea802911463255bf69b1a0ace1938db1a42a5d19add72
+EBUILD ksmtp-17.12.0-r1.ebuild 513 BLAKE2B 7214e635ee4f1fc09919b21ae5d18216e70dd870832c68ff8ee987c60077633286fb13b8116f16be0d95a50ec4d868f52c6ab141f0344ae600da6264de98b651 SHA512 bcb5c15d165b736bb9b71a45d5937b36183492580fc9d7acf3b9654c22a3b96a2dfa2ddca049301d6fe27aba378772e5334f0b028e7700bf0b82145c810aca49
MISC metadata.xml 249 BLAKE2B ad415db89e5dee1627aa77f44ded9d4e1e5b8217d06c7ca25bbaa3fe92ce67c2b1090957c45a821b407d7927e5af798498aa6a5b903895ee1af8ee20a446c7f7 SHA512 76a5a340b13f0053ca3c5e94ed24380ea8d29b45ac8655419e22eaadb1e4a827c04d2e7e36b65145c4964e6526f656618fc6ac144e277ef53cb7373e6239e3c3
diff --git a/kde-apps/ksmtp/files/ksmtp-17.12.0-ehlo-auth-fix.patch b/kde-apps/ksmtp/files/ksmtp-17.12.0-ehlo-auth-fix.patch
new file mode 100644
index 000000000000..903bfe0d1144
--- /dev/null
+++ b/kde-apps/ksmtp/files/ksmtp-17.12.0-ehlo-auth-fix.patch
@@ -0,0 +1,108 @@
+From 4564d77d3c644a7d1f99749c4e934969b4e21952 Mon Sep 17 00:00:00 2001
+From: Fabian Vogt <fabian@ritter-vogt.de>
+Date: Fri, 22 Dec 2017 14:22:49 +0100
+Subject: [PATCH] Fix duplicate authentication
+
+Summary:
+The response to EHLO triggers an authentication command, but with TLS
+two EHLOs are sent: For the 220 from the server and after TLS negotiation.
+However, sending it twice results in an unexpected "503 already authenticated"
+response which ends up getting parsed by the SendJob, causing confusion.
+
+BUG: 387926
+BUG: 388068
+
+Reviewers: mlaurent, dvratil
+
+Subscribers: rdieter, heikobecker, asn, #kde_pim, lbeltrame, cgiboudeaux
+
+Tags: #kde_pim
+
+Differential Revision: https://phabricator.kde.org/D9476
+---
+ src/session.cpp | 29 +++++++++++++++++++----------
+ src/session_p.h | 1 +
+ src/sessionthread.cpp | 1 -
+ 3 files changed, 20 insertions(+), 11 deletions(-)
+
+diff --git a/src/session.cpp b/src/session.cpp
+index 861419d..4320adc 100644
+--- a/src/session.cpp
++++ b/src/session.cpp
+@@ -80,6 +80,19 @@ void SessionPrivate::setAuthenticationMethods(const QList<QByteArray> &authMetho
+ }
+ }
+
++void SessionPrivate::startHandshake()
++{
++ QByteArray cmd;
++ if (!m_ehloRejected) {
++ cmd = "EHLO ";
++ } else {
++ cmd = "HELO ";
++ }
++ setState(Session::Handshake);
++ const auto hostname = m_customHostname.isEmpty() ? m_thread->hostName() : m_customHostname;
++ sendData(cmd + QUrl::toAce(hostname));
++}
++
+
+
+ Session::Session(const QString &hostName, quint16 port, QObject *parent)
+@@ -277,15 +290,7 @@ void SessionPrivate::responseReceived(const ServerResponse &r)
+
+ if (m_state == Session::Ready) {
+ if (r.isCode(22) || m_ehloRejected) {
+- QByteArray cmd;
+- if (!m_ehloRejected) {
+- cmd = "EHLO ";
+- } else {
+- cmd = "HELO ";
+- }
+- setState(Session::Handshake);
+- const auto hostname = m_customHostname.isEmpty() ? m_thread->hostName() : m_customHostname;
+- sendData(cmd + QUrl::toAce(hostname));
++ startHandshake();
+ return;
+ }
+ }
+@@ -346,7 +351,11 @@ KTcpSocket::SslVersion SessionPrivate::negotiatedEncryption() const
+
+ void SessionPrivate::encryptionNegotiationResult(bool encrypted, KTcpSocket::SslVersion version)
+ {
+- Q_UNUSED(encrypted);
++ if (encrypted) {
++ // Get the updated auth methods
++ startHandshake();
++ }
++
+ m_sslVersion = version;
+ }
+
+diff --git a/src/session_p.h b/src/session_p.h
+index 875f7be..90151f6 100644
+--- a/src/session_p.h
++++ b/src/session_p.h
+@@ -73,6 +73,7 @@ private Q_SLOTS:
+
+ private:
+
++ void startHandshake();
+ void startNext();
+ void startSocketTimer();
+ void stopSocketTimer();
+diff --git a/src/sessionthread.cpp b/src/sessionthread.cpp
+index 1e4db8b..c195826 100644
+--- a/src/sessionthread.cpp
++++ b/src/sessionthread.cpp
+@@ -223,7 +223,6 @@ void SessionThread::sslConnected()
+ } else {
+ qCDebug(KSMTP_LOG) << "TLS negotiation done.";
+
+- QMetaObject::invokeMethod(this, "sendData", Qt::QueuedConnection, Q_ARG(QByteArray, "EHLO " + QUrl::toAce(hostName())));
+ Q_EMIT encryptionNegotiationResult(true, m_socket->negotiatedSslVersion());
+ }
+ }
+--
+2.13.6
+
diff --git a/kde-apps/ksmtp/ksmtp-17.12.0.ebuild b/kde-apps/ksmtp/ksmtp-17.12.0-r1.ebuild
index 5514a7c2e8d7..b9a34c04f0e7 100644
--- a/kde-apps/ksmtp/ksmtp-17.12.0.ebuild
+++ b/kde-apps/ksmtp/ksmtp-17.12.0-r1.ebuild
@@ -20,3 +20,5 @@ DEPEND="
dev-libs/cyrus-sasl
"
RDEPEND="${DEPEND}"
+
+PATCHES=( "${FILESDIR}/${P}-ehlo-auth-fix.patch" )