tor-design.tex 99 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982
  1. % XXX Cite SS03
  2. \documentclass[times,10pt,twocolumn]{article}
  3. \usepackage{latex8}
  4. \usepackage{times}
  5. \usepackage{url}
  6. \usepackage{graphics}
  7. \usepackage{amsmath}
  8. \pagestyle{plain}
  9. \renewcommand\url{\begingroup \def\UrlLeft{<}\def\UrlRight{>}\urlstyle{tt}\Url}
  10. \newcommand\emailaddr{\begingroup \def\UrlLeft{<}\def\UrlRight{>}\urlstyle{tt}\Url}
  11. \newcommand{\workingnote}[1]{} % The version that hides the note.
  12. %\newcommand{\workingnote}[1]{(**#1)} % The version that makes the note visible.
  13. % If an URL ends up with '%'s in it, that's because the line *in the .bib/.tex
  14. % file* is too long, so break it there (it doesn't matter if the next line is
  15. % indented with spaces). -DH
  16. %\newif\ifpdf
  17. %\ifx\pdfoutput\undefined
  18. % \pdffalse
  19. %\else
  20. % \pdfoutput=1
  21. % \pdftrue
  22. %\fi
  23. \newenvironment{tightlist}{\begin{list}{$\bullet$}{
  24. \setlength{\itemsep}{0mm}
  25. \setlength{\parsep}{0mm}
  26. % \setlength{\labelsep}{0mm}
  27. % \setlength{\labelwidth}{0mm}
  28. % \setlength{\topsep}{0mm}
  29. }}{\end{list}}
  30. \begin{document}
  31. %% Use dvipdfm instead. --DH
  32. %\ifpdf
  33. % \pdfcompresslevel=9
  34. % \pdfpagewidth=\the\paperwidth
  35. % \pdfpageheight=\the\paperheight
  36. %\fi
  37. \title{Tor: The Second-Generation Onion Router\\DRAFT VERSION}
  38. % Putting the 'Private' back in 'Virtual Private Network'
  39. \author{Roger Dingledine \\ The Free Haven Project \\ arma@freehaven.net \and
  40. Nick Mathewson \\ The Free Haven Project \\ nickm@freehaven.net \and
  41. Paul Syverson \\ Naval Research Lab \\ syverson@itd.nrl.navy.mil}
  42. \maketitle
  43. \thispagestyle{empty}
  44. \begin{abstract}
  45. We present Tor, a circuit-based low-latency anonymous communication
  46. service. This second-generation Onion Routing system addresses limitations
  47. in the original design. Tor adds perfect forward secrecy, congestion
  48. control, directory servers, integrity checking, configurable exit policies,
  49. and a practical design for rendezvous points. Tor works on the real-world
  50. Internet, requires no special privileges or kernel modifications, requires
  51. little synchronization or coordination between nodes, and provides a
  52. reasonable tradeoff between anonymity, usability, and efficiency.
  53. We briefly describe our experiences with an international network of
  54. more than a dozen hosts. % that has been running for several months.
  55. We close with a list of open problems in anonymous communication.
  56. \end{abstract}
  57. %\begin{center}
  58. %\textbf{Keywords:} anonymity, peer-to-peer, remailer, nymserver, reply block
  59. %\end{center}
  60. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  61. \Section{Overview}
  62. \label{sec:intro}
  63. Onion Routing is a distributed overlay network designed to anonymize
  64. TCP-based applications like web browsing, secure shell,
  65. and instant messaging. Clients choose a path through the network and
  66. build a \emph{circuit}, in which each node (or ``onion router'' or ``OR'')
  67. in the path knows its predecessor and successor, but no other nodes in
  68. the circuit. Traffic flows down the circuit in fixed-size
  69. \emph{cells}, which are unwrapped by a symmetric key at each node
  70. (like the layers of an onion) and relayed downstream. The
  71. Onion Routing project published several design and analysis
  72. papers \cite{or-ih96,or-jsac98,or-discex00,or-pet00}. While a wide area Onion
  73. Routing network was deployed briefly, the only long-running
  74. public implementation was a fragile
  75. proof-of-concept that ran on a single machine. Even this simple deployment
  76. processed connections from over sixty thousand distinct IP addresses from
  77. all over the world at a rate of about fifty thousand per day.
  78. But many critical design and deployment issues were never
  79. resolved, and the design has not been updated in several years. Here
  80. we describe Tor, a protocol for asynchronous, loosely federated onion
  81. routers that provides the following improvements over the old Onion
  82. Routing design:
  83. \textbf{Perfect forward secrecy:} Onion Routing
  84. was originally vulnerable to a single hostile node recording traffic and
  85. later compromising successive nodes in the circuit and forcing them
  86. to decrypt it. Rather than using a single multiply encrypted data
  87. structure (an \emph{onion}) to lay each circuit,
  88. Tor now uses an incremental or \emph{telescoping} path-building design,
  89. where the initiator negotiates session keys with each successive hop in
  90. the circuit. Once these keys are deleted, subsequently compromised nodes
  91. cannot decrypt old traffic. As a side benefit, onion replay detection
  92. is no longer necessary, and the process of building circuits is more
  93. reliable, since the initiator knows when a hop fails and can then try
  94. extending to a new node.
  95. \textbf{Separation of ``protocol cleaning'' from anonymity:}
  96. Onion Routing originally required a separate ``application
  97. proxy'' for each supported application protocol---most of which were
  98. never written, so many applications were never supported. Tor uses the
  99. standard and near-ubiquitous SOCKS~\cite{socks4} proxy interface, allowing
  100. us to support most TCP-based programs without modification. Tor now
  101. relies on the filtering features of privacy-enhancing
  102. application-level proxies such as Privoxy~\cite{privoxy}, without trying
  103. to duplicate those features itself.
  104. \textbf{No mixing, padding, or traffic shaping (yet):} Onion
  105. Routing originally called for batching and reordering cells as they arrived,
  106. assumed padding between ORs, and in
  107. later designs added padding between onion proxies (users) and
  108. ORs~\cite{or-ih96,or-jsac98}. Tradeoffs between padding protection
  109. and cost were discussed, and \emph{traffic shaping} algorithms were
  110. theorized~\cite{or-pet00} to provide good security without expensive
  111. padding, but no concrete padding scheme was suggested.
  112. Recent research~\cite{econymics}
  113. and deployment experience~\cite{freedom21-security} suggest that this
  114. level of resource use is not practical or economical; and even full
  115. link padding is still vulnerable~\cite{defensive-dropping}. Thus,
  116. until we have a proven and convenient design for traffic shaping or
  117. low-latency mixing that improves anonymity against a realistic
  118. adversary, we leave these strategies out.
  119. \textbf{Many TCP streams can share one circuit:} Onion Routing originally
  120. built a separate circuit for each
  121. application-level request, but this required
  122. multiple public key operations for every request, and also presented
  123. a threat to anonymity from building so many circuits; see
  124. Section~\ref{sec:maintaining-anonymity}. Tor multiplexes multiple TCP
  125. streams along each circuit to improve efficiency and anonymity.
  126. \textbf{Leaky-pipe circuit topology:} Through in-band signaling
  127. within the circuit, Tor initiators can direct traffic to nodes partway
  128. down the circuit. This novel approach
  129. allows traffic to exit the circuit from the middle---possibly
  130. frustrating traffic shape and volume attacks based on observing the end
  131. of the circuit. (It also allows for long-range padding if
  132. future research shows this to be worthwhile.)
  133. \textbf{Congestion control:} Earlier anonymity designs do not
  134. address traffic bottlenecks. Unfortunately, typical approaches to
  135. load balancing and flow control in overlay networks involve inter-node
  136. control communication and global views of traffic. Tor's decentralized
  137. congestion control uses end-to-end acks to maintain anonymity
  138. while allowing nodes at the edges of the network to detect congestion
  139. or flooding and send less data until the congestion subsides.
  140. \textbf{Directory servers:} The earlier Onion Routing design
  141. planned to flood state information through the network---an approach
  142. that can be unreliable and complex. % open to partitioning attacks.
  143. Tor takes a simplified view toward distributing this
  144. information. Certain more trusted nodes act as \emph{directory
  145. servers}: they provide signed directories describing known
  146. routers and their current state. Users periodically download these
  147. directories via HTTP.
  148. \textbf{Variable exit policies:} Tor provides a consistent mechanism
  149. for each node to advertise a policy describing the hosts
  150. and ports to which it will connect. These exit policies are critical
  151. in a volunteer-based distributed infrastructure, because each operator
  152. is comfortable with allowing different types of traffic to exit the Tor
  153. network from his node.
  154. \textbf{End-to-end integrity checking:} The original Onion Routing
  155. design did no integrity checking on data. Any node on the
  156. circuit could change the contents of data cells as they passed by---for
  157. example, to alter a connection request so it would connect
  158. to a different webserver, or to `tag' encrypted traffic and look for
  159. corresponding corrupted traffic at the network edges~\cite{minion-design}.
  160. Tor hampers these attacks by verifying data integrity before it leaves
  161. the network.
  162. %\textbf{Improved robustness to failed nodes:} A failed node
  163. %in the old design meant that circuit building failed, but thanks to
  164. %Tor's step-by-step circuit building, users notice failed nodes
  165. %while building circuits and route around them. Additionally, liveness
  166. %information from directories allows users to avoid unreliable nodes in
  167. %the first place.
  168. %% Can't really claim this, now that we've found so many variants of
  169. %% attack on partial-circuit-building. -RD
  170. \textbf{Rendezvous points and hidden services:}
  171. Tor provides an integrated mechanism for responder anonymity via
  172. location-protected servers. Previous Onion Routing designs included
  173. long-lived ``reply onions'' that could be used to build circuits
  174. to a hidden server, but these reply onions did not provide forward
  175. security, and became useless if any node in the path went down
  176. or rotated its keys. In Tor, clients negotiate {\it rendezvous points}
  177. to connect with hidden servers; reply onions are no longer required.
  178. Unlike Freedom~\cite{freedom2-arch}, Tor does not anonymize
  179. non-TCP protocols---not requiring patches (or built-in support) in an
  180. operating system's network stack has been valuable to Tor's
  181. portability and deployability.
  182. We have implemented all of the above features except rendezvous
  183. points. Our source code is
  184. available under a free license, and Tor
  185. %, as far as we know, is unencumbered by patents.
  186. is not covered by the patent that affected distribution and use of
  187. earlier versions of Onion Routing.
  188. We have deployed a wide-area alpha network
  189. to test the design, to get more experience with usability
  190. and users, and to provide a research platform for experimentation.
  191. As of this writing, the network stands at sixteen nodes in thirteen
  192. distinct administrative domains on two continents.
  193. We review previous work in Section~\ref{sec:related-work}, describe
  194. our goals and assumptions in Section~\ref{sec:assumptions},
  195. and then address the above list of improvements in
  196. Sections~\ref{sec:design} and~\ref{sec:other-design}. We summarize
  197. in Section~\ref{sec:attacks} how our design stands up to
  198. known attacks, and talk about our early deployment experiences in
  199. Section~\ref{sec:in-the-wild}. We conclude with a list of open problems in
  200. Section~\ref{sec:maintaining-anonymity} and future work for the Onion
  201. Routing project in Section~\ref{sec:conclusion}.
  202. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  203. \Section{Related work}
  204. \label{sec:related-work}
  205. Modern anonymity systems date to Chaum's {\bf Mix-Net}
  206. design~\cite{chaum-mix}. Chaum
  207. proposed hiding the correspondence between sender and recipient by
  208. wrapping messages in layers of public-key cryptography, and relaying them
  209. through a path composed of ``mixes.'' Each mix in turn
  210. decrypts, delays, and re-orders messages, before relaying them
  211. onward.
  212. %toward their destinations.
  213. Subsequent relay-based anonymity designs have diverged in two
  214. main directions. Systems like {\bf Babel}~\cite{babel},
  215. {\bf Mixmaster}~\cite{mixmaster-spec},
  216. and {\bf Mixminion}~\cite{minion-design} have tried
  217. to maximize anonymity at the cost of introducing comparatively large and
  218. variable latencies. Because of this decision, these \emph{high-latency}
  219. networks resist strong global adversaries,
  220. but introduce too much lag for interactive tasks like web browsing,
  221. Internet chat, or SSH connections.
  222. Tor belongs to the second category: \emph{low-latency} designs that
  223. try to anonymize interactive network traffic. These systems handle
  224. a variety of bidirectional protocols. They also provide more convenient
  225. mail delivery than the high-latency anonymous email
  226. networks, because the remote mail server provides explicit and timely
  227. delivery confirmation. But because these designs typically
  228. involve many packets that must be delivered quickly, it is
  229. difficult for them to prevent an attacker who can eavesdrop both ends of the
  230. communication from correlating the timing and volume
  231. of traffic entering the anonymity network with traffic leaving it. These
  232. protocols are similarly vulnerable to an active adversary who introduces
  233. timing patterns into traffic entering the network and looks
  234. for correlated patterns among exiting traffic.
  235. Although some work has been done to frustrate
  236. these attacks, %\footnote{
  237. % The most common approach is to pad and limit communication to a constant
  238. % rate, or to limit
  239. % the variation in traffic shape. Doing so can have prohibitive bandwidth
  240. % costs and/or performance limitations.
  241. %}
  242. % Point in the footnote is covered above, yes? -PS
  243. most designs protect primarily against traffic analysis rather than traffic
  244. confirmation (see Section~\ref{subsec:threat-model}).
  245. The simplest low-latency designs are single-hop proxies such as the
  246. {\bf Anonymizer}~\cite{anonymizer}: a single trusted server strips the
  247. data's origin before relaying it. These designs are easy to
  248. analyze, but users must trust the anonymizing proxy.
  249. Concentrating the traffic to this single point increases the anonymity set
  250. (the people a given user is hiding among), but it is vulnerable if the
  251. adversary can observe all traffic going into and out of the proxy.
  252. More complex are distributed-trust, circuit-based anonymizing systems.
  253. In these designs, a user establishes one or more medium-term bidirectional
  254. end-to-end circuits, and tunnels data in fixed-size cells.
  255. Establishing circuits is computationally expensive and typically
  256. requires public-key
  257. cryptography, whereas relaying cells is comparatively inexpensive and
  258. typically requires only symmetric encryption.
  259. Because a circuit crosses several servers, and each server only knows
  260. the adjacent servers in the circuit, no single server can link a
  261. user to her communication partners.
  262. The {\bf Java Anon Proxy} (also known as JAP or Web MIXes) uses fixed shared
  263. routes known as \emph{cascades}. As with a single-hop proxy, this
  264. approach aggregates users into larger anonymity sets, but again an
  265. attacker only needs to observe both ends of the cascade to bridge all
  266. the system's traffic. The Java Anon Proxy's design
  267. calls for padding between end users and the head of the
  268. cascade~\cite{web-mix}. However, it is not demonstrated whether the current
  269. implementation's padding policy improves anonymity.
  270. {\bf PipeNet}~\cite{back01, pipenet}, another low-latency design proposed at
  271. about the same time as Onion Routing, provided
  272. stronger anonymity at the cost of allowing a single user to shut
  273. down the network simply by not sending. Systems like {\bf ISDN
  274. mixes}~\cite{isdn-mixes} were designed for other environments with
  275. different assumptions.
  276. %XXX please can we fix this sentence to something less demeaning
  277. In P2P designs like {\bf Tarzan}~\cite{tarzan:ccs02} and
  278. {\bf MorphMix}~\cite{morphmix:fc04}, all participants both generate
  279. traffic and relay traffic for others. These systems aim to conceal
  280. whether a given peer originated a request
  281. or just relayed it from another peer. While Tarzan and MorphMix use
  282. layered encryption as above, {\bf Crowds}~\cite{crowds-tissec} simply assumes
  283. an adversary who cannot observe the initiator: it uses no public-key
  284. encryption, so any node on a circuit can read the circuit's traffic.
  285. {\bf Hordes}~\cite{hordes-jcs} is based on Crowds but also uses multicast
  286. responses to hide the initiator. {\bf Herbivore}~\cite{herbivore} and
  287. $\mbox{\bf P}^{\mathbf 5}$~\cite{p5} go even further, requiring broadcast.
  288. These systems are designed primarily for communication between peers,
  289. although Herbivore users can make external connections by
  290. requesting a peer to serve as a proxy.
  291. Systems like {\bf Freedom} and the original Onion Routing build the circuit
  292. all at once, using a layered ``onion'' of public-key encrypted messages,
  293. each layer of which provides a set of session keys and the address of the
  294. next server in the circuit. Tor as described herein, Tarzan, MorphMix,
  295. {\bf Cebolla}~\cite{cebolla}, and Rennhard's {\bf Anonymity Network}~\cite{anonnet}
  296. build the circuit
  297. in stages, extending it one hop at a time.
  298. Section~\ref{subsubsec:constructing-a-circuit} describes how this
  299. approach makes perfect forward secrecy feasible.
  300. Circuit-based anonymity designs must choose which protocol layer
  301. to anonymize. They may choose to intercept IP packets directly, and
  302. relay them whole (stripping the source address) along the
  303. circuit~\cite{freedom2-arch,tarzan:ccs02}. Alternatively, like
  304. Tor, they may accept TCP streams and relay the data in those streams
  305. along the circuit, ignoring the breakdown of that data into TCP
  306. segments~\cite{morphmix:fc04,anonnet}. Finally, they may accept
  307. application-level protocols (such as HTTP) and relay the application
  308. requests themselves along the circuit.
  309. Making this protocol-layer decision requires a compromise between flexibility
  310. and anonymity. For example, a system that understands HTTP, such as Crowds,
  311. can strip
  312. identifying information from those requests, can take advantage of caching
  313. to limit the number of requests that leave the network, and can batch
  314. or encode those requests to minimize the number of connections.
  315. On the other hand, an IP-level anonymizer can handle nearly any protocol,
  316. even ones unforeseen by its designers (though these systems require
  317. kernel-level modifications to some operating systems, and so are more
  318. complex and less portable). TCP-level anonymity networks like Tor present
  319. a middle approach: they are fairly application neutral (so long as the
  320. application supports, or can be tunneled across, TCP), but by treating
  321. application connections as data streams rather than raw TCP packets,
  322. they avoid the well-known inefficiencies of tunneling TCP over
  323. TCP~\cite{tcp-over-tcp-is-bad}.
  324. Distributed-trust anonymizing systems need to prevent attackers from
  325. adding too many servers and thus compromising user paths.
  326. Tor relies on a small set of well-known directory servers, run by
  327. independent parties, to decide which nodes can
  328. join. Tarzan and MorphMix allow unknown users to run servers, and use
  329. a limited resource (like IP addresses) to prevent an attacker from
  330. controlling too much of the network. Crowds suggests requiring
  331. written, notarized requests from potential crowd members.
  332. Anonymous communication is essential for censorship-resistant
  333. systems like Eternity~\cite{eternity}, Free~Haven~\cite{freehaven-berk},
  334. Publius~\cite{publius}, and Tangler~\cite{tangler}. Tor's rendezvous
  335. points enable connections between mutually anonymous entities; they
  336. are a building block for location-hidden servers, which are needed by
  337. Eternity and Free~Haven.
  338. % didn't include rewebbers. No clear place to put them, so I'll leave
  339. % them out for now. -RD
  340. \Section{Design goals and assumptions}
  341. \label{sec:assumptions}
  342. \noindent{\large\bf Goals}\\
  343. Like other low-latency anonymity designs, Tor seeks to frustrate
  344. attackers from linking communication partners, or from linking
  345. multiple communications to or from a single user. Within this
  346. main goal, however, several considerations have directed
  347. Tor's evolution.
  348. \textbf{Deployability:} The design must be deployed and used in the
  349. real world. Thus it
  350. must not be expensive to run (for example, by requiring more bandwidth
  351. than volunteers are willing to provide); must not place a heavy
  352. liability burden on operators (for example, by allowing attackers to
  353. implicate onion routers in illegal activities); and must not be
  354. difficult or expensive to implement (for example, by requiring kernel
  355. patches, or separate proxies for every protocol). We also cannot
  356. require non-anonymous parties (such as websites)
  357. to run our software. (Our rendezvous point design does not meet
  358. this goal for non-anonymous users talking to hidden servers,
  359. however; see Section~\ref{subsec:rendezvous}.)
  360. \textbf{Usability:} A hard-to-use system has fewer users---and because
  361. anonymity systems hide users among users, a system with fewer users
  362. provides less anonymity. Usability is thus not only a convenience:
  363. it is a security requirement~\cite{econymics,back01}. Tor should
  364. therefore not
  365. require modifying applications; should not introduce prohibitive delays;
  366. and should require users to make as few configuration decisions
  367. as possible. Finally, Tor should be easily implemented on all common
  368. platforms; we cannot require users to change their operating system
  369. to be anonymous. (The current Tor implementation runs on Windows and
  370. assorted Unix clones including Linux, FreeBSD, and MacOS X.)
  371. \textbf{Flexibility:} The protocol must be flexible and well-specified,
  372. so Tor can serve as a test-bed for future research.
  373. Many of the open problems in low-latency anonymity
  374. networks, such as generating dummy traffic or preventing Sybil
  375. attacks~\cite{sybil}, may be solvable independently from the issues
  376. solved by
  377. Tor. Hopefully future systems will not need to reinvent Tor's design.
  378. %(But note that while a flexible design benefits researchers,
  379. %there is a danger that differing choices of extensions will make users
  380. %distinguishable. Experiments should be run on a separate network.)
  381. \textbf{Simple design:} The protocol's design and security
  382. parameters must be well-understood. Additional features impose implementation
  383. and complexity costs; adding unproven techniques to the design threatens
  384. deployability, readability, and ease of security analysis. Tor aims to
  385. deploy a simple and stable system that integrates the best accepted
  386. approaches to protecting anonymity.\\
  387. \noindent{\large\bf Non-goals}\label{subsec:non-goals}\\
  388. In favoring simple, deployable designs, we have explicitly deferred
  389. several possible goals, either because they are solved elsewhere, or because
  390. they are not yet solved.
  391. \textbf{Not peer-to-peer:} Tarzan and MorphMix aim to scale to completely
  392. decentralized peer-to-peer environments with thousands of short-lived
  393. servers, many of which may be controlled by an adversary. This approach
  394. is appealing, but still has many open
  395. problems~\cite{tarzan:ccs02,morphmix:fc04}.
  396. \textbf{Not secure against end-to-end attacks:} Tor does not claim
  397. to provide a definitive solution to end-to-end timing or intersection
  398. attacks. Some approaches, such as having users run their own onion routers,
  399. may help;
  400. see Section~\ref{sec:maintaining-anonymity} for more discussion.
  401. \textbf{No protocol normalization:} Tor does not provide \emph{protocol
  402. normalization} like Privoxy or the Anonymizer. If senders want anonymity from
  403. responders while using complex and variable
  404. protocols like HTTP, Tor must be layered with a filtering proxy such
  405. as Privoxy to hide differences between clients, and expunge protocol
  406. features that leak identity.
  407. Note that by this separation Tor can also provide services that
  408. are anonymous to the network yet authenticated to the responder, like
  409. SSH. Similarly, Tor does not integrate
  410. tunneling for non-stream-based protocols like UDP; this must be
  411. provided by an external service if appropriate.
  412. \textbf{Not steganographic:} Tor does not try to conceal who is connected
  413. to the network.
  414. \SubSection{Threat Model}
  415. \label{subsec:threat-model}
  416. A global passive adversary is the most commonly assumed threat when
  417. analyzing theoretical anonymity designs. But like all practical
  418. low-latency systems, Tor does not protect against such a strong
  419. adversary. Instead, we assume an adversary who can observe some fraction
  420. of network traffic; who can generate, modify, delete, or delay
  421. traffic; who can operate onion routers of his own; and who can
  422. compromise some fraction of the onion routers.
  423. In low-latency anonymity systems that use layered encryption, the
  424. adversary's typical goal is to observe both the initiator and the
  425. responder. By observing both ends, passive attackers can confirm a
  426. suspicion that Alice is
  427. talking to Bob if the timing and volume patterns of the traffic on the
  428. connection are distinct enough; active attackers can induce timing
  429. signatures on the traffic to force distinct patterns. Rather
  430. than focusing on these \emph{traffic confirmation} attacks,
  431. we aim to prevent \emph{traffic
  432. analysis} attacks, where the adversary uses traffic patterns to learn
  433. which points in the network he should attack.
  434. Our adversary might try to link an initiator Alice with her
  435. communication partners, or try to build a profile of Alice's
  436. behavior. He might mount passive attacks by observing the network edges
  437. and correlating traffic entering and leaving the network---by
  438. relationships in packet timing, volume, or externally visible
  439. user-selected
  440. options. The adversary can also mount active attacks by compromising
  441. routers or keys; by replaying traffic; by selectively denying service
  442. to trustworthy routers to move users to
  443. compromised routers, or denying service to users to see if traffic
  444. elsewhere in the
  445. network stops; or by introducing patterns into traffic that can later be
  446. detected. The adversary might subvert the directory servers to give users
  447. differing views of network state. Additionally, he can try to decrease
  448. the network's reliability by attacking nodes or by performing antisocial
  449. activities from reliable nodes and trying to get them taken down---making
  450. the network unreliable flushes users to other less anonymous
  451. systems, where they may be easier to attack. We summarize
  452. in Section~\ref{sec:attacks} how well the Tor design defends against
  453. each of these attacks.
  454. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  455. \Section{The Tor Design}
  456. \label{sec:design}
  457. The Tor network is an overlay network; each onion router (OR)
  458. runs as a normal
  459. user-level process without any special privileges.
  460. Each onion router maintains a TLS~\cite{TLS}
  461. connection to every other onion router.
  462. %(We discuss alternatives to this clique-topology assumption in
  463. %Section~\ref{sec:maintaining-anonymity}.)
  464. % A subset of the ORs also act as
  465. %directory servers, tracking which routers are in the network;
  466. %see Section~\ref{subsec:dirservers} for directory server details.
  467. Each user
  468. runs local software called an onion proxy (OP) to fetch directories,
  469. establish circuits across the network,
  470. and handle connections from user applications. These onion proxies accept
  471. TCP streams and multiplex them across the circuits. The onion
  472. router on the other side
  473. of the circuit connects to the destinations of
  474. the TCP streams and relays data.
  475. Each onion router maintains a long-term identity key and a short-term
  476. onion key. The identity
  477. key is used to sign TLS certificates, to sign the OR's \emph{router
  478. descriptor} (a summary of its keys, address, bandwidth, exit policy,
  479. and so on), and (by directory servers) to sign directories. %Changing
  480. %the identity key of a router is considered equivalent to creating a
  481. %new router.
  482. The onion key is used to decrypt requests
  483. from users to set up a circuit and negotiate ephemeral keys.
  484. The TLS protocol also establishes a short-term link key when communicating
  485. between ORs. Short-term keys are rotated periodically and
  486. independently, to limit the impact of key compromise.
  487. Section~\ref{subsec:cells} presents the fixed-size
  488. \emph{cells} that are the unit of communication in Tor. We describe
  489. in Section~\ref{subsec:circuits} how circuits are
  490. built, extended, truncated, and destroyed. Section~\ref{subsec:tcp}
  491. describes how TCP streams are routed through the network. We address
  492. integrity checking in Section~\ref{subsec:integrity-checking},
  493. and resource limiting in Section~\ref{subsec:rate-limit}.
  494. Finally,
  495. Section~\ref{subsec:congestion} talks about congestion control and
  496. fairness issues.
  497. \SubSection{Cells}
  498. \label{subsec:cells}
  499. Onion routers communicate with one another, and with users' OPs, via
  500. TLS connections with ephemeral keys. Using TLS conceals the data on
  501. the connection with perfect forward secrecy, and prevents an attacker
  502. from modifying data on the wire or impersonating an OR.
  503. Traffic passes along these connections in fixed-size cells. Each cell
  504. is 512 bytes, %(but see Section~\ref{sec:conclusion} for a discussion of
  505. %allowing large cells and small cells on the same network),
  506. and consists of a header and a payload. The header includes a circuit
  507. identifier (circID) that specifies which circuit the cell refers to
  508. (many circuits can be multiplexed over the single TLS connection), and
  509. a command to describe what to do with the cell's payload. (Circuit
  510. identifiers are connection-specific: each single circuit has a different
  511. circID on each OP/OR or OR/OR connection it traverses.)
  512. Based on their command, cells are either \emph{control} cells, which are
  513. always interpreted by the node that receives them, or \emph{relay} cells,
  514. which carry end-to-end stream data. The control cell commands are:
  515. \emph{padding} (currently used for keepalive, but also usable for link
  516. padding); \emph{create} or \emph{created} (used to set up a new circuit);
  517. and \emph{destroy} (to tear down a circuit).
  518. Relay cells have an additional header (the relay header) after the
  519. cell header, containing a streamID (stream identifier: many streams can
  520. be multiplexed over a circuit); an end-to-end checksum for integrity
  521. checking; the length of the relay payload; and a relay command.
  522. The entire contents of the relay header and the relay cell payload
  523. are encrypted or decrypted together as the relay cell moves along the
  524. circuit, using the 128-bit AES cipher in counter mode to generate a
  525. cipher stream.
  526. The
  527. relay commands are: \emph{relay
  528. data} (for data flowing down the stream), \emph{relay begin} (to open a
  529. stream), \emph{relay end} (to close a stream cleanly), \emph{relay
  530. teardown} (to close a broken stream), \emph{relay connected}
  531. (to notify the OP that a relay begin has succeeded), \emph{relay
  532. extend} and \emph{relay extended} (to extend the circuit by a hop,
  533. and to acknowledge), \emph{relay truncate} and \emph{relay truncated}
  534. (to tear down only part of the circuit, and to acknowledge), \emph{relay
  535. sendme} (used for congestion control), and \emph{relay drop} (used to
  536. implement long-range dummies).
  537. We describe each of these cell types and commands in more detail below.
  538. \SubSection{Circuits and streams}
  539. \label{subsec:circuits}
  540. Onion Routing originally built one circuit for each
  541. TCP stream. Because building a circuit can take several tenths of a
  542. second (due to public-key cryptography and network latency),
  543. this design imposed high costs on applications like web browsing that
  544. open many TCP streams.
  545. In Tor, each circuit can be shared by many TCP streams. To avoid
  546. delays, users construct circuits preemptively. To limit linkability
  547. among their streams, users' OPs build a new circuit
  548. periodically if the previous one has been used,
  549. and expire old used circuits that no longer have any open streams.
  550. OPs consider making a new circuit once a minute: thus
  551. even heavy users spend negligible time
  552. building circuits, but a limited number of requests can be linked
  553. to each other through a given exit node. Also, because circuits are built
  554. in the background, OPs can recover from failed circuit creation
  555. without delaying streams and thereby harming user experience.\\
  556. \noindent{\large\bf Constructing a circuit}\label{subsubsec:constructing-a-circuit}\\
  557. %\subsubsection{Constructing a circuit}
  558. A user's OP constructs circuits incrementally, negotiating a
  559. symmetric key with each OR on the circuit, one hop at a time. To begin
  560. creating a new circuit, the OP (call her Alice) sends a
  561. \emph{create} cell to the first node in her chosen path (call him Bob).
  562. (She chooses a new
  563. circID $C_{AB}$ not currently used on the connection from her to Bob.)
  564. The \emph{create} cell's
  565. payload contains the first half of the Diffie-Hellman handshake
  566. ($g^x$), encrypted to the onion key of the OR (call him Bob). Bob
  567. responds with a \emph{created} cell containing the second half of the
  568. DH handshake, along with a hash of the negotiated key $K=g^{xy}$.
  569. Once the circuit has been established, Alice and Bob can send one
  570. another relay cells encrypted with the negotiated
  571. key.\footnote{Actually, the negotiated key is used to derive two
  572. symmetric keys: one for each direction.} More detail is given in
  573. the next section.
  574. To extend the circuit further, Alice sends a \emph{relay extend} cell
  575. to Bob, specifying the address of the next OR (call her Carol), and
  576. an encrypted $g^{x_2}$ for her. Bob copies the half-handshake into a
  577. \emph{create} cell, and passes it to Carol to extend the circuit.
  578. (Bob chooses a new circID $C_{BC}$ not currently used on the connection
  579. between him and Carol. Alice never needs to know this circID; only Bob
  580. associates $C_{AB}$ on his connection with Alice to $C_{BC}$ on
  581. his connection with Carol.)
  582. When Carol responds with a \emph{created} cell, Bob wraps the payload
  583. into a \emph{relay extended} cell and passes it back to Alice. Now
  584. the circuit is extended to Carol, and Alice and Carol share a common key
  585. $K_2 = g^{x_2 y_2}$.
  586. To extend the circuit to a third node or beyond, Alice
  587. proceeds as above, always telling the last node in the circuit to
  588. extend one hop further.
  589. This circuit-level handshake protocol achieves unilateral entity
  590. authentication (Alice knows she's handshaking with the OR, but
  591. the OR doesn't care who is opening the circuit---Alice uses no public key
  592. and is trying to remain anonymous) and unilateral key authentication
  593. (Alice and the OR agree on a key, and Alice knows only the OR learns
  594. it). It also achieves forward
  595. secrecy and key freshness. More formally, the protocol is as follows
  596. (where $E_{PK_{Bob}}(\cdot)$ is encryption with Bob's public key,
  597. $H$ is a secure hash function, and $|$ is concatenation):
  598. \begin{equation*}
  599. \begin{aligned}
  600. \mathrm{Alice} \rightarrow \mathrm{Bob}&: E_{PK_{Bob}}(g^x) \\
  601. \mathrm{Bob} \rightarrow \mathrm{Alice}&: g^y, H(K | \mathrm{``handshake"}) \\
  602. \end{aligned}
  603. \end{equation*}
  604. \noindent In the second step, Bob proves that it was he who received $g^x$,
  605. and who chose $y$. We use PK encryption in the first step
  606. (rather than, say, using the first two steps of STS, which has a
  607. signature in the second step) because a single cell is too small to
  608. hold both a public key and a signature. Preliminary analysis with the
  609. NRL protocol analyzer~\cite{meadows96} shows this protocol to be
  610. secure (including perfect forward secrecy) under the
  611. traditional Dolev-Yao model.\\
  612. \noindent{\large\bf Relay cells}\\
  613. %\subsubsection{Relay cells}
  614. %
  615. Once Alice has established the circuit (so she shares keys with each
  616. OR on the circuit), she can send relay cells. Recall that every relay
  617. cell has a streamID that indicates to which
  618. stream the cell belongs. %This streamID allows a relay cell to be
  619. %addressed to any OR on the circuit.
  620. Upon receiving a relay
  621. cell, an OR looks up the corresponding circuit, and decrypts the relay
  622. header and payload with the session key for that circuit.
  623. If the cell is headed away from Alice the OR then checks
  624. whether the decrypted streamID is recognized---either because it
  625. corresponds to an open stream at this OR for the given circuit, or because
  626. it is the control streamID (zero). If the OR recognizes the
  627. streamID, it accepts the relay cell and processes it as described
  628. below. Otherwise,
  629. the OR looks up the circID and OR for the
  630. next step in the circuit, replaces the circID as appropriate, and
  631. sends the decrypted relay cell to the next OR. (If the OR at the end
  632. of the circuit receives an unrecognized relay cell, an error has
  633. occurred, and the cell is discarded.)
  634. OPs treat incoming relay cells similarly: they iteratively unwrap the
  635. relay header and payload with the session keys shared with each
  636. OR on the circuit, from the closest to farthest. % (Because we use a
  637. %stream cipher, encryption operations may be inverted in any order.)
  638. If at any stage the OP recognizes the streamID, the cell must have
  639. originated at the OR whose encryption has just been removed.
  640. To construct a relay cell addressed to a given OR, Alice iteratively
  641. encrypts the cell payload (that is, the relay header and payload) with
  642. the symmetric key of each hop up to that OR. Because the streamID is
  643. encrypted to a different value at each step, only at the targeted OR
  644. will it have a meaningful value.\footnote{
  645. % Should we just say that 2^56 is itself negligible?
  646. % Assuming 4-hop circuits with 10 streams per hop, there are 33
  647. % possible bad streamIDs before the last circuit. This still
  648. % gives an error only once every 2 million terabytes (approx).
  649. With 48 bits of streamID per cell, the probability of an accidental
  650. collision is far lower than the chance of hardware failure.}
  651. This \emph{leaky pipe} circuit topology
  652. allows Alice's streams to exit at different ORs on a single circuit.
  653. Alice may choose different exit points because of their exit policies,
  654. or to keep the ORs from knowing that two streams
  655. originate from the same person.
  656. When an OR later replies to Alice with a relay cell, it
  657. encrypts the cell's relay header and payload with the single key it
  658. shares with Alice, and sends the cell back toward Alice along the
  659. circuit. Subsequent ORs add further layers of encryption as they
  660. relay the cell back to Alice.
  661. To tear down a circuit, Alice sends a \emph{destroy} control
  662. cell. Each OR in the circuit receives the \emph{destroy} cell, closes
  663. all streams on that circuit, and passes a new \emph{destroy} cell
  664. forward. But just as circuits are built incrementally, they can also
  665. be torn down incrementally: Alice can send a \emph{relay
  666. truncate} cell to a single OR on a circuit. That OR then sends a
  667. \emph{destroy} cell forward, and acknowledges with a
  668. \emph{relay truncated} cell. Alice can then extend the circuit to
  669. different nodes, without signaling to the intermediate nodes (or
  670. a limited observer) that she has changed her circuit.
  671. Similarly, if a node on the circuit goes down, the adjacent
  672. node can send a \emph{relay truncated} cell back to Alice. Thus the
  673. ``break a node and see which circuits go down''
  674. attack~\cite{freedom21-security} is weakened.
  675. \SubSection{Opening and closing streams}
  676. \label{subsec:tcp}
  677. When Alice's application wants a TCP connection to a given
  678. address and port, it asks the OP (via SOCKS) to make the
  679. connection. The OP chooses the newest open circuit (or creates one if
  680. none is available), and chooses a suitable OR on that circuit to be the
  681. exit node (usually the last node, but maybe others due to exit policy
  682. conflicts; see Section~\ref{subsec:exitpolicies}.) The OP then opens
  683. the stream by sending a \emph{relay begin} cell to the exit node,
  684. using a streamID of zero (so the OR will recognize it), containing as
  685. its relay payload a new random streamID, the destination
  686. address, and the destination port. Once the
  687. exit node connects to the remote host, it responds
  688. with a \emph{relay connected} cell. Upon receipt, the OP sends a
  689. SOCKS reply to notify the application of its success. The OP
  690. now accepts data from the application's TCP stream, packaging it into
  691. \emph{relay data} cells and sending those cells along the circuit to
  692. the chosen OR.
  693. There's a catch to using SOCKS, however---some applications pass the
  694. alphanumeric hostname to the Tor client, while others resolve it into
  695. an IP address first and then pass the IP address to the Tor client. If
  696. the application does DNS resolution first, Alice thereby reveals her
  697. destination to the remote DNS server, rather than sending the hostname
  698. through the Tor network to be resolved at the far end. Common applications
  699. like Mozilla and SSH have this flaw.
  700. With Mozilla, the flaw is easy to address: the filtering HTTP
  701. proxy called Privoxy gives a hostname to the Tor client, so Alice's
  702. computer never does DNS resolution.
  703. But a portable general solution, such as is needed for
  704. SSH, is
  705. an open problem. Modifying or replacing the local nameserver
  706. can be invasive, brittle, and unportable. Forcing the resolver
  707. library to do resolution via TCP rather than UDP is
  708. hard, and also has portability problems. We could also provide a
  709. tool similar to \emph{dig} to perform a private lookup through the
  710. Tor network. Currently, we encourage the use of
  711. privacy-aware proxies like Privoxy wherever possible.
  712. Closing a Tor stream is analogous to closing a TCP stream: it uses a
  713. two-step handshake for normal operation, or a one-step handshake for
  714. errors. If the stream closes abnormally, the adjacent node simply sends a
  715. \emph{relay teardown} cell. If the stream closes normally, the node sends
  716. a \emph{relay end} cell down the circuit. When the other side has sent
  717. back its own \emph{relay end} cell, the stream can be torn down. Because
  718. all relay cells use layered encryption, only the destination OR knows
  719. that a given relay cell is a request to close a stream. This two-step
  720. handshake allows Tor to support TCP-based applications that use half-closed
  721. connections.
  722. % such as broken HTTP clients that close their side of the
  723. %stream after writing but are still willing to read.
  724. \SubSection{Integrity checking on streams}
  725. \label{subsec:integrity-checking}
  726. Because the old Onion Routing design used a stream cipher without integrity
  727. checking, traffic was
  728. vulnerable to a malleability attack: though the attacker could not
  729. decrypt cells, any changes to encrypted data
  730. would create corresponding changes to the data leaving the network.
  731. This weakness allowed an adversary to change a padding cell to a destroy
  732. cell; change the destination address in a \emph{relay begin} cell to the
  733. adversary's webserver; or change an FTP command from
  734. {\tt dir} to {\tt rm~*}. Any adversary who could guess the encrypted
  735. content could introduce such corruption in a stream. (Even an external
  736. adversary could do this, because the link encryption similarly used a
  737. stream cipher.)
  738. Tor uses TLS on its links---its integrity checking
  739. protects data from modification by external adversaries.
  740. Addressing the insider malleability attack, however, is
  741. more complex.
  742. We could do integrity checking of the relay cells at each hop, either
  743. by including hashes or by using an authenticating cipher mode like
  744. EAX~\cite{eax}, but there are some problems. First, these approaches
  745. impose a message-expansion overhead at each hop, and so we would have to
  746. either leak the path length or waste bytes by padding to a maximum
  747. path length. Second, these solutions can only verify traffic coming
  748. from Alice: ORs would not be able to produce suitable hashes for
  749. the intermediate hops, since the ORs on a circuit do not know the
  750. other ORs' session keys. Third, we have already accepted that our design
  751. is vulnerable to end-to-end timing attacks; tagging attacks performed
  752. within the circuit provide no additional information to the attacker.
  753. Thus, we check integrity only at the edges of each stream. When Alice
  754. negotiates a key with a new hop, they each initialize a SHA-1
  755. digest with a derivative of that key,
  756. thus beginning with randomness that only the two of them know. From
  757. then on they each incrementally add to the SHA-1 digest the contents of
  758. all relay cells they create, and include with each relay cell the
  759. first four bytes of the current digest. Each also keeps a SHA-1
  760. digest of data received, to verify that the received hashes are correct.
  761. To be sure of removing or modifying a cell, the attacker must be able
  762. to deduce the current digest state (which depends on all
  763. traffic between Alice and Bob, starting with their negotiated key).
  764. Attacks on SHA-1 where the adversary can incrementally add to a hash
  765. to produce a new valid hash don't work, because all hashes are
  766. end-to-end encrypted across the circuit. The computational overhead
  767. of computing the digests is minimal compared to doing the AES
  768. encryption performed at each hop of the circuit. We use only four
  769. bytes per cell to minimize overhead; the chance that an adversary will
  770. correctly guess a valid hash
  771. %, plus the payload the current cell,
  772. is
  773. acceptably low, given that Alice or Bob tear down the circuit if they
  774. receive a bad hash.
  775. \SubSection{Rate limiting and fairness}
  776. \label{subsec:rate-limit}
  777. Volunteers are generally more willing to run services that can limit
  778. their own bandwidth usage. To accommodate them, Tor servers use a
  779. token bucket approach~\cite{tannenbaum96} to
  780. enforce a long-term average rate of incoming bytes, while still
  781. permitting short-term bursts above the allowed bandwidth.
  782. % Current bucket sizes are set to ten seconds' worth of traffic.
  783. %Further, we want to avoid starving any Tor streams. Entire circuits
  784. %could starve if we read greedily from connections and one connection
  785. %uses all the remaining bandwidth. We solve this by dividing the number
  786. %of tokens in the bucket by the number of connections that want to read,
  787. %and reading at most that number of bytes from each connection. We iterate
  788. %this procedure until the number of tokens in the bucket is under some
  789. %threshold (currently 10KB), at which point we greedily read from connections.
  790. Because the Tor protocol generates roughly the same number of outgoing
  791. bytes as incoming bytes, it is sufficient in practice to limit only
  792. incoming bytes.
  793. With TCP streams, however, the correspondence is not one-to-one:
  794. relaying a single incoming byte can require an entire 512-byte cell.
  795. (We can't just wait for more bytes, because the local application may
  796. be waiting for a reply.) Therefore, we treat this case as if the entire
  797. cell size had been read, regardless of the fullness of the cell.
  798. Further, inspired by Rennhard et al's design in~\cite{anonnet}, a
  799. circuit's edges can heuristically distinguish interactive streams from bulk
  800. streams by comparing the frequency with which they supply cells. We can
  801. provide good latency for interactive streams by giving them preferential
  802. service, while still giving good overall throughput to the bulk
  803. streams. Such preferential treatment presents a possible end-to-end
  804. attack, but an adversary observing both
  805. ends of the stream can already learn this information through timing
  806. attacks.
  807. \SubSection{Congestion control}
  808. \label{subsec:congestion}
  809. Even with bandwidth rate limiting, we still need to worry about
  810. congestion, either accidental or intentional. If enough users choose the
  811. same OR-to-OR connection for their circuits, that connection can become
  812. saturated. For example, an attacker could send a large file
  813. through the Tor network to a webserver he runs, and then
  814. refuse to read any of the bytes at the webserver end of the
  815. circuit. Without some congestion control mechanism, these bottlenecks
  816. can propagate back through the entire network. We don't need to
  817. reimplement full TCP windows (with sequence numbers,
  818. the ability to drop cells when we're full and retransmit later, and so
  819. on),
  820. because TCP already guarantees in-order delivery of each
  821. cell.
  822. %But we need to investigate further the effects of the current
  823. %parameters on throughput and latency, while also keeping privacy in mind;
  824. %see Section~\ref{sec:maintaining-anonymity} for more discussion.
  825. We describe our response below.
  826. \textbf{Circuit-level throttling:}
  827. To control a circuit's bandwidth usage, each OR keeps track of two
  828. windows. The \emph{packaging window} tracks how many relay data cells the OR is
  829. allowed to package (from incoming TCP streams) for transmission back to the OP,
  830. and the \emph{delivery window} tracks how many relay data cells it is willing
  831. to deliver to TCP streams outside the network. Each window is initialized
  832. (say, to 1000 data cells). When a data cell is packaged or delivered,
  833. the appropriate window is decremented. When an OR has received enough
  834. data cells (currently 100), it sends a \emph{relay sendme} cell towards the OP,
  835. with streamID zero. When an OR receives a \emph{relay sendme} cell with
  836. streamID zero, it increments its packaging window. Either of these cells
  837. increments the corresponding window by 100. If the packaging window
  838. reaches 0, the OR stops reading from TCP connections for all streams
  839. on the corresponding circuit, and sends no more relay data cells until
  840. receiving a \emph{relay sendme} cell.
  841. The OP behaves identically, except that it must track a packaging window
  842. and a delivery window for every OR in the circuit. If a packaging window
  843. reaches 0, it stops reading from streams destined for that OR.
  844. \textbf{Stream-level throttling}:
  845. The stream-level congestion control mechanism is similar to the
  846. circuit-level mechanism. ORs and OPs use \emph{relay sendme} cells
  847. to implement end-to-end flow control for individual streams across
  848. circuits. Each stream begins with a packaging window (currently 500 cells),
  849. and increments the window by a fixed value (50) upon receiving a \emph{relay
  850. sendme} cell. Rather than always returning a \emph{relay sendme} cell as soon
  851. as enough cells have arrived, the stream-level congestion control also
  852. has to check whether data has been successfully flushed onto the TCP
  853. stream; it sends the \emph{relay sendme} cell only when the number of bytes pending
  854. to be flushed is under some threshold (currently 10 cells' worth).
  855. %% Maybe omit this next paragraph. -NM
  856. %Currently, non-data relay cells do not affect the windows. Thus we
  857. %avoid potential deadlock issues, for example, arising because a stream
  858. %can't send a \emph{relay sendme} cell when its packaging window is empty.
  859. These arbitrarily chosen parameters seem to give tolerable throughput
  860. and delay; see Section~\ref{sec:in-the-wild}.
  861. \SubSection{Rendezvous Points and hidden services}
  862. \label{subsec:rendezvous}
  863. Rendezvous points are a building block for \emph{location-hidden
  864. services} (also known as \emph{responder anonymity}) in the Tor
  865. network. Location-hidden services allow Bob to offer a TCP
  866. service, such as a webserver, without revealing his IP address.
  867. This type of anonymity protects against distributed DoS attacks:
  868. attackers are forced to attack the onion routing network
  869. because they do not know Bob's IP address.
  870. Our design for location-hidden servers has the following goals.
  871. \textbf{Access-controlled:} Bob needs a way to filter incoming requests,
  872. so an attacker cannot flood Bob simply by making many connections to him.
  873. \textbf{Robust:} Bob should be able to maintain a long-term pseudonymous
  874. identity even in the presence of router failure. Bob's service must
  875. not be tied to a single OR, and Bob must be able to tie his service
  876. to new ORs. \textbf{Smear-resistant:}
  877. A social attacker who offers an illegal or disreputable location-hidden
  878. service should not be able to ``frame'' a rendezvous router by
  879. making observers believe the router created that service.
  880. \textbf{Application-transparent:} Although we require users
  881. to run special software to access location-hidden servers, we must not
  882. require them to modify their applications.
  883. We provide location-hiding for Bob by allowing him to advertise
  884. several onion routers (his \emph{introduction points}) as contact
  885. points. He may do this on any robust efficient
  886. key-value lookup system with authenticated updates, such as a
  887. distributed hash table (DHT) like CFS~\cite{cfs:sosp01}\footnote{
  888. Rather than rely on an external infrastructure, the Onion Routing network
  889. can run the DHT itself. At first, we can run a simple lookup
  890. system on the
  891. directory servers.} Alice, the client, chooses an OR as her
  892. \emph{rendezvous point}. She connects to one of Bob's introduction
  893. points, informs him of her rendezvous point, and then waits for him
  894. to connect to the rendezvous point. This extra level of indirection
  895. helps Bob's introduction points avoid problems associated with serving
  896. unpopular files directly (for example, if Bob serves
  897. material that the introduction point's community finds objectionable,
  898. or if Bob's service tends to get attacked by network vandals).
  899. The extra level of indirection also allows Bob to respond to some requests
  900. and ignore others.
  901. In Appendix~\ref{sec:rendezvous-specifics} we provide a more detailed
  902. description of the rendezvous protocol, integration issues, attacks,
  903. and related rendezvous work.
  904. \Section{Other design decisions}
  905. \label{sec:other-design}
  906. \SubSection{Resource management and denial-of-service}
  907. \label{subsec:dos}
  908. Providing Tor as a public service creates many opportunities for
  909. denial-of-service attacks against the network. While
  910. flow control and rate limiting (discussed in
  911. Section~\ref{subsec:congestion}) prevent users from consuming more
  912. bandwidth than routers are willing to provide, opportunities remain for
  913. users to
  914. consume more network resources than their fair share, or to render the
  915. network unusable for others.
  916. First of all, there are several CPU-consuming denial-of-service
  917. attacks wherein an attacker can force an OR to perform expensive
  918. cryptographic operations. For example, an attacker who sends a
  919. \emph{create} cell full of junk bytes can force an OR to perform an RSA
  920. decrypt. Similarly, an attacker can
  921. fake the start of a TLS handshake, forcing the OR to carry out its
  922. (comparatively expensive) half of the handshake at no real computational
  923. cost to the attacker.
  924. We have not yet implemented any defenses for these attacks, but several
  925. approaches are possible. First, ORs can
  926. require clients to solve a puzzle~\cite{puzzles-tls} while beginning new
  927. TLS handshakes or accepting \emph{create} cells. So long as these
  928. tokens are easy to verify and computationally expensive to produce, this
  929. approach limits the attack multiplier. Additionally, ORs can limit
  930. the rate at which they accept \emph{create} cells and TLS connections,
  931. so that
  932. the computational work of processing them does not drown out the
  933. symmetric cryptography operations that keep cells
  934. flowing. This rate limiting could, however, allow an attacker
  935. to slow down other users when they build new circuits.
  936. % What about link-to-link rate limiting?
  937. Adversaries can also attack the Tor network's hosts and network
  938. links. Disrupting a single circuit or link breaks all streams passing
  939. along that part of the circuit. Users similarly lose service
  940. when a router crashes or its operator restarts it. The current
  941. Tor design treats such attacks as intermittent network failures, and
  942. depends on users and applications to respond or recover as appropriate. A
  943. future design could use an end-to-end TCP-like acknowledgment protocol,
  944. so that no streams are lost unless the entry or exit point itself is
  945. disrupted. This solution would require more buffering at the network
  946. edges, however, and the performance and anonymity implications from this
  947. extra complexity still require investigation.
  948. \SubSection{Exit policies and abuse}
  949. \label{subsec:exitpolicies}
  950. % originally, we planned to put the "users only know the hostname,
  951. % not the IP, but exit policies are by IP" problem here too. Not
  952. % worth putting in the submission, but worth thinking about putting
  953. % in sometime somehow. -RD
  954. Exit abuse is a serious barrier to wide-scale Tor deployment. Anonymity
  955. presents would-be vandals and abusers with an opportunity to hide
  956. the origins of their activities. Attackers can harm the Tor network by
  957. implicating exit servers for their abuse. Also, applications that commonly
  958. use IP-based authentication (such as institutional mail or webservers)
  959. can be fooled by the fact that anonymous connections appear to originate
  960. at the exit OR.
  961. We stress that Tor does not enable any new class of abuse. Spammers
  962. and other attackers already have access to thousands of misconfigured
  963. systems worldwide, and the Tor network is far from the easiest way
  964. to launch attacks.
  965. %Indeed, because of its limited
  966. %anonymity, Tor is probably not a good way to commit crimes.
  967. But because the
  968. onion routers can be mistaken for the originators of the abuse,
  969. and the volunteers who run them may not want to deal with the hassle of
  970. explaining anonymity networks to irate administrators, we must block or limit
  971. the abuse that travels through the Tor network.
  972. To mitigate abuse issues, in Tor, each onion router's \emph{exit policy}
  973. describes to which external addresses and ports the router will
  974. connect. On one end of the spectrum are \emph{open exit}
  975. nodes that will connect anywhere. On the other end are \emph{middleman}
  976. nodes that only relay traffic to other Tor nodes, and \emph{private exit}
  977. nodes that only connect to a local host or network. Using a private
  978. exit (if one exists) is a more secure way for a client to connect to a
  979. given host or network---an external adversary cannot eavesdrop traffic
  980. between the private exit and the final destination, and so is less sure of
  981. Alice's destination and activities. Most onion routers in the current
  982. network function as
  983. \emph{restricted exits} that permit connections to the world at large,
  984. but prevent access to certain abuse-prone addresses and services such
  985. as SMTP.
  986. Additionally, in some cases the OR can authenticate clients to
  987. prevent exit abuse without harming anonymity~\cite{or-discex00}.
  988. %The abuse issues on closed (e.g. military) networks are different
  989. %from the abuse on open networks like the Internet. While these IP-based
  990. %access controls are still commonplace on the Internet, on closed networks,
  991. %nearly all participants will be honest, and end-to-end authentication
  992. %can be assumed for important traffic.
  993. Many administrators use port restrictions to support only a
  994. limited set of services, such as HTTP, SSH, or AIM.
  995. This is not a complete solution, of course, since abuse opportunities for these
  996. protocols are still well known.
  997. We have not yet encountered any abuse in the deployed network, but if
  998. we do we should consider using proxies to clean traffic for certain
  999. protocols as it leaves the network. For example, much abusive HTTP
  1000. behavior (such as exploiting buffer overflows or well-known script
  1001. vulnerabilities) can be detected in a straightforward manner.
  1002. Similarly, one could run automatic spam filtering software (such as
  1003. SpamAssassin) on email exiting the OR network.
  1004. ORs may also rewrite exiting traffic to append
  1005. headers or other information indicating that the traffic has passed
  1006. through an anonymity service. This approach is commonly used
  1007. by email-only anonymity systems. ORs can also
  1008. run on servers with hostnames like {\tt anonymous} to further
  1009. alert abuse targets to the nature of the anonymous traffic.
  1010. A mixture of open and restricted exit nodes allows the most
  1011. flexibility for volunteers running servers. But while having many
  1012. middleman nodes provides a large and robust network,
  1013. having only a few exit nodes reduces the number of points
  1014. an adversary needs to monitor for traffic analysis, and places a
  1015. greater burden on the exit nodes. This tension can be seen in the
  1016. Java Anon Proxy
  1017. cascade model, wherein only one node in each cascade needs to handle
  1018. abuse complaints---but an adversary only needs to observe the entry
  1019. and exit of a cascade to perform traffic analysis on all that
  1020. cascade's users. The hydra model (many entries, few exits) presents a
  1021. different compromise: only a few exit nodes are needed, but an
  1022. adversary needs to work harder to watch all the clients; see
  1023. Section~\ref{sec:conclusion}.
  1024. Finally, we note that exit abuse must not be dismissed as a peripheral
  1025. issue: when a system's public image suffers, it can reduce the number
  1026. and diversity of that system's users, and thereby reduce the anonymity
  1027. of the system itself. Like usability, public perception is a
  1028. security parameter. Sadly, preventing abuse of open exit nodes is an
  1029. unsolved problem, and will probably remain an arms race for the
  1030. foreseeable future. The abuse problems faced by Princeton's CoDeeN
  1031. project~\cite{darkside} give us a glimpse of likely issues.
  1032. \SubSection{Directory Servers}
  1033. \label{subsec:dirservers}
  1034. First-generation Onion Routing designs~\cite{freedom2-arch,or-jsac98} used
  1035. in-band network status updates: each router flooded a signed statement
  1036. to its neighbors, which propagated it onward. But anonymizing networks
  1037. have different security goals than typical link-state routing protocols.
  1038. For example, delays (accidental or intentional)
  1039. that can cause different parts of the network to have different views
  1040. of link-state and topology are not only inconvenient: they give
  1041. attackers an opportunity to exploit differences in client knowledge.
  1042. We also worry about attacks to deceive a
  1043. client about the router membership list, topology, or current network
  1044. state. Such \emph{partitioning attacks} on client knowledge help an
  1045. adversary to efficiently deploy resources
  1046. against a target~\cite{minion-design}.
  1047. Tor uses a small group of redundant, well-known onion routers to
  1048. track changes in network topology and node state, including keys and
  1049. exit policies. Each such \emph{directory server} acts as an HTTP
  1050. server, so clients can fetch current network state
  1051. and router lists, and so other ORs can upload
  1052. state information. Onion routers periodically publish signed
  1053. statements of their state to each directory server. The directory servers
  1054. combine this information with their own views of network liveness,
  1055. and generate a signed description (a \emph{directory}) of the entire
  1056. network state. Client software is
  1057. pre-loaded with a list of the directory servers and their keys,
  1058. to bootstrap each client's view of the network.
  1059. % XXX this means that clients will be forced to upgrade as the
  1060. % XXX dirservers change or get compromised. argue that this is ok.
  1061. When a directory server receives a signed statement for an OR, it
  1062. checks whether the OR's identity key is recognized. Directory
  1063. servers do not automatically advertise unrecognized ORs. (If they did,
  1064. an adversary could take over the network by creating many
  1065. servers~\cite{sybil}.) Instead, new nodes must be approved by the
  1066. directory
  1067. server administrator before they are included. Mechanisms for automated
  1068. node approval are an area of active research, and are discussed more
  1069. in Section~\ref{sec:maintaining-anonymity}.
  1070. Of course, a variety of attacks remain. An adversary who controls
  1071. a directory server can track clients by providing them different
  1072. information---perhaps by listing only nodes under its control, or by
  1073. informing only certain clients about a given node. Even an external
  1074. adversary can exploit differences in client knowledge: clients who use
  1075. a node listed on one directory server but not the others are vulnerable.
  1076. Thus these directory servers must be synchronized and redundant, so
  1077. that they can agree on a common directory. Clients should only trust
  1078. this directory if it is signed by a threshold of the directory
  1079. servers.
  1080. The directory servers in Tor are modeled after those in
  1081. Mixminion~\cite{minion-design}, but our situation is easier. First,
  1082. we make the
  1083. simplifying assumption that all participants agree on the set of
  1084. directory servers. Second, while Mixminion needs to predict node
  1085. behavior, Tor only needs a threshold consensus of the current
  1086. state of the network.
  1087. Tor directory servers build a consensus directory through a simple
  1088. four-round broadcast protocol. In round one, each server dates and
  1089. signs its current opinion, and broadcasts it to the other directory
  1090. servers; then in round two, each server rebroadcasts all the signed
  1091. opinions it has received. At this point all directory servers check
  1092. to see whether any server has signed multiple opinions in the same
  1093. period. Such a server is either broken or cheating, so the protocol
  1094. stops and notifies the administrators, who either remove the cheater
  1095. or wait for the broken server to be fixed. If there are no
  1096. discrepancies, each directory server then locally computes an algorithm
  1097. (described below)
  1098. on the set of opinions, resulting in a uniform shared directory. In
  1099. round three servers sign this directory and broadcast it; and finally
  1100. in round four the servers rebroadcast the directory and all the
  1101. signatures. If any directory server drops out of the network, its
  1102. signature is not included on the final directory.
  1103. The rebroadcast steps ensure that a directory server is heard by
  1104. either all of the other servers or none of them, even when some links
  1105. are down (assuming that any two directory servers can talk directly or
  1106. via a third). Broadcasts are feasible because there are relatively few
  1107. directory servers (currently 3, but we expect as many as 9 as the network
  1108. scales). Computing the shared directory locally is a straightforward
  1109. threshold voting process: we include an OR if a majority of directory
  1110. servers believe it to be good.
  1111. To avoid attacks where a router connects to all the directory servers
  1112. but refuses to relay traffic from other routers, the directory servers
  1113. must build circuits and use them to anonymously test router
  1114. reliability~\cite{mix-acc}. Unfortunately, this defense is not yet
  1115. designed or
  1116. implemented.
  1117. Using directory servers is simpler and more flexible than flooding.
  1118. Flooding is expensive, and complicates the analysis when we
  1119. start experimenting with non-clique network topologies. Signed
  1120. directories can be cached by other
  1121. onion routers,
  1122. so directory servers are not a performance
  1123. bottleneck when we have many users, and do not aid traffic analysis by
  1124. forcing clients to periodically announce their existence to any
  1125. central point.
  1126. \Section{Attacks and Defenses}
  1127. \label{sec:attacks}
  1128. Below we summarize a variety of attacks, and discuss how well our
  1129. design withstands them.\\
  1130. \noindent{\large\bf Passive attacks}\\
  1131. \emph{Observing user traffic patterns.} Observing a user's connection
  1132. will not reveal her destination or data, but it will
  1133. reveal traffic patterns (both sent and received). Profiling via user
  1134. connection patterns requires further processing, because multiple
  1135. application streams may be operating simultaneously or in series over
  1136. a single circuit.
  1137. \emph{Observing user content.} While content at the user end is encrypted,
  1138. connections to responders may not be (indeed, the responding website
  1139. itself may be hostile). While filtering content is not a primary goal
  1140. of Onion Routing, Tor can directly use Privoxy and related
  1141. filtering services to anonymize application data streams.
  1142. \emph{Option distinguishability.} We allow clients to choose local
  1143. configuration options. For example, clients concerned about request
  1144. linkability should rotate circuits more often than those concerned
  1145. about traceability. There is economic incentive to attract users by
  1146. allowing this choice; but at the same time, a set of clients who are
  1147. in the minority may lose more anonymity by appearing distinct than they
  1148. gain by optimizing their behavior~\cite{econymics}.
  1149. \emph{End-to-end timing correlation.} Tor only minimally hides
  1150. such correlations. An attacker watching patterns of
  1151. traffic at the initiator and the responder will be
  1152. able to confirm the correspondence with high probability. The
  1153. greatest protection currently available against such confirmation is to hide
  1154. the connection between the onion proxy and the first Tor node,
  1155. by running the OP on the Tor node or behind a firewall. This approach
  1156. requires an observer to separate traffic originating at the onion
  1157. router from traffic passing through it: a global observer can do this,
  1158. but it might be beyond a limited observer's capabilities.
  1159. \emph{End-to-end size correlation.} Simple packet counting
  1160. will also be effective in confirming
  1161. endpoints of a stream. However, even without padding, we have some
  1162. limited protection: the leaky pipe topology means different numbers
  1163. of packets may enter one end of a circuit than exit at the other.
  1164. \emph{Website fingerprinting.} All the effective passive
  1165. attacks above are traffic confirmation attacks,
  1166. which puts them outside our design goals. There is also
  1167. a passive traffic analysis attack that is potentially effective.
  1168. Rather than searching exit connections for timing and volume
  1169. correlations, the adversary may build up a database of
  1170. ``fingerprints'' containing file sizes and access patterns for
  1171. targeted websites. He can later confirm a user's connection to a given
  1172. site simply by consulting the database. This attack has
  1173. been shown to be effective against SafeWeb~\cite{hintz-pet02}.
  1174. It may be less effective against Tor, since
  1175. streams are multiplexed within the same circuit, and
  1176. fingerprinting will be limited to
  1177. the granularity of cells (currently 512 bytes). Additional
  1178. defenses could include
  1179. larger cell sizes, padding schemes to group websites
  1180. into large sets, and link
  1181. padding or long-range dummies.\footnote{Note that this fingerprinting
  1182. attack should not be confused with the much more complicated latency
  1183. attacks of~\cite{back01}, which require a fingerprint of the latencies
  1184. of all circuits through the network, combined with those from the
  1185. network edges to the target user and the responder website.}\\
  1186. \noindent{\large\bf Active attacks}\\
  1187. \emph{Compromise keys.} An attacker who learns the TLS session key can
  1188. see control cells and encrypted relay cells on every circuit on that
  1189. connection; learning a circuit
  1190. session key lets him unwrap one layer of the encryption. An attacker
  1191. who learns an OR's TLS private key can impersonate that OR for the TLS
  1192. key's lifetime, but he must
  1193. also learn the onion key to decrypt \emph{create} cells (and because of
  1194. perfect forward secrecy, he cannot hijack already established circuits
  1195. without also compromising their session keys). Periodic key rotation
  1196. limits the window of opportunity for these attacks. On the other hand,
  1197. an attacker who learns a node's identity key can replace that node
  1198. indefinitely by sending new forged descriptors to the directory servers.
  1199. \emph{Iterated compromise.} A roving adversary who can
  1200. compromise ORs (by system intrusion, legal coercion, or extralegal
  1201. coercion) could march down the circuit compromising the
  1202. nodes until he reaches the end. Unless the adversary can complete
  1203. this attack within the lifetime of the circuit, however, the ORs
  1204. will have discarded the necessary information before the attack can
  1205. be completed. (Thanks to the perfect forward secrecy of session
  1206. keys, the attacker cannot force nodes to decrypt recorded
  1207. traffic once the circuits have been closed.) Additionally, building
  1208. circuits that cross jurisdictions can make legal coercion
  1209. harder---this phenomenon is commonly called ``jurisdictional
  1210. arbitrage.'' The Java Anon Proxy project recently experienced the
  1211. need for this approach, when
  1212. a German court forced them to add a backdoor to
  1213. all of their nodes~\cite{jap-backdoor}.
  1214. \emph{Run a recipient.} An adversary running a webserver
  1215. trivially learns the timing patterns of users connecting to it, and
  1216. can introduce arbitrary patterns in its responses.
  1217. End-to-end attacks become easier: if the adversary can induce
  1218. users to connect to his webserver (perhaps by advertising
  1219. content targeted to those users), she now holds one end of their
  1220. connection. There is also a danger that application
  1221. protocols and associated programs can be induced to reveal information
  1222. about the initiator. Tor depends on Privoxy and similar protocol cleaners
  1223. to solve this latter problem.
  1224. \emph{Run an onion proxy.} It is expected that end users will
  1225. nearly always run their own local onion proxy. However, in some
  1226. settings, it may be necessary for the proxy to run
  1227. remotely---typically, in institutions that want
  1228. to monitor the activity of those connecting to the proxy.
  1229. Compromising an onion proxy compromises all future connections
  1230. through it.
  1231. \emph{DoS non-observed nodes.} An observer who can only watch some
  1232. of the Tor network can increase the value of this traffic
  1233. by attacking non-observed nodes to shut them down, reduce
  1234. their reliability, or persuade users that they are not trustworthy.
  1235. The best defense here is robustness.
  1236. \emph{Run a hostile OR.} In addition to being a local observer,
  1237. an isolated hostile node can create circuits through itself, or alter
  1238. traffic patterns to affect traffic at other nodes. Nonetheless, a hostile
  1239. node must be immediately adjacent to both endpoints to compromise the
  1240. anonymity of a circuit. If an adversary can
  1241. run multiple ORs, and can persuade the directory servers
  1242. that those ORs are trustworthy and independent, then occasionally
  1243. some user will choose one of those ORs for the start and another
  1244. as the end of a circuit. If an adversary
  1245. controls $m>1$ out of $N$ nodes, he can to correlate at most
  1246. $\left(\frac{m}{N}\right)^2$ of the traffic in this way---although an
  1247. adversary
  1248. could possibly attract a disproportionately large amount of traffic
  1249. by running an OR with a permissive exit policy, or by
  1250. degrading the reliability of other routers.
  1251. \emph{Introduce timing into messages.} This is simply a stronger
  1252. version of passive timing attacks already discussed earlier.
  1253. \emph{Tagging attacks.} A hostile node could ``tag'' a
  1254. cell by altering it. If the
  1255. stream were, for example, an unencrypted request to a Web site,
  1256. the garbled content coming out at the appropriate time would confirm
  1257. the association. However, integrity checks on cells prevent
  1258. this attack.
  1259. \emph{Replace contents of unauthenticated protocols.} When
  1260. relaying an unauthenticated protocol like HTTP, a hostile exit node
  1261. can impersonate the target server. Clients
  1262. should prefer protocols with end-to-end authentication.
  1263. \emph{Replay attacks.} Some anonymity protocols are vulnerable
  1264. to replay attacks. Tor is not; replaying one side of a handshake
  1265. will result in a different negotiated session key, and so the rest
  1266. of the recorded session can't be used.
  1267. \emph{Smear attacks.} An attacker could use the Tor network for
  1268. socially disapproved acts, to bring the
  1269. network into disrepute and get its operators to shut it down.
  1270. Exit policies reduce the possibilities for abuse, but
  1271. ultimately the network requires volunteers who can tolerate
  1272. some political heat.
  1273. \emph{Distribute hostile code.} An attacker could trick users
  1274. into running subverted Tor software that did not, in fact, anonymize
  1275. their connections---or worse, could trick ORs into running weakened
  1276. software that provided users with less anonymity. We address this
  1277. problem (but do not solve it completely) by signing all Tor releases
  1278. with an official public key, and including an entry in the directory
  1279. that lists which versions are currently believed to be secure. To
  1280. prevent an attacker from subverting the official release itself
  1281. (through threats, bribery, or insider attacks), we provide all
  1282. releases in source code form, encourage source audits, and
  1283. frequently warn our users never to trust any software (even from
  1284. us) that comes without source.\\
  1285. \noindent{\large\bf Directory attacks}\\
  1286. \emph{Destroy directory servers.} If a few directory
  1287. servers disappear, the others still decide on a valid
  1288. directory. So long as any directory servers remain in operation,
  1289. they will still broadcast their views of the network and generate a
  1290. consensus directory. (If more than half are destroyed, this
  1291. directory will not, however, have enough signatures for clients to
  1292. use it automatically; human intervention will be necessary for
  1293. clients to decide whether to trust the resulting directory.)
  1294. \emph{Subvert a directory server.} By taking over a directory server,
  1295. an attacker can partially influence the final directory. Since ORs
  1296. are included or excluded by majority vote, the corrupt directory can
  1297. at worst cast a tie-breaking vote to decide whether to include
  1298. marginal ORs. It remains to be seen how often such marginal cases
  1299. occur in practice.
  1300. \emph{Subvert a majority of directory servers.} An adversary who controls
  1301. more than half the directory servers can include as many compromised
  1302. ORs in the final directory as he wishes. We must ensure that directory
  1303. server operators are independent and attack-resistant.
  1304. \emph{Encourage directory server dissent.} The directory
  1305. agreement protocol assumes that directory server operators agree on
  1306. the set of directory servers. An adversary who can persuade some
  1307. of the directory server operators to distrust one another could
  1308. split the quorum into mutually hostile camps, thus partitioning
  1309. users based on which directory they use. Tor does not address
  1310. this attack.
  1311. \emph{Trick the directory servers into listing a hostile OR.}
  1312. Our threat model explicitly assumes directory server operators will
  1313. be able to filter out most hostile ORs.
  1314. % If this is not true, an
  1315. % attacker can flood the directory with compromised servers.
  1316. \emph{Convince the directories that a malfunctioning OR is
  1317. working.} In the current Tor implementation, directory servers
  1318. assume that an OR is running correctly if they can start a TLS
  1319. connection to it. A hostile OR could easily subvert this test by
  1320. accepting TLS connections from ORs but ignoring all cells. Directory
  1321. servers must actively test ORs by building circuits and streams as
  1322. appropriate. The tradeoffs of a similar approach are discussed
  1323. in~\cite{mix-acc}.\\
  1324. \Section{Early experiences: Tor in the Wild}
  1325. \label{sec:in-the-wild}
  1326. As of mid-January 2004, the Tor network consists of 17 nodes
  1327. (15 in the US, 2 in Europe), and more are joining each week as the code
  1328. matures.\footnote{For comparison, the current remailer network
  1329. has about 30 reliable nodes. We haven't asked PlanetLab to provide
  1330. Tor nodes, since their AUP wouldn't allow exit nodes (see
  1331. also~\cite{darkside}) and because we aim to build a long-term community of
  1332. node operators and developers.} Each node has at least a 768Kb/768Kb
  1333. connection, and
  1334. many have 10Mb. The number of users varies (and of course, it's hard to
  1335. tell for sure), but we sometimes have several hundred users---administrators at
  1336. several companies have begun sending their entire departments' web
  1337. traffic through Tor, to block other divisions of
  1338. their company from reading their traffic. Tor users have reported using
  1339. the network for web browsing, FTP, IRC, AIM, Kazaa, and SSH.
  1340. Each Tor node currently processes roughly 800,000 relay
  1341. cells (a bit under half a gigabyte) per week. On average, about 80\%
  1342. of each 500-byte payload is full for cells going back to the client,
  1343. whereas about 40\% is full for cells coming from the client. (The difference
  1344. arises because most of the network's traffic is web browsing.) Interactive
  1345. traffic like SSH brings down the average a lot---once we have more
  1346. experience, and assuming we can resolve the anonymity issues, we may
  1347. partition traffic into two relay cell sizes: one to handle
  1348. bulk traffic and one for interactive traffic.
  1349. Based in part on our restrictive default exit policy (we
  1350. reject SMTP requests) and our low profile, we have had no abuse
  1351. issues since the network was deployed in October
  1352. 2003. Our slow growth rate gives us time to add features,
  1353. resolve bugs, and get a feel for what users actually want from an
  1354. anonymity system. Even though having more users would bolster our
  1355. anonymity sets, we are not eager to attract the Kazaa or warez
  1356. communities---we feel that we must build a reputation for privacy, human
  1357. rights, research, and other socially laudable activities.
  1358. As for performance, profiling shows that Tor spends almost
  1359. all its CPU time in AES, which is fast. Current latency is attributable
  1360. to two factors. First, network latency is critical: we are
  1361. intentionally bouncing traffic around the world several times. Second,
  1362. our end-to-end congestion control algorithm focuses on protecting
  1363. volunteer servers from accidental DoS rather than optimizing
  1364. performance. % Right now the first $500 \times 500\mbox{B}=250\mbox{KB}$
  1365. %of the stream arrives
  1366. %quickly, and after that throughput depends on the rate that \emph{relay
  1367. %sendme} acknowledgments arrive.
  1368. For example, we did some informal tests using a test network of 4 nodes on
  1369. the same machine. We downloaded a 60 megabyte file from {\tt debian.org}
  1370. every 30 minutes for 2 days (100 sample points). It arrived in about
  1371. 300 seconds on average, compared to 210s for a direct download. We ran
  1372. the same test on the main Tor network, pulling down the front page of
  1373. {\tt cnn.com}: while a direct download consistently took about 0.5s,
  1374. the performance through Tor was highly variable. Some downloads were
  1375. as fast as 0.6s, with others as slow as 25s (the average was 2.5s). It
  1376. seems that as the network expands, the chance of getting a slow circuit
  1377. (one that includes a slow or heavily loaded Tor node) is increasing. On
  1378. the other hand, we still have users, so this performance is good enough
  1379. for now.
  1380. %With the current network's topology and load, users can typically get 1-2
  1381. %megabits sustained transfer rate, which is good enough for now.
  1382. Indeed, the Tor
  1383. design aims foremost to provide a security research platform; performance
  1384. only needs to be sufficient to retain users~\cite{econymics,back01}.
  1385. We can tweak the congestion control
  1386. parameters to provide faster throughput at the cost of
  1387. larger buffers at each node; adding the heuristics mentioned in
  1388. Section~\ref{subsec:rate-limit} to favor low-volume
  1389. streams may also help. More research remains to find the
  1390. right balance.
  1391. % We should say _HOW MUCH_ latency there is in these cases. -NM
  1392. %performs badly on lossy networks. may need airhook or something else as
  1393. %transport alternative?
  1394. Although Tor's clique topology and full-visibility directories present
  1395. scaling problems, we still expect the network to support a few hundred
  1396. nodes and maybe 10,000 users before we're forced to become
  1397. more distributed. With luck, the experience we gain running the current
  1398. topology will help us choose among alternatives when the time comes.
  1399. \Section{Open Questions in Low-latency Anonymity}
  1400. \label{sec:maintaining-anonymity}
  1401. In addition to the non-goals in
  1402. Section~\ref{subsec:non-goals}, many other questions must be solved
  1403. before we can be confident of Tor's security.
  1404. Many of these open issues are questions of balance. For example,
  1405. how often should users rotate to fresh circuits? Frequent rotation
  1406. is inefficient, expensive, and may lead to intersection attacks and
  1407. predecessor attacks~\cite{wright03}, but infrequent rotation makes the
  1408. user's traffic linkable. Besides opening fresh circuits, clients can
  1409. also exit from the middle of the circuit,
  1410. or truncate and re-extend the circuit. More analysis is
  1411. needed to determine the proper tradeoff.
  1412. %% Duplicated by 'Better directory distribution' in section 9.
  1413. %
  1414. %A similar question surrounds timing of directory operations: how often
  1415. %should directories be updated? Clients that update infrequently receive
  1416. %an inaccurate picture of the network, but frequent updates can overload
  1417. %the directory servers. More generally, we must find more
  1418. %decentralized yet practical ways to distribute up-to-date snapshots of
  1419. %network status without introducing new attacks.
  1420. How should we choose path lengths? If Alice only ever uses two hops,
  1421. then both ORs can be certain that by colluding they will learn about
  1422. Alice and Bob. In our current approach, Alice always chooses at least
  1423. three nodes unrelated to herself and her destination.
  1424. %% This point is subtle, but not IMO necessary. Anybody who thinks
  1425. %% about it will see that it's implied by the above sentence; anybody
  1426. %% who doesn't think about it is safe in his ignorance.
  1427. %
  1428. %Thus normally she chooses
  1429. %three nodes, but if she is running an OR and her destination is on an OR,
  1430. %she uses five.
  1431. Should Alice choose a random path length (say,
  1432. increasing it from a geometric distribution) to foil an attacker who
  1433. uses timing to learn that he is the fifth hop and thus concludes that
  1434. both Alice and the responder are on ORs?
  1435. Throughout this paper, we have assumed that end-to-end traffic
  1436. confirmation will immediately and automatically defeat a low-latency
  1437. anonymity system. Even high-latency anonymity systems can be
  1438. vulnerable to end-to-end traffic confirmation, if the traffic volumes
  1439. are high enough, and if users' habits are sufficiently
  1440. distinct~\cite{statistical-disclosure,limits-open}. Can anything be
  1441. done to
  1442. make low-latency systems resist these attacks as well as high-latency
  1443. systems? Tor already makes some effort to conceal the starts and ends of
  1444. streams by wrapping long-range control commands in identical-looking
  1445. relay cells. Link padding could frustrate passive observers who count
  1446. packets; long-range padding could work against observers who own the
  1447. first hop in a circuit. But more research remains to find an efficient
  1448. and practical approach. Volunteers prefer not to run constant-bandwidth
  1449. padding; but no convincing traffic shaping approach has been
  1450. specified. Recent work on long-range padding~\cite{defensive-dropping}
  1451. shows promise. One could also try to reduce correlation in packet timing
  1452. by batching and re-ordering packets, but it is unclear whether this could
  1453. improve anonymity without introducing so much latency as to render the
  1454. network unusable.
  1455. A cascade topology may better defend against traffic confirmation by
  1456. aggregating users, and making padding and
  1457. mixing more affordable. Does the hydra topology (many input nodes,
  1458. few output nodes) work better against some adversaries? Are we going
  1459. to get a hydra anyway because most nodes will be middleman nodes?
  1460. Common wisdom suggests that Alice should run her own OR for best
  1461. anonymity, because traffic coming from her node could plausibly have
  1462. come from elsewhere. How much mixing does this approach need? Is it
  1463. immediately beneficial because of real-world adversaries that can't
  1464. observe Alice's router, but can run routers of their own?
  1465. To scale to many users, and to prevent an attacker from observing the
  1466. whole network, it may be necessary
  1467. to support far more servers than Tor currently anticipates.
  1468. This introduces several issues. First, if approval by a central set
  1469. of directory servers is no longer feasible, what mechanism should be used
  1470. to prevent adversaries from signing up many colluding servers? Second,
  1471. if clients can no longer have a complete picture of the network,
  1472. how can they perform discovery while preventing attackers from
  1473. manipulating or exploiting gaps in their knowledge? Third, if there
  1474. are too many servers for every server to constantly communicate with
  1475. every other, which non-clique topology should the network use?
  1476. (Restricted-route topologies promise comparable anonymity with better
  1477. scalability~\cite{danezis-pets03}, but whatever topology we choose, we
  1478. need some way to keep attackers from manipulating their position within
  1479. it~\cite{casc-rep}.) Fourth, if no central authority is tracking
  1480. server reliability, how do we stop unreliable servers from making
  1481. the network unusable? Fifth, do clients receive so much anonymity
  1482. from running their own ORs that we should expect them all to do
  1483. so~\cite{econymics}, or do we need another incentive structure to
  1484. motivate them? Tarzan and MorphMix present possible solutions.
  1485. % advogato, captcha
  1486. When a Tor node goes down, all its circuits (and thus streams) must break.
  1487. Will users abandon the system because of this brittleness? How well
  1488. does the method in Section~\ref{subsec:dos} allow streams to survive
  1489. node failure? If affected users rebuild circuits immediately, how much
  1490. anonymity is lost? It seems the problem is even worse in a peer-to-peer
  1491. environment---such systems don't yet provide an incentive for peers to
  1492. stay connected when they're done retrieving content, so we would expect
  1493. a higher churn rate.
  1494. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  1495. \Section{Future Directions}
  1496. \label{sec:conclusion}
  1497. Tor brings together many innovations into a unified deployable system. The
  1498. next immediate steps include:
  1499. \emph{Scalability:} Tor's emphasis on deployability and design simplicity
  1500. has led us to adopt a clique topology, semi-centralized
  1501. directories, and a full-network-visibility model for client
  1502. knowledge. These properties will not scale past a few hundred servers.
  1503. Section~\ref{sec:maintaining-anonymity} describes some promising
  1504. approaches, but more deployment experience will be helpful in learning
  1505. the relative importance of these bottlenecks.
  1506. \emph{Bandwidth classes:} This paper assumes that all ORs have
  1507. good bandwidth and latency. We should instead adopt the MorphMix model,
  1508. where nodes advertise their bandwidth level (DSL, T1, T3), and
  1509. Alice avoids bottlenecks by choosing nodes that match or
  1510. exceed her bandwidth. In this way DSL users can usefully join the Tor
  1511. network.
  1512. \emph{Incentives:} Volunteers who run nodes are rewarded with publicity
  1513. and possibly better anonymity~\cite{econymics}. More nodes means increased
  1514. scalability, and more users can mean more anonymity. We need to continue
  1515. examining the incentive structures for participating in Tor. Further,
  1516. we need to explore more approaches to limiting abuse, and understand
  1517. why most people don't bother using privacy systems.
  1518. \emph{Cover traffic:} Currently Tor omits cover traffic---its costs
  1519. in performance and bandwidth are clear but its security benefits are
  1520. not well understood. We must pursue more research on link-level cover
  1521. traffic and long-range cover traffic to determine whether some simple padding
  1522. method offers provable protection against our chosen adversary.
  1523. %%\emph{Offer two relay cell sizes:} Traffic on the Internet tends to be
  1524. %%large for bulk transfers and small for interactive traffic. One cell
  1525. %%size cannot be optimal for both types of traffic.
  1526. % This should go in the spec and todo, but not the paper yet. -RD
  1527. \emph{Caching at exit nodes:} Perhaps each exit node should run a
  1528. caching web proxy~\cite{shsm03}, to improve anonymity for cached pages
  1529. (Alice's request never
  1530. leaves the Tor network), to improve speed, and to reduce bandwidth cost.
  1531. On the other hand, forward security is weakened because caches
  1532. constitute a record of retrieved files. We must find the right
  1533. balance between usability and security.
  1534. \emph{Better directory distribution:}
  1535. Clients currently download a description of
  1536. the entire network every 15 minutes. As the state grows larger
  1537. and clients more numerous, we may need a solution in which
  1538. clients receive incremental updates to directory state.
  1539. More generally, we must find more
  1540. scalable yet practical ways to distribute up-to-date snapshots of
  1541. network status without introducing new attacks.
  1542. \emph{Implement location-hidden services:} The design in
  1543. Appendix~\ref{sec:rendezvous-specifics} has not yet been implemented.
  1544. While doing
  1545. so we are likely to encounter additional issues that must be resolved,
  1546. both in terms of usability and anonymity.
  1547. \emph{Further specification review:} Our public
  1548. byte-level specification~\cite{tor-spec} needs
  1549. external review. We hope that as Tor
  1550. is deployed, more people will examine its
  1551. specification.
  1552. \emph{Multisystem interoperability:} We are currently working with the
  1553. designer of MorphMix to unify the specification and implementation of
  1554. the common elements of our two systems. So far, this seems
  1555. to be relatively straightforward. Interoperability will allow testing
  1556. and direct comparison of the two designs for trust and scalability.
  1557. \emph{Wider-scale deployment:} The original goal of Tor was to
  1558. gain experience in deploying an anonymizing overlay network, and
  1559. learn from having actual users. We are now at a point in design
  1560. and development where we can start deploying a wider network. Once
  1561. we have many actual users, we will doubtlessly be better
  1562. able to evaluate some of our design decisions, including our
  1563. robustness/latency tradeoffs, our performance tradeoffs (including
  1564. cell size), our abuse-prevention mechanisms, and
  1565. our overall usability.
  1566. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  1567. %% commented out for anonymous submission
  1568. \section*{Acknowledgments}
  1569. We thank Peter Palfrader, Geoff Goodell, Adam Shostack, Joseph Sokol-Margolis,
  1570. John Bashinski, and Zack Brown
  1571. for editing and comments;
  1572. Matej Pfajfar, Andrei Serjantov, Marc Rennhard: for design discussions.
  1573. Bram Cohen for congestion control discussions;
  1574. Adam Back for suggesting telescoping circuits; and
  1575. Cathy Meadows for formal analysis of the \emph{extend} protocol.
  1576. This work has been supported by ONR and DARPA.
  1577. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  1578. \bibliographystyle{latex8}
  1579. \bibliography{tor-design}
  1580. \appendix
  1581. \Section{Rendezvous points and hidden services}
  1582. \label{sec:rendezvous-specifics}
  1583. In this appendix we provide more specifics about the rendezvous points
  1584. of Section~\ref{subsec:rendezvous}. We also describe integration
  1585. issues, related work, and how well the rendezvous point design
  1586. withstands various attacks.
  1587. \SubSection{Rendezvous protocol overview}
  1588. We give an overview of the steps of a rendezvous. These are
  1589. performed on behalf of Alice and Bob by their local OPs;
  1590. application integration is described more fully below.
  1591. \begin{tightlist}
  1592. \item Bob chooses some introduction points, and advertises them on
  1593. the DHT. He can add more later.
  1594. \item Bob builds a circuit to each of his introduction points,
  1595. and waits for requests.
  1596. \item Alice learns about Bob's service out of band (perhaps Bob told her,
  1597. or she found it on a website). She retrieves the details of Bob's
  1598. service from the DHT.
  1599. \item Alice chooses an OR as the rendezvous point (RP) for this
  1600. transaction. She builds a circuit to the RP, and gives it a
  1601. rendezvous cookie that it will use to recognize Bob.
  1602. \item Alice opens an anonymous stream to one of Bob's introduction
  1603. points, and gives it a message (encrypted to Bob's public key)
  1604. that tells him
  1605. about herself, her chosen RP and the rendezvous cookie, and the
  1606. first half of a DH
  1607. handshake. The introduction point sends the message to Bob.
  1608. \item If Bob wants to talk to Alice, he builds a circuit to Alice's
  1609. RP and sends the rendezvous cookie, the second half of the DH
  1610. handshake, and a hash of the session
  1611. key they now share. By the same argument as in
  1612. Section~\ref{subsubsec:constructing-a-circuit}, Alice knows she
  1613. shares the key only with Bob.
  1614. \item The RP connects Alice's circuit to Bob's. Note that RP can't
  1615. recognize Alice, Bob, or the data they transmit.
  1616. \item Alice now sends a \emph{relay begin} cell along the circuit. It
  1617. arrives at Bob's onion proxy. Bob's onion proxy connects to Bob's
  1618. webserver.
  1619. \item An anonymous stream has been established, and Alice and Bob
  1620. communicate as normal.
  1621. \end{tightlist}
  1622. When establishing an introduction point, Bob provides the onion router
  1623. with a public ``introduction'' key. The hash of this public key
  1624. identifies a unique service, and (since Bob signs his
  1625. messages) prevents anybody else from usurping Bob's introduction point
  1626. in the future. Bob uses the same public key to establish the other
  1627. introduction points for his service, and periodically refreshes his
  1628. entry in the DHT.
  1629. The message that Alice gives
  1630. the introduction point includes a hash of Bob's public key to identify
  1631. the service, along with an optional initial authorization token (the
  1632. introduction point can do prescreening, for example to block replays). Her
  1633. message to Bob may include an end-to-end authorization token so Bob
  1634. can choose whether to respond.
  1635. The authorization tokens can be used to provide selective access:
  1636. important users get tokens to ensure uninterrupted access to the
  1637. service. During normal situations, Bob's service might simply be offered
  1638. directly from mirrors, while Bob gives out tokens to high-priority users. If
  1639. the mirrors are knocked down,
  1640. %by distributed DoS attacks or even
  1641. %physical attack,
  1642. those users can switch to accessing Bob's service via
  1643. the Tor rendezvous system.
  1644. Since Bob's introduction points might themselves be subject to DoS he
  1645. could have to choose between keeping many
  1646. introduction connections open or risking such an attack. In this case,
  1647. he can provide selected users
  1648. with a current list and/or future schedule of introduction points that
  1649. are not advertised in the DHT\@. This is most likely to be practical
  1650. if there is a relatively stable and large group of introduction points
  1651. available. Alternatively, Bob could give secret public keys
  1652. to selected users for consulting the DHT\@. All of these approaches
  1653. have the advantage of limiting exposure even when
  1654. some of the selected high-priority users collude in the DoS\@.
  1655. \SubSection{Integration with user applications}
  1656. Bob configures his onion proxy to know the local IP address and port of his
  1657. service, a strategy for authorizing clients, and a public key. Bob
  1658. publishes the public key, an expiration time, and
  1659. the current introduction points for his service into the DHT, indexed
  1660. by the hash of the public key. Bob's webserver is unmodified,
  1661. and doesn't even know that it's hidden behind the Tor network.
  1662. Alice's applications also work unchanged---her client interface
  1663. remains a SOCKS proxy. We encode all of the necessary information
  1664. into the fully qualified domain name Alice uses when establishing her
  1665. connection. Location-hidden services use a virtual top level domain
  1666. called {\tt .onion}: thus hostnames take the form {\tt x.y.onion} where
  1667. {\tt x} is the authorization cookie, and {\tt y} encodes the hash of
  1668. the public key. Alice's onion proxy
  1669. examines addresses; if they're destined for a hidden server, it decodes
  1670. the key and starts the rendezvous as described above.
  1671. \subsection{Previous rendezvous work}
  1672. Rendezvous points in low-latency anonymity systems were first
  1673. described for use in ISDN telephony~\cite{jerichow-jsac98,isdn-mixes}.
  1674. Later low-latency designs used rendezvous points for hiding location
  1675. of mobile phones and low-power location
  1676. trackers~\cite{federrath-ih96,reed-protocols97}. Rendezvous for
  1677. low-latency
  1678. Internet connections was suggested in early Onion Routing
  1679. work~\cite{or-ih96}; however, the first published design of rendezvous
  1680. points for low-latency Internet connections was by Ian
  1681. Goldberg~\cite{ian-thesis}. His design differs from
  1682. ours in three ways. First, Goldberg suggests that Alice should manually
  1683. hunt down a current location of the service via Gnutella; our approach
  1684. makes lookup transparent to the user, as well as faster and more robust.
  1685. Second, in Tor the client and server negotiate session keys
  1686. via Diffie-Hellman, so plaintext is not exposed even at the rendezvous point. Third,
  1687. our design tries to minimize the exposure associated with running the
  1688. service, to encourage volunteers to offer introduction and rendezvous
  1689. point services. Tor's introduction points do not output any bytes to the
  1690. clients; the rendezvous points don't know the client or the server,
  1691. and can't read the data being transmitted. The indirection scheme is
  1692. also designed to include authentication/authorization---if Alice doesn't
  1693. include the right cookie with her request for service, Bob need not even
  1694. acknowledge his existence.
  1695. %\SubSection{Attacks against rendezvous points}
  1696. %
  1697. %We describe here attacks against rendezvous points and how well
  1698. %the system protects against them.
  1699. %
  1700. %\emph{Make many introduction requests.} An attacker could
  1701. %try to deny Bob service by flooding his introduction points with
  1702. %requests. Because the introduction points can block requests that
  1703. %lack authorization tokens, however, Bob can restrict the volume of
  1704. %requests he receives, or require a certain amount of computation for
  1705. %every request he receives.
  1706. %
  1707. %\emph{Attack an introduction point.} An attacker could
  1708. %disrupt a location-hidden service by disabling its introduction
  1709. %points. But because a service's identity is attached to its public
  1710. %key, the service can simply re-advertise
  1711. %itself at a different introduction point. Advertisements can also be
  1712. %done secretly so that only high-priority clients know the address of
  1713. %Bob's introduction points or so that different clients know of different
  1714. %introduction points. This forces the attacker to disable all possible
  1715. %introduction points.
  1716. %
  1717. %\emph{Compromise an introduction point.} An attacker who controls
  1718. %Bob's introduction point can flood Bob with
  1719. %introduction requests, or prevent valid introduction requests from
  1720. %reaching him. Bob can notice a flood, and close the circuit. To notice
  1721. %blocking of valid requests, however, he should periodically test the
  1722. %introduction point by sending rendezvous requests and making
  1723. %sure he receives them.
  1724. %
  1725. %\emph{Compromise a rendezvous point.} A rendezvous
  1726. %point is no more sensitive than any other OR on
  1727. %a circuit, since all data passing through the rendezvous is encrypted
  1728. %with a session key shared by Alice and Bob.
  1729. \end{document}
  1730. % Style guide:
  1731. % U.S. spelling
  1732. % avoid contractions (it's, can't, etc.)
  1733. % prefer ``for example'' or ``such as'' to e.g.
  1734. % prefer ``that is'' to i.e.
  1735. % 'mix', 'mixes' (as noun)
  1736. % 'mix-net'
  1737. % 'mix', 'mixing' (as verb)
  1738. % 'middleman' [Not with a hyphen; the hyphen has been optional
  1739. % since Middle English.]
  1740. % 'nymserver'
  1741. % 'Cypherpunk', 'Cypherpunks', 'Cypherpunk remailer'
  1742. % 'Onion Routing design', 'onion router' [note capitalization]
  1743. % 'SOCKS'
  1744. % Try not to use \cite as a noun.
  1745. % 'Authorizating' sounds great, but it isn't a word.
  1746. % 'First, second, third', not 'Firstly, secondly, thirdly'.
  1747. % 'circuit', not 'channel'
  1748. % Typography: no space on either side of an em dash---ever.
  1749. % Hyphens are for multi-part words; en dashs imply movement or
  1750. % opposition (The Alice--Bob connection); and em dashes are
  1751. % for punctuation---like that.
  1752. % A relay cell; a control cell; a \emph{create} cell; a
  1753. % \emph{relay truncated} cell. Never ``a \emph{relay truncated}.''
  1754. %
  1755. % 'Substitute ``Damn'' every time you're inclined to write ``very;'' your
  1756. % editor will delete it and the writing will be just as it should be.'
  1757. % -- Mark Twain