NTP monlist: how time servers amplified DDoS attacks
From December 2013, attackers abused a diagnostic command in NTP time servers to multiply their attack traffic. How it worked, and how the internet cleaned up.

What to do now
- Update ntpd to the latest 4.2.8 release: since development version 4.2.7p26, ntpd no longer answers monlist requests.
- If you cannot update, add
noqueryto therestrict defaultlines for IPv4 and IPv6 in ntp.conf to block all status queries, or at least adddisable monitorto switch off monlist. - Test your public time servers from outside your network, for example with the Nmap script
ntp-monlist: a safe server returns an error or no reply. - Check routers, firewalls and other devices with a built-in time server too, and block NTP requests from the internet where no outside client needs them.
- If you run a network, drop packets with forged sender addresses at its edge, as BCP 38 describes, so that nobody in your network can launch such attacks.
- Year
- 2014
- CVSS 2.0 score
- 5.0 medium
- different addresses of vulnerable NTP servers in 15 weeks of scans
- 2,166,097
- addresses hit by attacks within 15 weeks, in 184 countries
- 437,000
- Reach met
Weekly scans of the whole internet found 1,405,186 vulnerable NTP servers on January 10, 2014, and 2,166,097 different addresses over 15 weeks (Taming the 800 Pound Gorilla, 2014).
- Mass exploitation met
Within 15 weeks, attacks hit 437,000 addresses in 11,558 networks and 184 countries with 2.92 trillion packets (Taming the 800 Pound Gorilla, 2014).
- Damage not met
No total of the damage exists, and the sources document no outage of critical services; at a regional network in Michigan, the attacks added more than 2 % to its traffic and raised the fees it paid for its own internet connection (Taming the 800 Pound Gorilla, 2014).
- Extraordinary response met
Researchers, CERTs and network operators joined the cleanup across countries: weekly internet-wide scans and notifications through CERTs and directly to operators accompanied a 92 % drop in vulnerable servers within about three months, with declines of 63–97 % in every region of the world (Taming the 800 Pound Gorilla, 2014); US-CERT and CERT/CC issued warnings (US-CERT, CERT/CC).
| Affected | ntpd, the time server software of the NTP project, and devices that use it |
|---|---|
| CVE | CVE-2013-5211 |
| CVSS vector | AV:N/AC:L/Au:N/C:N/I:N/A:P |
| Weakness (CWE) | CWE-20 |
| Fixed in | ntpd 4.2.7p26, a development version (April 24, 2010); the first stable version without monlist is ntp 4.2.8 (December 19, 2014) |
| Found by | Not named in the NTP project's notice; the flaw drew wide attention only through the attacks of December 2013 |
- 1Fix available
- 2Amid a wave of DDoS attacks, the flaw receives the number CVE-2013-5211+1346 days
- 3The first weekly scan of the internet finds 1,405,186 vulnerable servers+1357 days
- 4US-CERT warns of NTP amplification attacks+1360 days
- 5An attack of almost 400 Gbps from 4,529 NTP servers hits a target in Cloudflare's network+1388 days
- 6NTP traffic peaks at about 1 % of all internet traffic+1389 days
- 7106,445 vulnerable servers are left, 92 % fewer than in January+1455 days
- 8ntp 4.2.8 is the first stable version without monlist+1700 days
In December 2013, attackers began to misuse ordinary time servers for distributed denial-of-service (DDoS) attacks, which knock a target offline by flooding it with more traffic than its connection can carry. They used monlist, a diagnostic command in ntpd, the server software of the NTP project. NTP, the Network Time Protocol, keeps the clocks of computers and network devices in sync. A measurement study found vulnerable servers at 2.2 million internet addresses and counted 437,000 attacked addresses in 15 weeks.
How it worked
Time servers answer short requests from devices that want to set their clocks. For diagnostics, ntpd also kept a list of the clients that had contacted it most recently. The monlist command returned this list, up to 600 entries, to anyone who asked. According to US-CERT, the US government’s computer emergency team, older devices with NTP had the command switched on by default.
NTP uses UDP, a way of sending single data packets without first setting up a connection, so the server cannot check who really sent a request. An attacker writes the victim’s address into the request as the sender, and the server sends its answer there. Because a monlist answer can be far larger than the request, the attack is amplified: the attacker sends a little data, and the victim receives a lot.
US-CERT gives NTP an amplification factor of 556.9: the answer carries 556.9 times the data of the request, counting only the content of the packets. For DNS, the internet’s address system, it gives 28 to 54. The study described below counted whole packets and found that a typical vulnerable server returned about 4 times the data of the request, and a quarter at least 15 times. A few “mega amplifiers” answered a single packet with gigabytes, the largest with more than 136 gigabytes in one day, probably because of a network loop.
Because the floods came from thousands of legitimate servers, they were hard to block. The servers were not broken into; they were used as tools against others.
- Attackersends a tiny monlist request with the victim's address as sender
- NTP serveranswers with its list of up to 600 recent clients
- Replymany packets, far larger than the request
- Victimis flooded with traffic it never asked for
Reach and damage
The most detailed measurements come from “Taming the 800 Pound Gorilla”, a 2014 study by researchers at the University of Michigan, Merit Network, Colorado State University and the University of Illinois. It combines traffic data from the security firm Arbor Networks, which covers a third to a half of all internet traffic, with weekly scans of the internet and data from two regional networks.
In November 2013, NTP made up about 0.001 % of the traffic in Arbor’s data. By mid-February 2014 it had reached about 1 %, more than DNS, and it peaked on February 11. In February and March, most attacks of more than 2 Gbps (gigabits per second) used NTP; three months earlier, only 0.07 % of all attacks had involved it.
The Open NTP Project began to scan the whole internet every week on January 10, 2014. Its first scan found 1,405,186 servers that answered monlist requests. Over 15 weeks, the scans saw 2,166,097 different addresses, partly because 13–35 % of the servers were end-user computers, such as home PCs, whose addresses can change.
| January 10, 2014 | 1,405,186 | |
|---|---|---|
| January 24, 2014 | 677,112 | |
| February 14, 2014 | 235,370 | |
| March 21, 2014 | 110,565 | |
| April 18, 2014 | 106,445 |
Selected weekly scans of the whole internet by the Open NTP Project. Source: Taming the 800 Pound Gorilla (2014).
The monlist lists also record the forged sender addresses, that is, the victims. In 15 weeks, the researchers found 437,000 attacked addresses in 184 countries, hit with 2.92 trillion packets, about 1.2 petabytes of data. Because a list typically covered only the last two days before a scan, they estimate the real numbers at about 3.8 times higher. About half of the victims were end-user computers, and many attacks targeted the network ports, a kind of numbered door, that online games use; the authors conclude that a large share of the attacks was aimed at gamers.
On February 10, 2014, an attack on a target in Cloudflare’s network set a record for NTP at the time. Cloudflare, a company that protects websites against such attacks, reported that it peaked just under 400 Gbps and came from 4,529 NTP servers in 1,298 networks.
No total of the damage exists, and the sources document no outages of critical services such as hospitals or power supply. Networks that carried the floods paid too: at Merit, a regional network in Michigan, the attacks added more than 2 % to its total traffic, which raised the fees it paid for its own internet connection.
The fix and the response
The NTP developers had removed monlist from ntpd long before, in development version 4.2.7p26 of April 24, 2010, and replaced it with a newer command, mrulist. But the stable series, version 4.2.6, kept monlist; the first stable version without it, ntp 4.2.8, appeared only on December 19, 2014. On December 30, 2013, a request on a public security mailing list pointed to “a recent rash of DDoS involving the monlist functionality”, and the flaw received the number CVE-2013-5211 the same day.
In January 2014, CERT/CC at Carnegie Mellon University published a vulnerability note, and US-CERT an alert. Their advice: update ntpd, or switch off the queries with one setting in the configuration file. ICS-CERT, the US team for industrial control systems, warned as well.
The vulnerable servers disappeared quickly. Two weeks after the first scan, fewer than half were left. By March 21, about 110,000 remained, and the number hardly moved after that: on April 18, it stood at 106,445, 92 % fewer than in January. The study praises the “community response”: the Open NTP Project published its counts every week, researchers notified operators through CERTs (computer emergency response teams) and directly, and many networks felt the attacks in their own traffic. The authors consider it likely that the notifications helped, but say that cause and effect cannot be proven.
| North America | 97 % | |
|---|---|---|
| Oceania | 93 % | |
| Europe | 89 % | |
| Asia | 84 % | |
| Africa | 77 % | |
| South America | 63 % |
Decline in the number of servers that answered monlist requests, from January to April 18, 2014. Source: Taming the 800 Pound Gorilla (2014).
The cleanup was far faster than for open DNS resolvers, servers that look up addresses for anyone and can be abused in the same way. But it was not complete: about 4 million NTP servers still answered another query, version, which can also be abused, though rarely with such large replies. That group shrank by only 19 %.
The National Vulnerability Database rates the flaw 5.0 out of 10 on the older CVSS version 2, “medium”, and gives no score on version 3. The score is not higher because an attacker can neither read nor change data on the server: the flaw only affects availability, mostly that of others.
Read next: ConfickerPrevious: HeartbleedOverview: Vulnerabilities