CVE-2020-1887

9.1 CRITICAL

📋 TL;DR

This vulnerability in osquery allows attackers to perform man-in-the-middle (MITM) attacks on osquery's TLS traffic when proper certificate validation is not configured. It affects osquery deployments where TLS is used without a configured root chain of trust. Organizations using vulnerable osquery versions for endpoint monitoring are at risk.

💻 Affected Systems

Products:
  • osquery
Versions: Versions after 2.9.0 and before 4.2.0
Operating Systems: All platforms supported by osquery
Default Config Vulnerable: ✅ No
Notes: Only vulnerable when TLS is used without a configured root chain of trust. The default osquery configuration may not use TLS, making many deployments not vulnerable.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Attackers could intercept, modify, or inject malicious data into osquery communications, potentially compromising endpoint monitoring data integrity and enabling lateral movement.

🟠

Likely Case

In environments without proper TLS certificate validation, attackers could intercept sensitive osquery data or inject false information into monitoring systems.

🟢

If Mitigated

With proper TLS certificate validation configured, the vulnerability has minimal impact as the SNI validation issue becomes irrelevant.

🌐 Internet-Facing: MEDIUM - Only affects osquery instances communicating over TLS without proper certificate validation to internet-facing endpoints.
🏢 Internal Only: MEDIUM - Internal osquery deployments using TLS without proper certificate validation are vulnerable to internal network MITM attacks.

🎯 Exploit Status

Public PoC: ✅ No
Weaponized: UNKNOWN
Unauthenticated Exploit: ✅ No
Complexity: MEDIUM

Requires network position to intercept TLS traffic and knowledge of osquery TLS configuration. Exploitation depends on specific deployment configurations.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: 4.2.0

Vendor Advisory: https://www.facebook.com/security/advisories/cve-2020-1887

Restart Required: Yes

Instructions:

1. Upgrade osquery to version 4.2.0 or later. 2. Restart osquery services. 3. Verify TLS configurations still work correctly after upgrade.

🔧 Temporary Workarounds

Configure TLS certificate validation

all

Ensure osquery TLS configurations include proper root certificate chain validation

# Configure osquery TLS flags with proper certificate validation
# Example: --tls_server_certs=/path/to/ca-bundle.crt

Disable TLS if not required

all

If TLS is not essential for your deployment, disable it temporarily

# Remove or comment out TLS-related flags in osquery configuration

🧯 If You Can't Patch

  • Ensure all osquery TLS connections use properly configured certificate validation with trusted root certificates
  • Implement network segmentation to limit potential MITM attack surfaces for osquery traffic

🔍 How to Verify

Check if Vulnerable:

Check osquery version with 'osqueryi --version' and verify if between 2.9.0 and 4.2.0, and check if TLS is configured without proper certificate validation.

Check Version:

osqueryi --version

Verify Fix Applied:

Verify osquery version is 4.2.0 or later with 'osqueryi --version' and test TLS connections with certificate validation.

📡 Detection & Monitoring

Log Indicators:

  • Unexpected TLS handshake failures
  • Certificate validation errors in osquery logs
  • Unusual network connections to osquery endpoints

Network Indicators:

  • Unencrypted osquery traffic when TLS expected
  • MITM patterns in network traffic
  • Unexpected certificates in TLS handshakes

SIEM Query:

source="osquery" AND (tls_handshake_failure OR certificate_error)

🔗 References

📤 Share & Export