[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [tor-bugs] #8308 [Tor]: Use smartlist-of-strings rather than preallocated-charbuf for more directory stuff



#8308: Use smartlist-of-strings rather than preallocated-charbuf for more
directory stuff
--------------------------------+-------------------------------------------
 Reporter:  nickm               |          Owner:                    
     Type:  defect              |         Status:  needs_review      
 Priority:  normal              |      Milestone:  Tor: 0.2.4.x-final
Component:  Tor                 |        Version:                    
 Keywords:  tor-auth tor-relay  |         Parent:                    
   Points:                      |   Actualpoints:                    
--------------------------------+-------------------------------------------

Comment(by andrea):

 Begin code review:
  * 9f044eac77ee2245de71283e71361346ee194f25 looks good to me
  * 72150e6a6d36e1537796cbf279c87b3e6079290e looks good
  * 1859de1cd3b6b5c6737cc36a291eac68f72f5b96 looks good
  * 0607c06ddd8ac3c39148fa58f0b00a5bbeb200a9 looks good
  * b293284110375e1567be7f20a2a0ab1db9c3b35a looks good; the factor of 2
 for base64 seems quite extreme and I believe 1.4 would suffice, but memory
 is abundant and the overallocation is temporary.
  * 185d93d1895f1ace9cde96022b8558faec3b82f7 looks good
  * 14e2fa9801abf18d132c4d6f96f83a4347133420 looks good
  * df49a2a7a77cea7b196879f4641109651906904d looks good
  * e5d828f524b7a729faf1bb20c182ce81a6ba2823 looks good

 I concur with nickm that continue rather than goto err is the right thing.
 One potential issue comes to mind: this removes limits on the length of
 serialized entities RS_ENTRY_LEN and replaces them with 'however much
 tor_asprintf()/smartlist_join() can allocate'; are we quite certain this
 could not be used for a DoS?

 In light of the amount of critical code this touches, it should receive
 intensive testing before being merged.

-- 
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/8308#comment:4>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
_______________________________________________
tor-bugs mailing list
tor-bugs@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs