s2smanager: Mark session as secure if it was negotiating TLS and opens a new stream

Mon, 05 Oct 2009 14:50:27 +0100

author
Matthew Wild <mwild1@gmail.com>
date
Mon, 05 Oct 2009 14:50:27 +0100
changeset 1909
84027581c995
parent 1908
27c1c6e6c583
child 1910
14c043d7fb77

s2smanager: Mark session as secure if it was negotiating TLS and opens a new stream

core/s2smanager.lua file | annotate | diff | comparison | revisions
--- a/core/s2smanager.lua	Mon Oct 05 14:42:56 2009 +0100
+++ b/core/s2smanager.lua	Mon Oct 05 14:50:27 2009 +0100
@@ -339,6 +339,10 @@
 	-- TODO: #29: SASL/TLS on s2s streams
 	session.version = tonumber(attr.version) or 0;
 	
+	if session.secure == false then
+		session.secure = true;
+	end
+	
 	if session.version >= 1.0 and not (attr.to and attr.from) then
 		log("warn", (session.to_host or "(unknown)").." failed to specify 'to' or 'from' hostname as per RFC");
 	end

mercurial