CVE-2022-36017: TensorFlow: DoS via malformed Requantize tensors
HIGH PoC AVAILABLEA network-exploitable denial-of-service in TensorFlow's Requantize op allows unauthenticated attackers to crash inference services by sending malformed tensor shapes — no auth, no special conditions. Any TF Serving deployment accepting external inputs is directly exposed. Patch immediately to TF 2.10.0, 2.9.1, 2.8.1, or 2.7.2; no workaround exists.
What is the risk?
High risk for organizations running TensorFlow Serving or any TF inference endpoint exposed to untrusted input. CVSS 7.5 (AV:N/AC:L/PR:N/UI:N) means a single malformed request can crash the ML inference service with zero prerequisites. Impact is limited to availability (no C/I compromise), but repeated DoS renders AI-dependent services unreliable at scale. Internal-only deployments have reduced but non-zero risk if adversaries gain lateral network access.
What systems are affected?
| Package | Ecosystem | Vulnerable Range | Patched |
|---|---|---|---|
| TensorFlow | pip | — | No patch |
Do you use TensorFlow? You're affected.
How severe is it?
What is the attack surface?
What should I do?
6 steps-
Patch to TF 2.10.0, TF 2.9.1, TF 2.8.1, or TF 2.7.2 (fix commit: 785d67a78a1d533759fcd2f5e8d6ef778de849e0).
-
No known workarounds — patching is the only remediation.
-
Add input validation at the API gateway layer to reject malformed or unexpected tensor ranks before reaching the model runtime.
-
Implement rate limiting and schema validation on TF Serving gRPC/HTTP endpoints.
-
Monitor inference service crash rates and pod restarts; alert on anomalous restart patterns.
-
Place TF Serving behind authenticated API gateways to reduce unauthenticated attack surface.
What does CISA's SSVC say?
Source: CISA Vulnrichment (SSVC v2.0). Decision based on the CISA Coordinator decision tree.
How is it classified?
Which compliance frameworks are affected?
This CVE is relevant to:
Frequently Asked Questions
What is CVE-2022-36017?
A network-exploitable denial-of-service in TensorFlow's Requantize op allows unauthenticated attackers to crash inference services by sending malformed tensor shapes — no auth, no special conditions. Any TF Serving deployment accepting external inputs is directly exposed. Patch immediately to TF 2.10.0, 2.9.1, 2.8.1, or 2.7.2; no workaround exists.
Is CVE-2022-36017 actively exploited?
Proof-of-concept exploit code is publicly available for CVE-2022-36017, increasing the risk of exploitation.
How to fix CVE-2022-36017?
1. Patch to TF 2.10.0, TF 2.9.1, TF 2.8.1, or TF 2.7.2 (fix commit: 785d67a78a1d533759fcd2f5e8d6ef778de849e0). 2. No known workarounds — patching is the only remediation. 3. Add input validation at the API gateway layer to reject malformed or unexpected tensor ranks before reaching the model runtime. 4. Implement rate limiting and schema validation on TF Serving gRPC/HTTP endpoints. 5. Monitor inference service crash rates and pod restarts; alert on anomalous restart patterns. 6. Place TF Serving behind authenticated API gateways to reduce unauthenticated attack surface.
What systems are affected by CVE-2022-36017?
This vulnerability affects the following AI/ML architecture patterns: model serving, training pipelines, inference APIs.
What is the CVSS score for CVE-2022-36017?
CVE-2022-36017 has a CVSS v3.1 base score of 7.5 (HIGH). The EPSS exploitation probability is 0.40%.
What is the AI security impact?
Affected AI Architectures
MITRE ATLAS Techniques
AML.T0029 Denial of AI Service AML.T0040 AI Model Inference API Access AML.T0049 Exploit Public-Facing Application Compliance Controls Affected
What are the technical details?
Original Advisory
TensorFlow is an open source platform for machine learning. If `Requantize` is given `input_min`, `input_max`, `requested_output_min`, `requested_output_max` tensors of a nonzero rank, it results in a segfault that can be used to trigger a denial of service attack. We have patched the issue in GitHub commit 785d67a78a1d533759fcd2f5e8d6ef778de849e0. The fix will be included in TensorFlow 2.10.0. We will also cherrypick this commit on TensorFlow 2.9.1, TensorFlow 2.8.1, and TensorFlow 2.7.2, as these are also affected and still in supported range. There are no known workarounds for this issue.
Exploitation Scenario
An adversary targeting an organization's AI inference service discovers a TensorFlow Serving endpoint via port scan or API documentation. They craft a gRPC prediction request containing a Requantize operation where input_min/input_max/requested_output_min/requested_output_max are supplied as rank-1+ tensors instead of the expected scalar (rank-0) values. This triggers a segfault in the TF runtime, crashing the inference process. In a Kubernetes deployment, the pod restarts automatically — but repeated requests at low rate maintain a persistent DoS, disrupting real-time prediction APIs without triggering volumetric DDoS defenses.
Weaknesses (CWE)
CWE-20 — Improper Input Validation: The product receives input or data, but it does not validate or incorrectly validates that the input has the properties that are required to process the data safely and correctly.
- [Architecture and Design] Consider using language-theoretic security (LangSec) techniques that characterize inputs using a formal language and build "recognizers" for that language. This effectively requires parsing to be a distinct layer that effectively enforces a boundary between raw input and internal data representations, instead of allowing parser code to be scattered throughout the program, where it could be subject to errors or inconsistencies that create weaknesses. [REF-1109] [REF-1110] [REF-1111]
- [Architecture and Design] Use an input validation framework such as Struts or the OWASP ESAPI Validation API. Note that using a framework does not automatically address all input validation problems; be mindful of weaknesses that could arise from misusing the framework itself (CWE-1173).
Source: MITRE CWE corpus.
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H References
Timeline
Related Vulnerabilities
CVE-2020-15196 9.9 TensorFlow: heap OOB read in sparse/ragged count ops
Same package: tensorflow CVE-2020-15205 9.8 TensorFlow: heap overflow in StringNGrams, ASLR bypass
Same package: tensorflow CVE-2020-15208 9.8 TFLite: OOB read/write via tensor dimension mismatch
Same package: tensorflow CVE-2019-16778 9.8 TensorFlow: heap overflow in UnsortedSegmentSum op
Same package: tensorflow CVE-2022-23587 9.8 TensorFlow: integer overflow in Grappler enables RCE
Same package: tensorflow