Changeset

12126:0d8e6646ce42

mod_admin_shell: Log creation of incoming s2s connections during ping The 's2s-created' fires just after accepting the TCP connection, before the addresses are known, so this can have some false positives.
author Kim Alvefur <zash@zash.se>
date Mon, 27 Dec 2021 17:04:33 +0100
parents 12125:649268c9f603
children 12127:baa7cdde69a6
files plugins/mod_admin_shell.lua
diffstat 1 files changed, 2 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/mod_admin_shell.lua	Mon Dec 27 16:16:53 2021 +0100
+++ b/plugins/mod_admin_shell.lua	Mon Dec 27 17:04:33 2021 +0100
@@ -1396,6 +1396,8 @@
 				local dir = available_columns.dir.mapper(s2s_session.direction, s2s_session);
 				print(("Session %s (%s%s%s) %s (%gs)"):format(s2s_session.id, localhost, dir, remotehost, what,
 					time.now() - time_start));
+			elseif s2s_session.type == "s2sin_unauthed" and s2s_session.to_host == nil and s2s_session.from_host == nil then
+				print(("Session %s %s (%gs)"):format(s2s_session.id, what, time.now() - time_start));
 			end
 		end
 	end