CVE-2023-33976: TensorFlow: DoS via upper_bound rank validation crash
HIGHAn unauthenticated remote attacker can crash any TensorFlow service that processes user-supplied tensors through array_ops.upper_bound by sending a non-rank-2 tensor, causing an immediate segfault and service disruption. If your organization exposes TensorFlow inference endpoints to untrusted input, this is exploitable with trivial effort. Patch to TensorFlow 2.12 (cherrypick) or 2.13+ immediately; add tensor shape validation at API boundaries as a defense-in-depth measure.
What is the risk?
Risk is HIGH for externally-exposed TensorFlow serving infrastructure. The CVSS vector (AV:N/AC:L/PR:N/UI:N) means no authentication, no special knowledge, and network-accessible — a script-kiddie can trigger this. Impact is availability only (no data exfiltration), but crashing a production inference service can cascade into business disruption. Not in CISA KEV and no confirmed active exploitation, which reduces urgency slightly. Organizations running TensorFlow behind authentication layers or with strict input validation have materially lower exposure.
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?
5 steps-
PATCH
Upgrade to TensorFlow 2.13+ or apply the cherry-pick to TensorFlow 2.12 (commits 6fa05df and 915884f).
-
VALIDATE
Add explicit tensor rank checks before any call to array_ops.upper_bound — assert input.shape.rank == 2.
-
ISOLATE
Run TensorFlow serving processes with resource limits (ulimits, cgroups) to contain crash blast radius and enable auto-restart.
-
MONITOR
Alert on abnormal segfault/OOM kill rates in model serving containers — repeated crashes pattern may indicate active probing.
-
HARDEN
Deploy input schema validation (shape, dtype, rank) at API gateway layer before requests reach TensorFlow runtime.
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-2023-33976?
An unauthenticated remote attacker can crash any TensorFlow service that processes user-supplied tensors through array_ops.upper_bound by sending a non-rank-2 tensor, causing an immediate segfault and service disruption. If your organization exposes TensorFlow inference endpoints to untrusted input, this is exploitable with trivial effort. Patch to TensorFlow 2.12 (cherrypick) or 2.13+ immediately; add tensor shape validation at API boundaries as a defense-in-depth measure.
Is CVE-2023-33976 actively exploited?
No confirmed active exploitation of CVE-2023-33976 has been reported, but organizations should still patch proactively.
How to fix CVE-2023-33976?
1. PATCH: Upgrade to TensorFlow 2.13+ or apply the cherry-pick to TensorFlow 2.12 (commits 6fa05df and 915884f). 2. VALIDATE: Add explicit tensor rank checks before any call to array_ops.upper_bound — assert input.shape.rank == 2. 3. ISOLATE: Run TensorFlow serving processes with resource limits (ulimits, cgroups) to contain crash blast radius and enable auto-restart. 4. MONITOR: Alert on abnormal segfault/OOM kill rates in model serving containers — repeated crashes pattern may indicate active probing. 5. HARDEN: Deploy input schema validation (shape, dtype, rank) at API gateway layer before requests reach TensorFlow runtime.
What systems are affected by CVE-2023-33976?
This vulnerability affects the following AI/ML architecture patterns: model serving, inference APIs, training pipelines, custom ML ops.
What is the CVSS score for CVE-2023-33976?
CVE-2023-33976 has a CVSS v3.1 base score of 7.5 (HIGH). The EPSS exploitation probability is 0.36%.
What is the AI security impact?
Affected AI Architectures
MITRE ATLAS Techniques
AML.T0029 Denial of AI Service AML.T0034 Cost Harvesting AML.T0049 Exploit Public-Facing Application Compliance Controls Affected
What are the technical details?
Original Advisory
TensorFlow is an end-to-end open source platform for machine learning. `array_ops.upper_bound` causes a segfault when not given a rank 2 tensor. The fix will be included in TensorFlow 2.13 and will also cherrypick this commit on TensorFlow 2.12.
Exploitation Scenario
An adversary targeting an organization's AI-powered product (e.g., an ML inference API for fraud detection or image classification) sends a crafted HTTP request to the model serving endpoint with a rank-1 tensor payload instead of the expected rank-2 input. TensorFlow's array_ops.upper_bound dereferences an invalid memory address, triggering a segfault that crashes the serving process. If the service auto-restarts, the adversary can loop requests to maintain a persistent DoS condition at negligible cost. No authentication, no ML knowledge, and no exploit code is needed — only a malformed tensor shape.
Weaknesses (CWE)
CWE-190 — Integer Overflow or Wraparound: The product performs a calculation that can produce an integer overflow or wraparound when the logic assumes that the resulting value will always be larger than the original value. This occurs when an integer value is incremented to a value that is too large to store in the associated representation. When this occurs, the value may become a very small or negative number.
- [Requirements] Ensure that all protocols are strictly defined, such that all out-of-bounds behavior can be identified simply, and require strict conformance to the protocol.
- [Requirements] Use a language that does not allow this weakness to occur or provides constructs that make this weakness easier to avoid. If possible, choose a language or compiler that performs automatic bounds checking.
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