CVE-2015-3223
Medium · 5.3CVSS
5.3
EPSS
6.9%
Published
Dec 29, 2015
CISA due date
—
Cloudanix analysis
A flaw in directory software lets remote attackers send bad data that freezes the service, blocking logins and access for everyone using it.
- Exploitation
- Remote Unauthenticated
- Attacker needs
- None
- Complexity
- Low
- Impact
- Denial Of Service
- Component
- Network Service
- Class
- Denial of service
- Remediation
- Upgrade
- Effort
- Medium
- Patch risk
- Low
What it actually does
The vulnerability causes an infinite loop in the ldb_wildcard_compare function within ldb_match.c when processing certain zero values in LDAP wildcard comparisons, allowing remote attackers to trigger a denial of service via crafted network packets against the Active Directory LDAP server.
Why it matters to the business
Successful exploitation can render directory services unavailable, disrupting authentication, authorization, and resource access for any systems or users relying on the Samba-based Active Directory environment, leading to operational downtime.
How an attack unfolds
An attacker crafts malicious LDAP packets targeting the Samba Active Directory server and sends them over the network; the ldb library mishandles zero values during wildcard matching, entering an infinite loop that consumes resources and denies service to legitimate users.
How to fix it
Upgrade Samba to version 4.1.22 or later for the 4.1.x branch, 4.2.7 or later for the 4.2.x branch, or 4.3.3 or later for the 4.3.x branch; apply vendor patches addressing ldb before 1.1.24.
How to confirm the fix worked
Confirm Samba and ldb versions meet or exceed the fixed releases, then test LDAP operations with edge-case wildcard queries containing zero values to ensure no infinite loop occurs.
Typical attack path
- Identify exposed Samba AD LDAP service
- Craft packets containing specific zero values for wildcard comparisons
- Transmit packets to trigger infinite loop in ldb_match.c
- Observe service degradation or crash
How to detect it
Review Samba and LDAP server logs for repeated malformed query patterns, monitor for sustained high CPU utilization on the directory service process without corresponding legitimate traffic volume.
What your security team should do
- Prioritize upgrade of all Samba instances to the fixed versions listed
- Restrict network access to LDAP ports to trusted sources until patched
- Monitor CPU and resource usage on AD servers for anomalous spikes
The record
The ldb_wildcard_compare function in ldb_match.c in ldb before 1.1.24, as used in the AD LDAP server in Samba 4.x before 4.1.22, 4.2.x before 4.2.7, and 4.3.x before 4.3.3, mishandles certain zero values, which allows remote attackers to cause a denial of service (infinite loop) via crafted packets.
Affected packages
| Ecosystem | Package | Introduced | Fixed |
|---|---|---|---|
| Debian:11 | ldb | 0 | 2:1.1.24-1 |
| Debian:11 | samba | 0 | 2:4.1.22+dfsg-1 |
| Debian:12 | samba | 0 | 2:4.1.22+dfsg-1 |
| Debian:13 | samba | 0 | 2:4.1.22+dfsg-1 |
| Debian:7 | samba | 0 | 2:3.6.6-6+deb7u6 |
| Debian:8 | samba | 0 | 2:4.1.17+dfsg-2+deb8u1 |
| Mageia:5 | ldb | 0 | 1.1.26-1.mga5 |
| Mageia:5 | samba | 0 | 3.6.25-2.1.mga5 |
| Mageia:5 | talloc | 0 | 2.1.5-1.mga5 |
| Mageia:5 | tdb | 0 | 1.3.8-1.mga5 |
| Mageia:5 | tevent | 0 | 0.9.28-1.mga5 |
| Red Hat:enterprise_linux:6::client | ldb-tools | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::client | libldb | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::client | libldb-debuginfo | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::client | libldb-devel | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::client | pyldb | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::client | pyldb-devel | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::computenode | ldb-tools | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::computenode | libldb | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::computenode | libldb-debuginfo | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::computenode | libldb-devel | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::computenode | pyldb | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::computenode | pyldb-devel | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::server | ldb-tools | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::server | libldb | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::server | libldb-debuginfo | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::server | libldb-devel | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::server | pyldb | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::server | pyldb-devel | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::workstation | ldb-tools | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::workstation | libldb | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::workstation | libldb-debuginfo | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::workstation | libldb-devel | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::workstation | pyldb | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:6::workstation | pyldb-devel | 0 | 0:1.1.13-3.el6_7.1 |
| Red Hat:enterprise_linux:7::client | ldb-tools | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::client | libldb | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::client | libldb-debuginfo | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::client | libldb-devel | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::client | pyldb | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::client | pyldb-devel | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::computenode | ldb-tools | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::computenode | libldb | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::computenode | libldb-debuginfo | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::computenode | libldb-devel | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::computenode | pyldb | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::computenode | pyldb-devel | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::server | ldb-tools | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::server | libldb | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::server | libldb-debuginfo | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::server | libldb-devel | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::server | pyldb | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::server | pyldb-devel | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::workstation | ldb-tools | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::workstation | libldb | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::workstation | libldb-debuginfo | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::workstation | libldb-devel | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::workstation | pyldb | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:enterprise_linux:7::workstation | pyldb-devel | 0 | 0:1.1.20-1.el7_2.2 |
| Red Hat:storage:3.1:samba:el7 | ldb-tools | 0 | 0:1.1.20-3.el7rhgs |
| Red Hat:storage:3.1:samba:el7 | libldb | 0 | 0:1.1.20-3.el7rhgs |
| Red Hat:storage:3.1:samba:el7 | libldb-debuginfo | 0 | 0:1.1.20-3.el7rhgs |
| Red Hat:storage:3.1:samba:el7 | libldb-devel | 0 | 0:1.1.20-3.el7rhgs |
| Red Hat:storage:3.1:samba:el7 | pyldb | 0 | 0:1.1.20-3.el7rhgs |
| Red Hat:storage:3.1:samba:el7 | pyldb-devel | 0 | 0:1.1.20-3.el7rhgs |
| Red Hat:storage:3.1:server:el6 | ldb-tools | 0 | 0:1.1.20-3.el6rhs |
| Red Hat:storage:3.1:server:el6 | libldb | 0 | 0:1.1.20-3.el6rhs |
| Red Hat:storage:3.1:server:el6 | libldb-debuginfo | 0 | 0:1.1.20-3.el6rhs |
| Red Hat:storage:3.1:server:el6 | libldb-devel | 0 | 0:1.1.20-3.el6rhs |
| Red Hat:storage:3.1:server:el6 | pyldb | 0 | 0:1.1.20-3.el6rhs |
| Red Hat:storage:3.1:server:el6 | pyldb-devel | 0 | 0:1.1.20-3.el6rhs |
| SUSE:Linux Enterprise Desktop 12 | ldb | 0 | 1.1.24-4.3.1 |
| SUSE:Linux Enterprise Desktop 12 | samba | 0 | 4.1.12-18.3.1 |
| SUSE:Linux Enterprise Desktop 12 | talloc | 0 | 2.1.5-3.4.1 |
| SUSE:Linux Enterprise Desktop 12 | tdb | 0 | 1.3.8-2.3.1 |
| SUSE:Linux Enterprise Desktop 12 | tevent | 0 | 0.9.26-3.3.1 |
| SUSE:Linux Enterprise Desktop 12 SP1 | ldb | 0 | 1.1.24-4.1 |
| SUSE:Linux Enterprise Desktop 12 SP1 | samba | 0 | 4.2.4-6.1 |
| SUSE:Linux Enterprise Desktop 12 SP1 | talloc | 0 | 2.1.5-4.1 |
| SUSE:Linux Enterprise Desktop 12 SP1 | tdb | 0 | 1.3.8-4.1 |
| SUSE:Linux Enterprise Desktop 12 SP1 | tevent | 0 | 0.9.26-4.1 |
| SUSE:Linux Enterprise Server 12 | ldb | 0 | 1.1.24-4.3.1 |
| SUSE:Linux Enterprise Server 12 | samba | 0 | 4.1.12-18.3.1 |
| SUSE:Linux Enterprise Server 12 | talloc | 0 | 2.1.5-3.4.1 |
| SUSE:Linux Enterprise Server 12 | tdb | 0 | 1.3.8-2.3.1 |
| SUSE:Linux Enterprise Server 12 | tevent | 0 | 0.9.26-3.3.1 |
| SUSE:Linux Enterprise Server 12 SP1 | ldb | 0 | 1.1.24-4.1 |
| SUSE:Linux Enterprise Server 12 SP1 | samba | 0 | 4.2.4-6.1 |
| SUSE:Linux Enterprise Server 12 SP1 | talloc | 0 | 2.1.5-4.1 |
| SUSE:Linux Enterprise Server 12 SP1 | tdb | 0 | 1.3.8-4.1 |
| SUSE:Linux Enterprise Server 12 SP1 | tevent | 0 | 0.9.26-4.1 |
| SUSE:Linux Enterprise Server for SAP Applications 12 | ldb | 0 | 1.1.24-4.3.1 |
| SUSE:Linux Enterprise Server for SAP Applications 12 | samba | 0 | 4.1.12-18.3.1 |
| SUSE:Linux Enterprise Server for SAP Applications 12 | talloc | 0 | 2.1.5-3.4.1 |
| SUSE:Linux Enterprise Server for SAP Applications 12 | tdb | 0 | 1.3.8-2.3.1 |
| SUSE:Linux Enterprise Server for SAP Applications 12 | tevent | 0 | 0.9.26-3.3.1 |
| SUSE:Linux Enterprise Server for SAP Applications 12 SP1 | ldb | 0 | 1.1.24-4.1 |
| SUSE:Linux Enterprise Server for SAP Applications 12 SP1 | samba | 0 | 4.2.4-6.1 |
| SUSE:Linux Enterprise Server for SAP Applications 12 SP1 | talloc | 0 | 2.1.5-4.1 |
| SUSE:Linux Enterprise Server for SAP Applications 12 SP1 | tdb | 0 | 1.3.8-4.1 |
| SUSE:Linux Enterprise Server for SAP Applications 12 SP1 | tevent | 0 | 0.9.26-4.1 |
| SUSE:Linux Enterprise Software Development Kit 12 | ldb | 0 | 1.1.24-4.3.1 |
| SUSE:Linux Enterprise Software Development Kit 12 | samba | 0 | 4.1.12-18.3.1 |
| SUSE:Linux Enterprise Software Development Kit 12 | talloc | 0 | 2.1.5-3.4.1 |
| SUSE:Linux Enterprise Software Development Kit 12 | tdb | 0 | 1.3.8-2.3.1 |
| SUSE:Linux Enterprise Software Development Kit 12 | tevent | 0 | 0.9.26-3.3.1 |
| SUSE:Linux Enterprise Software Development Kit 12 SP1 | ldb | 0 | 1.1.24-4.1 |
| SUSE:Linux Enterprise Software Development Kit 12 SP1 | samba | 0 | 4.2.4-6.1 |
| SUSE:Linux Enterprise Software Development Kit 12 SP1 | talloc | 0 | 2.1.5-4.1 |
| SUSE:Linux Enterprise Software Development Kit 12 SP1 | tdb | 0 | 1.3.8-4.1 |
| SUSE:Linux Enterprise Software Development Kit 12 SP1 | tevent | 0 | 0.9.26-4.1 |
| Ubuntu:14.04:LTS | ldb | 0 | 1:1.1.16-1ubuntu0.1 |
| Ubuntu:14.04:LTS | samba | 0 | 2:4.1.6+dfsg-1ubuntu2.14.04.11 |
| Ubuntu:16.04:LTS | ldb | 0 | 2:1.1.24-1ubuntu1 |
| Ubuntu:16.04:LTS | samba | 0 | 2:4.3.3+dfsg-1ubuntu1 |
| openSUSE:Tumbleweed | ldb | 0 | 1.1.27-1.1 |
| openSUSE:Tumbleweed | samba | 0 | 4.5.0-1.1 |
Related vulnerabilities
- CVE-2020-1472 An elevation of privilege vulnerability exists when an attacker establishes a vulnerable… Also affects samba
- CVE-2017-15275 Samba before 4.7.3 might allow remote attackers to obtain sensitive information by… Also affects samba
- CVE-2017-14746 Use-after-free vulnerability in Samba 4.x before 4.7.3 allows remote attackers to execute… Also affects samba
- CVE-2017-11103 Heimdal before 7.4 allows remote attackers to impersonate services with Orpheus' Lyre… Also affects samba
- CVE-2017-9461 smbd in Samba before 4.4.10 and 4.5.x before 4.5.6 has a denial of service vulnerability… Also affects samba
- CVE-2017-7494 Samba since version 3.5.0 and before 4.6.4, 4.5.10 and 4.4.14 is vulnerable to remote… Also affects samba
- CVE-2016-2119 libcli/smb/smbXcli_base.c in Samba 4.x before 4.2.14, 4.3.x before 4.3.11, and 4.4.x… Also affects samba
- CVE-2016-2115 Samba 3.x and 4.x before 4.2.11, 4.3.x before 4.3.8, and 4.4.x before 4.4.2 does not… Also affects samba