Re: SUDO....Question

From: Seth Arnold (sarnold@wirex.com)
Date: 01/08/02


Date: Tue, 8 Jan 2002 11:47:41 -0800
From: Seth Arnold <sarnold@wirex.com>
To: iEqual <shonh@iequal.net>


On Tue, Jan 08, 2002 at 12:01:53PM +0900, iEqual wrote:
> thought that I could use "sudo" to use only needed commands can be run
> by a certain user. However, our programmers are developing our
> solution in C++ and I have no clue how to apply "sudo" to our
> solution. For example, in the program, it does not use 'system("sudo
> cp /etc/* ./")' instead the program calls for 'cp()' function. Is
> there any other way to use sudo???

sudo is really intended for system administrators who wish to delegate
tasks to other users on the system, without handing over root.

Programs that require fiddling with user/group permissions really should
be using the POSIX functions getuid, setuid, etc .. to perform these
operations. And yes, the security implications are extreme, so consider
reading, for example, Stephens's Advanced Programming in the Unix
Environment's section on the get/set id functions, before starting work.

Cheers

-- 
"I'm not sure which upsets me more: that people are so unwilling
to accept responsibility for their own actions, or that they are
so eager to regulate everyone else's." -- Kee Hinckley




Relevant Pages

  • Re: Sun support quality, was: Re: SUNSOLVE IS DRIVING ME INSANE!!!
    ... don't care: an alternative hypothesis is that they do care, ... Sun has some extraordinarily clever people but most are programmers ... rather than system administrators, so tend ... and external storage spring to mind. ...
    (comp.unix.solaris)
  • Modern computer users sent back in time...
    ... take a bunch of programmers, system administrators, ... hardware techies, et cetera and unceremoniously dump them in the ...
    (comp.sys.apple2)
  • Re: Where is FreeBSD going?
    ... WP> Programmers, system administrators, end users, and anyone else who wants ... WP> to contribute to FreeBSD are welcome to contribute in whatever way they ... WP> willingness to work be known, and become a committer too. ...
    (freebsd-hackers)