CVE-2021-20211

7.5 HIGH

📋 TL;DR

A memory leak vulnerability in Privoxy versions before 3.0.29 when client tags are active can cause the application to crash, leading to denial of service. This affects systems running vulnerable Privoxy configurations with client tagging enabled. Organizations using Privoxy as a web proxy with client tags are at risk.

💻 Affected Systems

Products:
  • Privoxy
Versions: All versions before 3.0.29
Operating Systems: Linux, BSD, Unix-like systems, Windows
Default Config Vulnerable: ✅ No
Notes: Only vulnerable when client tags are enabled in configuration. Default installations without client tags are not affected.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Privoxy process crashes repeatedly, causing complete loss of proxy functionality and disrupting all web traffic through the proxy server.

🟠

Likely Case

Gradual memory exhaustion leads to Privoxy crashes, causing intermittent proxy service disruptions until restarted.

🟢

If Mitigated

With client tags disabled or memory limits in place, the vulnerability cannot be triggered and normal operation continues.

🌐 Internet-Facing: MEDIUM - Internet-facing Privoxy instances could be targeted to cause service disruption, but exploitation requires specific configuration.
🏢 Internal Only: LOW - Internal-only deployments have limited attack surface and the impact is primarily availability rather than data compromise.

🎯 Exploit Status

Public PoC: ✅ No
Weaponized: UNKNOWN
Unauthenticated Exploit: ⚠️ Yes
Complexity: LOW

Exploitation requires sending traffic through a vulnerable Privoxy instance with client tags enabled. No authentication needed to trigger the memory leak.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: 3.0.29 and later

Vendor Advisory: https://www.privoxy.org/3.0.29/user-manual/whatsnew.html

Restart Required: Yes

Instructions:

1. Download Privoxy 3.0.29 or later from privoxy.org. 2. Stop the current Privoxy service. 3. Install the updated version. 4. Restart the Privoxy service. 5. Verify the new version is running.

🔧 Temporary Workarounds

Disable Client Tags

all

Remove or comment out client tag configurations to prevent triggering the memory leak

# Edit privoxy config file
# Comment out or remove lines containing: client-header-tagger
# Restart privoxy: systemctl restart privoxy

Memory Limit Configuration

linux

Configure system memory limits for the Privoxy process to prevent complete system exhaustion

# Set memory limits via systemd:
# In /etc/systemd/system/privoxy.service.d/memory.conf:
# [Service]
# MemoryMax=512M
# systemctl daemon-reload
# systemctl restart privoxy

🧯 If You Can't Patch

  • Disable client tags in Privoxy configuration immediately
  • Implement monitoring for Privoxy memory usage and restart automatically if thresholds exceeded

🔍 How to Verify

Check if Vulnerable:

Check Privoxy version and configuration: 'privoxy --version' and examine config for client-header-tagger directives

Check Version:

privoxy --version

Verify Fix Applied:

Confirm version is 3.0.29 or later: 'privoxy --version | grep -q "3.0.29\|3.0.3[0-9]\|3.[1-9]"'

📡 Detection & Monitoring

Log Indicators:

  • Privoxy crash logs
  • Memory allocation failure messages
  • Frequent restarts in system logs

Network Indicators:

  • Sudden loss of proxy connectivity
  • HTTP 502/503 errors from proxy

SIEM Query:

source="privoxy.log" ("crash" OR "segmentation fault" OR "memory" OR "restart")

🔗 References

📤 Share & Export