From 81fedc9a08fafb1f2cbbe6568a6e904ebbea25b8 Mon Sep 17 00:00:00 2001 From: Matthew Wild Date: Fri, 29 May 2009 14:28:53 +0100 Subject: sessionmanager, mod_tls: Mark a session as secure when TLS is active --- core/sessionmanager.lua | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'core') diff --git a/core/sessionmanager.lua b/core/sessionmanager.lua index 68493d87..07c44dfb 100644 --- a/core/sessionmanager.lua +++ b/core/sessionmanager.lua @@ -171,6 +171,12 @@ function streamopened(session, attr) session:close{ condition = "host-unknown", text = "This server does not serve "..tostring(session.host)}; return; end + + -- If session.secure is *false* (not nil) then it means we /were/ encrypting + -- since we now have a new stream header, session is secured + if session.secure == false then + session.secure = true; + end local features = st.stanza("stream:features"); fire_event("stream-features", session, features); -- cgit v1.2.3