[IRCServices] Segfault again.

Andrew Church achurch at achurch.org
Fri Apr 9 14:18:30 PDT 2004


>-----BEGIN PGP SIGNED MESSAGE-----
>Hash: SHA1
>
>Andrew Church wrote:
>| I can't find any reference to a -fstack-protector option in the GCC
>| documentation.  Are you using an unofficial build?  If so, your GCC could
>| be broken.  If you can send me your executable file and core, I'll try to
>| look into the problem as time permits.
>
>I am not the one controling this part at our server, so I don't know so
>much about it. As far as I know it's an extantion to gcc, see [0], and
>are used to protect agains stack overflows. The other admins just said
>that I should use -fstack-protector while compiling IRCd and services,
>and so I did. I think this was why I got seg fraults using .27 before too.
[...]
>[0] http://www.trl.ibm.com/projects/security/ssp/

     I finally got around to looking at this, and it turns out that this
stack-protector extension has a bug which generates incorrect code for
certain cases, and Services triggers this bug.  I've sent a report to the
author of the patch; for the meantime, don't use -fstack-protector when
compiling Services.  (I'll put in a configure check in the next release to
ensure that it's not used.)

  --Andrew Church
    achurch at achurch.org
    http://achurch.org/