CVE-2021-33574

9.8 CRITICAL

📋 TL;DR

This CVE describes a use-after-free vulnerability in the GNU C Library (glibc) mq_notify function affecting versions 2.32 and 2.33. Attackers could exploit this to cause denial of service (application crashes) or potentially achieve arbitrary code execution. Systems running applications that use POSIX message queues with glibc 2.32-2.33 are affected.

💻 Affected Systems

Products:
  • GNU C Library (glibc)
Versions: 2.32 and 2.33
Operating Systems: Linux distributions using glibc 2.32-2.33
Default Config Vulnerable: ⚠️ Yes
Notes: Only affects applications using the mq_notify function with POSIX message queues. Many systems may not use this functionality.

📦 What is this software?

Glibc by Gnu

The GNU C Library (glibc) is the core C library for Linux systems, providing essential system calls and basic functions for all C programs. It is a fundamental component that nearly every Linux application depends on.

Learn more about Glibc →

Glibc by Gnu

The GNU C Library (glibc) is the core C library for Linux systems, providing essential system calls and basic functions for all C programs. It is a fundamental component that nearly every Linux application depends on.

Learn more about Glibc →

⚠️ Risk & Real-World Impact

🔴

Worst Case

Remote code execution leading to complete system compromise, though this requires specific conditions and hasn't been demonstrated publicly.

🟠

Likely Case

Denial of service through application crashes, potentially disrupting services that use POSIX message queues.

🟢

If Mitigated

Limited impact with proper patching and minimal use of vulnerable mq_notify functionality.

🌐 Internet-Facing: MEDIUM - Exploitation requires applications using mq_notify to be exposed, which is less common than other glibc functions.
🏢 Internal Only: MEDIUM - Similar risk profile internally, dependent on application usage patterns.

🎯 Exploit Status

Public PoC: ✅ No
Weaponized: NO
Unauthenticated Exploit: ✅ No
Complexity: HIGH

Exploitation requires control over the notification thread attributes object and specific timing conditions. No public exploits have been reported.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: glibc 2.34 and later, or backported patches for 2.32-2.33

Vendor Advisory: https://sourceware.org/bugzilla/show_bug.cgi?id=27896

Restart Required: Yes

Instructions:

1. Update glibc package using your distribution's package manager. 2. For Debian/Ubuntu: apt update && apt upgrade libc6. 3. For RHEL/CentOS: yum update glibc. 4. Restart affected applications or reboot system.

🔧 Temporary Workarounds

Disable mq_notify usage

linux

Avoid using mq_notify function in applications or disable POSIX message queue functionality where possible.

🧯 If You Can't Patch

  • Implement strict network segmentation to limit exposure of affected systems
  • Monitor for application crashes related to message queue operations and implement restart automation

🔍 How to Verify

Check if Vulnerable:

Check glibc version with: ldd --version | head -1

Check Version:

ldd --version | head -1

Verify Fix Applied:

Verify glibc version is 2.34+ or check with: strings /lib/x86_64-linux-gnu/libc.so.6 | grep 'GLIBC 2.3[2-3]' (should return no output if patched)

📡 Detection & Monitoring

Log Indicators:

  • Application crashes with segmentation faults in processes using message queues
  • Kernel logs showing memory corruption errors

Network Indicators:

  • Unusual process termination patterns in systems using POSIX message queues

SIEM Query:

process.name: (*mq* OR *glibc*) AND event.type: (crash OR segmentation_fault)

🔗 References

📤 Share & Export