Given access to impacted systems and domain infrastructure, the operator will enumerate user accounts across hosts and domain, validate account legitimacy, and remove any unauthorized, malicious, or attacker-created accounts.
Operator Note: Attackers often create new user accounts, escalate privileges of existing accounts, or hide in unused accounts to maintain access. Detection and removal of unauthorized accounts is critical for successful eradication.
All attacker-created or unauthorized accounts have been identified, validated, removed, and documented. Access control integrity has been restored.
Get-LocalUser
net user
Get-ADUser -Filter * | Select-Object Name, SamAccountName, Enabled, LastLogonDate
cat /etc/passwd
getent passwd
dscl . list /Users
Operator Note: Pay close attention to accounts with UID < 500 on macOS (system accounts) and accounts without login history or descriptions.
svc-updates
, test123
, adm1n
).Disable-LocalUser -Name "suspiciousaccount"
Disable-ADAccount -Identity "suspiciousaccount"
sudo usermod --lock suspiciousaccount
sudo pwpolicy -u suspiciousaccount disableuser
Remove-LocalUser -Name "suspiciousaccount"
Remove-ADUser -Identity "suspiciousaccount"
sudo userdel suspiciousaccount
sudo dscl . -delete /Users/suspiciousaccount
[2025-05-02] Removed unauthorized user "svc-update" from HOST123. Account confirmed attacker-created. Approved by IR Lead. Operator: Leo
Get-LocalUser | Select-Object Name, Enabled, LastLogon
lastlog | grep "**Never logged in**"
Operator Note: Accounts with no logins and unusual names are often used as backdoors.
Tool | Platform | Installation | Usage |
---|---|---|---|
PowerShell | Windows | Built-in | Enumerate and remove local/domain users |
Active Directory Users & Computers | Windows (Domain) | Built-in MMC snap-in | Visual account validation and removal |
dscl | macOS | Built-in | Manage local users and groups |
userdel / passwd | Linux | Built-in | Remove and lock local users |
Operator Note: Always lock/disable first before deleting to prevent accidental service impact.
Microsoft PowerShell Local Accounts Cmdlets
Linux User Management
Apple macOS dscl Command
Date | Version | Description | Author |
---|---|---|---|
2025-05-02 | 1.0 | Fully generated operator guide for removing unauthorized accounts with platform guidance, tools, checklist | Leo |