--- Routes
-local defroutev4 = sys.net.defaultroute()
-local defroutev6 = sys.net.defaultroute6()
-
-if defroutev4 then
- defroutev4.dest = defroutev4.dest:string()
- defroutev4.gateway = defroutev4.gateway:string()
-else
- -- probably policy routing activated, try olsr-default table
- local dr4 = sys.exec("ip r s t olsr-default")
- if dr4 then
- defroutev4 = { }
- defroutev4.dest, defroutev4.gateway, defroutev4.device, defroutev4.metric = dr4:match("^(%w+) via (%d+.%d+.%d+.%d+) dev ([%w-]+) +metric (%d+)")
- end
-end
-
-if defroutev6 then
- defroutev6.dest = defroutev6.dest:string()
- defroutev6.nexthop = defroutev6.nexthop:string()
-end
-