freebsd-nq/lib
Alfred Perlstein 08760d5a57 Fix the credential handling code.
In NetBSD, Solaris, xprt->xp_p2 pointed directly to the credentials,
in FreeBSD xprt->xp_verf.oa_base was a pointer to a struct cmessage,
which is defined as follow:

struct cmessage {
        struct cmsghdr cmsg;
        struct cmsgcred cmcred;
};

The credentials were submitted the right way and xprt->xp_p2 pointed to them.
But cb_verf.oa_flavor was still empty. There was an assignment missing
in svc_recv() in svc_vc.c:

msg->rm_call.cb_verf.oa_flavor = AUTH_UNIX;

Also

+       if (addr.ss_family == AF_LOCAL) {
+               xprt->xp_raddr = *(struct sockaddr_in *)xprt->xp_rtaddr.buf;
+               xprt->xp_addrlen = sizeof (struct sockaddr_in);
+       }

was missing. But the first seems not to be needed:

I guess in rpc.yppasswdd there was a typo:

- transp>xp_verf.oa_flavor != AUTH_UNIX) {
+ rqstp->rq_cred.oa_flavor != AUTH_UNIX) {

This little fix does fix the breakage in rpc.yppasswdd :-)

+       if (msg.msg_controllen == 0 ||
+           (msg.msg_flags & MSG_CTRUNC) != 0)
+               return (-1);

We cannot set the cb_verf.oa_length in svc_recv() of svc_vc.c,
the credentials get overwritten then, and that's bad.

