# HG changeset patch # User Waqas Hussain # Date 1298406886 -18000 # Node ID f08f649b898be85a13037503cf7dbffa18b9a6eb # Parent 52eaa2590bfb53f627132ba6f2ae40211a05227f mod_auth_*: Get rid of undocumented and broken 'sasl_realm' config option. diff -r 52eaa2590bfb -r f08f649b898b plugins/mod_auth_anonymous.lua --- a/plugins/mod_auth_anonymous.lua Wed Feb 23 01:22:04 2011 +0500 +++ b/plugins/mod_auth_anonymous.lua Wed Feb 23 01:34:46 2011 +0500 @@ -34,13 +34,12 @@ end function provider.get_sasl_handler() - local realm = module:get_option("sasl_realm") or module.host; local anonymous_authentication_profile = { anonymous = function(sasl, username, realm) return true; -- for normal usage you should always return true here end }; - return new_sasl(realm, anonymous_authentication_profile); + return new_sasl(module.host, anonymous_authentication_profile); end return provider; diff -r 52eaa2590bfb -r f08f649b898b plugins/mod_auth_cyrus.lua --- a/plugins/mod_auth_cyrus.lua Wed Feb 23 01:22:04 2011 +0500 +++ b/plugins/mod_auth_cyrus.lua Wed Feb 23 01:34:46 2011 +0500 @@ -28,9 +28,8 @@ end do -- diagnostic - local realm = module:get_option("sasl_realm") or module.host; local list; - for mechanism in pairs(new_sasl(realm):mechanisms()) do + for mechanism in pairs(new_sasl(module.host):mechanisms()) do list = (not(list) and mechanism) or (list..", "..mechanism); end if not list then @@ -68,8 +67,7 @@ end function provider.get_sasl_handler() - local realm = module:get_option("sasl_realm") or module.host; - local handler = new_sasl(realm); + local handler = new_sasl(module.host); if require_provisioning then function handler.require_provisioning(username) return usermanager_user_exists(username, module.host); diff -r 52eaa2590bfb -r f08f649b898b plugins/mod_auth_internal_hashed.lua --- a/plugins/mod_auth_internal_hashed.lua Wed Feb 23 01:22:04 2011 +0500 +++ b/plugins/mod_auth_internal_hashed.lua Wed Feb 23 01:34:46 2011 +0500 @@ -140,7 +140,6 @@ end function provider.get_sasl_handler() - local realm = module:get_option("sasl_realm") or module.host; local testpass_authentication_profile = { plain_test = function(sasl, username, password, realm) local prepped_username = nodeprep(username); @@ -175,7 +174,7 @@ return stored_key, server_key, iteration_count, salt, true; end }; - return new_sasl(realm, testpass_authentication_profile); + return new_sasl(module.host, testpass_authentication_profile); end return provider; diff -r 52eaa2590bfb -r f08f649b898b plugins/mod_auth_internal_plain.lua --- a/plugins/mod_auth_internal_plain.lua Wed Feb 23 01:22:04 2011 +0500 +++ b/plugins/mod_auth_internal_plain.lua Wed Feb 23 01:34:46 2011 +0500 @@ -68,7 +68,6 @@ end function provider.get_sasl_handler() - local realm = module:get_option("sasl_realm") or module.host; local getpass_authentication_profile = { plain = function(sasl, username, realm) local prepped_username = nodeprep(username); @@ -83,7 +82,7 @@ return password, true; end }; - return new_sasl(realm, getpass_authentication_profile); + return new_sasl(module.host, getpass_authentication_profile); end return provider;