Tor and Anonymity Networks
Abstract
Tor (The Onion Router) is a network of volunteer-operated servers that routes internet traffic through multiple layers of encryption, making it difficult to trace communications back to their origin. Originally developed by the US Naval Research Laboratory in the 1990s to protect American intelligence communications, Tor was released as free software in 2002 and turned over to a nonprofit that maintains it today. The same technology that protects political dissidents in authoritarian countries, whistleblowers sending documents to journalists, and abuse survivors communicating safely also routes drug markets, child exploitation material, and ransomware operations. Tor is the clearest example in computing history of dual-use technology: the same properties that make it valuable for human rights protection make it valuable for criminal concealment, and there is no technical mechanism to provide one without the other.
The Naval Research Laboratory Origins
The mathematics behind Tor (onion routing) was developed by Paul Syverson, Michael Reed, and David Goldschlag at the US Naval Research Laboratory (NRL), starting in November or December 1995. Their goal was practical: the US intelligence community needed a way to communicate online that would not reveal the identity of the communicating parties to adversaries monitoring internet traffic. Reed later put it bluntly: the purpose was use by the military and intelligence services, not helping dissidents in authoritarian countries.
The problem with standard internet communication was not encryption, by the mid-1990s, encrypting message content with SSL or PGP was practical. The problem was traffic analysis: an adversary watching network connections could see who was communicating with whom even without reading the content. A CIA officer connecting to a known foreign contact’s server revealed the connection regardless of message encryption.
Onion routing’s solution was elegant. Instead of connecting directly to a destination, a user’s traffic travels through a sequence of volunteer relay nodes:
- The user’s software selects a path through three relay nodes: a Guard node, a Middle relay, and an Exit node.
- The message is encrypted in three layers, one for each relay. The outermost layer addresses the Guard node; inside is a layer for the Middle relay; inside that is a layer for the Exit node; inside that is the actual message.
- Each relay decrypts one layer (“peels the onion”), learns only the previous and next hop, and forwards the traffic.
No single node knows both the origin and destination of a communication. The Guard node knows the user’s IP address but not the destination. The Exit node knows the destination but not the user’s IP address. Only the user knows the complete path.
The NRL published the concept in 1996 in the paper “Hiding Routing Information” and built a first prototype the same year, routing traffic over five simulated nodes on a single NRL machine; a second prototype with 13 nodes followed in 1998. In 1999, the NRL stopped funding the work and most of the team left; a patent was still granted in 2000. The design had been released publicly from the start, and by necessity: a secret anonymity protocol known only to intelligence agencies would be useless for protecting those agencies’ communications, since an adversary monitoring unusual encrypted traffic could infer that a small number of users were likely intelligence operatives. Roger Dingledine spelled out the logic in a 2004 Berlin talk: the US government cannot run an anonymity system for everybody and then use it only itself, because every connection would then be read as yet another CIA agent visiting the site. A public network with millions of ordinary users provides better cover.
The 1996 paper closed with a passage that anticipated the next 25 years: “There is an obvious tension between anonymity and law enforcement. If this tension is resolved in favor of law enforcement, it would be straightforward to integrate a key escrow system within the onion, which would make routing information available to the lawful authorities.” The escrow was never built.
Tor as Free Software
The project’s second life began at a Berkeley workshop in 2000, where Syverson met Roger Dingledine, a fresh MIT graduate whose master’s thesis had produced the anonymous storage system Free Haven. Dingledine joined the onion routing work, and brought along fellow MIT student Nick Mathewson, developer of the anonymous remailer Mixminion. In 2001, DARPA stepped in as a new funder.
The name arrived in 2001. Several onion routing experiments existed at the time, and whenever Dingledine said he worked on onion routing, people asked which project. His stock answer was “the onion routing”, and his colleague Rachel Greenstadt pointed out that this made a nice acronym: Tor. Dingledine noted a bonus: Tor also works as a standalone German word (it means “gate”).
In 2002, the team discarded the aging NRL code base, whose authors had scattered and were unavailable for questions, and restarted from a minimalist onion routing implementation that Cambridge student Matej Pfajfar had written as his thesis; it was rewritten so heavily that by 2004 none of his code remained. Dingledine announced a pre-alpha on a mailing list in September 2002, and in October 2003 the network went live. By the end of that year it consisted of about a dozen volunteer-run relays, one of them in Dresden. In 2004, Dingledine, Mathewson, and Syverson published “Tor: The Second-Generation Onion Router”, the design paper that remains largely valid today and that also introduced hidden services under the .onion pseudo-domain. The code was released as free software; anyone could run a relay and contribute to the network. In December 2006, Dingledine, Mathewson, and five others established the Tor Project, a nonprofit that maintains the software and advocates for online privacy, with the EFF as its early fiscal sponsor.
By 2008, the Tor Browser (Firefox configured to route traffic through Tor) made using the network accessible to non-technical users. Before the Tor Browser, configuring Tor required technical knowledge; after it, any user could download a single application and achieve network anonymity within minutes.
Who Pays for Tor
The largest contradiction in Tor’s history is financial: the leading counterweight to state surveillance has been funded mostly by the government whose NSA works on breaking it (internal NSA slides leaked by Snowden were titled “Tor stinks”). Until 2015, about 85 percent of the Tor Project’s budget came from US government sources, chiefly the Department of Defense (via DARPA), the State Department, the congressionally funded broadcaster Radio Free Asia with its Open Technology Fund, and the National Science Foundation. The share fell to 51 percent in 2017, and the financial report for July 2018 to June 2019 marked a milestone: of roughly $4.9 million in revenue, 39.8 percent came from US government sources, less than half for the first time. The rest came from the Swedish development agency Sida, the Mozilla Foundation, philanthropic funds, and about $577,000 in individual donations. Dingledine has repeatedly denied that money buys influence: nobody, he wrote, says “I’ll pay you X dollars to do Y.” Critics who probed the funding relationship, such as journalist Yasha Levine in 2014, have drawn heated responses from the project and its community.
How Tor Works in Practice
A user who installs Tor Browser and visits a website achieves several properties:
- The website sees the Exit node’s IP address, not the user’s.
- The user’s ISP sees that the user is connecting to Tor (specifically to a Guard node or bridge), but not the websites visited.
- Tor relay operators see only adjacent hops, never both origin and destination.
- Network observers (surveillance systems, traffic monitors) can detect Tor traffic and can see that someone is using Tor, but (in the typical case) cannot determine what sites the user visits.
Tor also enables Hidden Services (now called Onion Services): servers whose IP addresses are unknown even to the Tor network’s operators. An onion service creates a cryptographic rendezvous through the Tor network; neither the client nor the server reveals its real IP address. Onion addresses (16 or 56 characters of Base32 followed by .onion) are not resolvable through the public DNS system; they are only reachable through Tor.
Onion services were designed for legitimate confidentiality: a newspaper could operate a secure submission portal invisible to censors, a company could provide an internal service inaccessible from the open internet. Facebook launched an onion service (facebookcorewwwi.onion) on October 31, 2014, giving users in censored countries a secure way to access Facebook; it moved to a longer v3 address (facebookwkhpilnemxj7asaniu7vnjjbiltxjqhye3mhbshg7kx5tfyd.onion) in 2021. The New York Times, BBC, and Deutsche Welle ran onion services enabling readers in China, Iran, and Russia to access their content when blocked.
For all the headlines, onion services are a niche within the niche: Dingledine has said that only one to three percent of Tor users actually visit them, while the rest use Tor to browse the normal web without surveillance or censorship. The Tor Project has visibly struggled with the darknet’s reputation rubbing off on Tor; in 2014 it even engaged a PR agency and searched for a friendlier word (“Onionspace” was considered), without finding one that stuck.
The same mechanism enabled drug markets. Silk Road, launched in 2011, allowed sellers and buyers to transact in Bitcoin for drugs, with the market accessible only through Tor. At its peak, Silk Road processed approximately $1.2 billion in sales before the FBI identified and arrested its founder, Ross Ulbricht, in 2013. Silk Road’s closure spawned successors (Agora, AlphaBay, Hansa, Dream Market, White House Market) that used the same Tor-hidden-service model.
Users and Adversaries
As of 2020, Tor’s own metrics counted about two million daily users worldwide, most of them in the US, Russia, Germany, the Netherlands, and France; the modeled numbers are uncertain, and one 2018 study arrived at eight million instead. The infrastructure has a distinctly German accent: of roughly 9,000 nodes (including about 2,000 unlisted “bridge” nodes for users in censoring countries), around 22 percent of the regular relays ran in Germany, carrying about 35 percent of Tor’s traffic by consensus weight, more than France, the US, and the Netherlands combined. Many operators are public: the associations Zwiebelfreunde and Digitalcourage, members of the Chaos Computer Club, the newspaper taz, and Reporters Without Borders all run relays. The first German node had appeared in 2003 at TU Dresden, run by researcher Stefan Köpsell’s group, partly out of sympathy, partly to study the technology.
Tor’s user base is diverse and reflects the technology’s dual-use nature:
Journalists and sources: SecureDrop, a system for anonymous document submission used by major news organizations, relies on Tor hidden services. Edward Snowden recommended that journalists use Tor. The Committee to Protect Journalists and other press freedom organizations train journalists in Tor use.
Political dissidents: Citizens in China, Iran, Russia, and other authoritarian states use Tor to access blocked content and communicate without government surveillance. Tor’s use spikes measurably after major censorship events.
Privacy-conscious ordinary users: People who wish to avoid commercial surveillance (targeted advertising profiling, data broker tracking) use Tor for general browsing.
Security researchers: Security professionals use Tor to research threats without revealing their organizational IP addresses to hostile sites.
Criminals: Tor hidden services host drug markets, hacked credential markets, ransomware command-and-control infrastructure, and other illegal operations. The FBI, Europol, and law enforcement agencies globally devote significant resources to Tor de-anonymization.
The Tor Project has never attempted to prevent criminal use because it is technically impossible to do so: the same properties that protect a dissident protect a criminal. The organization’s position (shared by most privacy advocates) is that the free speech, privacy, and safety benefits to the far larger legitimate user population outweigh the costs of criminal access.
Attacks and Limitations
Tor is not anonymous against all adversaries. Several attack classes exist:
Traffic correlation attacks: An adversary who can monitor both the entry and exit traffic of the Tor network (a Global Passive Adversary) can potentially correlate the timing and volume of entering and exiting traffic to identify users. The NSA’s XKEYSCORE and related programs, revealed by Snowden, included Tor traffic; NSA analysts discussed statistical techniques for de-anonymizing Tor users. Nation-state intelligence agencies with access to major network infrastructure are the adversaries Tor is least effective against.
Exit node monitoring: Tor encrypts traffic between the user and the exit node, but the exit node connects to the destination over the open internet. An exit node operator can monitor unencrypted HTTP traffic leaving through their node. Users who connect to HTTP (rather than HTTPS) sites through Tor and submit sensitive information are visible to the exit node operator.
Browser fingerprinting: Even when network anonymity is maintained, browser characteristics (fonts installed, screen resolution, JavaScript capabilities, timezone) can identify individual users across sessions. The Tor Browser is configured to reduce these fingerprints, but sophisticated fingerprinting can still distinguish users.
Malware and operational security failures: Tor does not protect users who are running malware, who log into identified accounts through Tor, or who make other operational security mistakes. Ross Ulbricht was identified not through Tor attacks but through ordinary investigation: he had used his real email address in early Silk Road forum posts.
End-to-end timing attacks: If an adversary can see traffic entering the Tor network from one location and traffic leaving to a destination, they can correlate timing patterns even without reading the content. This is difficult at small scale but feasible for intelligence agencies.
The Broader Anonymity Landscape
Tor exists within a broader ecosystem of anonymity technologies:
Myth: The “deep web” and the “dark web” are the same thing.
They are not. The deep web is simply everything search engines do not index, email inboxes, banking portals, paywalled databases, intranets, anything behind a login. It is the overwhelming majority of the web and almost entirely mundane. The dark web is a tiny subset reachable only through special software such as Tor, where sites use addresses (.onion) that resolve nowhere on the ordinary internet. All dark web is deep web; almost no deep web is dark web. Conflating the two makes a vast, ordinary space sound sinister. See Myths and Misconceptions.
JAP/AN.ON, developed at TU Dresden, was Tor’s most serious early competitor and was actually earlier: working code existed by 2000, three years before Tor’s network went live, and German media celebrated the “Java Anon Proxy” as a “virtuelle Tarnkappe” (virtual invisibility cloak). Its architecture was the philosophical opposite of Tor’s: instead of thousands of volunteer relays assembled into random paths, JAP routed traffic through a small number of trusted, partly fee-financed mix cascades. The trusted-operator model lost. Tor’s volunteer swarm scaled globally while JAP remained a German research project; it survives as the commercial spin-off JonDonym, a footnote next to Tor. The Dresden group’s Tor connection was direct: it ran Germany’s first Tor relay in 2003, partly to evaluate whether Tor could be integrated into its own system.
I2P (Invisible Internet Project), launched in 2003, provides a parallel approach using a “garlic routing” variant of onion routing. I2P is optimized for internal network services and is more commonly used for file sharing and internal communications among its user community.
Freenet, developed by Ian Clarke in 2000, provides a distributed file storage network where content is replicated across volunteer nodes, making censorship and deletion difficult. Freenet’s approach stores content; Tor’s approach routes traffic.
VPNs (Virtual Private Networks) provide privacy against ISP monitoring and simple traffic analysis by routing traffic through an operator’s servers, but require trusting the VPN provider, which may log traffic, comply with legal orders, or be compromised. Tor distributes trust across three independent nodes; compromise requires controlling multiple nodes simultaneously.
Zero-knowledge proofs and privacy-preserving computation technologies represent emerging approaches that provide verifiable properties without revealing underlying data, relevant for financial applications, identity systems, and other domains where anonymity and accountability must be balanced.
📚 Sources
- Goldschlag, Reed and Syverson, “Hiding Routing Information” — Information Hiding 1996, LNCS 1174, the original Naval Research Laboratory onion routing paper
- Goldschlag, Reed, and Syverson: Hiding Routing Information (1996), Information Hiding Workshop, Cambridge, source of the “obvious tension” and key-escrow passage
- Paul Syverson: Onion Routing — Brief Selected History, Syverson’s own chronology of the early years
- Paul Syverson: A Peel of Onion (2011), ACSAC keynote, includes the naming story
- Stefan Mey: Missing Link: 25 Jahre Anonymisierung mit Tor, eine Geschichte mit Widersprüchen — heise online (2020), history with interviews (Syverson, Köpsell), funding figures, German relay statistics
- The Tor Project: Financial reports, annual Form 990 filings behind the funding percentages
- Dingledine, Mathewson, and Syverson, Tor: The Second-Generation Onion Router (2004), the academic paper describing Tor’s design
- The Tor Project, official documentation, threat model, and annual reports
- NSA slides on Tor (via Guardian/Snowden) · Guardian coverage of NSA Tor de-anonymization efforts
- Silk Road and Ross Ulbricht investigation · Wired’s account of how the FBI identified Ulbricht despite Tor
- SecureDrop: anonymous document submission · Freedom of the Press Foundation’s Tor-based whistleblowing system
- CSO Online: “Dark web vs. deep web: What’s the difference?”, explainer distinguishing the unindexed deep web from the Tor-reachable dark web
- Facebook onion address — Wikipedia (facebookcorewwwi.onion launched Oct 31, 2014; v3 address from 2021)