Changeset

2180:8de2f7f5b870 sasl

Allow ampersands in passwords for SASL PLAIN mechanism.
author Tobias Markmann <tm@ayena.de>
date Fri, 28 Aug 2009 19:20:12 +0200
parents 2179:c985536d5452
children 2181:d5cd6a868959
files util/sasl.lua
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/util/sasl.lua	Fri Aug 28 13:04:38 2009 +0200
+++ b/util/sasl.lua	Fri Aug 28 19:20:12 2009 +0200
@@ -119,9 +119,9 @@
 --SASL PLAIN
 local function sasl_mechanism_plain(self, message)
 	local response = message
-	local authorization = s_match(response, "([^&%z]+)")
-	local authentication = s_match(response, "%z([^&%z]+)%z")
-	local password = s_match(response, "%z[^&%z]+%z([^&%z]+)")
+	local authorization = s_match(response, "([^%z]+)")
+	local authentication = s_match(response, "%z([^%z]+)%z")
+	local password = s_match(response, "%z[^%z]+%z([^%z]+)")
 
 	if authentication == nil or password == nil then
 		return "failure", "malformed-request";