CVE Vulnerabilities

CVE-2021-44141

Improper Link Resolution Before File Access ('Link Following')

Published: Feb 21, 2022 | Modified: Sep 17, 2023
CVSS 3.x
4.3
MEDIUM
Source:
NVD
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N
CVSS 2.x
3.5 LOW
AV:N/AC:M/Au:S/C:P/I:N/A:N
RedHat/V2
RedHat/V3
6.5 MODERATE
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N
Ubuntu
LOW

All versions of Samba prior to 4.15.5 are vulnerable to a malicious client using a server symlink to determine if a file or directory exists in an area of the server file system not exported under the share definition. SMB1 with unix extensions has to be enabled in order for this attack to succeed.

Weakness

The product attempts to access a file based on the filename, but it does not properly prevent that filename from identifying a link or shortcut that resolves to an unintended resource.

Affected Software

Name Vendor Start Version End Version
Samba Samba * 4.15.5 (excluding)
Red Hat Enterprise Linux 8 RedHat samba-0:4.15.5-5.el8 *
Red Hat Enterprise Linux 8 RedHat samba-0:4.15.5-5.el8 *
Red Hat Gluster Storage 3.5 for RHEL 8 RedHat samba-0:4.15.5-100.el8rhgs *
Samba Ubuntu bionic *
Samba Ubuntu devel *
Samba Ubuntu esm-infra-legacy/trusty *
Samba Ubuntu esm-infra/bionic *
Samba Ubuntu esm-infra/xenial *
Samba Ubuntu focal *
Samba Ubuntu impish *
Samba Ubuntu jammy *
Samba Ubuntu trusty/esm *
Samba Ubuntu upstream *

Potential Mitigations

  • Follow the principle of least privilege when assigning access rights to entities in a software system.
  • Denying access to a file can prevent an attacker from replacing that file with a link to a sensitive file. Ensure good compartmentalization in the system to provide protected areas that can be trusted.

References