🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.security.misc
Article #120

Re: Advice on (potential?) security problem

#120
From: Casper H.S. Dik
Date: Mon, 10 Aug 1992 14:08
26 lines
1374 bytes
sjr@afterlife.ncsc.mil (Stephen J. Roznowski) writes:

>I'm busy looking for potential security holes in a suid root program.

>Currently, the program does the following:

>	system("/bin/stty -echo ...");

>Now, I realize that the "exec-ed" program also has to be "trusted",
>or there is a security hole (i.e. If I can replace /bin/stty, all
>bets are off).

>Now suppose that I do "all the correct things" before issuing the
>"system" call (set IFS, etc.) is this worse/same as the following:

>	tcgetattr(fd, &t);
>	t.c_lflag &= ~ECHO;
>	tcsetattr(fd, TCSANOW, &t);

The best things is to totally kill the environment. You'll never
no what kind of environment variables will be used for whatever purpuse
in future. Currently IFS, all variables starting with LD_ (on Suns), TERM
and PATH are the potentially dangerous ones (that I know of).
-- 
						|	Casper H.S. Dik
						|	casper@fwi.uva.nl
Technical Details
Message-ID: <1992Aug10.140817.20221@fwi.uva.nl>
Path: arc1-ca.pugleaf.net!sparky!uunet!mcsun!sun4nl!fwi.uva.nl!casper
References: <1992Aug7.022422.9878@afterlife.ncsc.mil>

Show Full Headers
Complete Article Headers
Newsgroups: comp.security.misc,alt.security
Path: arc1-ca.pugleaf.net!sparky!uunet!mcsun!sun4nl!fwi.uva.nl!casper
From: casper@fwi.uva.nl (Casper H.S. Dik)
Subject: Re: Advice on (potential?) security problem
Message-ID: <1992Aug10.140817.20221@fwi.uva.nl>
Sender: news@fwi.uva.nl
Nntp-Posting-Host: adam.fwi.uva.nl
Organization: FWI, University of Amsterdam
References: <1992Aug7.022422.9878@afterlife.ncsc.mil>
Date: Mon, 10 Aug 1992 14:08:17 GMT
Lines: 26