$OpenBSD: patch-options_c,v 1.3 2010/08/30 18:32:20 fkr Exp $ --- options.c.orig Tue Jul 27 23:44:34 2010 +++ options.c Sun Aug 22 16:10:23 2010 @@ -254,6 +254,7 @@ static const char usage_message[] = "--sndbuf size : Set the TCP/UDP send buffer size.\n" "--rcvbuf size : Set the TCP/UDP receive buffer size.\n" "--txqueuelen n : Set the tun/tap TX queue length to n (Linux only).\n" + "--rtable n : Set the routing table (default=0, OpenBSD only)\n" "--mlock : Disable Paging -- ensures key material and tunnel\n" " data will never be written to disk.\n" "--up cmd : Shell cmd to execute after successful tun device open.\n" @@ -1261,6 +1262,7 @@ show_settings (const struct options *o) #endif SHOW_INT (rcvbuf); SHOW_INT (sndbuf); + SHOW_INT (rtable); SHOW_INT (sockflags); SHOW_BOOL (fast_io); @@ -4169,6 +4171,11 @@ add_option (struct options *options, { VERIFY_PERMISSION (OPT_P_SOCKBUF); options->sndbuf = positive_atoi (p[1]); + } + else if (streq (p[0], "rtable") && p[1]) + { + VERIFY_PERMISSION (OPT_P_SOCKFLAGS); + options->rtable = positive_atoi (p[1]); } else if (streq (p[0], "socket-flags")) {