When the RMM platform you approved and rely on is compromised, the attacker inherits a signed, trusted agent running as SYSTEM or root on every managed device, plus the scripting engine to use it. Entry usually comes through a stolen technician login, a leaked API key, an unpatched internet-facing RMM server, or a breach of the provider's hosted service. This playbook is for the team that operates the RMM, whether an internal IT department or a managed service provider running it for clients, and for incident responders supporting them. It covers only the compromise of a legitimate, approved platform. A rogue or unapproved remote access tool on a device is a different incident, handled in the Unauthorised Remote Monitoring and Management Tool Playbook; if you are the customer of a provider whose RMM was breached, use the Compromised MSP Playbook. Hardening before an incident is in the RMM Tool Security Guide. The page is vendor-neutral; confirm feature names in your own product's documentation.
Key takeaways
- Stop the scripting engine first. Pause every scheduled script, policy and automation task, and block new remote sessions, before anyone starts investigating.
- Cut the agents off from the server, not from your EDR. Block agent check-in at the network or host firewall so the attacker loses reach while your EDR channel stays open.
- Everything run in the window is suspect. Each script, file transfer and remote session needs an owner and a ticket, or it is investigated on every device it touched.
- The RMM's credentials reach past the RMM. Technician accounts, API keys, stored device credentials, domain accounts used for deployment and backup or documentation integrations all need rotation.
- Rebuild the server and re-enrol agents with new trust. An on-premises server or relay that may have been modified is rebuilt from clean media, not patched in place.
Why an RMM compromise is different
MITRE ATT&CK describes T1072 Software Deployment Tools as access to enterprise-wide endpoint management software that may enable remote code execution on all connected systems, for lateral movement or for effects such as wiping every endpoint. An RMM adds two things a patch tool usually lacks: interactive remote control (T1219.002 Remote Desktop Software, performed through software you approved) and, for providers, reach into many separate client networks at once (T1199 Trusted Relationship). The agents are allowlisted, signed and excluded from many security controls, so payloads delivered through them look like routine administration. The BeyondTrust breach shows how one stolen API key for a hosted remote support service was used to reset local application account passwords and reach customer workstations; the lesson for operators is that the platform's own keys are tier-zero credentials.
How the compromise shows up
| Signal | Where you see it | What it can mean |
|---|---|---|
| A script or job run against many devices that no technician raised | RMM job and script history, audit log | Payload distribution (T1072); the joint remote access guide uses pushes to 10 or more devices within an hour as a step-up trigger |
| Remote sessions by an unknown technician, out of hours or to servers technicians rarely touch | Session log, recordings | Stolen technician account (T1078) |
| New technician accounts, API keys, roles or MFA resets | RMM audit log, identity provider logs | Persistence ahead of a wider push (T1098) |
| The RMM agent spawning shells, downloading binaries or creating services | EDR process trees; Windows event 7045 for new services | Tool transfer and persistence (T1105, T1543.003) |
| Agent policy changes that alter EDR, firewall or backup settings | RMM policy history, EDR console | Defence impairment before encryption (T1685, T1490) |
| Bulk file transfers from devices to the RMM | RMM transfer log, network flow data | Data theft through the trusted channel |
| Exploitation attempts or new files on the RMM server | Web server and application logs, EDR on the server | Server-side compromise; check vendor advisories |
| Provider security notice or forced shutdown of the hosted service | Provider advisories, account team | Compromise outside your tenant |
Triage: the first hour
- Is anything running now? List active sessions, running and scheduled scripts, and pending policy deployments. Active mass execution means containment step 1 immediately.
- Where did it start? Technician account and SSO, an API integration such as ticketing or documentation, the self-hosted server or relay, or the hosted service.
- What can the RMM reach? Workstations, servers, domain controllers, hypervisors, backup servers, network devices and, for providers, every client tenant. Domain controllers, backup servers or multiple clients in scope raise severity at once.
- Which credentials does it hold or use? Stored device and domain credentials, local administrator credentials, the RMM's own API keys, and integration tokens for backup, documentation, ticketing and cloud management.
- What ran in the window? Export script history with content, targets and the account that ran each job, plus session and file transfer logs. Do this before containment changes anything.
- Who must be told now? Providers: affected clients, under the notification terms in their contracts. Internal teams: the business owners of critical servers in scope.
Blast radius by component
This is NHI Mgmt Group's view of common RMM components and the first containment move for each. Not every product has every component.
| Component | What an attacker gains | First containment action |
|---|---|---|
| Technician console and roles | Remote control, scripts and policy for every device | Disable all but a named responder group; force sign-out; re-register MFA |
| Scripting and automation engine | Code execution as SYSTEM or root at scale | Pause all schedules and policies; disable script execution where the product allows |
| Agents on devices | A trusted, persistent channel that survives reboots | Block agent traffic to the server at network and host firewall; keep EDR online |
| Self-hosted server, database and relays | Control of agent instructions and stored secrets | Isolate, keep powered for capture, rebuild later |
| Stored device and domain credentials | Lateral movement outside the RMM | Disable or reset; restrict logon rights; watch for reuse |
| API keys and integrations (ticketing, documentation, backup, billing) | Access to client records, stored passwords and backup deletion | Revoke at both ends; review documentation platforms for exposed secrets |
| Multi-tenant client groupings (providers) | Movement from one client to all clients | Treat each client as a separate scope with its own containment owner |
Containment by priority
- Freeze execution. Pause scheduled scripts, automation policies and patch jobs, and disable unattended remote access. If the console is not trusted, skip to step 3.
- Lock the console. Disable technician accounts except the responders, revoke API keys and personal tokens, and require MFA re-registration. The remote access guide's advice that MSP accounts with access to customer environments use MFA and are treated as privileged applies here with no exceptions.
- Cut agents from the server. Block the server and relay addresses or domains at perimeter and host firewalls, ideally through your EDR's network containment policy, which keeps EDR telemetry flowing (D3FEND D3-NI Network Isolation). For a hosted service that has been taken offline by the provider, still block it so agents do not reconnect when it returns.
- Isolate the server. Disconnect a self-hosted RMM server, database and relays from the network while powered on for memory and disk capture.
- Disable stored and deployment credentials. Domain accounts used by the RMM, local administrator credentials it stored, and cloud roles it used (D3-CR Credential Revocation).
- Protect backups. Check that backup jobs, retention and immutability settings were not changed through the RMM, and take a known good copy offline. CISA's 2021 guidance to customers affected by an RMM supply chain ransomware attack stressed current backups kept air-gapped from the network.
- Arrange patching and support without the RMM. The same CISA guidance told affected customers to return to manual patch management. Plan who will apply critical fixes and give urgent user support through other means.
Credential rotation and trust reset
| Order | Credential | Action |
|---|---|---|
| 1 | RMM administrator and technician accounts | Reset, re-register phishing-resistant MFA, remove dormant and shared accounts, rebuild roles with reduced-privilege read-only monitoring for most staff |
| 2 | Domain and deployment service accounts | Reset, restrict logon to the systems they manage, and keep them out of domain administrator groups |
| 3 | Local administrator passwords on managed devices | Rotate through LAPS or your PAM tool, not through the RMM; see the Local Administrator Password Solution (LAPS) Guide |
| 4 | RMM API keys and integration tokens | Revoke and reissue per integration with minimum scopes |
| 5 | Secrets in connected documentation and ticketing platforms | Rotate every credential stored there that the RMM integration could read |
| 6 | Agent enrolment secrets and server certificates | Issue new ones for the rebuilt server so old agents cannot reconnect |
| 7 | Credentials typed or cached on devices during attacker sessions | Reset the user and admin accounts used on those devices |
The joint remote access guide also says not to reuse admin credentials across multiple customers; a provider that did must treat every client sharing a credential as compromised. The OWASP Secrets Management Cheat Sheet order applies to each item: revoke, rotate, delete from the exposed system, log.
Where identity fits
Each RMM agent is a non-human identity holding a credential to a console that can run code as SYSTEM, and each integration key is another. Re-enrolment is the moment to build the inventory you were missing: one record per agent, per technician and per key, with an owner. Technicians should sign in through SSO with named accounts, and provider staff should reach client environments through scoped, time-bound access. See the Remote Access Identity Guide and the Service Account Security Guide.
Eradication and rebuild
- Review every script run in the window against your approved script library. Unknown scripts are reversed device by device, using the script content to find the changes they made.
- Hunt for second channels. Attackers who held an RMM often install a different remote access tool as a backup. Search for remote access software installed in the window; the unauthorised tool playbook covers removal.
- Rebuild the self-hosted server from clean media on a new host at the vendor's fixed version, restore configuration only after review, and keep the console off the public internet or behind VPN or VDI, as CISA advisory AA23-025A recommends for authorised RMM use.
- Re-enrol agents. Remove and reinstall agents with new enrolment secrets, or follow the vendor's documented re-keying procedure. Use detection tooling the vendor publishes for the incident, where available, on servers and endpoints.
- Rebuild hosts that ran malicious payloads rather than cleaning them, starting with domain controllers and backup servers.
Recovery and reconnection
- Confirm eradication by monitoring. NCSC's incident response guidance advises confirming remediation, possibly by monitoring for a period, before recovery.
- Reconnect a pilot ring of non-critical workstations to the rebuilt platform with monitoring-only roles.
- Restore scripting with safeguards. Use the remote access guide's mass scripting safeguards and script approval process: step-up MFA or a second approver for any job targeting 10 or more devices.
- Expand in waves: workstations, then general servers, then high-value servers. Leave domain controllers and backup servers off the RMM if a separate admin path can serve them.
- Restore integrations last, each with a new, scoped key.
Rollback: if anomalies reappear in a wave, block agent traffic for that wave again and return those devices to manual administration while you investigate.
Evidence to preserve and notification
- Platform: audit log, script history with content, session logs and recordings, file transfer logs, policy history, technician and API key lists.
- Server: memory and disk images, web and application logs, database snapshot.
- Endpoints: EDR timelines for the agent process, new services and scheduled tasks.
- Log integrity: the remote access guide says to keep log servers and the ability to delete or alter logs out of reach of RMM tools. If they were within reach, record that and look for gaps.
Personal data on managed devices or in transferred files can make this a personal data breach, with notification to the supervisory authority within 72 hours of awareness under UK and EU GDPR Article 33 where there is a risk to individuals. NIS2 entities must give an early warning within 24 hours, an incident notification within 72 hours and a final report within one month of that notification under Article 23(4) of Directive (EU) 2022/2555. Providers have contractual duties to tell each affected client, who may then have their own clocks.
Decision guidance
| Situation | Choose | Trade-off |
|---|---|---|
| Self-hosted server exploited | Shut down and rebuild on new host | Days without remote support; manual patching |
| One technician account misused, console trusted | Disable account, pause scripting, keep platform up | Faster, but you rely on the audit log being complete |
| Provider-side breach of a hosted service | Block the service, follow the provider's restart guidance | Timeline depends on the provider |
| Mass payload already run | Run ransomware response in parallel, rebuild affected hosts | Recovery from backups drives the timeline |
| Same platform or move | Stay if root cause is fixed and verified; see the RMM migration playbook to move | Moving under pressure adds risk; plan it after recovery |
Small organisations usually depend on a provider's RMM; their first job is blocking the agents and getting the provider's written scope. Providers and large estates must run containment per client or business unit, with a coordinator tracking which tenants are blocked, cleaned and reconnected.
Detection and measurement
- Forward RMM audit, script and session logs to a SIEM the RMM cannot administer.
- Alert on scripts targeting many devices, sessions outside working hours and new technician accounts or keys.
- Correlate the agent process with child shells, new services and outbound downloads in EDR.
| Metric | Target direction |
|---|---|
| Time from detection to agents blocked from the server | Under an hour, rehearsed |
| Share of scripts run in the window with an owner and ticket | 100% accounted for before recovery |
| Managed devices re-enrolled with new trust | 100% before full reconnection |
| Technician accounts with SSO and phishing-resistant MFA | 100% |
| Credentials shared across clients or sites | Zero |
Framework mapping
| Playbook step | NIST CSF 2.0 | NIST SP 800-53 Rev. 5 | MITRE |
|---|---|---|---|
| Triage and scope | RS.AN-03 | IR-4, AU-6 | ATT&CK T1072, T1219.002, T1199 |
| Containment | RS.MI-01 | IR-4, SC-7 | D3FEND D3-NI |
| Credential rotation | RS.MI-02, PR.AA-01 | IA-5, AC-2, AC-6 | D3FEND D3-CR; ATT&CK T1078, T1098 |
| Eradication of payloads and persistence | RS.MI-02 | SI-7, CM-7 | ATT&CK T1543.003, T1105, T1685 |
| Evidence and log integrity | RS.AN-06 | AU-9 | ATT&CK T1685 |
| Recovery | RC.RP-03, RC.RP-05 | CP-10 | ATT&CK T1486, T1490 |
| Notification | RS.CO-02 | IR-6 | ATT&CK T1199 |
Common failure patterns
- Uninstalling agents through the compromised console: the attacker sees it coming and the uninstall job is itself unverified. Block at the network first.
- Patching the server in place: web shells and modified binaries survive the update.
- Rotating local admin passwords through the RMM: the new values pass through the platform you are rotating away from.
- Forgetting the documentation platform: passwords stored there for clients were readable through the integration.
- Missing the backup channel: a second remote access tool installed during the intrusion keeps the attacker in after the RMM is clean.
- One containment plan for all clients: providers lose track of which tenants are clean.
Practitioner checklist
- Script schedules, policies and unattended access paused.
- Logs exported before changes; server isolated and imaged.
- Agents blocked from the server with EDR still online.
- Technician accounts and API keys disabled or reset, MFA re-registered.
- Deployment, domain and local administrator credentials rotated outside the RMM.
- Backups checked and a clean copy held offline.
- Every script and session in the window owned or investigated.
- Hunt completed for second remote access tools.
- Server rebuilt, agents re-enrolled with new secrets, reconnection in waves.
- Client, regulator and contractual notifications recorded.
Standards and references
- CISA, NSA and MS-ISAC: AA23-025A Protecting Against Malicious Use of Remote Monitoring and Management Software
- CISA and partners: Guide to Securing Remote Access Software
- CISA and FBI: Guidance for MSPs and customers affected by the July 2021 RMM supply chain ransomware attack
- NIST: SP 800-61 Rev. 3, Incident Response Recommendations and Considerations for Cybersecurity Risk Management
- NCSC: Cyber incident response processes
- MITRE ATT&CK: T1072 Software Deployment Tools
- OWASP: Secrets Management Cheat Sheet
- EUR-Lex: Directive (EU) 2022/2555 (NIS2)
Related NHI Mgmt Group resources: RMM Tool Security Guide · Unauthorised Remote Monitoring and Management Tool Playbook · Compromised MSP Playbook · If your patch management tool is compromised · Remote monitoring and management (RMM) tool health check