delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2012/04/23/10:24:27

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=-0.5 required=5.0 tests=AWL,BAYES_00,KHOP_THREADED,RCVD_IN_DNSWL_NONE,RCVD_IN_HOSTKARMA_YE,RCVD_IN_SORBS_WEB,SPF_HELO_PASS
X-Spam-Check-By: sourceware.org
From: "James Johnston" <JamesJ AT motionview3d DOT com>
To: <cygwin AT cygwin DOT com>
References: <00f201cd1f1d$43430230$c9c90690$@motionview3d.com> <20120420205019 DOT GA25994 AT ednor DOT casa DOT cgf DOT cx>
In-Reply-To: <20120420205019.GA25994@ednor.casa.cgf.cx>
Subject: RE: Two probable basing issues causing fork failures: (1) cygreadline7.dll has ASLR enabled, (2) default base address conflicts with ASLR-relocated/system DLLs
Date: Mon, 23 Apr 2012 14:23:50 -0000
Message-ID: <012001cd215c$b521ee20$1f65ca60$@motionview3d.com>
MIME-Version: 1.0
X-IsSubscribed: yes
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

Perhaps I did not make it clear enough, but these issues still exist as far
as I can tell.  I have clean Windows 7 and Windows XP virtual machines, and
a clean install of Cygwin that was updated at the time I sent my original
message.  Both issues I described still exist.  This is why I wrote the
message.  If the issues weren't existing on an up-to-date Cygwin
installation, I would not write to this mailing list and waste anyone's time
- I am usually not that dumb! 

Just this morning, I turned on my Cygwin installation in the Windows 7 VM.
This time, cygreadline7.dll decided to relocate to 0x70030000 - different
from the original location I mentioned in my original e-mail.  This DLL is
not locating itself in a stable location.  And there are still system DLLs
located very close to the Cygwin DLLs.

If having Windows randomly rebase cygreadline7.dll in a child process via
ASLR is not a problem, I'd simply be interested to know why.  I thought
*any* Cygwin DLL relocating itself would cause fork to fail.  If having
Cygwin DLLs conflict with system DLLs in the address space is not a
potential problem, I'd also be interested to know why.  Because I am
observing both of these on an *up-to-date Cygwin installation* - not just
the Cygwin 1.7.9 setup.  According to the users guide at
http://cygwin.com/cygwin-ug-net/highlights.html#ov-hi-process - section
"Problems with process creation" - having Cygwin DLLs conflict with system
DLLs is a problem, and having cygreadline7.dll randomly based via ASLR is a
problem - so is my logic faulty in this case or not?

As far as I can tell, I'm up-to-date...  Setup says I have libreadline7
6.1.2-2 installed - the latest according to
http://cygwin.com/packages/libreadline7/.  My file size and date matches
what is shown at that URL.  Yet:

c:\cygwin\bin>dumpbin /headers cygreadline7.dll | more
<snip>
            8040 DLL characteristics
                   Dynamic base
                   Terminal Server Aware

Notice the "Dynamic base" flag set.

-----Original Message-----
Sent: Friday, April 20, 2012 20:50
Subject: Re: Two probable basing issues causing fork failures: (1)
cygreadline7.dll has ASLR enabled, (2) default base address conflicts with
ASLR-relocated/system DLLs

On Fri, Apr 20, 2012 at 05:44:38PM -0000, James Johnston wrote:
>[snip]
>...  Today this issue came
>to a head on one installation of Cygwin 1.7.9,...
>[snip]
>Thoughts, anyone?

Yep.  Update your Cygwin installation.  You're four revisions out of date.

It should come not too great a surprise that we've had extensive discussions
about this issue and have made some changes in recent releases.

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019