[tor-bugs] #2031 [Tor Client]: gcc warning : not protecting function: no buffer at least 8 bytes long

Tor Bug Tracker & Wiki torproject-admin at torproject.org
Sat Oct 9 19:19:26 UTC 2010


#2031: gcc warning : not protecting function: no buffer at least 8 bytes long
-----------------+----------------------------------------------------------
 Reporter:  keb  |        Type:  defect                                   
   Status:  new  |    Priority:  normal                                   
Milestone:       |   Component:  Tor Client                               
  Version:       |    Keywords:  debian --gcc-hardening --linker-hardening
   Parent:       |  
-----------------+----------------------------------------------------------

Comment(by Sebastian):

 Well, we're using

 {{{
   if test x$have_gcc42 = xyes ; then?
     # These warnings break gcc 4.0.2 and work on gcc 4.2
     # XXXX020 Use -fstack-protector.
     # XXXX020 See if any of these work with earlier versions.
     CFLAGS="$CFLAGS -Waddress -Wmissing-noreturn -Wnormalized=id
 -Woverride-init -Wstrict-overflow=1 --param ssp-buffer-size=1"
     # We used to use -Wstrict-overflow=5, but that breaks us heavily under
 4.3.
   fi
 }}}

 Looks like we need to carefully evaluate which options to use depending on
 the compiler's version.

-- 
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/2031#comment:3>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list