Comparison

plugins/mod_tls.lua @ 1910:14c043d7fb77

mod_tls: Mark session as not secure before negotiating TLS
author Matthew Wild <mwild1@gmail.com>
date Mon, 05 Oct 2009 14:51:53 +0100
parent 1903:b7552b1e267d
child 1911:bfe120db1ec4
comparison
equal deleted inserted replaced
1909:84027581c995 1910:14c043d7fb77
32 if session.conn.starttls then 32 if session.conn.starttls then
33 session.sends2s(st.stanza("proceed", { xmlns = xmlns_starttls })); 33 session.sends2s(st.stanza("proceed", { xmlns = xmlns_starttls }));
34 session:reset_stream(); 34 session:reset_stream();
35 session.conn.starttls(); 35 session.conn.starttls();
36 session.log("info", "TLS negotiation started for incoming s2s..."); 36 session.log("info", "TLS negotiation started for incoming s2s...");
37 session.secure = false;
37 else 38 else
38 -- FIXME: What reply? 39 -- FIXME: What reply?
39 session.log("warn", "Attempt to start TLS, but TLS is not available on this s2s connection"); 40 session.log("warn", "Attempt to start TLS, but TLS is not available on this s2s connection");
40 end 41 end
41 end); 42 end);