summaryrefslogtreecommitdiff
path: root/cpp/src
diff options
context:
space:
mode:
authorGordon Sim <gsim@apache.org>2012-11-14 11:21:18 +0000
committerGordon Sim <gsim@apache.org>2012-11-14 11:21:18 +0000
commit3a112539ec2a65a2d8ab58b6f96f7255bd573903 (patch)
tree73b5d815f1ef2c6c6c8b662603c08ad50c0381a6 /cpp/src
parentb63619ecda28aae61fe0894f11fc4592a7a1afd2 (diff)
downloadqpid-python-3a112539ec2a65a2d8ab58b6f96f7255bd573903.tar.gz
NO-JIRA: Fail on invalid PLAIN request
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1409161 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src')
-rw-r--r--cpp/src/qpid/NullSaslServer.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/cpp/src/qpid/NullSaslServer.cpp b/cpp/src/qpid/NullSaslServer.cpp
index 8f415ba3ba..40bd9ebbc6 100644
--- a/cpp/src/qpid/NullSaslServer.cpp
+++ b/cpp/src/qpid/NullSaslServer.cpp
@@ -39,7 +39,10 @@ NullSaslServer::Status NullSaslServer::start(const std::string& mechanism, const
} else if (i != std::string::npos) {
//authorization id is first null delimited field
uid = response->substr(0, i);
- }//else not a valid SASL PLAIN response, throw error?
+ } else {
+ QPID_LOG(error, "Invalid PLAIN request, null delimiter not found in response data");
+ return FAIL;
+ }
if (!uid.empty()) {
//append realm if it has not already been added
i = uid.find(realm);