Skip to content
Access control Write-up Advanced

Looking into the patch

A flaw in vmdir's legacy LDAP access check caused it to grant access when permission checks failed, and a design flaw granted root privileges to LDAP sessions with no token. An attacker with network access to the vCenter Directory Service could add an administrator account and take over the vSphere deployment.

guardicore.com

Published on guardicore.com

Last Thursday, VMware published a security advisory for CVE-2020-3952, describing a “sensitive information disclosure vulnerability in the VMware Directory Service (vmdir)”. It’s a pretty terse advisory, and it doesn’t go into much more detail than that, besides stating that any vCenter Server v6.7 that has been…

The author, on guardicore.com

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

Likely two issues: VmDirLegacyAccessCheck returned success by default when its permission check failed, and VmDirIsFailedAccessInfo treated a missing access token as an internal operation with root privileges.

Impact

An attacker with network access to the vCenter Directory Service could add an administrator account and take over the entire vSphere deployment.

What the attacker needed

Network access to vCenter Directory Service; vCenter Server 6.7 upgraded from a previous version

The fix

The vulnerability was fixed in vCenter Appliance 6.7 Update 3f, and installing the latest patch or version 7.0 is recommended; limiting access to the LDAP port also mitigates the risk.

How it was found

  1. Send an LDAP bind request with invalid credentials; the bind fails but the session is marked as non-anonymous and the access token is cleared.
  2. Send an LDAP add request to create a new user entry; the access check incorrectly grants permission.
  3. Send an LDAP modify request to add the new user to the Administrators group.
  4. Log in to vSphere with the new user, which now has administrator rights.

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.

vCenter is software that manages virtual machines. Its directory service (vmdir) handles logins and permissions. A mistake in the code meant that when a permission check failed, the service still said 'yes' instead of 'no'. Also, a session that had not logged in properly was treated as an internal, trusted operation. Together, these let anyone who could reach the directory service add a new administrator account without knowing any password.

What is Access control?

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.

Similar reports

View all

Same bug class and techniques, clearest first.

Broken access control

The lesson behind this report.

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.