Attention is currently required from: flichtenheld.
Hello flichtenheld,
I'd like you to do a code review.
Please visit
http://gerrit.openvpn.net/c/openvpn/+/1288?usp=email
to review the following change.
Change subject: Warn if push is used without --mode
server/--server/--server-bridge
......................................................................
Warn if push is used without --mode server/--server/--server-bridge
This is not a supported configuration and will often work good enough
to get a connection working but will operate more in a weird pre P2P
negotiation compatibility way rather than actually negotiating
protocol features.
Also remove an used macro.
Change-Id: I82c7c61be07593ecd5bf2f854767dda74ab5170c
---
M src/openvpn/options.c
M src/openvpn/options.h
2 files changed, 6 insertions(+), 5 deletions(-)
git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/88/1288/1
diff --git a/src/openvpn/options.c b/src/openvpn/options.c
index 65c6b3b..6cfe62f 100644
--- a/src/openvpn/options.c
+++ b/src/openvpn/options.c
@@ -3334,6 +3334,12 @@
"Ignoring these options.");
}
}
+
+ if (o->push_list.head && o->mode != MODE_SERVER)
+ {
+ msg(M_WARN, "Note: Using --push without --mode server is an
unsupported"
+ " configuration. Negotiation of OpenVPN features is
expected to fail.");
+ }
}
static void
diff --git a/src/openvpn/options.h b/src/openvpn/options.h
index 009904a..24253af 100644
--- a/src/openvpn/options.h
+++ b/src/openvpn/options.h
@@ -768,16 +768,11 @@
#define OPT_P_DEFAULT (~(OPT_P_INSTANCE | OPT_P_PULL_MODE))
#define PULL_DEFINED(opt) ((opt)->pull)
-#define PUSH_DEFINED(opt) ((opt)->push_list)
#ifndef PULL_DEFINED
#define PULL_DEFINED(opt) (false)
#endif
-#ifndef PUSH_DEFINED
-#define PUSH_DEFINED(opt) (false)
-#endif
-
#ifdef _WIN32
#define ROUTE_OPTION_FLAGS(o) ((o)->route_method & ROUTE_METHOD_MASK)
#else
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1288?usp=email
To unsubscribe, or for help writing mail filters, visit
http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: newchange
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: I82c7c61be07593ecd5bf2f854767dda74ab5170c
Gerrit-Change-Number: 1288
Gerrit-PatchSet: 1
Gerrit-Owner: plaisthos <[email protected]>
Gerrit-Reviewer: flichtenheld <[email protected]>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-Attention: flichtenheld <[email protected]>
_______________________________________________
Openvpn-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openvpn-devel