problem with readonly pinfo?

Pierre A. Humblet Pierre.Humblet@ieee.org
Wed Sep 17 04:06:00 GMT 2003


At 11:32 PM 9/16/2003 -0400, Christopher Faylor wrote:
>On Tue, Sep 16, 2003 at 10:48:33PM -0400, Pierre A. Humblet wrote:
>>>Yes, I know about those problems.  That's why I haven't checked in the
>>>pipe stuff yet.
>>
>>Is SIGCHLD the only case where that occurs (in addition to the process
>>group leader who isn't an ancestor)? 
>
>I believe so, yes.
>
A solution for SIGCHLD could be to have an event just for that,
settable by Everyone.
The parent has pinfo's for all its children and can scan them to see
who did it.
That doesn't solve the case of the group leader who isn't an ancestor.

I am looking at your changes in fhandler_process::fill_filebuf.
By insisting on PID_MAP_RW we will be depriving ourselves (in the future)
of the possibility of getting information that doesn't require writing.

One way out would be for pinfo::init to open read only if it can't
do it RW. It would then set a flag in pinfo. Users of the pinfo
would look it up before attempting to write to the _pinfo.

I am also mulling on the case of a process that setuids and execs.
The resulting Windows process won't have access to the pinfo of its
cygpid. That pinfo has been created long ago by its Windows grandfather.
One would be to change the acl of the pinfo mapping before the exec.
 
Pierre



More information about the Cygwin-developers mailing list