Date: Sun, 15 Jun 1997 04:00:01 -0700 (PDT) From: Doug Rabson <dfr@nlsystems.com> To: freebsd-bugs Subject: Re: kern/3838: fifos on nfs-mounted fs no longer permitted Message-ID: <199706151100.EAA05820@hub.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR kern/3838; it has been noted by GNATS. From: Doug Rabson <dfr@nlsystems.com> To: Bruce Evans <bde@zeta.org.au> Cc: admin@citylink.dinoex.sub.org, FreeBSD-gnats-submit@freebsd.org, dfr@freebsd.org Subject: Re: kern/3838: fifos on nfs-mounted fs no longer permitted Date: Sun, 15 Jun 1997 11:57:50 +0100 (BST) On Wed, 11 Jun 1997, Bruce Evans wrote: > >mkfifo on a nfs-mounted filesystem will reply: "operation not permitted". > >This didn't happen with release 2.1.0. (No, the fs isn't mounted with > >nodev!) > > This was broken in the initial v3 import (rev.1.16), which is essentially > the same as Lite2. There are several bugs: > > 1. In the v2 case, nfsrv_create() lost some special handling for fifos. > suser() is always called, although mkfifo doesn't require special > privileges. > 2. In the v3 case, the new nfsrv_mknod() never had enough special handling > for fifos. suser() is always called, except for sockets. > 3. In the v3 case, after suser() fails, the error code is eventually > thrown away. nfsrv_mknod() returns 0, and mkfifo() returns the bogus > errno EIO. > > Bruce > > Untested fixes for (1)-(2): > > ! if (vap->va_type == VFIFO && > ! (error = suser(cred, (u_short *)0))) { I think this should be: if (vap->va_type != VFIFO && (error = suser(cred, (u_short *)0))) { Apart from that, your fixes seem to work fine. Oh. I just noticed that your fixes have already been committed. Sorry for not giving feedback earlier; I have been extremely busy on other stuff for the last few days. -- Doug Rabson Mail: dfr@nlsystems.com Nonlinear Systems Ltd. Phone: +44 181 951 1891 Fax: +44 181 381 1039
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199706151100.EAA05820>