🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.unix.programmer
Article #109

Re: Making ``.plan'' EXECUTE a Program ???

#109
From: Carl Edman
Date: Fri, 24 Jul 1992 15:25
27 lines
1487 bytes
Tom Christiansen <tchrist@convex.COM> writes
> > This is because it was possible to do the following
> > ln -s <any file> ~/.plan
> > finger <my username>
> > and read any file on the system on some versions of unix.
> > The simplist fix is to just have fingerd refuse to read
> > anything not a regular file. 
> 
> Seem to me that doing this in fingerd:
> 
>     if (fork) return;
>     setuid(-2);
>     (do file reading
>     exit(0);
> 
> Would have been better.

Why even start up fingerd as root at all ? Most systems which I'm aware have  
'nobody' as the user for fingerd. BTW, a forked finger (my god, what images  
does that evoke ?) does the file reading for fingerd.

This of course wouldn't work for a fingerd/finger hack, I once wrote which  
checks whether the .plan or .project files have their executable bits set and  
if executes them as the finger target user if so. That avoids all that nasty  
pipe business which breaks under NFS and requires a constantly running daemon.

	Carl Edman
Technical Details
Message-ID: <2A7020E3.21935@noiro.acs.uci.edu>
Path: arc1-ca.pugleaf.net!sparky!uunet!news.claremont.edu!ucivax!noiro.acs.uci.edu!nntpsrv
References: <1992Jul24.131605.8213@news.eng.convex.com>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!news.claremont.edu!ucivax!noiro.acs.uci.edu!nntpsrv
From: cedman@714-725-3165.nts.uci.edu (Carl Edman)
Subject: Re: Making ``.plan'' EXECUTE a Program ???
Nntp-Posting-Host: 714-725-3165.nts.uci.edu
Message-ID: <2A7020E3.21935@noiro.acs.uci.edu>
Newsgroups: comp.unix.programmer
Reply-To: cedman@golem.ps.uci.edu (Carl Edman)
Lines: 27
Date: 24 Jul 92 15:25:23 GMT
References: <1992Jul24.131605.8213@news.eng.convex.com>