OpenVPN
|
#include "syshead.h"
#include "forward.h"
#include "helper.h"
#include "pool.h"
#include "push.h"
#include "memdbg.h"
Go to the source code of this file.
Functions | |
static const char * | print_netmask (int netbits, struct gc_arena *gc) |
static const char * | print_opt_route_gateway (const in_addr_t route_gateway, struct gc_arena *gc) |
static const char * | print_opt_route_gateway_dhcp (struct gc_arena *gc) |
static const char * | print_opt_route (const in_addr_t network, const in_addr_t netmask, struct gc_arena *gc) |
static const char * | print_opt_topology (const int topology, struct gc_arena *gc) |
static const char * | print_str_int (const char *str, const int i, struct gc_arena *gc) |
static const char * | print_str (const char *str, struct gc_arena *gc) |
static void | helper_add_route (const in_addr_t network, const in_addr_t netmask, struct options *o) |
static void | verify_common_subnet (const char *opt, const in_addr_t a, const in_addr_t b, const in_addr_t subnet) |
void | helper_setdefault_topology (struct options *o) |
Set –topology default depending on –mode. More... | |
void | helper_client_server (struct options *o) |
void | helper_keepalive (struct options *o) |
void | helper_tcp_nodelay (struct options *o) |
|
static |
Definition at line 114 of file helper.c.
References add_route_to_option_list(), options::gc, print_in_addr_t(), rol_check_alloc(), and options::routes.
Referenced by helper_client_server().
void helper_client_server | ( | struct options * | o | ) |
Definition at line 172 of file helper.c.
References add_in6_addr(), ASSERT, options::client, options::dev, options::dev_type, dev_type_enum(), DEV_TYPE_TAP, DEV_TYPE_TUN, options::enable_c2c, options::gc, gc_free(), gc_new(), helper_add_route(), helper_setdefault_topology(), options::ifconfig_ipv6_local, options::ifconfig_ipv6_netbits, options::ifconfig_ipv6_pool_base, options::ifconfig_ipv6_pool_defined, options::ifconfig_ipv6_pool_netbits, options::ifconfig_ipv6_remote, options::ifconfig_local, options::ifconfig_pool_defined, options::ifconfig_pool_end, IFCONFIG_POOL_MIN_NETBITS, options::ifconfig_pool_netmask, options::ifconfig_pool_start, ifconfig_pool_verify_range(), options::ifconfig_remote_netmask, M_USAGE, M_WARN, options::mode, MODE_SERVER, msg, netmask_to_netbits(), print_in6_addr(), print_in_addr_t(), print_netmask(), print_opt_route(), print_opt_route_gateway(), print_opt_route_gateway_dhcp(), print_opt_topology(), options::pull, options::push_ifconfig_constraint_defined, options::push_ifconfig_constraint_netmask, options::push_ifconfig_constraint_network, push_option(), options::route_default_gateway, options::server_bridge_defined, options::server_bridge_ip, options::server_bridge_netmask, options::server_bridge_pool_end, options::server_bridge_pool_start, options::server_bridge_proxy_dhcp, options::server_defined, options::server_flags, options::server_ipv6_defined, options::server_netbits_ipv6, options::server_netmask, options::server_network, options::server_network_ipv6, SF_NO_PUSH_ROUTE_GATEWAY, SF_NOPOOL, options::shared_secret_file, status, options::tls_client, options::tls_server, TOP_NET30, TOP_P2P, TOP_SUBNET, options::topology, and verify_common_subnet().
Referenced by options_postprocess_mutate().
void helper_keepalive | ( | struct options * | o | ) |
Definition at line 541 of file helper.c.
References ASSERT, options::gc, options::keepalive_ping, options::keepalive_timeout, M_USAGE, options::mode, MODE_POINT_TO_POINT, MODE_SERVER, msg, options::ping_rec_timeout, options::ping_rec_timeout_action, PING_RESTART, options::ping_send_timeout, print_str_int(), and push_option().
Referenced by options_postprocess_mutate().
void helper_setdefault_topology | ( | struct options * | o | ) |
Set –topology default depending on –mode.
Definition at line 144 of file helper.c.
References options::dev, options::dev_type, dev_type_enum(), DEV_TYPE_TUN, options::mode, MODE_SERVER, TOP_NET30, TOP_SUBNET, TOP_UNDEF, and options::topology.
Referenced by helper_client_server(), and options_postprocess_mutate().
void helper_tcp_nodelay | ( | struct options * | o | ) |
Definition at line 600 of file helper.c.
References options::gc, M_USAGE, options::mode, MODE_SERVER, print_str(), push_option(), options::server_flags, SF_TCP_NODELAY, SF_TCP_NODELAY_HELPER, and options::sockflags.
Referenced by options_postprocess_mutate().
|
static |
Definition at line 39 of file helper.c.
References alloc_buf_gc(), BSTR, buf_printf(), netbits_to_netmask(), and print_in_addr_t().
Referenced by helper_client_server().
|
static |
Definition at line 67 of file helper.c.
References alloc_buf_gc(), ASSERT, BSTR, buf_printf(), and print_in_addr_t().
Referenced by helper_client_server().
|
static |
Definition at line 50 of file helper.c.
References alloc_buf_gc(), ASSERT, BSTR, buf_printf(), and print_in_addr_t().
Referenced by helper_client_server().
|
static |
Definition at line 59 of file helper.c.
References alloc_buf_gc(), BSTR, and buf_printf().
Referenced by helper_client_server().
|
static |
Definition at line 88 of file helper.c.
References alloc_buf_gc(), BSTR, buf_printf(), and print_topology().
Referenced by helper_client_server().
|
static |
Definition at line 106 of file helper.c.
References alloc_buf_gc(), BSTR, and buf_printf().
Referenced by helper_tcp_nodelay().
|
static |
Definition at line 98 of file helper.c.
References alloc_buf_gc(), BSTR, and buf_printf().
Referenced by helper_keepalive().
|
static |
Definition at line 125 of file helper.c.
References gc_free(), gc_new(), M_USAGE, msg, and print_in_addr_t().
Referenced by helper_client_server().