CVE-2022-23583: TensorFlow: SavedModel type confusion triggers DoS crash
MEDIUM PoC AVAILABLE CISA: TRACK*A low-privileged attacker can crash TensorFlow inference services by supplying a malicious SavedModel with mismatched dtype fields, causing CHECK assertion failures. Any platform that loads externally-supplied or user-provided SavedModels is directly exposed. Patch to TF 2.8.0, 2.7.1, 2.6.3, or 2.5.3 immediately and restrict who can push models to your serving infrastructure.
Risk Assessment
Medium operational risk. CVSS 6.5 understates the practical impact for multi-tenant ML platforms: low complexity, low privileges, and network delivery make this trivially weaponizable for service disruption. Confidentiality and integrity are unaffected, but availability impact is high for shared inference endpoints. Organizations running internal-only, air-gapped model serving with controlled model provenance face significantly lower exposure.
Affected Systems
| Package | Ecosystem | Vulnerable Range | Patched |
|---|---|---|---|
| tensorflow | pip | — | No patch |
Do you use tensorflow? You're affected.
Severity & Risk
Attack Surface
Recommended Action
6 steps-
Patch: upgrade to TensorFlow 2.8.0, or cherry-pick to 2.7.1, 2.6.3, or 2.5.3.
-
Validate SavedModel integrity at ingestion: verify SHA-256 checksums and digital signatures before loading.
-
Restrict model upload permissions — only allow trusted CI/CD pipelines or verified model registries to push SavedModels to serving infrastructure.
-
Run model loading in isolated sandboxed processes with resource limits so a crash does not take down the entire inference service.
-
Monitor for unexpected process exits or CHECK failure logs in TensorFlow serving logs as an indicator of exploitation attempts.
-
Enforce protobuf schema validation on SavedModel files before deserialization.
CISA SSVC Assessment
Source: CISA Vulnrichment (SSVC v2.0). Decision based on the CISA Coordinator decision tree.
Classification
Compliance Impact
This CVE is relevant to:
Frequently Asked Questions
What is CVE-2022-23583?
A low-privileged attacker can crash TensorFlow inference services by supplying a malicious SavedModel with mismatched dtype fields, causing CHECK assertion failures. Any platform that loads externally-supplied or user-provided SavedModels is directly exposed. Patch to TF 2.8.0, 2.7.1, 2.6.3, or 2.5.3 immediately and restrict who can push models to your serving infrastructure.
Is CVE-2022-23583 actively exploited?
Proof-of-concept exploit code is publicly available for CVE-2022-23583, increasing the risk of exploitation.
How to fix CVE-2022-23583?
1. Patch: upgrade to TensorFlow 2.8.0, or cherry-pick to 2.7.1, 2.6.3, or 2.5.3. 2. Validate SavedModel integrity at ingestion: verify SHA-256 checksums and digital signatures before loading. 3. Restrict model upload permissions — only allow trusted CI/CD pipelines or verified model registries to push SavedModels to serving infrastructure. 4. Run model loading in isolated sandboxed processes with resource limits so a crash does not take down the entire inference service. 5. Monitor for unexpected process exits or CHECK failure logs in TensorFlow serving logs as an indicator of exploitation attempts. 6. Enforce protobuf schema validation on SavedModel files before deserialization.
What systems are affected by CVE-2022-23583?
This vulnerability affects the following AI/ML architecture patterns: model serving, training pipelines, multi-tenant ML platforms, model registries, inference endpoints.
What is the CVSS score for CVE-2022-23583?
CVE-2022-23583 has a CVSS v3.1 base score of 6.5 (MEDIUM). The EPSS exploitation probability is 0.29%.
Technical Details
NVD Description
Tensorflow is an Open Source Machine Learning Framework. A malicious user can cause a denial of service by altering a `SavedModel` such that any binary op would trigger `CHECK` failures. This occurs when the protobuf part corresponding to the tensor arguments is modified such that the `dtype` no longer matches the `dtype` expected by the op. In that case, calling the templated binary operator for the binary op would receive corrupted data, due to the type confusion involved. If `Tin` and `Tout` don't match the type of data in `out` and `input_*` tensors then `flat<*>` would interpret it wrongly. In most cases, this would be a silent failure, but we have noticed scenarios where this results in a `CHECK` crash, hence a denial of service. The fix will be included in TensorFlow 2.8.0. We will also cherrypick this commit on TensorFlow 2.7.1, TensorFlow 2.6.3, and TensorFlow 2.5.3, as these are also affected and still in supported range.
Exploitation Scenario
An adversary with a low-privilege account on a shared ML platform (e.g., a researcher account on an internal Kubeflow or MLflow deployment) crafts a SavedModel where the protobuf tensor descriptors for a binary op have a deliberately mismatched dtype — e.g., declaring float32 but providing int32 data. They upload this model to the model registry. When the inference service loads and executes the model, the templated binary operator in cwise_ops_common.h receives corrupted type data, the flat<> accessor interprets memory with the wrong type, and TensorFlow triggers a CHECK failure that crashes the serving process. If the service lacks process isolation or auto-restart, all tenants on that inference endpoint experience a complete outage until an operator intervenes.
Weaknesses (CWE)
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H References
- github.com/tensorflow/tensorflow/blob/a1320ec1eac186da1d03f033109191f715b2b130/tensorflow/core/kernels/cwise_ops_common.h Exploit 3rd Party
- github.com/tensorflow/tensorflow/commit/a7c02f1a9bbc35473969618a09ee5f9f5d3e52d9 Patch 3rd Party
- github.com/tensorflow/tensorflow/security/advisories/GHSA-gjqc-q9g6-q2j3 Patch 3rd Party
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
AI Threat Alert