Software /
code /
prosody
Changeset
2991:0fa3a7c885bd
util.sasl: Moving SASL authentication backends documentation to the mechanism files.
author | Tobias Markmann <tm@ayena.de> |
---|---|
date | Sun, 28 Feb 2010 22:32:12 +0100 |
parents | 2990:21933063dd9f |
children | 2992:9ce36f7eb24a |
files | util/sasl.lua util/sasl/digest-md5.lua util/sasl/plain.lua |
diffstat | 3 files changed, 30 insertions(+), 21 deletions(-) [+] |
line wrap: on
line diff
--- a/util/sasl.lua Sun Feb 28 22:23:03 2010 +0100 +++ b/util/sasl.lua Sun Feb 28 22:32:12 2010 +0100 @@ -41,27 +41,6 @@ state = false : disabled state = true : enabled state = nil : non-existant - -plain: - function(username, realm) - return password, state; - end - -plain-test: - function(username, realm, password) - return true or false, state; - end - -digest-md5: - function(username, domain, realm, encoding) -- domain and realm are usually the same; for some broken - -- implementations it's not - return digesthash, state; - end - -digest-md5-test: - function(username, domain, realm, encoding, digesthash) - return true or false, state; - end ]] local method = {};
--- a/util/sasl/digest-md5.lua Sun Feb 28 22:23:03 2010 +0100 +++ b/util/sasl/digest-md5.lua Sun Feb 28 22:32:12 2010 +0100 @@ -29,6 +29,21 @@ --========================= --SASL DIGEST-MD5 according to RFC 2831 +--[[ +Supported Authentication Backends + +digest-md5: + function(username, domain, realm, encoding) -- domain and realm are usually the same; for some broken + -- implementations it's not + return digesthash, state; + end + +digest-md5-test: + function(username, domain, realm, encoding, digesthash) + return true or false, state; + end +]] + local function digest(self, message) --TODO complete support for authzid
--- a/util/sasl/plain.lua Sun Feb 28 22:23:03 2010 +0100 +++ b/util/sasl/plain.lua Sun Feb 28 22:32:12 2010 +0100 @@ -19,6 +19,21 @@ -- ================================ -- SASL PLAIN according to RFC 4616 + +--[[ +Supported Authentication Backends + +plain: + function(username, realm) + return password, state; + end + +plain-test: + function(username, realm, password) + return true or false, state; + end +]] + local function plain(self, message) if not message then return "failure", "malformed-request";