Re: route add ::/0 ...

2020-07-06 Thread YASUOKA Masahiko
Let me updated the diff. On Mon, 06 Jul 2020 17:54:30 +0900 (JST) YASUOKA Masahiko wrote: > On Tue, 30 Jun 2020 02:42:02 +0200 > Klemens Nanni wrote: >> On Tue, Jun 30, 2020 at 09:00:30AM +0900, YASUOKA Masahiko wrote: >>> inet_makenetandmask() had required another treatment. >>> >>> Also -pref

Re: route add ::/0 ...

2020-07-06 Thread YASUOKA Masahiko
On Tue, 30 Jun 2020 02:42:02 +0200 Klemens Nanni wrote: > On Tue, Jun 30, 2020 at 09:00:30AM +0900, YASUOKA Masahiko wrote: >> inet_makenetandmask() had required another treatment. >> >> Also -prefixlen 0 for -inet has a bug >> >> % doas ./obj/route -T100 add -inet 0.0.0.0 -prefixlen 0 127.0.

Re: route add ::/0 ...

2020-06-29 Thread Klemens Nanni
On Tue, Jun 30, 2020 at 09:00:30AM +0900, YASUOKA Masahiko wrote: > inet_makenetandmask() had required another treatment. > > Also -prefixlen 0 for -inet has a bug > > % doas ./obj/route -T100 add -inet 0.0.0.0 -prefixlen 0 127.0.0.1 > add net 0.0.0.0: gateway 127.0.0.1 > % netstat -nrf inet -

Re: route add ::/0 ...

2020-06-29 Thread YASUOKA Masahiko
On Mon, 29 Jun 2020 19:18:17 +0200 Klemens Nanni wrote: > On Mon, Jun 29, 2020 at 11:55:10PM +0900, YASUOKA Masahiko wrote: >> The function mask_addr() doesn't mask address for IPv4 and IPv6. Does >> any address family other than IPv4 or IPv6 require #1142:1148? The >> function seems to just tri

Re: route add ::/0 ...

2020-06-29 Thread Klemens Nanni
On Mon, Jun 29, 2020 at 11:55:10PM +0900, YASUOKA Masahiko wrote: > The function mask_addr() doesn't mask address for IPv4 and IPv6. Does > any address family other than IPv4 or IPv6 require #1142:1148? The > function seems to just trim the trailing zero. Is it neccesaary? And > it causes the c

Re: route add ::/0 ...

2020-06-29 Thread YASUOKA Masahiko
On Mon, 29 Jun 2020 18:45:07 +0900 (JST) YASUOKA Masahiko wrote: > On Mon, 29 Jun 2020 10:12:23 +0200 > Martin Pieuchot wrote: >> On 28/06/20(Sun) 20:41, YASUOKA Masahiko wrote: >>> Hi, >>> >>> When "::/0" is used as "default", >>

Re: route add ::/0 ...

2020-06-29 Thread YASUOKA Masahiko
Hi, On Mon, 29 Jun 2020 10:12:23 +0200 Martin Pieuchot wrote: > On 28/06/20(Sun) 20:41, YASUOKA Masahiko wrote: >> Hi, >> >> When "::/0" is used as "default", >> >> # route add ::/0 fe80::1%em0 >> add net ::/0: gateway fe80::1%em

Re: route add ::/0 ...

2020-06-29 Thread Martin Pieuchot
On 28/06/20(Sun) 20:41, YASUOKA Masahiko wrote: > Hi, > > When "::/0" is used as "default", > > # route add ::/0 fe80::1%em0 > add net ::/0: gateway fe80::1%em0: Invalid argument > > route command trims the sockaddr to { .len = 2, .family =

route add ::/0 ...

2020-06-28 Thread YASUOKA Masahiko
Hi, When "::/0" is used as "default", # route add ::/0 fe80::1%em0 add net ::/0: gateway fe80::1%em0: Invalid argument route command trims the sockaddr to { .len = 2, .family = AF_INET6 } for "::/0", but rtable_satoplen() refuses it. I think it should be acce