signals to running processes

Maarten Litmaath maart at cs.vu.nl
Fri Dec 2 03:14:05 AEST 1988


cjosta at taux01.UUCP (Jonathan Sweedler) writes:

\...  This all works fine but only I (the owner
\of the process) can send the signal.  If my boss, for example, wants to
\look at the status of the process, he can't.

\My questions are these:  
\1) Is there any way for someone who is not the owner of a process to
\send the process a signal?

If your boss is root, he can :-)

\2) Or, is there another way for a random user to cause a program to
\asynchronously print out a status report (or perform some action) once
\it has started running?

You could let a child of the program test if a certain file in /tmp
exists, and, if so, signal the parent; anyone can make the file, and it's
still a process of yours (the child) who's doing the signaling. The
signal handler could look at the owner of the file, to determine who to
send the status report to. By using a child process the asynchronous
signal scheme is still possible; you'd rather not let the parent constantly
check /tmp for the file.

\...
\I could also probably (haven't done this yet) write a shell script that
                                                       ^^^^^^^^^^^^
\would send the signal and is setuid to me but then if different people
                              ^^^^^^

Aaaaaaaaaaaaarrrrrrrrrrrrgh!!!!!
Haven't you followed the `setuid shell scripts' discussion?
-- 
fcntl(fd, F_SETFL, FNDELAY):          |Maarten Litmaath @ VU Amsterdam:
      let's go weepin' in the corner! |maart at cs.vu.nl, mcvax!botter!maart



More information about the Comp.unix.questions mailing list