[tor-bugs] #4662 [Tor Relay]: Revert changes from bug4312 and thereafter until 0.2.4.x

Tor Bug Tracker & Wiki torproject-admin at torproject.org
Wed Dec 7 00:59:29 UTC 2011


#4662: Revert changes from bug4312 and thereafter until 0.2.4.x
-----------------------+----------------------------------------------------
 Reporter:  nickm      |          Owner:                    
     Type:  defect     |         Status:  needs_review      
 Priority:  normal     |      Milestone:  Tor: 0.2.3.x-final
Component:  Tor Relay  |        Version:                    
 Keywords:             |         Parent:                    
   Points:             |   Actualpoints:                    
-----------------------+----------------------------------------------------
Changes (by nickm):

  * status:  new => needs_review


Comment:

 Here's how I made the branches.  To find commits which should maybe be
 reverted, I looked for things that changed tortls.c, connection_or.c, or
 compat_libevent.ch:
 {{{
 [528]$ git log --no-merges --reverse --format='%h %s'
 tor-0.2.3.8-alpha..master src/common/tortls.c src/or/connection_or.c
 src/common/compat_libevent.[ch] > revertable
 [529]$ cp revertable revert
 [530]$ vim revert
 }}}

 I then edited the file "revert" to have only the commits that we wanted to
 remove.  Those are:
 {{{
 69a821e Refactor the SSL_set_info_callback() callbacks.
 4fd79f9 Detect renegotiation when it actually happens.
 ecd239e Detect and deny excess renegotiations attempts.
 340809d Get rid of tor_tls_block_renegotiation().
 e2b3527 Also handle needless renegotiations in SSL_write().
 e097bff Fix issues pointed out by nickm.
 406ae1b Use callback-driven approach to block renegotiations.
 f77f9bd appease check-spaces
 7920ea5 Refactor tor_event_base_once to do what we actually want
 633071e Avoid a double-mark in connection_or_close_connection_cb
 e8dde3a Fix some wide lines in tortls.c
 9a88c0c use event_free() wrapper; fix bug 4582
 617617e Don't schedule excess_renegotiations_callback unless it's set
 40a87c4 indent; add comment
 aba25a6 Make pending libevent actions cancelable
 e27a26d Set renegotiation callbacks immediately on tls inititation
 }}}

 Note that we are *NOT* reverting the following commits even though they
 affect those files:
 {{{
 b42ff65 Use random bytes as our certificate serial numbers.
 7b02d1a Clarify function documentation.
 f89c619 Use the preferred address and port when initiating a connection.
 529820f Use correct address family where necessary for bridges on IPv6.
 2376a6a Merge node_get_{prim,pref,pref_ipv6}_addr with their _orport
 counterparts.
 682a85f Don't just tell the controller "foo" on id mismatch
 }}}

 I then created the set of reverts automatically using:
 {{{
 % git checkout master
 % git checkout -b revert_4312
 % git revert --no-edit `cut -f 1  -d ' ' revert`
 }}}

 I then made a new set of commits to reapply the old changes using:
 {{{
 % git checkout -b reapply_4312
 % git cherry-pick --no-edit `cut -f 1  -d ' ' revert`
 }}}

 So if I missed anything, let me know: it'll be easy to regenerate two new
 branches that have the right set of commits.

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


More information about the tor-bugs mailing list