The first question is whether the script content shows active intent or is just an inert reference to the API names, something that happens in documentation, training material, and security-tool signature databases. Pull the full script by reconstructing every fragment sharing the same ScriptBlockId, since script block logging can split one script across multiple 4104 events and the polling loop, the window-labeling call, and the output path often land in separate fragments. Then recover the process launch chain: what spawned PowerShell, whether it came from a document, browser, or scheduled task, and whether the account and host pairing has a legitimate reason to run input-capture code.
If the script pairs hook registration or key-state polling with window labeling, writes to a hidden log path, or is followed by an archive and an outbound connection, treat it as confirmed collection rather than a maintenance false positive, and move fast: keystroke capture implies whatever the user typed next, including a password reset or a wallet unlock, is already compromised. Preserve the reconstructed script, the written log or archive artifacts, and any destination IP or domain before doing anything destructive. Reset credentials for the affected account as a precaution rather than waiting for confirmation of reuse, hunt for the same script-block fingerprint or file pattern on other hosts, and isolate the endpoint if there is evidence the captured data already left the network.