Malware & ransomware

IoT Botnet Explained: How Mirai Works and How to Stop It

Your router or camera could be part of a botnet without you knowing. Here is how IoT botnets recruit devices, what the Mirai attacks showed, and how to protect your network.

Cysoro Security TeamPublished · 8 min read
MALWARE & RANSOMWARE IoT Botnet Explained How Mirai recruits routers and cameras — and how to stop it. C2 CYSORO.COM
Quick answer

An IoT botnet is a network of internet-connected devices such as routers, cameras and DVRs that malware has infected and now controls remotely. Attackers use the infected devices together to launch distributed denial-of-service attacks, send spam or mine cryptocurrency. The best-known example is Mirai, which in 2016 enslaved hundreds of thousands of devices using just 62 default username and password pairs.

Key takeaways

  • IoT botnets mostly recruit devices through default passwords, not advanced exploits.
  • Mirai turned over 380,000 devices into a botnet that launched a 620 Gbps DDoS attack in 2016.
  • Change default passwords, update firmware and reboot an infected device while it is offline.

Your router, your doorbell camera and your smart TV all run software, connect to the internet and usually have a password you never changed. That combination is exactly what botnet operators look for.

What is an IoT botnet?

An IoT botnet is a network of internet-connected devices that malware has infected and that an attacker controls remotely, usually to launch distributed denial-of-service (DDoS) attacks. The devices can be routers, cameras, DVRs, printers or smart TVs, and their owners rarely notice anything wrong.

The word botnet combines robot and network. Each infected device is a bot. A command-and-control server tells every bot what to do, and because there can be hundreds of thousands of them, their combined traffic can overwhelm almost any target. CISA's Mirai alert describes IoT devices as particularly susceptible to malware, and warns that protecting them is critical.

Unlike a virus on a PC, botnet malware on a camera or router has no screen to show a warning and no user to click anything. It just sits there, quietly waiting for orders, while the device keeps working normally. That silence is why IoT botnets can grow so large before anyone notices.

How does an IoT botnet work?

An IoT botnet works in four stages: scan, infect, report home, and attack. Infected devices scan the internet for new targets, log in with weak credentials or an exploit, report back to a command server, and then flood a chosen target on command.

The scan stage is automated and constant. A bot probes internet addresses looking for devices with remote login ports open, especially Telnet on ports 23 and 2323. When it finds one, it tries a list of default usernames and passwords. Mirai used only 62 pairs, yet CISA says that short dictionary was enough to access hundreds of thousands of devices.

Once inside, the bot installs itself in the device memory and contacts its command-and-control server. From then on it waits. When the operator picks a target, every bot sends traffic at once. Individually each device is weak, but together they can push hundreds of gigabits per second.

How an IoT botnet recruits a device1. ScanBots probe the internetfor open Telnet ports2. InfectDefault password tried;malware loads in memory3. Report homeBot contacts commandand control server4. AttackAll bots flood the targetat once (DDoS)Mirai needed no advanced exploit for most devices: a factory password was enough.CISA alert TA16-288A: the bot tried 62 common default username and password pairs.
The four stages of IoT botnet recruitment, from scanning to a coordinated DDoS attack. Illustration by Cysoro.

Some botnets do more than DDoS. Operators also rent out their bots for spam, click fraud, credential stuffing and cryptocurrency mining. The business model is the same either way: recruit cheaply, control centrally, and sell the combined power.

What happened with Mirai in 2016?

Mirai is the case that made IoT botnets famous. In September and October 2016 it launched some of the largest DDoS attacks ever recorded, using home routers, cameras and DVRs that still had factory passwords.

On September 20, 2016, the security blog Krebs on Security was hit with an attack exceeding 620 gigabits per second, one of the largest on record at the time. CISA reports that the purported Mirai author claimed more than 380,000 IoT devices were enslaved in that attack. Days later, a separate Mirai attack on the French host OVH reached at least 1.1 terabits per second, and may have been as large as 1.5 Tbps.

In October 2016, a Mirai variant was used in the attack on DNS provider Dyn, which disrupted access to major sites including Netflix, Twitter and CNN. The FBI issued guidance five days later urging organizations to change default credentials and prepare DDoS response plans.

The source code was published online at the end of September 2016, which CISA said opened the door to more widespread use. Variants have circulated ever since, some adding exploits for router flaws such as the SOAP vulnerability on TCP port 7547 that CISA documented in November 2016.

IoT botnet vs PC botnet: what is the difference?

