More fun with IPv6 route(8) output

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

More fun with IPv6 route(8) output

David Higgs
Last year, I reported some confusing behavior with route(8), which was
kindly resolved with both an immediate workaround and code improvements.
https://marc.info/?l=openbsd-misc&m=152712936731762&w=2

I now realize that I am experiencing the reverse problem in 6.6, in that I
cannot resolve any IPv6 address with explicit netmasks.  This applies to
IPv6 addresses with and without the trailing double-colon.  There have been
several changes in mid-2018 that could have caused this, but I had blamed
failures on intermittent (intermittent) ISP / dhcpcd issues without
investigating.

I can easily fix my script, but figured I should report the regression.
(Apologies for formatting as usual.)

Thanks!

--david

$ route -n get 2607:f8b0:4004:805::/128
get host 2607:f8b0:4004:805::/128: not in table

$ route -n get 2607:f8b0:4004:805::
   route to: 2607:f8b0:4004:805::
destination: ::
       mask: ::
    gateway: fe80::201:5cff:fe86:7046%em0
  interface: em0
 if address: fe80::20d:b9ff:fe4a:52e4%em0
   priority: 56 (default)
      flags: <UP,GATEWAY,DONE,STATIC>
      label: slaacd
     use       mtu    expire
 1631319         0         0
sockaddrs: <DST,GATEWAY,NETMASK,IFP,IFA,LABEL>
Reply | Threaded
Open this post in threaded view
|

Re: More fun with IPv6 route(8) output

Alarig Le Lay
Since the matching route is ::/0, it does make sense to me to print this
error message. The /128 route doesn’t exist.

However, I’m getting an error about ::/0

guinch# route -n get 2a00:5884:102:1::/64



   route to: 2a00:5884:102:1::
destination: 2a00:5884:102:1::
       mask: ffff:ffff:ffff:ffff::
  interface: vio0
 if address: 2a00:5884:102:1::9
   priority: 4 (connected)
      flags: <UP,DONE,CLONING,CONNECTED>
     use       mtu    expire
       0         0         0
guinch# route -n get ::/0
get net ::/0: not in table
guinch# route -n get 2a00:5884::1
   route to: 2a00:5884::1
destination: ::
       mask: ::
    gateway: fe80::209%vio0
  interface: vio0
 if address: fe80::5054:ff:fed4:f3fa%vio0
   priority: 8 (static)
      flags: <UP,GATEWAY,DONE,STATIC>
     use       mtu    expire
  218366         0         0

--
Alarig