[tor-bugs] #3289 [Tor Hidden Services]: Tor does not complain if the user specifies two HSes with the same HiddenServiceDir

Tor Bug Tracker & Wiki torproject-admin at torproject.org
Sun May 29 02:08:01 UTC 2011


#3289: Tor does not complain if the user specifies two HSes with the same
HiddenServiceDir
---------------------------------+------------------------------------------
 Reporter:  rransom              |          Owner:  rransom           
     Type:  defect               |         Status:  needs_review      
 Priority:  normal               |      Milestone:  Tor: 0.2.2.x-final
Component:  Tor Hidden Services  |        Version:                    
 Keywords:                       |         Parent:                    
   Points:                       |   Actualpoints:                    
---------------------------------+------------------------------------------

Comment(by nickm):

 I'm okay leaving this as O(n^2) in 0.2.2.x, but having every FS be case-
 insensitive everywhere seems questionable to me.  Even the operating
 systems with case-insensitive file-systems have only some of their file-
 systems case-insensitive.

 To see whether two directories are equal ... hooboy.

 On unixy systems, it's not too hard.  Try to stat them.   If they have
 st_dev and st_ino fields equal, then they are equal.

 On windows, we can use use GetFileInformationByHandle, and see whether
 dwVolumeSerialNumber, nFileIndexHigh, and nFileIndexLow are equal.

 Hm.  I'm tempted to just say, "Let's check with strcmp() alone, and deal
 with this stuff through real locking later on."

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


More information about the tor-bugs mailing list