CVE-2019-7612

9.8 CRITICAL

📋 TL;DR

CVE-2019-7612 is a sensitive data disclosure vulnerability in Logstash where malformed URLs in configuration files cause credentials to be logged in error messages. This affects Logstash versions before 5.6.15 and 6.6.1, potentially exposing authentication credentials to anyone with access to logs.

💻 Affected Systems

Products:
  • Elastic Logstash
Versions: All versions before 5.6.15 and 6.6.1
Operating Systems: All platforms running affected Logstash versions
Default Config Vulnerable: ⚠️ Yes
Notes: Vulnerability triggers when Logstash configuration contains malformed URLs with embedded credentials. Any configuration using URL-based inputs/outputs with authentication is potentially affected.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Attackers gain access to sensitive credentials (database passwords, API keys, authentication tokens) from error logs, leading to complete system compromise, data exfiltration, or lateral movement.

🟠

Likely Case

Administrators or users with log access inadvertently expose credentials, potentially leading to credential reuse attacks or unauthorized access to connected systems.

🟢

If Mitigated

With proper log access controls and monitoring, exposure is limited to authorized personnel only, reducing risk of external exploitation.

🌐 Internet-Facing: MEDIUM - While the vulnerability itself doesn't expose services directly, exposed credentials could lead to compromise of internet-facing systems if credentials are reused.
🏢 Internal Only: HIGH - Internal users with log access can extract credentials, potentially leading to privilege escalation and lateral movement within the network.

🎯 Exploit Status

Public PoC: ✅ No
Weaponized: UNKNOWN
Unauthenticated Exploit: ✅ No
Complexity: LOW - Requires ability to modify Logstash configuration or induce configuration errors with malformed URLs.

Exploitation requires access to modify Logstash configuration files or induce configuration parsing errors. No public exploit code has been documented.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: 5.6.15 or 6.6.1 and later

Vendor Advisory: https://discuss.elastic.co/t/elastic-stack-6-6-1-and-5-6-15-security-update/169077

Restart Required: Yes

Instructions:

1. Stop Logstash service. 2. Backup configuration files. 3. Upgrade to Logstash 5.6.15+ or 6.6.1+ using package manager or manual installation. 4. Verify configuration files don't contain malformed URLs. 5. Restart Logstash service.

🔧 Temporary Workarounds

Restrict Log Access

linux

Limit access to Logstash log files to authorized personnel only using file permissions.

chmod 640 /var/log/logstash/*
chown root:logstash /var/log/logstash/*

Monitor Log Files

all

Implement log monitoring to detect credential exposure in error messages.

grep -i 'password\|credential\|auth' /var/log/logstash/*.log

🧯 If You Can't Patch

  • Review and sanitize all Logstash configuration files to ensure URLs are properly formatted without embedded credentials in plain text
  • Implement strict access controls on log directories and consider log encryption or redaction for sensitive information

🔍 How to Verify

Check if Vulnerable:

Check Logstash version: /usr/share/logstash/bin/logstash --version. If version is below 5.6.15 or 6.6.1, system is vulnerable.

Check Version:

/usr/share/logstash/bin/logstash --version

Verify Fix Applied:

After upgrade, verify version is 5.6.15+ or 6.6.1+ and test with a malformed URL configuration to confirm credentials are not logged.

📡 Detection & Monitoring

Log Indicators:

  • Error messages containing URL parsing failures with embedded credentials
  • Log entries showing authentication strings in clear text

Network Indicators:

  • Unusual authentication attempts to systems connected via Logstash using potentially exposed credentials

SIEM Query:

source="logstash*" AND ("malformed URL" OR "error parsing URL") AND (password OR auth OR credential)

🔗 References

📤 Share & Export