tor-design.tex 102 KB

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