spy program tty error

From: selcuk karaca <selcuk.karaca_at_aski.gov.tr>
Date: Mon, 04 Jun 2001 14:17:03 +0300

Hello admins,
I have small problem, I ask you to help me ...

My platform :
Alpha 4100 2 Gb RAM ,
DU 4.0D

I am trying to make a spy program, to see what our terminal users are doing
(sometimes it is really neeeded)
I have written a script ;
in .profile, last line is;
/usr/bin/sh -c "runform30 form_application | tee -a `tty` " 1> MY_TTY

in this shell command, the output is directly sent to my terminal and "tee"d
to the user's terminal.
Now there are some problems here,
Shell command can not write to the root's tty, infact it can not write to
anyone's tty, apart from himself..
it gives an error in the profile execution like the following ;
/dev/ttyXX: can not create

When I look at the file permissions...
crw--w---- 2 selcuk terminal 6, 59 Jun 4 14:09 /dev/ttysb

it is easy to understand because no one is permitted to write to my terminal
file..
But I want that user to output his screen to my terminal

How can I achieve this without changing terminal device file permissions ..
OR any other method to spy terminal user display ???

TIA...
Received on Mon Jun 04 2001 - 11:21:23 NZST

This archive was generated by hypermail 2.4.0 : Wed Nov 08 2023 - 11:53:42 NZDT