CVE-2020-36221

7.5 HIGH

📋 TL;DR

An integer underflow vulnerability in OpenLDAP's Certificate Exact Assertion processing can cause slapd to crash, leading to denial of service. This affects OpenLDAP servers processing certificate assertions. Attackers can trigger this remotely without authentication.

💻 Affected Systems

Products:
  • OpenLDAP
Versions: All versions before 2.4.57
Operating Systems: All platforms running OpenLDAP
Default Config Vulnerable: ⚠️ Yes
Notes: Vulnerable when processing Certificate Exact Assertions, which may occur during TLS/SSL certificate validation.

📦 What is this software?

Macos by Apple

macOS is Apple's desktop and laptop operating system powering Mac computers used by millions of professionals, developers, creative professionals, and enterprise users worldwide. Built on a Unix foundation with the Darwin kernel and modern Cocoa frameworks, macOS delivers a seamless ecosystem integr...

Learn more about Macos →

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete service disruption of LDAP directory services, potentially affecting authentication, authorization, and directory lookups for dependent systems.

🟠

Likely Case

Service disruption causing authentication failures and application outages until slapd is restarted.

🟢

If Mitigated

Minimal impact with proper network segmentation and monitoring allowing quick service restoration.

🌐 Internet-Facing: HIGH
🏢 Internal Only: MEDIUM

🎯 Exploit Status

Public PoC: ⚠️ Yes
Weaponized: LIKELY
Unauthenticated Exploit: ⚠️ Yes
Complexity: LOW

Exploitation requires sending specially crafted certificate assertions to trigger the integer underflow.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: 2.4.57 and later

Vendor Advisory: https://bugs.openldap.org/show_bug.cgi?id=9404

Restart Required: Yes

Instructions:

1. Download OpenLDAP 2.4.57 or later from openldap.org. 2. Stop slapd service. 3. Install updated version. 4. Restart slapd service.

🔧 Temporary Workarounds

Disable Certificate Exact Assertion Processing

all

Configure OpenLDAP to reject or ignore certificate exact assertions if not required.

# Add to slapd.conf or configure via cn=config:
# reject or ignore certificate exact assertions

Network Filtering

linux

Block or rate-limit LDAP requests containing certificate assertions at network perimeter.

# Example iptables rule (adjust ports):
# iptables -A INPUT -p tcp --dport 389 -m string --string "certificateExactAssertion" --algo bm -j DROP

🧯 If You Can't Patch

  • Implement strict network ACLs to limit LDAP access to trusted sources only.
  • Deploy load balancers with health checks to automatically restart failed slapd instances.

🔍 How to Verify

Check if Vulnerable:

Check OpenLDAP version: slapd -VV 2>&1 | grep '^@' or check installed package version.

Check Version:

slapd -VV 2>&1 | grep '^@'

Verify Fix Applied:

Confirm version is 2.4.57 or later and test certificate assertion processing.

📡 Detection & Monitoring

Log Indicators:

  • slapd crash logs
  • segmentation fault errors in syslog
  • unexpected slapd restarts

Network Indicators:

  • LDAP requests with certificate exact assertions followed by service unavailability

SIEM Query:

source="syslog" AND ("slapd" AND ("segmentation fault" OR "crash" OR "restart"))

🔗 References

📤 Share & Export