Software /
code /
prosody
Changeset
6039:f8df0a996575
Merge 0.10->trunk
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Tue, 25 Mar 2014 19:18:32 +0100 |
parents | 6032:c0ee152400ff (current diff) 6038:b3ceb7627e27 (diff) |
children | 6055:596539a30e9b |
files | |
diffstat | 5 files changed, 17 insertions(+), 10 deletions(-) [+] |
line wrap: on
line diff
--- a/core/modulemanager.lua Sun Mar 09 23:48:32 2014 +0100 +++ b/core/modulemanager.lua Tue Mar 25 19:18:32 2014 +0100 @@ -30,7 +30,7 @@ end local autoload_modules = {prosody.platform, "presence", "message", "iq", "offline", "c2s", "s2s"}; -local component_inheritable_modules = {"tls", "dialback", "iq", "s2s"}; +local component_inheritable_modules = {"tls", "saslauth", "dialback", "iq", "s2s"}; -- We need this to let modules access the real global namespace local _G = _G;
--- a/plugins/mod_saslauth.lua Sun Mar 09 23:48:32 2014 +0100 +++ b/plugins/mod_saslauth.lua Tue Mar 25 19:18:32 2014 +0100 @@ -197,7 +197,7 @@ return s2s_external_auth(session, stanza) end - if session.type ~= "c2s_unauthed" then return; end + if session.type ~= "c2s_unauthed" or module:get_host_type() ~= "local" then return; end if session.sasl_handler and session.sasl_handler.selected then session.sasl_handler = nil; -- allow starting a new SASL negotiation before completing an old one
--- a/prosody.cfg.lua.dist Sun Mar 09 23:48:32 2014 +0100 +++ b/prosody.cfg.lua.dist Tue Mar 25 19:18:32 2014 +0100 @@ -63,7 +63,6 @@ --"http_files"; -- Serve static files from a directory over HTTP -- Other specific functionality - --"posix"; -- POSIX functionality, sends server to background, enables syslog, etc. --"groups"; -- Shared roster support --"announce"; -- Send announcement to all online users --"welcome"; -- Welcome users who register accounts @@ -78,6 +77,7 @@ -- "offline"; -- Store offline messages -- "c2s"; -- Handle client connections -- "s2s"; -- Handle server-to-server connections + -- "posix"; -- POSIX functionality, sends server to background, enables syslog, etc. } -- Disable account creation by default, for security
--- a/prosodyctl Sun Mar 09 23:48:32 2014 +0100 +++ b/prosodyctl Tue Mar 25 19:18:32 2014 +0100 @@ -687,7 +687,12 @@ conf.distinguished_name[k] = nv ~= "." and nv or nil; end end - local conf_file = io.open(conf_filename, "w"); + local conf_file, err = io.open(conf_filename, "w"); + if not conf_file then + show_warning("Could not open OpenSSL config file for writing"); + show_warning(err); + os.exit(1); + end conf_file:write(conf:serialize()); conf_file:close(); print("");
--- a/util/sasl.lua Sun Mar 09 23:48:32 2014 +0100 +++ b/util/sasl.lua Tue Mar 25 19:18:32 2014 +0100 @@ -100,14 +100,16 @@ function method:mechanisms() local current_mechs = {}; for mech, _ in pairs(self.mechs) do - if mechanism_channelbindings[mech] and self.profile.cb then - local ok = false; - for cb_name, _ in pairs(self.profile.cb) do - if mechanism_channelbindings[mech][cb_name] then - ok = true; + if mechanism_channelbindings[mech] then + if self.profile.cb then + local ok = false; + for cb_name, _ in pairs(self.profile.cb) do + if mechanism_channelbindings[mech][cb_name] then + ok = true; + end end + if ok == true then current_mechs[mech] = true; end end - if ok == true then current_mechs[mech] = true; end else current_mechs[mech] = true; end