From 372a88e7019fba875ed154d81b6cd0c20a988b64 Mon Sep 17 00:00:00 2001 From: Josef 'Jeff' Sipek Date: Thu, 17 Sep 2020 15:43:02 -0400 Subject: [PATCH] login-common: Include the proxy's source address in log messages --- src/login-common/client-common-auth.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/login-common/client-common-auth.c b/src/login-common/client-common-auth.c index 3328d0df1c..00db836aa7 100644 --- a/src/login-common/client-common-auth.c +++ b/src/login-common/client-common-auth.c @@ -264,6 +264,11 @@ static void proxy_free_password(struct client *client) static void client_proxy_append_conn_info(string_t *str, struct client *client) { + const char *source_host; + + source_host = login_proxy_get_source_host(client->login_proxy); + if (source_host[0] != '\0') + str_printfa(str, " from %s", source_host); if (strcmp(client->virtual_user, client->proxy_user) != 0) { /* remote username is different, log it */ str_printfa(str, " as user %s", client->proxy_user); -- 2.47.3