util.sasl: Moving SASL authentication backends documentation to the mechanism files.
authorTobias Markmann <tm@ayena.de>
Sun, 28 Feb 2010 21:32:12 +0000 (22:32 +0100)
committerTobias Markmann <tm@ayena.de>
Sun, 28 Feb 2010 21:32:12 +0000 (22:32 +0100)
util/sasl.lua
util/sasl/digest-md5.lua
util/sasl/plain.lua

index 9c8fff7804a28edd6b7e4e430b846d3d23093696..925e5124adad36e99a2e8804888d17fc8161bd62 100644 (file)
@@ -41,27 +41,6 @@ Authentication Backend Prototypes:
 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 = {};
index 5b8f5c8a6ab4f6b28a73caee6f0981a79fb94964..3d6a3e1e7e80350bb27957be228e16f8dbd9171c 100644 (file)
@@ -29,6 +29,21 @@ module "digest-md5"
 --=========================
 --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
 
index ae5c777a77423f466ecd5977f696e0f9bec7e313..43bb239f4900dd5aaa3b1c5eeaca450696c8c4b3 100644 (file)
@@ -19,6 +19,21 @@ module "plain"
 
 -- ================================
 -- 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";