X-Recipient: archive-cygwin@delorie.com
X-Spam-Check-By: sourceware.org
Date: Mon, 23 Apr 2012 17:02:16 +0200
From: Corinna Vinschen <corinna-cygwin@cygwin.com>
To: cygwin@cygwin.com
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
Message-ID: <20120423150216.GI7097@calimero.vinschen.de>
Reply-To: cygwin@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
References: <00f201cd1f1d$43430230$c9c90690$@motionview3d.com> <20120420205019.GA25994@ednor.casa.cgf.cx> <012001cd215c$b521ee20$1f65ca60$@motionview3d.com> <20120423145106.GH7097@calimero.vinschen.de> <4F956D30.7010801@redhat.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <4F956D30.7010801@redhat.com>
User-Agent: Mutt/1.5.21 (2010-09-15)
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
Precedence: bulk
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie.com@cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com

On Apr 23 08:54, Eric Blake wrote:
> On 04/23/2012 08:51 AM, Corinna Vinschen wrote:
> >> 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.
> > 
> > Yes, it is a problem in the first place if DLLs have the dynamicbase
> > flag set, because, obviously, it undermines what rebaseall is doing.
> > It's not a problem if the new address it gets rebased to doesn't collide
> > with any other used DLL since ASLR on Windows only shuffles ASLR-enabled
> > DLL addresses when a DLL is loaded by an application for the first time.
> > Afterwards, it will use the new address for that DLL until reboot.
> > So, yes, we should make sure that the ASLR flag is not used for Cygwin
> > DLLs.
> > 
> > Eric, could you create a new package which avoids setting the
> > dynamicbase flag for cygreadline and cyghistory?
> 
> At the time I created the current cygreadline package, cygwin didn't
> have quite as good support for running rebaseall; since things have
> improved on that front, I will see about getting a new release of the
> readline package this week that disables the ASLR hack I had added way
> back when.

Thanks!


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader          cygwin AT cygwin DOT com
Red Hat

--
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

