HKLM\SYSTEM\CurrentControlSet\Services is the Windows registry key holding one subkey per installed service and kernel driver, including its ImagePath and Start values. Attackers add or edit subkeys to gain persistence or load malicious drivers, and weak key permissions allow privilege escalation. Defenders monitor changes to these values and audit who can write to the key.
What this registry key contains
This key is the Windows service control point where each installed service or kernel driver has its own subkey. The values under it, especially ImagePath and Start, define what loads, when it loads, and how Windows treats that component during boot and runtime. Because that makes it both operationally essential and security-sensitive, it is a common target for persistence and privilege abuse.
The subkeys under this path are not just configuration records, they are execution instructions. For defenders, that means service creation, driver loading, and start-mode changes all deserve the same attention as executable modification, because a small registry edit can change the system’s trust boundary.
Why attackers target it
Attackers value this location because they can create or alter service entries to make malware start automatically, survive reboots, or load a malicious driver with elevated system access. If permissions on the key are weak, the same mechanism can be used to move from a lower-privileged foothold to higher privilege through service hijacking or driver-based abuse.
That makes the key part of the broader Windows persistence problem: an attacker does not need to replace the whole service, only the registry-backed instructions that govern it. A malicious ImagePath can redirect execution, while a tampered Start value can change whether a payload runs at boot, on demand, or as part of a critical system component.
For Windows hardening guidance around services, autoruns, privileges and related telemetry, see Windows Internals for Defenders Guide.
How defenders check exposure
Exposure starts with inventory. Organisations need to know which services and drivers exist, which ones are expected, and which accounts, installers or tools are allowed to write to the key. That inventory should be matched against startup type, file path, signing status and ownership so that unusual service entries stand out quickly.
Internet exposure matters too, but here the more immediate concern is local write access. A writable service registry path on a server or endpoint can become a direct persistence mechanism, especially when combined with scheduled tasks, remote management tools or a compromised admin account.
When reviewing exposure, defenders should compare the registry state with vendor documentation, installed software baselines and known-good service configurations. The main question is whether the current registry values describe the authorised service, or a substituted execution path that merely looks normal.
Detection and remediation priorities
Monitoring should focus on change detection for service subkeys, especially new entries, altered ImagePath values, unusual Start modes and unexpected permission changes. Event telemetry, registry auditing and endpoint detection tools are most useful when they correlate registry edits with service creation, driver load attempts, process launches and privilege changes.
Remediation depends on whether the change is legitimate, malicious or unknown. If the registry entry is hostile, remove the persistence mechanism, verify the associated binary or driver, and review whether the service has already executed with elevated rights. If the change is legitimate but risky, tighten permissions, reduce who can write the key, and validate the service’s binary path and signing state.
Because this registry location can also anchor driver loading, post-remediation checks should confirm that no malicious kernel component remains resident. If compromise is suspected, the review should extend beyond the registry itself to binaries, loaded modules, scheduled startup mechanisms and any credentials or admin sessions used to make the change.
Standards & Framework Alignment
This section maps relevant standards and security frameworks to the operational risks and controls described in this guidance.
MITRE ATT&CK addresses the attack and risk surface, while CIS Controls v8 and NIST SP 800-53 Rev 5 set the governance and control requirements practitioners need to meet.
| Framework | Control / Reference | Relevance |
|---|---|---|
| CIS Controls v8 | CIS-4 — Secure Configuration of Enterprise Assets and Software | Service registry keys are part of endpoint configuration that must be hardened and monitored. |
| Recommendation — Harden service registry permissions and continuously validate service configuration drift. | ||
| NIST SP 800-53 Rev 5 | CM-6 — Configuration Settings | This key stores security-relevant configuration values that determine service and driver behaviour. |
| AC-6 — Least Privilege | Write access to service keys can enable escalation or persistence when overly broad. | |
| AU-2 — Event Logging | Registry edits and service changes need logging to support detection and review. | |
| Recommendation — Define approved service registry settings and detect unauthorized changes. Restrict who can modify service registry keys to the minimum necessary. Log service registry modifications and correlate them with process and service events. | ||
| MITRE ATT&CK | T1547.001 — Registry Run Keys / Startup Folder | Abuse of Windows registry-based persistence is a direct threat pattern for service-related autoruns. |
| T1031 — Scheduled Task/Job | Service and startup manipulation commonly overlaps with other persistence mechanisms that defenders must correlate. | |
| Recommendation — Map suspicious service registry changes to persistence hunting and containment workflows. Correlate service-key tampering with other startup mechanisms during intrusion analysis. | ||
Practitioner Guidance
What to watch for: Treat unexpected changes under this key as both a persistence signal and a privilege signal. The most dangerous cases are not always the loudest, they are the entries that look like normal service maintenance but quietly redirect execution to attacker-controlled code.
Governance implication: Ownership for this key should sit with the team that manages service and endpoint baselines, not with ad hoc local administrators. If multiple groups can write here without review, the registry becomes a shared escalation surface rather than a controlled configuration store.
Related resources from NHI Mgmt Group
Deepen Your Knowledge
Free weekly newsletter
Subscribe to the NHI & AI Identity Journal
The latest on NHI and Agentic AI security – articles, research, breaches, news and events every week.
Bonus 33% off our NHI Course when you subscribe.
Reviewed and updated by the NHIMG editorial team on November 26, 2026.
NHI Mgmt Group — the #1 independent authority on Non-Human Identity, IAM, and Agentic AI security. nhimg.org