summaryrefslogtreecommitdiffstats
path: root/libc/sysdeps/linux/common/ssp.c
Commit message (Collapse)AuthorAgeFilesLines
* guard *_chk() related stuff with UCLIBC_HAS_FORTIFYPeter S. Mazinger2011-03-091-1/+5
| | | | | | | | | | | | Guard x86_64 memset_chk/memcpy_chk be guarded by UCLIBC_HAS_FORTIFY. Compile ssp.c if one of SSP/FORTIFY is defined. Guard __chk_fail() with UCLIBC_HAS_FORTIFY and move its prototype to libc-internal.h. Disable _FORTIFY_SOURCE if UCLIBC_HAS_FORTIFY is not set. The config option itself is omitted on purpose, headers need to be reviewed and generic *_chk() functions need to be first provided. Signed-off-by: Peter S. Mazinger <ps.m@gmx.net>
* Correct ssp codePeter S. Mazinger2011-03-031-1/+2
| | | | | | | | Avoid using strong_alias in ssp, some archs dislike it. Make stack_chk_guard static. Export __stack_smash_handler only if compatibility option is enabled. Signed-off-by: Peter S. Mazinger <ps.m@gmx.net>
* x86_64: fix multiple definition of chk functionsAustin Foxley2009-12-191-2/+1
| | | | | | also enable __chk_fail and only try to call it when SSP is on Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
* trim Experimentally off and uncommented hiddenBernhard Reutner-Fischer2009-09-181-11/+0
| | | | | | | | sed -i -e '/Experimentally off - /d' $(grep -rl "Experimentally off - " *) sed -i -e '/^\/\*[[:space:]]*libc_hidden_proto(/d' $(grep -rl "libc_hidden_proto" *) should be a nop Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
* - workaround oddity with position of function attributesBernhard Reutner-Fischer2009-02-131-1/+1
|
* on Bernd's request, remove commented-out code snippetsDenis Vlasenko2008-12-011-1/+0
|
* remove checks for "impossible" errors,Denis Vlasenko2008-12-011-2/+1
| | | | | | | | | | | | | | | | clarify uses of unoptimized sigXXX ops (they check signo), use faster sigops where approproate. text data bss dec hex filename - 68 0 0 68 44 libc/signal/sighold.o + 63 0 0 63 3f libc/signal/sighold.o - 114 0 0 114 72 libc/signal/sigintr.o + 110 0 0 110 6e libc/signal/sigintr.o - 113 0 0 113 71 libc/signal/sigpause.o + 108 0 0 108 6c libc/signal/sigpause.o - 68 0 0 68 44 libc/signal/sigrelse.o + 63 0 0 63 3f libc/signal/sigrelse.o
* optimize signal mask ops. comment out "impossible" errorsDenis Vlasenko2008-12-011-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | text data bss dec hex filename - 1179 13 2 1194 4aa libc/misc/syslog/syslog.o + 1165 13 2 1180 49c libc/misc/syslog/syslog.o - 435 4 0 439 1b7 libc/pwd_grp/lckpwdf.o + 393 4 0 397 18d libc/pwd_grp/lckpwdf.o - 38 0 0 38 26 libc/signal/sigandset.o + 32 0 0 32 20 libc/signal/sigandset.o - 63 0 0 63 3f libc/signal/sigblock.o + 56 0 0 56 38 libc/signal/sigblock.o - 22 0 0 22 16 libc/signal/sigempty.o + 20 0 0 20 14 libc/signal/sigempty.o - 25 0 0 25 19 libc/signal/sigfillset.o + 20 0 0 20 14 libc/signal/sigfillset.o - 34 0 0 34 22 libc/signal/sigisempty.o + 16 0 0 16 10 libc/signal/sigisempty.o - 38 0 0 38 26 libc/signal/sigorset.o + 32 0 0 32 20 libc/signal/sigorset.o - 119 0 0 119 77 libc/signal/sigpause.o + 113 0 0 113 71 libc/signal/sigpause.o - 215 0 0 215 d7 libc/signal/sigset.o + 211 0 0 211 d3 libc/signal/sigset.o - 63 0 0 63 3f libc/signal/sigsetmask.o + 56 0 0 56 38 libc/signal/sigsetmask.o - 194 0 1 195 c3 libc/stdlib/abort.o + 183 0 1 184 b8 libc/stdlib/abort.o - 323 0 0 323 143 libc/unistd/sleep.o + 309 0 0 309 135 libc/unistd/sleep.o
* shring sugnal-relared stuff a bit. BTW why constant memset is not inlined by ↵Denis Vlasenko2008-11-291-3/+4
| | | | | | | | | | | gcc? text data bss dec hex filename - 38015 18096 8636 64747 fceb lib/libpthread-0.9.30-svn.so + 38001 18096 8636 64733 fcdd lib/libpthread-0.9.30-svn.so - 274842 1835 19012 295689 48309 lib/libuClibc-0.9.30-svn.so + 274779 1835 19012 295626 482ca lib/libuClibc-0.9.30-svn.so
* Last portion of libc_hidden_proto removal.Denis Vlasenko2008-11-201-6/+6
| | | | | Appears to build fine (several .configs tried)
* next portion of libc_hidden_proto removalDenis Vlasenko2008-11-201-5/+5
|
* - add __hot and __cold annotationsBernhard Reutner-Fischer2008-11-181-3/+3
| | | | | Will spare us quite some likely()/unlikely() occurances. See http://gcc.gnu.org/onlinedocs/gcc/Function-Attributes.html for details
* - honour UCLIBC_HAS_SYSLOGBernhard Reutner-Fischer2008-09-291-5/+8
|
* Moving libc_hidden_proto's into #ifdef UCLIBC_INTERNAL blockDenis Vlasenko2008-05-191-2/+2
| | | | | | | | | in string.h and strings.h. This caught unguarded string ops in libc/inet/ethers.c __ether_line_w() function. I will wait for fallout reports for a week or so, then continue converting more libc_hidden_proto's.
* Get rid of missing prototype warningsPeter S. Mazinger2006-01-261-4/+6
|
* hidden_def/hidden_proto: convert all users (I hope) termios split, add some ↵Peter S. Mazinger2006-01-141-16/+22
| | | | missing headers, other jump relocs removed
* Hope I have it correct now w/ native gcc4 sspPeter S. Mazinger2006-01-091-2/+1
|
* one reloc less, uninline, should save some spacePeter S. Mazinger2006-01-041-4/+5
|
* tweak __progname handling some more since some [bad] apps actually try and ↵Mike Frysinger2006-01-041-6/+3
| | | | use it
* Convert some usersPeter S. Mazinger2005-12-161-1/+1
|
* Try to mimic glibc sigaction, sjhill, could you please test w/ this version?Peter S. Mazinger2005-12-081-1/+1
|
* Correct use of __*logPeter S. Mazinger2005-12-081-3/+3
|
* More hiding, including __mempcpyPeter S. Mazinger2005-12-031-9/+26
|
* Hide mostly used functionsPeter S. Mazinger2005-12-011-6/+6
|
* Make use of newly introduced attribute_noreturnPeter S. Mazinger2005-11-041-4/+4
|
* Moved guard_setup to dl-osinfo.h (used commonly by ldso and libc). Renamed ↵Peter S. Mazinger2005-10-271-0/+2
| | | | to _dl_setup_stack_chk_guard, as in glibc. SSP requires now binutils-2.16.1 and newer. Add NOT_IN_libc/IS_IN_libc. Began using -DSHARED in uClibc_main.c, there are more candidates in there. Move back dl_protect_relro to it's earlier place.
* Add gcc-4.1 non-TLS __stack_chk_guard support. Run the guard setup only once.Peter S. Mazinger2005-10-011-1/+32
|
* Changed ssp.c license to LGPL and added vapier as contributorPeter S. Mazinger2005-09-231-8/+4
|
* New ssp code using syscalls where possible.Peter S. Mazinger2005-09-231-103/+34
| | | | | Moved guard_setup to __uClibc_main.c, the only place where it is called. Removed SIGKILL option, not usable with sigaction.
* move tv def back with gettimeofday() funcMike Frysinger2005-06-071-4/+5
|
* touchup defines so that we can use same ssp.c in both glibc and uclibcMike Frysinger2005-05-271-16/+28
|
* - keep gcc-4.x happyNed Ludd2005-05-271-1/+5
|
* style updatesMike Frysinger2005-05-271-9/+9
|
* - added externs to keep gcc quiet about implicit declaration of 3 functionsNed Ludd2005-03-121-0/+5
|
* - 2/NN patches for ssp. Updates from Peter S. Mazinger and Robert ConnollyNed Ludd2005-02-081-10/+9
|
* - 1/NN patches for sspNed Ludd2005-02-081-6/+7
|
* dont bother including sysctl.h unless we need itMike Frysinger2005-01-111-1/+3
|
* update : $Ned Ludd2004-11-251-1/+1
|
* misc cleanups of __stack_smash_handler() function when ssp support is ↵Ned Ludd2004-11-111-2/+2
| | | | enabled. syslog() support should now work both inside and outside of chroots. erandom code left in but remains #ifdef out by default. May remove erandom completely in the future for uClibc unless the LFS guys and gals want to keep it.
* misc cleanups of __stack_smash_handler() function when ssp support is ↵Ned Ludd2004-11-111-76/+100
| | | | enabled. syslog() support should now work both inside and outside of chroots. erandom code left in but remains #ifdef out by default. May remove erandom completely in the future for uClibc unless the LFS guys and gals want to keep it.
* Split up syscalls.c, since it had grown to be quite large and ugly.Eric Andersen2004-01-211-2/+2
| | | | -Erik
* Peter S. Mazinger writes:Eric Andersen2004-01-021-0/+97
Hello Erik! I have made some cosmetical changes to the files, removed the added SCRT=-fPIC option from building the crt0.S file (but it is a requirement to build them with -fPIC), and changed some comments. I have left the ldso.c patch with PIE_SUPPORT ifdefs, but consider applying it w/o them (see some earlier comment from PaX Team on this issue, as it is considered a bug). To have it work correctly, you'll also need removing COMPLETELY_PIC. One thing is missing: PIE_SUPPORT should be usable only for i386 (for now). Also added the support for propolice protection (that works for me and catches memcpy/strcpy attacks (but needs a special gcc version). Thanks, Peter