logo

PsExec’ing the right way and why zero trust is mandatory

ID: 03d478e2-3380-5d24-b513-2950f375bee8

STIX ID: report--03d478e2-3380-5d24-b513-2950f375bee8

Feed Name: SensePost Blog

Date Published: 2025-02-10

Date Updated: 2026-04-30

...
...

The post dissects how PsExec operates (service extraction, remote service control via RPC, initialization packet structure, and named pipes), then demonstrates a Python-based client that mimics the legitimate PsExec client to obtain SYSTEM or user shells, highlighting that older PsExec versions send cleartext credentials and can populate LSASS. It underscores the risks of overly trusting signed/whitelisted tools—illustrated by a logical flaw in a sample static analyzer that over-relies on signatures—and explains how this trust can enable EDR bypass. The author provides practical detections and mitigations, including monitoring the PsExec EULA registry key, correlating remote service creation events (e.g., 4697), limiting/disable ADMIN$ where possible, correlating named pipe naming patterns tied to the deployed service, and generally avoiding blanket trust in certificates, publishers, or file locations.

Your team is not currently subscribed to this feed. You must subscribe to it in order to see this post.