The main difference is the device. A PC botnet is built from infected computers, while an IoT botnet is built from smart devices. IoT devices are easier to recruit in bulk, harder for owners to notice, and harder to clean, but each one is far weaker than a PC.

FeatureIoT botnetPC botnet
DevicesRouters, cameras, DVRs, smart TVsWindows and Mac computers
How it spreadsDefault passwords, open Telnet, firmware flawsPhishing, malicious downloads, exploits
Owner awarenessVery low: no screen, no warningHigher: slow PC, pop-ups, antivirus alerts
CleanupReboot while offline, change password, update firmwareAntivirus scan, removal tool, reinstall if needed
Typical sizeHundreds of thousands of weak devicesThousands to tens of thousands of stronger PCs
Main useDDoS attacksDDoS, spam, banking theft, ransomware delivery

For a deeper look at how malware gets onto computers, read our guide to free malware removal, which covers the cleanup tools that work when a PC is infected.

How can you tell if a device is part of a botnet?

There is no single alert that says your camera joined a botnet. Look for a pattern instead: unexplained slow internet, a router that runs hot or reboots itself, and traffic spikes when nobody is using the network.

Check these signs one by one:

  • Internet speed drops sharply, especially upload speed, for no clear reason.
  • The router admin page shows devices you do not recognize, or settings you did not change.
  • You can no longer log into a camera or router with the password you set.
  • Your ISP warns you about unusual traffic, or your IP address ends up on a blocklist.
  • Devices feel warm, fans run constantly, or a camera reboots on its own.

On a home network, log into the router and review the connected devices list and the traffic log. CISA advises monitoring TCP ports 23 and 2323 for Telnet login attempts, and watching port 48101, which infected devices use to send scan results to the attacker. If you run a small business, your firewall or router logs are the first place to look.

Keep your home network itself in shape too. Our guide on how to secure your Wi-Fi walks through router settings that cut off the easiest paths into your network.

How do you remove a device from an IoT botnet?

Follow CISA's removal steps in order: disconnect the device, reboot it while offline, change its password, then reconnect. Skipping the password change is the most common mistake, because the device can be reinfected within minutes.

  1. Disconnect the device from the network and the internet.
  2. While it is offline, reboot it. Mirai-style malware lives in memory, so a reboot clears it.
  3. Change the default password to a strong, unique password before reconnecting.
  4. Check for a firmware update from the manufacturer and install it.
  5. Reconnect the device and watch its traffic for a day or two.
  6. If the device cannot be updated or its password cannot be changed, replace it.

For a router, also disable remote administration and Universal Plug and Play (UPnP) unless you have a specific need for it. CISA lists disabling UPnP as a preventive step, because it can expose devices to the internet without you realizing it.

If many devices are affected, or the infection returns after a clean reboot and password change, the firmware itself may be compromised. At that point a factory reset followed by a firmware reinstall from the vendor is the safer path, and for old devices that no longer receive updates, replacement is the right call.

How do you prevent IoT devices joining a botnet?

Prevention is mostly configuration, not new software. Change every default password, install firmware updates promptly, and keep IoT devices on a separate network from your computers and phones.

Start with the basics CISA and NIST recommend:

  • Change all default usernames and passwords before a device goes live. Default credentials for most devices are easy to find online.
  • Update firmware as soon as the manufacturer releases a patch.
  • Disable UPnP on your router unless you absolutely need it.
  • Buy devices from vendors with a reputation for shipping security updates.
  • Turn off remote access features you do not use, such as Telnet and remote admin.
  • Put IoT devices on a guest or separate network segment, so a compromised camera cannot reach your laptop.
Six defenses that stop most IoT botnetsChange every default passwordInstall firmware updates promptlyDisable UPnP and TelnetSeparate IoT network segmentTurn off unused remote accessReplace devices with no updatesBased on CISA preventive steps and NIST SP 1800-15 guidance for home and small-business IoT.
Six practical defenses against IoT botnets, based on CISA and NIST guidance. Illustration by Cysoro.

For small businesses, NIST SP 1800-15 describes a stronger approach called Manufacturer Usage Description, or MUD. It lets a network automatically allow only the traffic a device actually needs and block everything else, which limits what a compromised device can do. Even without MUD, a separate IoT network and a firewall rule that blocks outbound Telnet will stop most recruitment attempts. The NIST project page documents the approach in full.

When you buy a new device, check whether the vendor still publishes firmware updates for that model. A cheap camera with no update path is a future botnet member. Paying a little more for a vendor that patches is cheaper than cleaning up after an incident.

Who is most at risk from IoT botnets?

