[tor-bugs] #3370 [Tor Client]: Race condition - file system access in Tor

Tor Bug Tracker & Wiki torproject-admin at torproject.org
Thu Jun 9 14:19:40 UTC 2011


#3370: Race condition - file system access in Tor
------------------------+---------------------------------------------------
 Reporter:  runa        |          Owner:                    
     Type:  defect      |         Status:  new               
 Priority:  normal      |      Milestone:                    
Component:  Tor Client  |        Version:  Tor: 0.2.2.27-beta
 Keywords:              |         Parent:                    
   Points:              |   Actualpoints:                    
------------------------+---------------------------------------------------
 I have scanned tor-0.2.2.27-beta with Fortify, which picked up a few
 issues in the "Race Condition: File System Access" category. I believe we
 have discussed these types of issues before, but I couldn't find a bug
 where they were all listed.

 config.c:4723 - regarding the window of time between the call to
 read_file_to_str() and rename().

 config.c:5124 - regarding the window of time between the call to
 read_file_to_str() and or_state_save_broken().

 config.c:5138 - regarding the window of time between the call to
 read_file_to_str() and or_state_save_broken().

 routerlist.c:835 - regarding the window of time between the call to
 tor_mmap_file() and remove_file_if_very_old().

 I don't think we need to worry too much about these issues, but maybe we
 should be sure to check the files before we read/write/execute/move?

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


More information about the tor-bugs mailing list