Re: how to restrict access of FIFO-pipes to two dedicated processes?
From: bine (sabine.hubrig-schaumburg_at_sungard.de)
Date: 04/21/04
- Next message: Stu: "Printing rlog message upto a label"
- Previous message: Barry Margolin: "Re: help with perl"
- In reply to: those who know me have no need of my name: "Re: how to restrict access of FIFO-pipes to two dedicated processes?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 21 Apr 2004 08:18:07 -0700
those who know me have no need of my name <not-a-real-address@usa.net> wrote in message news:<m1llkunv01.gnus@usa.net>...
> ... or you can use the classic solution of
> removing the file after the reader (gzip) has it open -- neither are atomic
> so there is still a period of time which is vulnerable.
>
> an example of the later, which should executed via a single call to the
> shell is:
>
> mknod apipe$$ p ; gzip -1 < apipe$$ > apipe$$.gz & rm -f apipe$$
>
> i've used $$ so that the same program running more than one at a time will
> not destroy each other's files. whether that's appropriate you will have
> to decide.
Nice try :-)
unfortunately in that case I get a file named like the apipe$$ written
by the WRITING process, instead of the packed version apipe$$.gz which
I wanted.
I tried the above not as currently needed out of COBol, byt directly
in a script where we do the same for some time already, were we gzip a
dumpfile which is written out of oracle's exp[ort], which I would have
made more secure as well if I'd found a solution. In that case I don't
even have a chance to "rm" the "file" after the export starts until
it's finished (if I don't use another script looking for the file and
doing the rm which might not work, I'll experiment a bit with that).
But for my current problem I might try the "rm" out of my COBol after
the OPEN OUTPUT statement and look what happens, if COBol still can
WRITE into a nonvisible "file=pipe" and gzip still can read and nobody
else is lead into temptation because nobody knows of that file, that
would be a stunning solution.
Thanks anyway so far,
bine
----------------------------------------------------------------------
The goal of science is to build better mousetraps,
The goal of nature is to build better mice !
- Next message: Stu: "Printing rlog message upto a label"
- Previous message: Barry Margolin: "Re: help with perl"
- In reply to: those who know me have no need of my name: "Re: how to restrict access of FIFO-pipes to two dedicated processes?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|