Skip to main content
VulnerabilityPublished

Inside PostHog: How SSRF, a ClickHouse SQL Escaping 0day, and Default PostgreSQL Credentials Formed an RCE Chain (ZDI-25-099, ZDI-25-097, ZDI-25-096)

Source Reddit NetSec

0
Severity
Medium

Rated by Threat Radar

Data as of 17 Dec 2025, 19:06 UTC

What to do

AI-suggested

1. Immediately change all default PostgreSQL credentials used by PostHog installations to strong, unique passwords. 2. Apply any available patches or updates to PostHog, ClickHouse, and PostgreSQL as soon as they are released addressing these vulnerabilities. 3. Restrict SSRF attack vectors by implementing strict input validation and network segmentation to limit internal service exposure. 4. Employ Web Application Firewalls (WAFs) with rules targeting SSRF and SQL injection patterns specific to ClickHouse. 5. Conduct thorough audits of database configurations to ensure secure authentication and authorization settings. 6. Monitor logs for unusual SSRF requests, suspicious SQL queries, and authentication anomalies. 7. Use network-level controls to restrict outbound requests from PostHog services to only necessary endpoints. 8. Educate development and operations teams about secure coding practices to prevent SQL injection and credential mismanagement. 9. Consider deploying runtime application self-protection (RASP) tools to detect and block exploitation attempts in real-time. 10. Prepare incident response plans tailored to potential RCE incidents involving analytics platforms.

Description

A critical remote code execution (RCE) vulnerability chain was discovered in PostHog involving Server-Side Request Forgery (SSRF), a zero-day SQL escaping flaw in ClickHouse, and default PostgreSQL credentials. This chain allows attackers to escalate from SSRF to full RCE on the affected system. Although no known exploits are currently in the wild, the combination of these vulnerabilities poses a significant risk. The vulnerabilities stem from improper input validation, insecure default credentials, and SQL injection weaknesses. European organizations using PostHog for analytics or data processing could face data breaches, system compromise, and service disruption. Mitigation requires immediate credential changes, patching or configuration hardening of ClickHouse and PostgreSQL, and restricting SSRF attack vectors. Countries with higher adoption of PostHog and related database technologies, such as Germany, the UK, France, and the Netherlands, are most at risk. Given the ease of exploitation and potential impact on confidentiality, integrity, and availability, this threat is assessed as high severity. Defenders should prioritize detection of SSRF attempts, audit default credentials, and apply security best practices to prevent exploitation.

References

Community reviews

Loading reviews…