A critical severity vulnerability, tracked as CVE-2026-35194, has been disclosed in Apache Flink, exposing the distributed processing engine to remote code execution attacks.
Apache Flink is widely known as a powerful framework and distributed processing engine designed to handle stateful computations over both unbounded and bounded data streams. However, a newly discovered SQL injection flaw in its code generation process is currently sounding the alarm for data engineering and security teams worldwide.
The vulnerability resides in the way Apache Flink handles SQL code generation. According to the security advisory, authenticated users who already possess query submission privileges can weaponize maliciously crafted SQL queries to execute arbitrary code directly on the TaskManagers.
The technical root cause is a dangerous input sanitization failure. The vulnerability specifically targets JSON functions (in versions 1.15.0 and newer) as well as LIKE expressions utilizing ESCAPE clauses (in versions 1.17.0 and newer). When these functions are processed, user-controlled strings are interpolated directly into the generated Java code without adequate escaping. This critical oversight allows an attacker to seamlessly break out of string literals and inject their own arbitrary expressions, leading to a complete system compromise at the Java execution level.
The vulnerable versions include:
- Apache Flink 1.15.0 through 1.20.x
- Apache Flink 2.0.0 through 2.x
(Note: Specifically, this impacts the 1.15.0 line before 1.20.4, 2.0.2, 2.1.2, and 2.2.1).
Given the “critical” severity rating, organizations leveraging Apache Flink for real-time analytics and data pipelines are urged to act immediately. Security maintainers have released patches that properly sanitize the code generation process and eliminate the injection vector.
Users are strongly recommended to upgrade their clusters to one of the following patched versions to permanently resolve the issue:
- Version 1.20.4
- Version 2.0.2
- Version 2.1.2
- Version 2.2.1
Support Our Threat Intelligence
If you find our CVE report and cybersecurity news helpful, consider supporting our work.