Skip to contentSkip to conversation

Change float log message to include common name, if available.

PATCH In review Steffan Karger 3 participants 3 messages Mar 7, 2015 – Mar 8, 2015

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Change float log message to include common name, if available.

Makes it a lot easier to see which client is floating.

---
 src/openvpn/multi.c | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)
src/openvpn/multi.c +5 -2
index 4412491..b0f66ca 100644
@@ -2151,8 +2151,11 @@ void multi_process_float (struct multi_context* m, struct multi_instance* mi)
       multi_close_instance(m, ex_mi, false);
     }
 
-    msg (D_MULTI_MEDIUM, "peer %" PRIu32 " floated from %s to %s", mi->context.c2.tls_multi->peer_id,
-        mroute_addr_print (&mi->real, &gc), print_link_socket_actual (&m->top.c2.from, &gc));
+    msg (D_MULTI_MEDIUM, "peer %" PRIu32 " (%s) floated from %s to %s",
+	mi->context.c2.tls_multi->peer_id,
+	tls_common_name (mi->context.c2.tls_multi, false),
+	mroute_addr_print (&mi->real, &gc),
+	print_link_socket_actual (&m->top.c2.from, &gc));
 
     ASSERT (hash_remove(m->hash, &mi->real));
     ASSERT (hash_remove(m->iter, &mi->real));
Signature · 1 line
2.1.0
#1 lore raw

ACK

2015-03-07 18:23 GMT+02:00 Steffan Karger <[email protected]...>:

Quoted 39 lines

Makes it a lot easier to see which client is floating.

---
 src/openvpn/multi.c | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)
src/openvpn/multi.c +5 -3
index 4412491..b0f66ca 100644
@@ -2151,8 +2151,11 @@ void multi_process_float (struct multi_context* m, struct multi_instance* mi)
       multi_close_instance(m, ex_mi, false);
     }
 
-    msg (D_MULTI_MEDIUM, "peer %" PRIu32 " floated from %s to %s", mi->context.c2.tls_multi->peer_id,
-        mroute_addr_print (&mi->real, &gc), print_link_socket_actual (&m->top.c2.from, &gc));
+    msg (D_MULTI_MEDIUM, "peer %" PRIu32 " (%s) floated from %s to %s",
+       mi->context.c2.tls_multi->peer_id,
+       tls_common_name (mi->context.c2.tls_multi, false),
+       mroute_addr_print (&mi->real, &gc),
+       print_link_socket_actual (&m->top.c2.from, &gc));
 
     ASSERT (hash_remove(m->hash, &mi->real));
     ASSERT (hash_remove(m->iter, &mi->real));
--

2.1.0

------------------------------------------------------------------------------
Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/
_______________________________________________
Openvpn-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openvpn-devel

Signature · 1 line
-Lev
#2 lore raw
In reply to Steffan Karger

Your patch has been applied to the master branch.

commit bacd640f57c935fb8de4efa71be0e8601c48f26f

Author: Steffan Karger
Date:   Sat Mar 7 17:23:11 2015 +0100
     Change float log message to include common name, if available.

     Signed-off-by: Steffan Karger <[email protected]...>
     Acked-by: Lev Stipakov <[email protected]...>
     Message-Id: <[email protected]...>
     URL: http://article.gmane.org/gmane.network.openvpn.devel/9526
     Signed-off-by: Gert Doering <[email protected]...>

--
kind regards,

Gert Doering