rpc.statd already ipv6 clean?

Rick Macklem rmacklem at uoguelph.ca
Thu Sep 26 15:25:42 UTC 2019


Mihir Luthra wrote:
>Hiroki Sato wrote:
>>
>>
>>  I think you should learn TI-RPC API first.  The nettype specifies a
>>  class of transport protocol, not address family.
>>
>> Thanks, I did some more research on TI-RPC today.
>In `statd.c` what I see is in `create_service()`/`complete_service()`,
>transport info is being fetched through getnetconfig(), which makes it
>listen on all transports. I guess its clean in `statd.c` but same can also
>be done in `procs.c`/`file.c`. Maybe trying all transports until it finds
>one which is connectionless? Apologies if I got something wrong, new to
>this topic.
>
>Also, while looking at the code, I think it always assumes ipv4 is always
>present. Like `127.0.0.1` is added to host list always. On ipv6 only
>machine this may fail.
Although I'll admit it isn't something I am particularily fond of, FreeBSD likes
utilities to build/work with only one of ipv4/ipv6.
To do this, "#ifdef INET" and "#ifdef INET6" is applied to the code and the
Makefile is tweaked to define one or both of these.
(You can look at usr.sbin/nfsuserd for an example of this.)

Btw, these protocols are old Sun Microsystems ones without any published
RFC, so what is "correct" is difficult to determine. I suppose the Open
Solaris sources is the best protocol specification. (Interop. testing with Linux
would be nice, since Linux is the "defacto standard" now.)

Good luck with it, rick

Kind Regards,
Mihir
_______________________________________________
freebsd-net at freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscribe at freebsd.org"


More information about the freebsd-net mailing list