[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: =?utf-8?q?=5Bkdelibs=5D_kioslave/http=3A_By_default_support_only?=
From: Dawit Alemayehu <adawit () kde ! org>
Date: 2011-05-04 18:52:31
Message-ID: 20110504185231.A1A0CA60A4 () git ! kde ! org
[Download RAW message or body]
Git commit 2fdcbe849ef50e64b3b5ce6d6615ef85851d008c by Dawit Alemayehu.
Committed on 04/05/2011 at 20:29.
Pushed by adawit into branch 'master'.
By default support only NTLMv1 like other browsers. However, make it possible
for users to manually enable the usage of NTLMv2 authentication by adding a
"EnableNTLMv2Auth=true" flag to either one of the following to configuration files:
$KDEHOME/share/config/kioslaverc OR
$KDEHOME/share/config/kio_httprc
Note this setting like every other ioslave setting can be set on a per site
basis by adding the parameter to a host specific section instead of the global
one. For example,
[foo.bar]
EnableNTLMv2Auth=true
CCBUG: 232626
(cherry picked from commit f79aacfcb658a57d9b7785018dfe4f970e524644)
M +7 -2 kioslave/http/httpauthentication.cpp
http://commits.kde.org/kdelibs/2fdcbe849ef50e64b3b5ce6d6615ef85851d008c
diff --git a/kioslave/http/httpauthentication.cpp \
b/kioslave/http/httpauthentication.cpp index bf4f01d..374f703 100644
--- a/kioslave/http/httpauthentication.cpp
+++ b/kioslave/http/httpauthentication.cpp
@@ -607,8 +607,13 @@ void KHttpNtlmAuthentication::generateResponse(const QString \
&_user, const QStri
m_forceKeepAlive = true;
const QByteArray challenge = QByteArray::fromBase64(m_challenge[0]);
- if (!KNTLM::getAuth(buf, challenge, user, password, domain, \
QHostInfo::localHostName(),
- (KNTLM::Force_V1 | KNTLM::Add_LM))) {
+
+ KNTLM::AuthFlags flags = KNTLM::Add_LM;
+ if (!m_config || !m_config->readEntry("EnableNTLMv2Auth", false)) {
+ flags |= KNTLM::Force_V1;
+ }
+
+ if (!KNTLM::getAuth(buf, challenge, user, password, domain, \
QHostInfo::localHostName(), flags)) {
kWarning(7113) << "Error while constructing Type 3 NTLM authentication \
request"; m_isError = true;
return;
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic