Skip to content

Commit

Permalink
Fix performance problem with NTLM auth in http POST
Browse files Browse the repository at this point in the history
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 <[email protected]>
(cherry picked from commit 3c3ea9a869086ebb02a5d0c475754f6a184a50ab)
  • Loading branch information
Shane Kearns authored and Qt by Nokia committed Mar 23, 2012
1 parent 327fa27 commit 3e29d87
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/network/kernel/qauthenticator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -392,6 +392,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"));
Expand Down

0 comments on commit 3e29d87

Please sign in to comment.