Differentiating piped processes

eddy keller eddy at bohica.com
Sat Nov 25 06:19:16 AEST 1989


I have a packaged program that allows the user to send the
output to either a file or pipe it to a process (most common here 
is to send it to lp ).  Without having to go into length and detail
this program runs in background and allows users of a certain 
emulation program the ability to print.  What I want to do is pipe 
this output to a program that I have written which takes the data and 
puts it in a file in the users directory.  The problem however, is that
all the output appears to be owned by the person (usually root)  who
started the packaged program, not the user who requested a print.
Is there any way anyone can think of to work around this.  I cannot
get the uid of the process as it always return the person who started
the process.  I can create a single user print processor (using 
lockfiles)  but that seems rather a waste of resources.  Any
helpful suggestions???

--eddy
-- 
Security Pacific National Bank           S         Systems Division
Financial Management & Trust Services  _\|/_       Glendale, Calif.
Internet: ekeller at bohica.com         UUCP: ...ames!elroy!bohica!ekeller



More information about the Comp.unix.questions mailing list