17 |
17 |
18 module "plain" |
18 module "plain" |
19 |
19 |
20 -- ================================ |
20 -- ================================ |
21 -- SASL PLAIN according to RFC 4616 |
21 -- SASL PLAIN according to RFC 4616 |
|
22 |
|
23 --[[ |
|
24 Supported Authentication Backends |
|
25 |
|
26 plain: |
|
27 function(username, realm) |
|
28 return password, state; |
|
29 end |
|
30 |
|
31 plain-test: |
|
32 function(username, realm, password) |
|
33 return true or false, state; |
|
34 end |
|
35 ]] |
|
36 |
22 local function plain(self, message) |
37 local function plain(self, message) |
23 if not message then |
38 if not message then |
24 return "failure", "malformed-request"; |
39 return "failure", "malformed-request"; |
25 end |
40 end |
26 |
41 |