Skip to contentSkip to conversation

Do not add leading space to pushed options

PATCH In review [email protected]... 2 participants 2 messages Nov 30, 2022

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Do not add leading space to pushed options

From: Selva Nair <[email protected]...>

This makes auth-token push during reneg
consistent with regular PUSH_REPLY.

---
 src/openvpn/push.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
src/openvpn/push.c +1 -1
index 92a0bc2d..f8c747d4 100644
@@ -746,7 +746,7 @@ send_push_reply_auth_token(struct tls_multi *multi)
 
     /* Construct a mimimal control channel push reply message */
     struct buffer buf = alloc_buf_gc(PUSH_BUNDLE_SIZE, &gc);
-    buf_printf(&buf, "%s, %s", push_reply_cmd, e->option);
+    buf_printf(&buf, "%s,%s", push_reply_cmd, e->option);
     send_control_channel_string_dowork(multi, BSTR(&buf), D_PUSH);
     gc_free(&gc);
 }
Signature · 1 line
2.34.1
Acked-by on v1 1/1
#1 lore raw

"Trivial enough, when you have found the place" :-) - tested, confirmed.

Without:

2022-11-30 12:55:38 PUSH: Received control message: 'PUSH_REPLY, auth-tokenSESS_ID'

With:

2022-11-30 12:57:42 PUSH: Received control message: 'PUSH_REPLY,auth-tokenSESS_ID'

Your patch has been applied to the master and release/2.5 branch (not a "critical bug", but "fixing unintended behaviour", so: bugfix).

commit d0672e7a06437c730e27df645b9b9a5407b44ccf (master) commit d682c77d5646466693991f0db797432fe5e09c95 (release/2.5)

Author: Selva Nair
Date:   Wed Nov 30 05:56:09 2022 -0500
     Do not add leading space to pushed options

     Signed-off-by: Selva Nair <[email protected]...>
     Acked-by: Gert Doering <[email protected]...>
     Message-Id: <[email protected]...>
     URL: https://www.mail-archive.com/[email protected]/msg25583.html
     Signed-off-by: Gert Doering <[email protected]...>

--
kind regards,

Gert Doering