Software /
code /
prosody
Diff
net/server_epoll.lua @ 10307:6a997f0ceba8
net.server_epoll: Log TLS version and cipher for all completed handshakes
The similar logging in mod_c2s and mod_s2s does not cover all
connections, like HTTPS or other Direct TLS ports.
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Sun, 06 Oct 2019 16:23:43 +0200 |
parent | 10305:2fadbf209678 |
child | 10309:2a31571efce0 |
line wrap: on
line diff
--- a/net/server_epoll.lua Sun Oct 06 16:07:26 2019 +0200 +++ b/net/server_epoll.lua Sun Oct 06 16:23:43 2019 +0200 @@ -548,7 +548,12 @@ end local ok, err = self.conn:dohandshake(); if ok then - self:debug("TLS handshake complete"); + if self.conn.info then + local info = self.conn:info(); + self:debug("TLS handshake complete (%s with %s)", info.protocol, info.cipher); + else + self:debug("TLS handshake complete"); + end self.onwritable = nil; self.onreadable = nil; self:on("status", "ssl-handshake-complete");