Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 30 Aug 1999 00:46:24 +0200 (CEST)
From:      Alban Hertroys <dalroi@wit401310.student.utwente.nl>
To:        Chris Piazza <cpiazza@home.net>
Cc:        "Chris D. Faulhaber" <jedgar@fxp.org>, Natty Rebel <dervish@ikhala.tcimet.net>, freebsd-hackers@FreeBSD.ORG, Volker Stolz <stolz@Pool.Informatik.RWTH-Aachen.DE>
Subject:   Re: [mount.c]: Option "user"-patch
Message-ID:  <19990829224626.16DA51DE9@wit401310.student.utwente.nl>
In-Reply-To: <19990829153613.A34749@norn.ca.eu.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On 29 Aug, Chris Piazza wrote:
> On Sun, Aug 29, 1999 at 06:30:35PM -0400, Chris D. Faulhaber wrote:
>> On Sun, 29 Aug 1999, Natty Rebel wrote:
>> 
>> > This procedure can be automated by entering the following command
>> > in /etc/rc.sysctl
>> > 	sysctl -w vfs.usermount=1

I have seen this line a lot lately. It isn't in FreeBSD 3.2-STABLE, is
it? My /usr/src/sbin/mount/mount.c says:

        /*
         * If the mount was successfully, and done by root, tell mountd the
         * good news.  Pid checks are probably unnecessary, but don't hurt.
         */
        if (rval == 0 && getuid() == 0 &&
            (mountdfp = fopen(_PATH_MOUNTDPID, "r")) != NULL) {
                if (fscanf(mountdfp, "%d", &pid) == 1 &&
                     pid > 0 && kill(pid, SIGHUP) == -1 && errno != ESRCH)
                        err(1, "signal mountd");
                (void)fclose(mountdfp);
        }

getuid() == 0 looks a lot like root-only to me... Or am I missing
something?


-- 
Alban Hertroys.
http://wit401310.student.utwente.nl
==
If there is a here-after,
then there are much more people dead than alive.
Even that much more that the number of living people
is insignificant in comparison to the dead ones.
Thus it is safe to say that we don't exist.



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19990829224626.16DA51DE9>