CVE-2017-20123

8.8 HIGH

📋 TL;DR

This vulnerability in Viscosity VPN client allows attackers to execute arbitrary code by exploiting an untrusted search path issue in the DLL handler. Attackers can plant malicious DLLs in directories that Viscosity searches, leading to remote code execution. Users of Viscosity 1.6.7 and earlier versions are affected.

💻 Affected Systems

Products:
  • Viscosity VPN Client
Versions: 1.6.7 and earlier
Operating Systems: Windows, macOS
Default Config Vulnerable: ⚠️ Yes
Notes: Vulnerability exists in the DLL loading mechanism when Viscosity searches for required libraries.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Full system compromise with attacker gaining administrative privileges, data theft, and persistent backdoor installation.

🟠

Likely Case

Attacker gains user-level access to execute arbitrary code, potentially stealing VPN credentials and network traffic.

🟢

If Mitigated

Limited impact if proper application whitelisting and DLL search path restrictions are in place.

🌐 Internet-Facing: MEDIUM - Requires attacker to trick user into downloading malicious file or accessing compromised network share.
🏢 Internal Only: HIGH - Internal attackers can exploit this via network shares or by placing malicious DLLs in accessible directories.

🎯 Exploit Status

Public PoC: ⚠️ Yes
Weaponized: CONFIRMED
Unauthenticated Exploit: ✅ No
Complexity: LOW

Exploit requires user interaction or network access to place malicious DLL in search path. Public exploit code available on GitHub.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: 1.6.8

Vendor Advisory: https://www.sparklabs.com/blog/viscosity-for-mac-windows-version-1-6-8/

Restart Required: Yes

Instructions:

1. Download Viscosity 1.6.8 from official website. 2. Install over existing version. 3. Restart computer to ensure all components are updated.

🔧 Temporary Workarounds

Restrict DLL Search Path

windows

Use Windows Group Policy or application control to restrict DLL search paths for Viscosity.

Set-ProcessMitigation -Name viscosity.exe -Disable DynamicCode -Enable ForceRelocateImages

Remove Write Permissions

windows

Remove write permissions from directories in Viscosity's DLL search path that non-admin users can access.

icacls "C:\Program Files\Viscosity" /deny Users:(W)

🧯 If You Can't Patch

  • Implement application whitelisting to prevent execution of unauthorized DLLs
  • Monitor for DLL planting in directories accessible to Viscosity process

🔍 How to Verify

Check if Vulnerable:

Check Viscosity version in Help > About menu. If version is 1.6.7 or earlier, system is vulnerable.

Check Version:

On Windows: wmic product where name="Viscosity" get version

Verify Fix Applied:

Verify version shows 1.6.8 or later in Help > About menu.

📡 Detection & Monitoring

Log Indicators:

  • Unexpected DLL loads from non-standard directories
  • Viscosity process loading DLLs from user-writable locations

Network Indicators:

  • Unusual network connections from Viscosity process
  • SMB connections to unexpected shares

SIEM Query:

process_name="viscosity.exe" AND (file_path="*\Users\*\*.dll" OR file_path="*\Temp\*.dll")

🔗 References

📤 Share & Export