X-Recipient: archive-cygwin AT delorie DOT com X-Spam-Check-By: sourceware.org From: "Dave Korn" To: References: <47D4B7D2 DOT 1F78DADB AT dessent DOT net> <47D4E892 DOT 1090305 AT tlinx DOT org> <47D50BB6 DOT EFB28302 AT dessent DOT net> <47D6056B DOT 6000805 AT tlinx DOT org> <47D610C2 DOT EECE7EE9 AT dessent DOT net> <00b601c8843a$d94fe2c0$2708a8c0 AT CAM DOT ARTIMI DOT COM> <47D7EFEC DOT 122C76AE AT dessent DOT net> <00d001c88456$9f75a3c0$2708a8c0 AT CAM DOT ARTIMI DOT COM> <47D7FDDB DOT 73ABB705 AT dessent DOT net> <00dd01c8845c$078e8ee0$2708a8c0 AT CAM DOT ARTIMI DOT COM> <20080312162302 DOT GT18407 AT calimero DOT vinschen DOT de> Subject: RE: Bug: C-prog from Win dies in fork; gdb.exe also won't run Date: Wed, 12 Mar 2008 17:06:20 -0000 Message-ID: <00e101c88463$64d79d60$2708a8c0@CAM.ARTIMI.COM> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 11 In-Reply-To: <20080312162302.GT18407@calimero.vinschen.de> Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Corinna Vinschen wrote on 12 March 2008 16:23: > On Mar 12 16:13, Dave Korn wrote: > > Brian Dessent wrote on 12 March 2008 15:59: > > > Dave Korn wrote: > > > > Now, who supposes you could work around the restriction by writing > > > > > > > > * (WORD *) 0x004000dc = POSIX_CUI; > > > > > > > > just before calling NtSetInformation? > > > > > > How are you going to fool the executive by poking around in the PE > > > header from userspace long after the process has initialized? The > > > executive fundamentally knows which subsystem any given process is > > > running in because it created it and manages the low level process > > > table. > > > > This is not just any code - this is MS code. > > > > Given that, it's therefore going to have been done as quickly and > > cheaply as possible, so why should we assume they wouldn't they just > > check the value in the PE header at the start of > > NtSetInformationProcess? > > Is that just an assumption or do you know that this would work? It's neither. It's a question, which I raise on the basis of an educated guess about what is possible. I don't have Vista or I'd already have reversed the ker^H^H^H^H^H^H^H^H^H^H^H^H^H^H^H^H written a test program to see if it works or not. cheers, DaveK -- Can't think of a witty .sigline today.... -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/