From 7fb0e07ec3f7c5f6514523085dbe02ea6b8933e2 Mon Sep 17 00:00:00 2001 From: James Yonan Date: Sun, 12 Jun 2011 01:14:36 +0000 Subject: Added redirect-gateway block-local flag, with support for Linux, Mac OS X, and Linux. This flag (which is pushable from server) blocks client access to local LAN while VPN session is active. Added standalone --show-gateway option to show info about default gateway. Extensively refactored get_default_gateway function in route.c to ease implementation of block-local. Removed "Experimental" disclaimer from redirect-gateway man page. Version 2.1.3y. git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@7334 e7ae566f-a301-0410-adde-c780ea21d3b5 --- forward.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'forward.c') diff --git a/forward.c b/forward.c index 90b7d9f..758f402 100644 --- a/forward.c +++ b/forward.c @@ -1015,7 +1015,7 @@ process_ipv4_header (struct context *c, unsigned int flags, struct buffer *buf) if (!c->options.passtos) flags &= ~PIPV4_PASSTOS; #endif - if (!c->options.route_gateway_via_dhcp || !route_list_default_gateway_needed (c->c1.route_list)) + if (!c->options.route_gateway_via_dhcp || !route_list_vpn_gateway_needed (c->c1.route_list)) flags &= ~PIPV4_EXTRACT_DHCP_ROUTER; if (buf->len > 0) @@ -1056,7 +1056,7 @@ process_ipv4_header (struct context *c, unsigned int flags, struct buffer *buf) { const in_addr_t dhcp_router = dhcp_extract_router_msg (&ipbuf); if (dhcp_router) - route_list_add_default_gateway (c->c1.route_list, c->c2.es, dhcp_router); + route_list_add_vpn_gateway (c->c1.route_list, c->c2.es, dhcp_router); } } } -- cgit