Command to run to create and communicate with local network
interface. Passed to sh -c. Must speak SLIP on stdin/stdout.
The following additional interpolations aare substituted:
- %(local)s %(peer)s %(rnet)s
- on server <vaddr> <vrelay> <vnetwork>
- on client <client> <vaddr> <vroutes>
+ %(local)s %(peer)s %(rnet)s %(ifname)s
+ on server <vaddr> <vrelay> <vnetwork> <ifname_server>
+ on client <client> <vaddr> <vroutes> <ifname_client>
["userv root ipif %(local)s,%(peer)s,%(mtu)s,slip %(rnets)s"]
On server: applies to all clients; not looked up in
mtu
Must match exactly. (UNCHECKED) [1500 bytes]
+ ifname_server
+ Virtual interface name on the server. [shippo%d]
+ ifname_client
+ Virtual interface name on the client. [hippo%d]
+ Any %d is interpolated (by the kernel).
+
Ordinary settings, used by client only:
http_timeout_grace
c.max_queue_time = srch(cfg.getint, 'max_queue_time')
c.vroutes = srch(cfg.get, 'vroutes')
+ def cfg_get_raw(*args, **kwargs):
+ return cfg.get(*args, raw=True, **kwargs)
+
+ try: c.ifname = srch(cfg_get_raw, 'ifname_client')
+ except NoOptionError: pass
+
try: c.url = srch(cfg.get,'url')
except NoOptionError:
cfg_process_saddrs(c, ss)
c.vrelay = search
break
+ try: c.ifname = cfg.get(c.server, 'ifname_server', raw=True)
+ except NoOptionError: pass
+
cfg_process_ipif(c,
[c.server, 'DEFAULT'],
(('local','vaddr'),
http_retry = 5
port = 80
vroutes = ''
+ifname_client = hippo%%d
+ifname_server = shippo%%d
#[server] or [<client>] overrides
-ipif = userv root ipif %(local)s,%(peer)s,%(mtu)s,slip %(rnets)s
+ipif = userv root ipif %(local)s,%(peer)s,%(mtu)s,slip,%(ifname)s %(rnets)s
# relating to virtual network
mtu = 1500