[comp.unix.admin] SUMMARY: Background processes writing to other people's ptys

chip@pender.ee.upenn.edu (Charles H. Buchholtz) (05/11/91)

Here's the original question:

>I run a few multi-user machines running SunOS 4.1.  Our users login
>via telnet and rlogin.  Frequently, the following problem occurs:
>
>Arnold logs in on ptyp1, starts a long running job, puts it in
>background (via ^Z bg), and then logs out.  "ps" shows "?" as the
>process' tty.
>
>Betty logs in on ptyp1, and sees the output of Arnold's background
>process on her display mixed in along with her session.
>
>What I want is:
>
>Some way to cause such processes to abort as soon as they try to write
>to the pty, or failing that, some way to cause the processes to block
>when they try to write to the pty.
>
>I can't count on the users to do anything; I need a system wide
>solution.  A Sun Patch number or "fixed in 4.1.1" is an acceptable
>solution.

I got the answer I was looking for from hr@sirius.astro.uiuc.edu
(Harold Ravlin).  He pointed me to the CERT advisory concerning Sun
telnet, and Sun patch 100125-03.

Many people suggested using "ofiles" to determine which process was
using that pty.

Thanks to all those who responded:

Harold Ravlin <hr@sirius.astro.uiuc.edu>
Pat Barron    <pat@orac.pgh.pa.us>
Henry Clark   <henryc@oar.net>
Lyle Seaman   <lws@sununix.comm.wang.com>
Gary Mills    <mills@ccu.umanitoba.ca>

Charles H. Buchholtz                           chip@ee.upenn.edu
Systems Programmer                             (215) 898-2491
School of Engineering and Applied Science      200 S. 33rd St, rm 154
University of Pennsylvania                     Philadelphia, PA 19104