aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeremy Lainé <jeremy.laine@m4x.org>2012-07-19 18:17:02 +0200
committerJeremy Lainé <jeremy.laine@m4x.org>2012-07-19 18:17:02 +0200
commit7d42e6e47c4022783264cc039dfc6f6f4523df13 (patch)
tree667c9f5a8b51d0183c2ade73e5e78db1ca01b7ad
parent12bf99e94f3037b083bbb4adc8897c7f7e55cb6e (diff)
downloadqxmpp-7d42e6e47c4022783264cc039dfc6f6f4523df13.tar.gz
fix error in SASL
-rw-r--r--src/base/QXmppSaslAuth.cpp2
-rw-r--r--tests/sasl.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/base/QXmppSaslAuth.cpp b/src/base/QXmppSaslAuth.cpp
index b3758873..12a920d1 100644
--- a/src/base/QXmppSaslAuth.cpp
+++ b/src/base/QXmppSaslAuth.cpp
@@ -174,7 +174,7 @@ bool QXmppSaslClientDigestMd5::respond(const QByteArray &challenge, QByteArray &
output["nc"] = m_saslDigest.nc();
output["qop"] = m_saslDigest.qop();
output["digest-uri"] = m_saslDigest.digestUri();
- output["output"] = m_saslDigest.calculateDigest(
+ output["response"] = m_saslDigest.calculateDigest(
QByteArray("AUTHENTICATE:") + m_saslDigest.digestUri());
if(!m_saslDigest.authzid().isEmpty())
diff --git a/tests/sasl.cpp b/tests/sasl.cpp
index edd9b230..db9f8fe1 100644
--- a/tests/sasl.cpp
+++ b/tests/sasl.cpp
@@ -60,7 +60,7 @@ void tst_QXmppSaslClient::testDigestMd5()
QCOMPARE(response, QByteArray());
QVERIFY(client->respond(QByteArray("nonce=\"2530347127\",qop=\"auth\",charset=utf-8,algorithm=md5-sess"), response));
- QCOMPARE(response, QByteArray("charset=utf-8,cnonce=\"AMzVG8Oibf+sVUCPPlWLR8lZQvbbJtJB9vJd+u3c6dw=\",digest-uri=\"xmpp/jabber.ru\",nc=00000001,nonce=2530347127,output=a61fbf4320577d74038b71a8546bc7ae,qop=auth,username=qxmpp1"));
+ QCOMPARE(response, QByteArray("charset=utf-8,cnonce=\"AMzVG8Oibf+sVUCPPlWLR8lZQvbbJtJB9vJd+u3c6dw=\",digest-uri=\"xmpp/jabber.ru\",nc=00000001,nonce=2530347127,qop=auth,response=a61fbf4320577d74038b71a8546bc7ae,username=qxmpp1"));
QVERIFY(client->respond(QByteArray("rspauth=d92bf7f4331700c24799cbab364a14b7"), response));
QCOMPARE(response, QByteArray());