diff -r 8cd05c3d0f1f -r 58cd27b74ba5 util/sasl/plain.lua --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/util/sasl/plain.lua Thu Sep 18 18:59:34 2014 +0200 @@ -0,0 +1,10 @@ + +return function (stream, mechanisms, preference) + if stream.username and stream.password then + mechanisms["PLAIN"] = function (stream) + return "success" == coroutine.yield("\0"..stream.username.."\0"..stream.password); + end; + preference["PLAIN"] = 5; + end +end +