Access continues after the password changed
Why a new password doesn't end an existing session
~/.ssh/authorized_keys.
Red herrings that slow the investigation
The order that closes both doors
- If you reset first and revoke later, the attacker keeps working through the old session in the gap.
- If you revoke first and reset later, the attacker logs back in with the stolen password, and passes MFA too if they captured a backup code or the factor is weak.
- Isolate the infected device. Disconnect it from the network so it stops sending fresh credentials to the attacker. Don't wipe it yet if you need it for forensics.
- Move to a clean machine. Use a device that has not been used by the affected person and is not on the same compromised profile.
- Reset the password for each account the stealer could have captured. That means every saved browser password, not only the main work login.
- Immediately revoke all sessions and tokens for those accounts: web sessions, refresh tokens, app passwords, API keys, and SSH keys.
- Review persistence the attacker may have added while they had access: mail forwarding rules, new admin users, OAuth app grants, cron jobs, and authorized_keys entries.
- Re-check MFA enrollment. Remove any factor the user doesn't recognize and re-enroll. The research context recommends phishing-resistant MFA for privileged accounts.
BASH
# Show active sessions for a user (read-only)
wp user session list 'admin-username'
# End every session for that user
wp user session destroy 'admin-username' --allwp-config.php. On core WordPress authentication, this invalidates every login cookie for every user. Warning: everyone gets logged out, including legitimate admins, so plan for that before you do it.
On a Linux server, check for open sessions belonging to the affected user before and after the reset:
BASH
# Who is logged in right now, with idle time and PID
who -u
# Recent logins with source IPs
last -i | head -n 20
# systemd login sessions, where available
loginctl list-sessions~/.ssh/authorized_keys for keys nobody recognizes.