Submitted by: mbr
2002-02-05 19:30:30 +00:00
..
compat Add libfetch.so.2 from a 17-Dec-2001 4.5-RC (releng4) build. 2002-01-24 18:59:29 +00:00
csu GC code that moved to crtbrand.c. 2002-01-28 19:02:34 +00:00
libalias Fixed the bug in transparent TCP proxying with the "encode_ip_hdr" 2001-12-18 16:13:45 +00:00
libatm __FBSDID() Cleanup 2001-09-30 21:06:00 +00:00
libbind
libbz2 style nit 2001-07-09 23:12:23 +00:00
libc Fix the credential handling code. 2002-02-05 19:30:30 +00:00
libc_r Undo the work-around for the sendfile bug where nbytes needed the hdr/trl 2002-01-22 23:35:09 +00:00
libcalendar mdoc(7) police: Use the new .In macro for #include statements. 2001-10-01 16:09:29 +00:00
libcam Const'ify the CDB format string passed to the CDB parsing routines 2001-12-18 00:48:44 +00:00
libcom_err MAN[1-9] -> MAN. 2001-03-27 17:27:19 +00:00
libcompat mdoc(7) police: Use the new .In macro for #include statements. 2001-10-01 16:09:29 +00:00
libcrypt s/crypt_format/crypt_default/ to match reality. 2001-12-13 08:05:32 +00:00
libdevinfo Made this header self-sufficient. 2001-10-03 05:25:07 +00:00
libdevstat Fixed wrong arg type in synopsis. 2001-10-03 03:57:42 +00:00
libdisk Modify Delete_Chunk() into Delete_Chunk2() which can take a flags 2002-01-07 07:47:25 +00:00
libedit Fix problem where with PicoBSD the shell coredumps if it does not find an 2002-01-24 13:54:19 +00:00
libfetch Check the return value from read() when reading the CR/LF at the end of a 2002-01-20 19:53:12 +00:00
libform MAN[1-9] -> MAN. 2001-03-27 17:27:19 +00:00
libftpio mdoc(7) police: Use the new .In macro for #include statements. 2001-10-01 16:09:29 +00:00
libgnumalloc Do not fail doing rm -f ${DESTDIR}${LIBDIR}/lib${LIB}.a if the 2001-11-03 06:33:08 +00:00
libio Add __FBSDID()s to libio 2001-09-30 21:41:46 +00:00
libipsec mdoc(7) police: Use the new .In macro for #include statements. 2001-10-01 16:09:29 +00:00
libipx mdoc(7) police: Use the new .In macro for #include statements. 2001-10-01 16:09:29 +00:00
libisc hex.c is new in libisc with 8.3.1-REL. 2002-02-04 19:18:23 +00:00
libkse Use the real function address (instead of function address + 8) for the 2001-12-22 06:11:06 +00:00
libkvm Finish cleanup in kvm.c revisions 1.10 and 1.11 -- mark sf (swapfile) 2002-01-22 10:07:03 +00:00
libm Removed most of the zombie man pages in libm. All relevant parts have 2001-10-13 14:22:08 +00:00
libmd mdoc(7) police: Use the new .In macro for #include statements. 2001-10-01 16:09:29 +00:00
libmenu Update for ncurses 5.2-20010512 import 2001-05-17 08:30:09 +00:00
libmp Fixed spelling of rpow in rpow's prototype. 2001-10-03 16:33:00 +00:00
libncp Compensate for "Compensate for header dethreading" by backing it out. 2001-10-10 17:48:44 +00:00
libncurses Add __FBSDID()s to libncurses 2001-09-30 22:02:43 +00:00
libnetgraph Fix bugs in NgSendMsg() and NgSendAsciiMsg() where the wrong token 2001-10-25 04:02:25 +00:00
libopie Turn off USER_LOCKING which allows intruder to completely disable OPIE 2002-01-03 16:04:57 +00:00
libpam Three times lucky: <stddef.h>, not <sys/param.h> 2002-02-05 08:01:32 +00:00
libpanel MAN[1-9] -> MAN. 2001-03-27 17:27:19 +00:00
libpcap Update our bpf.h with tcpdump.org's new DLT_ types. 2001-07-31 23:27:06 +00:00
libpthread Use the real function address (instead of function address + 8) for the 2001-12-22 06:11:06 +00:00
libradius mdoc(7) police: Use the new .In macro for #include statements. 2001-10-01 16:09:29 +00:00
libresolv Dont fail if ${DESTDIR}${LIBDIR}/ or any of its components dont 2001-11-03 06:26:15 +00:00
librpcsvc Add __FBSDID()s to librpcsvc 2001-09-30 22:15:15 +00:00
libsbuf Enable WARNS?=2. 2002-01-06 08:47:19 +00:00
libsmb Supply SMB_CFG_FILE in CFLAGS. The newly imported smbfs-1.4.2 2001-12-20 16:21:47 +00:00
libsmdb Add a MAINTAINER= line so people know who to blame 2000-10-26 23:02:36 +00:00
libsmutil Add a MAINTAINER= line so people know who to blame 2000-10-26 23:02:36 +00:00
libstand Fixed world breakage in previous commit. The generated headers are in 2002-02-02 00:20:32 +00:00
libtacplus mdoc(7) police: Use the new .In macro for #include statements. 2001-10-01 16:09:29 +00:00
libtelnet Merge the (in)complete ANSIfication work from src/crypto/telnet. 2001-11-30 22:37:28 +00:00
libusb mdoc(7) police: Use the new .In macro for #include statements. 2001-10-01 16:09:29 +00:00
libusbhid mdoc(7) police: Use the new .In macro for #include statements. 2001-10-01 16:09:29 +00:00
libutil ANSIfy and constify. 2002-02-05 06:49:11 +00:00
libvgl add missing MLINKS 2001-12-21 18:26:01 +00:00
libwrap MAN[1-9] -> MAN. 2001-03-27 17:27:19 +00:00
libxpg4 Bump major to preserve 3.x binaries compatibility 2000-06-13 00:41:38 +00:00
liby Dont fail if the intermediate directories in ${DESTDIR}/usr/lib/compat/* 2001-11-03 06:24:23 +00:00
libz Add huff __FBSDID()s puff to whew! libz 2001-09-30 22:39:00 +00:00
msun Add ifdef sparc64. 2002-01-02 06:54:18 +00:00
ncurses Add __FBSDID()s to libncurses 2001-09-30 22:02:43 +00:00
Makefile Kernel support for smbfs is only built on the i386 at the moment, so 2001-12-14 23:11:45 +00:00
Makefile.inc