On Tue, 3 Aug 1999, Oscar Bonilla wrote: > > Following on the NSS (Name Service Switch): > > *Step One: I ported the NetBSD implementation of nsdispatch(3) as > implemented > by Luke Mewburn. See attached patch to libc and new header file. I'm also > attaching the man page for /etc/nsswitch.conf. Right now it compiles, > installs, and works for some simple tests I've run.
Great. I haven't alnalyse all of the code but this thing looks a little bit limited: > /* Basically we reduce getpwent to a simple nsdispatch call */ > > struct passwd * > getpwent() > { > int r; > static const ns_dtab dtab[] = { > NS_FILES_CB(_local_getpw, NULL) > NS_DNS_CB(_dns_getpw, NULL) > NS_NIS_CB(_nis_getpw, NULL) > NS_COMPAT_CB(_compat_getpwent, NULL) > { 0 } > }; May be I'm totally wrong, but dtab[] array can be constructed (or extended) dynamically, based on configuration file and _*_getpw() functions can be placed in shared libraries (just like PAM modules). In this case it is possible to extend NSS space without disturbing libc code. -- Boris Popov http://www.butya.kz/~bp/ To Unsubscribe: send mail to majord...@freebsd.org with "unsubscribe freebsd-hackers" in the body of the message