[tor-bugs] #17983 [Tor]: Build tor with -ftrapv by default (was: Build tor with -fwrapv by default)

Tor Bug Tracker & Wiki blackhole at torproject.org
Wed Feb 10 12:21:26 UTC 2016


#17983: Build tor with -ftrapv by default
-------------------------+------------------------------------
 Reporter:  teor         |          Owner:  nickm
     Type:  enhancement  |         Status:  accepted
 Priority:  Medium       |      Milestone:  Tor: 0.2.8.x-final
Component:  Tor          |        Version:
 Severity:  Normal       |     Resolution:
 Keywords:               |  Actual Points:
Parent ID:               |         Points:
  Sponsor:               |
-------------------------+------------------------------------

Old description:

> If the CFLAGS passed to tor don't contain -ftrapv (or the undefined
> behaviour sanitiser), let's build with -fwrapv.
>
> This resolves #13538 non-intrusively, and prevents an entire class of
> integer safety bugs. (That said, wrapping can hide some issues rather
> than resolving them.)

New description:

 If the CFLAGS passed to tor don't contain -ftrapv (or the undefined
 behaviour sanitiser), let's build with -ftrapv.

 This resolves #13538 non-intrusively, and prevents an entire class of
 integer safety bugs. (That said, wrapping can hide some issues rather than
 resolving them.)

--

Comment (by teor):

 Replying to [comment:14 cypherpunks]:
 > This ticket is a bad idea, ftrapv should be used:
 > https://trac.torproject.org/projects/tor/ticket/18296

 Yes, we've worked that out already. Please read comments 6 onwards.

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


More information about the tor-bugs mailing list