This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Compile glibc with -fstack-protector (was Re: [BZ #7064] Put vm86 into libc.a)


On 21 Apr 2012, Andreas Jaeger spake thusly:

> There's a patch set attached to http://sourceware.org/bugzilla/show_bug.cgi?id=7065

Sorry, I should have given the bug number, only I'd forgotten it myself
and was having self-inflicted network problems severe enough that glibc
bugzilla was inaccessible...

> Your change contains two different changes:
> * Supporting stack-protector
> * A different implementation of chk_fail function
>
> I would only add the first one - and looking at the patch, it looks straight forward.

Agreed. The second one could be added easily enough if you wanted it,
but the two parts are separable without effort. (I should have separated
them already.)

> The question to the rest of the maintainers: Do we want this? Please
> read the bug for details,

I was somewhat concerned when I wrote it in 2008 that it might add too
much maintenance overhead even to suppress the stack protector in all of
ld.so (because you have to track things which are included in ld.so but
are not built via the recursive rtld-routines trickery in elf/Makefile,
and add -fno-stack-protector to them). It turns out that this overhead
is essentially nil: this set has never changed since I wrote the patch
(and in fact I've spent less than half an hour bringing the patch up to
date for all versions of glibc I've used from 2.9 up to 2.13). So added
maintenance overhead, at least, is not worth being concerned about.
Added complexity may be, but there's not much of that.

(An ideal patch would keep the stack protector on in most of ld.so as
well as in the rest of glibc, rather than turning it off in ld.so
wholesale, but it didn't seem worth exploring when even the simpler
apporach had been rejected.)

-- 
NULL && (void)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]