};
page1
CLINET * clntudp_create (sockaddr_xxx remote_address,..., int socket) if ( ((struct sockaddr_in *)raddr)->sin_family == AF_INET6 ) { copy(remote_address into cl_private) else it's ipv4 so map to ipv6 sin6_addr ::FFFF:<IPv4-address>
If socket == ANYSOCK -- no problem create an AF_INET6 sock If passed in a socket, user getsockname(socket) to determine if it AF_INET or AF_INET6 clntudp_control( ,,CLGET_SERVER_ADDR) if you've mapped, un-mapp and return sockaddr_in (ipv4)
page 3
Server transport changes Transport Specific Server svctcp_recv, svctcp_stat, svctcp_getargs, svctcp_reply, svctcp_freeargs, svctcp_destroy typedef struct SVCXPRT { int xp_sock; u_short xp_port; /* associated port number */ ... >>> struct sockaddr_in xp_raddr; /* remote address */ struct opaque_auth xp_verf; /* raw response verifier */ caddr_t xp_p1; /* private: for use by svc ops */ caddr_t xp_p2; /* private: for use by svc ops */ caddr_t xp_p3; /* private: for use by svc lib */ } SVCXPRT; svcxxx_yyyyy() svcxxx_yyyyy2() extern SVCXPRT *svcudp_create(); <<< ipv4 extern SVCXPRT *svcudp_create2(); <<< ipvx pass in address_family pass in len (just in case) misc lib calls to determine and map addresses and names see: draft-ietf-ipngwg-bsd-api-00.txt Advanced Sockets API for IPv6 RFC2292 contractors whom do this type of work: http://journyx.com/consulting.html