Everyone with a router is at risk, but small businesses and homes with many smart devices carry the most exposure. Each device is another door, and the weakest one decides the security of the whole network.

Small businesses are attractive because their networks often mix guest Wi-Fi, point-of-sale systems and cameras on one flat network, with nobody assigned to patch the cameras. A single infected DVR can become a launchpad for attacks and a foothold for deeper intrusion.

Home users are at risk in a quieter way. Your devices can attack others without you ever noticing, and your IP address can be blocked by services that see the attack traffic. If you work from home, that can also mean your work connection suffers when the botnet floods a target.

If you run a small business, use our small business cybersecurity checklist to review the basics, including network segmentation and update routines that cover IoT gear as well as computers.

The bottom line

IoT botnets are not a sophisticated mystery. They succeed because millions of devices still use factory passwords and never get updated. Mirai proved in 2016 that 62 default passwords were enough to build a botnet of more than 380,000 devices and launch attacks above 620 Gbps.

Change the defaults, update the firmware, and separate your IoT devices from your main network. If a device is already infected, disconnect it, reboot it offline, change its password, and only then reconnect. Run a quick check on your own connection with our what is my IP tool while you review your router, and treat every smart device as a computer that needs the same care.

Frequently asked questions

What is an IoT botnet?

An IoT botnet is a group of internet-connected devices, such as routers, cameras, smart TVs and DVRs, that malware has infected. The attacker controls all of them from a command-and-control server and can order them to attack a target at the same time, usually with a distributed denial-of-service attack.

How do devices join an IoT botnet?

Most join because they still use a factory default username and password, or because unpatched firmware leaves a known weakness open. Mirai scanned the internet for devices with Telnet open and tried a short list of 62 common default credential pairs. Later variants also exploited flaws such as a SOAP vulnerability on TCP port 7547.

Can a reboot remove an IoT botnet infection?

Yes, for Mirai-style malware that lives only in memory, a reboot clears it. CISA advises disconnecting the device first, rebooting it while offline, changing the default password to a strong one, and only then reconnecting. If you reconnect before changing the password, the device can be reinfected quickly.

How can I tell if my router or camera is in a botnet?

Common signs are unexplained slow internet, a router that reboots or overheats, outbound traffic spikes at odd hours, and devices you cannot log into because the password changed. On a home network, check the router admin page for unknown connected devices and look for repeated login attempts on ports 23 and 2323.

What damage can an IoT botnet cause to a home or small business?

An infected device can be used to attack others, which may get your IP address blocked or flagged. For a business, a botnet-driven DDoS attack can take a website or service offline and cause real financial harm. CISA warns that such attacks can severely disrupt communications and cause significant financial losses.

Are IoT botnets still a threat in 2026?

Yes. The Mirai source code was published online in September 2016, so many variants still circulate today, often with added exploits. The underlying weakness has not gone away: millions of devices still ship with weak defaults and are rarely updated.

Do I need antivirus on my router or camera?

Most routers and cameras cannot run antivirus software. Protection comes from configuration instead: change default credentials, install firmware updates promptly, disable UPnP unless you need it, and put IoT devices on a separate network from your computers and phones.

What is the difference between an IoT botnet and a regular botnet?

A regular botnet is usually made of infected Windows PCs, while an IoT botnet is made of smart devices such as routers and cameras. IoT devices are easier to recruit in bulk because they often have weak defaults and no screen to show a warning, but they are also weaker individually, so attackers need far more of them.

Sources

  1. CISA — Heightened DDoS Threat Posed by Mirai and Other Botnets
  2. NIST NCCoE — Securing Small-Business and Home IoT Devices (SP 1800-15B)
  3. Center for Internet Security — The Mirai Botnet: Threats and Mitigations
  4. NIST CSRC — Mitigating IoT-based Distributed Denial of Service (DDoS)
Written & fact-checked byCysoro Security Team

The engineers and analysts who build Cysoro's domain scanner, email-authentication checks and free security tools. We test what we write about every day — SPF, DKIM, DMARC, certificates, look-alike domains and phishing — and check each guide against the relevant standards, government guidance and vendor documentation.

  • Email authentication
  • Phishing & BEC
  • Domain & DNS security
  • Small-business security

Checked against CISA alert TA16-288A on Mirai, NIST SP 1800-15 on mitigating IoT-based DDoS, and the Center for Internet Security Mirai analysis.

How we write and fact-check →

Free tools for this topic

No account needed.

See where your domain stands

Free for up to 3 domains. No card, no installs.

Start free