aboutsummaryrefslogtreecommitdiffstats
path: root/util/sasl.lua
diff options
context:
space:
mode:
authorTobias Markmann <tm@ayena.de>2009-08-16 23:20:02 +0200
committerTobias Markmann <tm@ayena.de>2009-08-16 23:20:02 +0200
commitf39e7b794bccd19deba6241b45d4050c2762b416 (patch)
treedef3f32ef11ec0e453e4872263a12c9ab1b99a2f /util/sasl.lua
parente8d31c23939c42c0489f33fba40a13bbecb966e4 (diff)
downloadprosody-f39e7b794bccd19deba6241b45d4050c2762b416.tar.gz
prosody-f39e7b794bccd19deba6241b45d4050c2762b416.zip
Adding some docu.
Diffstat (limited to 'util/sasl.lua')
-rw-r--r--util/sasl.lua25
1 files changed, 25 insertions, 0 deletions
diff --git a/util/sasl.lua b/util/sasl.lua
index d6ac5c1e..772e2dd5 100644
--- a/util/sasl.lua
+++ b/util/sasl.lua
@@ -37,6 +37,30 @@ local keys = keys
local array = require "util.array"
module "sasl"
+--[[
+Authentication Backend Prototypes:
+
+plain:
+ function(username, realm)
+ return password, state;
+ end
+
+plain-test:
+ function(username, realm, password)
+ return true or false, state;
+ end
+
+digest-md5:
+ function(username, realm, encoding)
+ return digesthash, state;
+ end
+
+digest-md5-test:
+ function(username, realm, encoding, digesthash)
+ return true or false, state;
+ end
+]]
+
local method = {};
method.__index = method;
local mechanisms = {};
@@ -71,6 +95,7 @@ function method:mechanisms()
end
end
end
+ self["possible_mechanisms"] = mechanisms;
return array.collect(keys(mechanisms));
end