The route configuration directive accepts the keyword 'default'

In that case it will return a default route irrespective of any other
route directives. That allows overriding existing routes with a default
route for specific users and groups.
This commit is contained in:
Nikos Mavrogiannopoulos
2014-05-19 09:58:37 +02:00
parent 0f0f96ef5c
commit 6bc625df81
7 changed files with 82 additions and 37 deletions
+2
View File
@@ -212,6 +212,7 @@ typedef struct worker_st {
/* information on the tun device addresses and network */
struct vpn_st vinfo;
unsigned default_route;
/* additional data - received per user or per group */
unsigned routes_size;
@@ -253,6 +254,7 @@ void __attribute__ ((format(printf, 3, 4)))
int complete_vpn_info(worker_st * ws,
struct vpn_st* vinfo);
unsigned check_if_default_route(char **routes, unsigned routes_size);
int send_tun_mtu(worker_st *ws, unsigned int mtu);
int handle_worker_commands(struct worker_st *ws);