Mercurial > prosody-hg
comparison plugins/mod_saslauth.lua @ 2997:6ccaefea80ec
Merge with tip.
| author | Tobias Markmann <tm@ayena.de> |
|---|---|
| date | Fri, 12 Mar 2010 18:41:05 +0100 |
| parents | 3fcf1048a896 |
| children | 066c199135d5 |
comparison
equal
deleted
inserted
replaced
| 2996:b0515ed4d9d7 | 2997:6ccaefea80ec |
|---|---|
| 34 local xmlns_bind ='urn:ietf:params:xml:ns:xmpp-bind'; | 34 local xmlns_bind ='urn:ietf:params:xml:ns:xmpp-bind'; |
| 35 local xmlns_stanzas ='urn:ietf:params:xml:ns:xmpp-stanzas'; | 35 local xmlns_stanzas ='urn:ietf:params:xml:ns:xmpp-stanzas'; |
| 36 | 36 |
| 37 local new_sasl; | 37 local new_sasl; |
| 38 if sasl_backend == "cyrus" then | 38 if sasl_backend == "cyrus" then |
| 39 prosody.unlock_globals(); --FIXME: Figure out why this is needed and | |
| 40 -- why cyrussasl isn't caught by the sandbox | |
| 39 local ok, cyrus = pcall(require, "util.sasl_cyrus"); | 41 local ok, cyrus = pcall(require, "util.sasl_cyrus"); |
| 42 prosody.lock_globals(); | |
| 40 if ok then | 43 if ok then |
| 41 local cyrus_new = cyrus.new; | 44 local cyrus_new = cyrus.new; |
| 42 new_sasl = function(realm) | 45 new_sasl = function(realm) |
| 43 return cyrus_new(realm, module:get_option("cyrus_service_name") or "xmpp"); | 46 return cyrus_new(realm, module:get_option("cyrus_service_name") or "xmpp"); |
| 44 end | 47 end |
