SpiderLabs Blog

Credential Leak Flaws in Windows PureVPN Client

Written by | Sep 27, 2018 1:43:00 PM

Using a VPN (Virtual Private Network) can bring many advantages, particularly when you want to access remote resources, or you are using a network you don't fully trust, for example, a coffee shop or an airport.

In the recent years, there has been a rise in the number of VPN providers targeting users who may not be technically savvy but still want to use a VPN to improve the security of their connections, are concerned about privacy or want to bypass some geographical restriction.

One of the main features such providers offer is that it's really easy to set up a VPN. Just a couple of clicks, a straightforward configuration and you are ready to go. Since they want to make it easy for users, most of the clients offer to store the password so you can connect with a click (or even do it automatically each time your laptop starts).

I had some curiosity regarding the "stored password" functionality, so I started digging, and I found two vulnerabilities. We disclosed these vulnerabilities to PureVPN as part of our Responsible Disclosure program. They accepted the risk of the first one and provided a patch for the second. The details can be found in the advisory TWSL2018-010.

I tested for these vulnerabilities under the following assumptions and conditions:

  • The PureVPN client has a default installation.
  • The attacker has access to any local user account.
  • Someone has successfully logged in to the PureVPN using the client on a Windows machine at any point in time.
  • The Windows machine has more than one user in the case of disclosing another users credentials in a multiuser environment.

The vulnerabilities were found in version 5.18.2.0 of the PureVPN Windows client and disclosed to the vendor. The vendor has released a patch. We've tested version 6.1.0, and it's no longer vulnerable.

I'll explain each of the vulnerabilities I found:

Vulnerability #1 – Password revealed in Client's Configuration Window

Not Fixed. The vendor accepted the risk.

Description

The PureVPN Windows Client provided by PureVPN may allow a local attacker to retrieve the stored password of the last user who successfully logged in to the PureVPN service. Because of this, a local attacker may obtain another user's PureVPN credentials when a Windows machine has multiple users if they have successfully logged in. The attack is done exclusively through the GUI (Graphical User Interface), there's no need to use an external tool.

PoC

Steps to obtain the password:

  1. Open the PureVPN Windows Client.
  2. Go to Configuration
  3. Open the "User Profile" tab
  4. Click on "Show Password"

Evidence

Figure 1. Configuration tab with information about the login

Figure 2. Configuration tab with the credentials

Vulnerability #2 – Plaintext storage of PureVPN Windows Client Credentials

Fixed

Description

The PureVPN Windows Client stores the Login Credentials (username and password) in plaintext. The location of such files is: 'C:\ProgramData\purevpn\config\login.conf'

Additionally, all local users can read this file.

 

PoC

Steps to obtain the password:

  1. Read the file in 'C:\ProgramData\purevpn\config\login.conf'

Evidence

Figure 3. Location and content of the file with the credentials in plaintext

Figure 4. Permissions of the file with the credentials in plaintext

Finally, some recommendations are:

  • In case you use the PureVPN for Windows, verify you are running the latest version, if not update.
  • Never reuse password between services.
  • Whenever possible, enable two-factor authentication.

To help you test for the presence of this vulnerability, I also created a Metasploit module that you can access here: https://github.com/rapid7/metasploit-framework/pull/10716