diff options
author | Waqas Hussain <waqas20@gmail.com> | 2010-08-23 16:54:56 +0500 |
---|---|---|
committer | Waqas Hussain <waqas20@gmail.com> | 2010-08-23 16:54:56 +0500 |
commit | 373662e4a695ef9d75381173eb4efb439e91d91b (patch) | |
tree | 82b3a14bfacbc2e01a2d47570a01d55e2c985eb9 /util/sasl_cyrus.lua | |
parent | 06fbe2e85325a81cff5f2ddf816ebaf4925364c6 (diff) | |
download | prosody-373662e4a695ef9d75381173eb4efb439e91d91b.tar.gz prosody-373662e4a695ef9d75381173eb4efb439e91d91b.zip |
mod_saslauth, mod_auth_cyrus, util.sasl_cyrus: Moved cyrus account provisioning check out of mod_saslauth.
Diffstat (limited to 'util/sasl_cyrus.lua')
-rw-r--r-- | util/sasl_cyrus.lua | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/util/sasl_cyrus.lua b/util/sasl_cyrus.lua index 3ec8adca..aafd5455 100644 --- a/util/sasl_cyrus.lua +++ b/util/sasl_cyrus.lua @@ -143,6 +143,9 @@ function method:process(message) self.username = cyrussasl.get_username(self.cyrus) if (err == 0) then -- SASL_OK + if self.require_provisioning and not self.require_provisioning(self.username) then + return "failure", "not-authorized", "User authenticated successfully, but not provisioned for XMPP"; + end return "success", data elseif (err == 1) then -- SASL_CONTINUE return "challenge", data |