summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorShane Kearns <ext-shane.2.kearns@nokia.com>2012-03-22 15:10:26 +0000
committerMartin Petersson <Martin.Petersson@nokia.com>2012-03-30 10:30:58 +0200
commit722efd5f72258bc77868642fa5f9276d3ab2b3f6 (patch)
tree36eb451bbfa7a38cc14f88f392e8a526de415405
parent9db4b7046098883c65f5440c9b6994551fd24a30 (diff)
Fix performance problem with NTLM auth in http POST
A combination of other fixes resulted in authentication credentials with a blank username & password being incorrectly added to the cache only for NTLM. This caused authentication to be attempted with blank credentials first (which would fail), before the authenticationRequired signal was emitted. It caused a performance issue because of the extra 2 requests to the server (and possibly delays inserted by the server following a failed login) Task-number: ou1cimx1#985786 Change-Id: Ic588a20cfe7c24d5e60cd384caff0673a587e484 Reviewed-by: Martin Petersson <Martin.Petersson@nokia.com> (cherry picked from commit 3c3ea9a869086ebb02a5d0c475754f6a184a50ab) (cherry picked from commit 3e29d87844e1b6b0360ff05e38993567a85ac445)
-rw-r--r--src/network/kernel/qauthenticator.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/network/kernel/qauthenticator.cpp b/src/network/kernel/qauthenticator.cpp
index d0524eec64..8a7317995e 100644
--- a/src/network/kernel/qauthenticator.cpp
+++ b/src/network/kernel/qauthenticator.cpp
@@ -394,6 +394,8 @@ void QAuthenticatorPrivate::parseHttpResponse(const QList<QPair<QByteArray, QByt
break;
case Ntlm:
// #### extract from header
+ if (user.isEmpty() && password.isEmpty())
+ phase = Done;
break;
case DigestMd5: {
this->options[QLatin1String("realm")] = realm = QString::fromLatin1(options.value("realm"));