Writing / incident report

INC-002: A second botnet evicted the first and took over Honeypot #2

Honeypot #2 · Incident date 2026-11-16 (UTC) · Analyst: Estul Lachin

Final report · 48-hour observation closed 2026-11-18 08:00 UTC · victim stopped 2026-11-27

Summary

At 08:03 UTC on 2026-11-16, a second botnet guessed the bait account's new weak password on Honeypot #2. Within three minutes it killed the miner left by the first intruder (INC-001); a minute later it deleted that group's SSH keys and planted its own. Over the next three hours it installed a disguised trojan, an XMRig miner and at least four kinds of persistence.

Its scanner then tried SSH on 509 internal addresses, including our gateway. Every packet was dropped on the victim, and the scanner later ran the 1 GB server out of memory and was killed by the kernel. The attacker never got root (sudo and su were refused) and no traffic got out.

This time detection was automatic: a rule added after INC-001 raised a High incident in Microsoft Sentinel. The investigation also found a blind spot, which a new rule closed the same day.

ItemFinding
SeverityMedium: an expected break-in inside a honeypot, with no spillover
Initial accessSSH with a common weak password (the phase-2 bait), guessed after about 54 minutes of brute force
ObjectiveCrypto mining; most likely also to use the server as a base for attacking others (it brought an SSH scanner and a password list)
Relation to INC-001Evicted the first group: killed its miner, removed its two SSH keys
Privilege escalationNone: sudo said "user NOT in sudoers", su failed
EgressNone: mining pools, C2, downloads and outbound brute force all blocked
Lateral movementAttempted and failed: SSH to 509 internal addresses, dropped on the victim
DetectionRules 100210 (High incident #603), 100211 and 100212; new rule 100202
Antivirus viewMiner 28/64 engines; trojan 4/52; scanner 1/51 (VirusTotal hash lookups)
DispositionNot cleaned; observed for 48 hours, then left running until 2026-11-27. Evidence snapshot taken and victim stopped; rebuilt from a clean image for the next phase

Detection

Rule 100210, added after INC-001, fires on any password login to the bait account. It matched at 08:03:19 and Sentinel raised High incident #603 automatically. Two minutes later, rule 100211 raised Medium incident #604 for the cron change. Nobody was watching at the time; the incidents were waiting at the next routine check.

Microsoft Sentinel incident 603: High severity, rule 100210 on web01, source IP 109[.]160[.]32[.]162, with related incidents 604, 525 and 595.
Figure 1. Incident #603, raised automatically. IP addresses are defanged and the owner name is replaced in this image.
RuleLevelWhat it caught in this incident
10021013Password logins at 08:03:19 and 08:05:53
10021112Cron rewritten; then again about every 12 hours
10021212Changes under /home/admin: the rival's miner deleted, authorized_keys replaced, persistence and decoy files
auditd execve—Every program the attacker ran, and whether it ran as root
510812The server running out of memory at 11:00

What was missed: the scanner's SSH attempts against the gateway. The victim's own firewall dropped them, so they were filed as routine blocked traffic and rule 100200 stayed silent (see Detection improvements).

Timeline (UTC, 2026-11-16)

The bait password had been changed about three hours earlier. From login to evicting the rival took about two and a half minutes; the rest of the setup took three hours.

TimeSourceEventEvidence
07:00–08:0695[.]216[.]80[.]157Another address brute-forcing at the same time, without successWazuh 5551, 5763
07:09–08:02109[.]160[.]32[.]162Brute force, mostly with user names that do not existWazuh 5712, 5551
08:03:19109[.]160[.]32[.]162Logs in as admin with the bait password100210 → #603
08:03sessionSurveys the machine: uname, uptime, nproc, lspci, lscpu, one curlauditd
08:05:47sessionEvicts the rival: killall5, pgrep, kill; deletes INC-001's .dhpcd; rewrites cron100211 (#604), 100212
08:05:53109[.]160[.]32[.]162Second login100210
08:06:36sessionTries sudo to run /var/tmp/fLSJqZDe as root: refused. su to root: failedjournal
08:06:40sessionReplaces authorized_keys: INC-001's two keys gone, one new key left100212
08:06sessionStarts the scanner /var/tmp/.x/network; runs passwd three timesauditd
08:06:46scannerFirst SSH attempt to the internal network, blocked on the victim100201
08:16sessionStarts the trojan under the fake name httpd -DFOREGROUNDauditd; ps
about 08:32sessionStarts the same trojan again as /var/tmp/.X189 under the fake name mysqld, then deletes the fileauditd; ps
08:40–11:05—Persistence and decoy files: a systemd user service, shell start-up files, a desktop autostart entry, program copies100212
about 09:27—XMRig miner 6ad23bdc starts (from the process's run time)ps
11:00:13kernelOut of memory: the kernel kills the scanner. Scanning stopsjournal; 5108
11-16 to 11-18—The trojan moves to a new random folder under /var/tmp and rewrites cron about every 12 hours100211
11-18 08:00—48-hour observation ends: no return visits, no third group, no root—

What the attacker did

Compared with the careless script in INC-001, this group was organised: clear out the competition first, then hold the machine with several layers of persistence and disguise, and bring a scanner to spread further.

Terminal output: sudo refused because admin is not in sudoers, su authentication failure, and authorized_keys now containing a single RSA key labelled ElPatrono1337.
Figure 2. Root refused twice; the rival's backdoor keys replaced by a single new key.
Process list showing httpd and mysqld names pointing to a hidden desktop metadata file and a deleted file in /var/tmp, and a randomly named miner.
Figure 3. Three processes, three disguises.
Archive listing: seven 41 MB files with system-like names and dates from 2025-10 to 2026-05, plus our two memory copies dated 2026-11-16.
Figure 4. One program copied seven times, with forged dates.

MITRE ATT&CK mapping

TacticTechniqueIn this incident
Credential AccessT1110.001 Password GuessingGuessed the bait password after about 54 minutes
Initial AccessT1078 Valid AccountsTwo logins as admin
DiscoveryT1082 System Information Discoveryuname, uptime, nproc, lspci, lscpu
DiscoveryT1057 Process Discoverypgrep to find the rival's processes
DiscoveryT1046 Network Service DiscoveryScanned port 22 on 509 internal addresses
Lateral MovementT1021.004 SSH (failed)Brought a password list to log in to other machines; every attempt blocked
ExecutionT1059.004 Unix Shellbash -c commands; nohup for background jobs
Privilege EscalationT1548.003 Sudo (failed)sudo refused; su failed
PersistenceT1053.003 CronEvery minute, @reboot, daily, monthly, plus every 30 minutes
PersistenceT1543.002 Systemd ServiceUser service gvfs-metadata.service
PersistenceT1547.013 XDG Autostart Entries.config/autostart/.gnome-software-service.desktop
PersistenceT1546.004 Unix Shell Configuration Modification.profile, .bashrc, .bash_profile
PersistenceT1098.004 SSH Authorized KeysReplaced the rival's two keys with its own
Defense EvasionT1036.005 Match Legitimate NameProcesses named httpd -DFOREGROUND and mysqld --defaults-file=…
Defense EvasionT1070.006 TimestompSeven copies dated 2025-10 to 2026-05
Defense EvasionT1070.004 File DeletionDeleted its own files after starting them; deleted the rival's miner
Defense EvasionT1027.002 Software PackingAll three samples UPX-packed (VirusTotal tags)
ImpactT1496 Resource HijackingXMRig miner; the trojan holds 220 MB of memory

Two behaviours fall outside ATT&CK but are worth noting. Turf war: removing a competitor's miner and keys within minutes is common between mining botnets. Moving house: the trojan relocates to a new random folder about every 12 hours, so tools that look for a fixed path miss it.

Impact assessment

No root, no traffic out, no contact with the gateway. The impact stayed inside the admin account's permissions and the server's memory and CPU.

Privilege escalation: none. The evidence comes from auditd and the journal, which are shipped off the victim:

Egress: none. Between 08:00 and about 16:40 on 2026-11-16, the victim's tripwire blocked 22,417 outbound connections to the destinations below. Not one succeeded.

DestinationAttemptsMost likely
139[.]99[.]123[.]196: 443, 3333, 802,816 / 2,809 / 1,992Mining pool (3333 is a common pool port)
85[.]11[.]167[.]190, 209[.]99[.]187[.]94: 4432,027 / 2,024Backup pool or C2
51[.]161[.]204[.]231, 147[.]189[.]131[.]67, 147[.]189[.]131[.]206, 166[.]1[.]249[.]218: 80802,027 / 2,018 / 2,016 / 1,069C2 or proxy
91[.]92[.]47[.]220: 2221,527Suspicious (non-standard SSH port)
107[.]167[.]92[.]130, 107[.]167[.]83[.]34: 4431,072 / 1,020INC-001's pool; still contacted until 16:40, reason not confirmed

Lateral movement: attempted, all blocked. From 08:06 until the kernel killed it at 11:00:13, the scanner tried SSH on 509 internal addresses (the last blocked attempt reached us at 11:05:33 because monitoring was running about five minutes behind), including 132 attempts at the gateway's two addresses. The victim's own firewall dropped every packet, and without root the attacker could not turn that firewall off. The cloud firewall is a second layer behind it.

Gateway query results: 63 and 69 blocked SSH attempts at the gateway's two internal addresses, scanning from 08:06 to 11:05, 509 distinct internal addresses.
Figure 5. The scanner turned on the internal network and never got out of the victim.

Resources: memory at the limit. The victim has 969 MB and no swap. The trojan holds 220 MB and the scanner peaked at about 160 MB, so at 11:00:13 the kernel's out-of-memory killer stopped the scanner. Our monitoring agent and admin access are set to be killed last, and kept running. The miner used under 1.5% CPU, most likely because it could not reach any pool.

Kernel log: out of memory, killed process network; the process list afterwards shows the fake httpd, fake mysqld, the miner and an old admin SSH session.
Figure 6. The attacker's own scanner ran the server out of memory and was killed.

Indicators of compromise

Hashes were only searched on VirusTotal; no samples were uploaded.

TypeValueRole
IPv4109[.]160[.]32[.]162Brute force and successful logins
IPv495[.]216[.]80[.]157Parallel brute force, no success
IPv4Outbound destinations in the egress tablePools, C2 or proxies, all blocked
SHA2566b9e912f408b96ac92b400e8c4f373626ff810085008a9eddba6957520bd9edfTrojan, 41,057,364 bytes (fake httpd / mysqld); VirusTotal 4/52
SHA256e013414f6b93db4b29a47979b8d2a64a8e7c08c86e5f285d8efded4a57392635XMRig miner 6ad23bdc; VirusTotal 28/64
SHA25693077a9a0e0ccade17264f2ba27395d563a683b5f83abc17bb46d259b89e7bf8Scanner .x/network, 44,919,928 bytes; VirusTotal 1/51
Path/var/tmp/.x/ (network, pass, iplist, bios.txt)Scanner kit
Path~/.local/share/gvfs-metadata/home, /var/tmp/.X189 (deleted) and other copiesTrojan copies with forged dates
Path/var/tmp/<random>/99045aa5, .cCron entry points; the folder changes about every 12 hours
Path~/.config/systemd/user/gvfs-metadata.service, ~/.config/autostart/.gnome-software-service.desktopPersistence
SSH keySHA256:AkrAM6Cdbkqok1OHU527WzpYGQqPQJrubcEP9Dlj7yI (RSA 2048, comment ElPatrono1337)Backdoor
VirusTotal results: INC-002 miner 28 of 64, INC-001 miner 32 of 64, INC-002 trojan 4 of 52, INC-002 scanner 1 of 51.
Figure 7. Antivirus knows the miners, but barely sees the tools that did the real work.

Response and evidence handling

As in INC-001, the plan was to observe, not clean. One predefined isolation trigger was hit along the way. We weighed it and chose not to isolate, and record that decision openly here.

  1. Safety first. Confirmed the agent was online, rule 100200 had not fired and no attacker program ran as root before digging in.
  2. Read-only investigation over the WireGuard management channel (ps, ls, journalctl, crontab -l, ssh-keygen -lf). The attacker's command history came from Wazuh alerts on the gateway.
  3. Evidence. Archived /var/tmp, /home/admin, the crontab, and copies of the three running programs taken from /proc/<pid>/exe. The mysqld file had already been deleted and was recovered from memory. Nothing was extracted or run; hashes were computed by streaming files out of the archive.
  4. Closed the detection blind spot the same day (rule 100202).
  5. Observed for 48 hours, until 2026-11-18 08:00 UTC: no return visits, no third group, no root.

The isolation decision. Our rule was to isolate if the victim probed the gateway. The scanner did aim at the gateway's addresses, but every packet died on the victim. All three layers held: no root, the victim's firewall, and the cloud firewall. We did not isolate. We narrowed the trigger to "a probe actually reaches the gateway (rule 100200) or any sign of root", and added rule 100202 so that this kind of attempt raises an alert from now on.

Detection improvements

Why rule 100200 stayed silent: it only matches the gateway's own firewall log, so it fires only when a probe actually reaches the gateway. These probes were dropped earlier, on the victim, and were filed as routine blocked traffic. The earlier a packet is stopped, the less this rule saw.

Rule 100200 definition matching only VICTIM- gateway logs, and a wazuh-logtest run showing a real scan log line now matching new rule 100202 at level 12.
Figure 8. The blind spot and the fix, tested against a real line from the scan.
IDChangeVerification
100202New rule, level 12: a blocked connection from the victim to any internal 10.x address. At most one alert per 15 minutes, so a scan cannot flood Sentinel; the rest stay logged as rule 100201wazuh-analysisd -t passes; wazuh-logtest on a real scan line matches 100202 at level 12
Isolation triggerNarrowed to rule 100200 (a probe reaches the gateway), any sign of root, or the agent or management SSH going offline—

Rule 100202 has not fired since: the scanner never came back after the kernel killed it. Its end-to-end path into Sentinel is therefore still to be confirmed. It did not fire before the victim was stopped on 2026-11-27; it will be tested on the rebuilt victim. The rules added after INC-001 all proved themselves: 100210 raised the High incident, and 100211 and 100212 recorded every persistence step.

After the observation window

The victim stayed online and uncleaned from the end of the 48-hour window (2026-11-18 08:00 UTC) until 2026-11-27. Nobody new logged in, and there was no sign of root.

WhatSeen
PersistenceThe cron entry points under /var/tmp/<random>/ moved to a new folder about every 12 hours, through 2026-11-27
A long sessionThe SSH session opened with INC-001's planted key on 2026-11-16 04:06 (from 118[.]36[.]203[.]94) stayed open until 2026-11-22 17:08: 6.5 days
New files, 2026-11-22Copies in ~/.local/bin named after desktop components (pipewire-pulse, pipewire, gnome-keyring-daemon, dbus-daemon); .bashrc, .profile and .bash_profile changed. The names follow the pattern of the trojan copies under gvfs-metadata. Which process wrote them is not yet established
Login attemptsBrute force on admin continued and failed: the attacker had changed the password. 118[.]36[.]203[.]94 was still trying on 2026-11-27
Rule 100202Did not fire: no internal scan in this period

Closed on 2026-11-27: evidence snapshot at 18:20 UTC (the original, never to be booted), victim stopped at 18:24 UTC. Rule 100202 will be tested on the rebuilt victim before it goes online.

Lessons learned

The programs that did the real work were almost invisible to antivirus (4 and 1 detections). Behaviour monitoring caught them: auditd recorded every program run, file integrity monitoring recorded every persistence file, and the egress tripwire recorded every attempt to get out.

What worked

What to improve

Next steps