Raining SYSTEM Shells with Citrix Workspace app
The Citrix Workspace Updater Service, running as SYSTEM, accepted update requests over a named pipe and only checked that the client process ID matched a legitimate updater and that the update binary had a valid Authenticode signature. An attacker could spoof the client PID and point to a signed executable that launches other programs, achieving arbitrary code execution as SYSTEM, either locally or remotely via NTLM relay.
pentestpartners.com
Published on pentestpartners.com
Citrix Workspace is vulnerable to a remote command execution attack running under the context of the SYSTEM account. By sending a crafted message over a named pipe and spoofing the client process ID, the Citrix Workspace Updater Service can be tricked into executing an arbitrary process under the SYSTEM account.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
The service relied on the client process ID and a valid Authenticode signature as security checks, both of which could be bypassed by spoofing the PID and using a signed LOLBin.
Impact
An attacker could execute arbitrary code as SYSTEM locally or remotely, and if SMB signing is not enforced, no valid credentials are needed via NTLM relaying.
What the attacker needed
Low privilege account (local) or NTLM relay (remote); SMB signing not enforced (for remote relay)
The fix
The vulnerability was fixed in updated versions of Citrix Workspace app; additionally, developers should restrict named pipe access and not rely on client PID for security.
How it was found
- Craft a JSON message with MessageType 1, pointing UpdateFilePath to a signed executable that can launch other processes (e.g., ScriptRunner.exe) and setting CmdLineArguments to run a command.
- Load a DLL into the CitrixReceiverUpdater.exe process to send the crafted JSON message over the named pipe.
- For remote attacks, use NTLM relaying with a modified impacket that spoofs the client PID in SMB packets.
- Cycle through PIDs until the spoofed PID matches that of the CitrixReceiverUpdater.exe process, causing the service to execute the payload as SYSTEM.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
A named pipe is a way for programs on the same or different computers to talk to each other. The Citrix updater service runs with high privileges and listens on such a pipe. The service tried to check who was calling by looking at the caller's process ID, but that ID can be faked, so an attacker could make the service run their own program with high privileges.
What is RCE?
Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.