HIGH7.5
PYSEC-2022-102
Quick fix
PYSEC-2022-102 — tensorflow-cpu: upgrade to the fixed version with the command below.
pip install --upgrade 'tensorflow-cpu>=35f0fabb4c178253a964d7aabdbb15c6a398b69a'Details
Tensorflow is an Open Source Machine Learning Framework. The `simplifyBroadcast` function in the MLIR-TFRT infrastructure in TensorFlow is vulnerable to a segfault (hence, denial of service), if called with scalar shapes. If all shapes are scalar, then `maxRank` is 0, so we build an empty `SmallVector`. The fix will be included in TensorFlow 2.8.0. This is the only affected version.
Are you affected?
Enter the version of the package you're using.
Affected packages
PyPI/tensorflow-cpu
Introduced in:
0Fixed in: 35f0fabb4c178253a964d7aabdbb15c6a398b69aFix
pip install --upgrade 'tensorflow-cpu>=35f0fabb4c178253a964d7aabdbb15c6a398b69a'References
- https://github.com/tensorflow/tensorflow/blob/274df9b02330b790aa8de1cee164b70f72b9b244/tensorflow/compiler/mlir/tfrt/jit/transforms/tf_cpurt_symbolic_shape_optimization.cc#L149-L205[WEB]
- https://github.com/tensorflow/tensorflow/security/advisories/GHSA-gwcx-jrx4-92w2[ADVISORY]
- https://github.com/tensorflow/tensorflow/commit/35f0fabb4c178253a964d7aabdbb15c6a398b69a[FIX]
Check it before you install it
One call answers whether to add this package: known advisories, CISA KEV, and whether the name is a hallucinated or freshly squatted one. No key needed to try it.
curl -s https://vdb.ai.kr/v1/ai/check-packages \
-H 'Content-Type: application/json' \
-d '{"packages":["pkg:pypi/tensorflow-cpu"]}'