util/sasl/plain.lua

changeset 2206
78c9b5255b27
parent 2205
adbedc32d41b
child 2252
98a2bc275e0e
--- a/util/sasl/plain.lua	Thu Nov 19 17:08:58 2009 +0100
+++ b/util/sasl/plain.lua	Thu Nov 19 17:17:52 2009 +0100
@@ -35,7 +35,7 @@
 	
 	if (not password) or (password == "") or (not authentication) or (authentication == "") then
 		log("debug", "Username or password violates SASLprep.");
-		return "failure", "malformed-request";
+		return "failure", "malformed-request", "Invalid username or password.";
 	end
 
 	local correct, state = false, false;
@@ -55,7 +55,7 @@
 	if correct then
 		return "success";
 	else
-		return "failure", "not-authorized";
+		return "failure", "not-authorized", "Unable to authorize you with the authentication credentials you've sent.";
 	end
 end
 

mercurial