Skip to content
RCE Write-up Intermediate

Local Privilege Escalation in Lenovo UDC

The Lenovo UDC service running as SYSTEM attempted to load an OpenSSL configuration file from a directory writable by unprivileged users. An attacker could plant a malicious configuration that loads an arbitrary DLL, leading to code execution with SYSTEM privileges.

Moritz Rauch Follow

Published on blog.advact.ch

I discovered a local privilege escalation vulnerability in the UDC (Universal Device Client) service from Lenovo. The vulnerability allows a non-privileged user to get SYSTEM permissions.

Moritz Rauch, on blog.advact.ch

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 loaded a configuration file from a world-writable directory without validating its origin or integrity.

What the attacker needed

Local access to a Lenovo machine with UDC installed; Ability to write to C:\ (default for unprivileged users); Reboot to trigger the service

The fix

The vulnerability was fixed by Lenovo in UDC version 23.10, which now loads openssl.cnf from a directory with restricted ACLs.

How it was found

  1. Use ProcMon with boot logging to capture file access by SYSTEM services.
  2. Filter for CreateFile events with 'not found' result from SYSTEM processes.
  3. Identify that UDClientService.exe tries to load openssl.cnf from a writable path.
  4. Create a malicious openssl.cnf that references a custom DLL.
  5. Place the DLL and openssl.cnf in the writable directory.
  6. Reboot the system to trigger the service to load the malicious configuration and DLL.

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 service running with high privileges (SYSTEM) looked for a configuration file in a folder that normal users can write to. By placing a crafted file there, an attacker could make the service load their own code and run it with those high privileges, taking over the computer.

What is RCE?

Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.

More from Lenovo

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Remote code execution

The lesson behind this report.

Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.