From 0e1fd33247460bdfa65d306e8bcdd3cbafed8b73 Mon Sep 17 00:00:00 2001 From: Gert Doering Date: Sun, 23 Nov 2014 20:17:30 +0100 Subject: Add client-only support for peer-id. This is a reduced version of the peer-id patch from Lev Stipakov implementing only the client side bits - send IV_PROTO=2, accept "peer-id " as pushed option, support P_DATA_V2 packets. v2: remove addition of "struct tls_multi;" to options.h, not needed Signed-off-by: Gert Doering Acked-by: Steffan Karger Message-Id: <1416770250-92680-1-git-send-email-gert@greenie.muc.de> URL: http://article.gmane.org/gmane.network.openvpn.devel/9274 --- src/openvpn/options.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/openvpn/options.c') diff --git a/src/openvpn/options.c b/src/openvpn/options.c index d91bb63..5bddca4 100644 --- a/src/openvpn/options.c +++ b/src/openvpn/options.c @@ -6996,6 +6996,12 @@ add_option (struct options *options, options->persist_mode = 1; } #endif + else if (streq (p[0], "peer-id")) + { + VERIFY_PERMISSION (OPT_P_PEER_ID); + options->use_peer_id = true; + options->peer_id = atoi(p[1]); + } else { int i; -- cgit