Goal Reached Thanks to every supporter — we hit 100%!

Goal: 1000 CNY · Raised: 1359 CNY

100%

CVE-2021-41228— Code injection in `saved_model_cli`

Quick assessment

Affected
tensorflow tensorflow
Exploitation
No confirmed in-the-wild exploitation; assess based on exposure
Recommended action
Check the vendor advisory and references for a fixed version. If immediate upgrade is impossible, restrict exposure and increase monitoring.

Google TensorFlow是美国谷歌(Google)公司的一套用于机器学习的端到端开源平台。 Google TensorFlow 存在代码注入漏洞,该漏洞源于 saved_model_cli 工具容易受到代码注入的影响,因为它会在用户提供的字符串上调用 eval。 攻击者可以使用它在 CLI 工具运行的平台上运行任意代码。 不过,鉴于该工具始终是手动运行的,因此其影响并不严重。 我们通过添加一个默认为 True 的 safe 标志和对用户的明确警告来修补这个问题。

CVSS 7.5 · High EPSS 0.22% · P12

Possible ATT&CK Techniques 1 AI

T1059 · Command and Scripting Interpreter
Get alerts for future matching vulnerabilities Log in to subscribe

I. Basic Information for CVE-2021-41228

Vulnerability Information

Have questions about the vulnerability? See if Shenlong's analysis helps!
View Shenlong Deep Dive ↗

Although we use advanced large model technology, its output may still contain inaccurate or outdated information.Shenlong tries to ensure data accuracy, but please verify and judge based on the actual situation.

Vulnerability Title
Code injection in `saved_model_cli`
Source: CVE Program / CVE List V5
Vulnerability Description
TensorFlow is an open source platform for machine learning. In affected versions TensorFlow's `saved_model_cli` tool is vulnerable to a code injection as it calls `eval` on user supplied strings. This can be used by attackers to run arbitrary code on the plaform where the CLI tool runs. However, given that the tool is always run manually, the impact of this is not severe. We have patched this by adding a `safe` flag which defaults to `True` and an explicit warning for users. The fix will be included in TensorFlow 2.7.0. We will also cherrypick this commit on TensorFlow 2.6.1, TensorFlow 2.5.2, and TensorFlow 2.4.4, as these are also affected and still in supported range.
Source: CVE Program / CVE List V5
CVSS Information
CVSS:3.1/AV:L/AC:H/PR:H/UI:N/S:C/C:H/I:H/A:H
Source: CVE Program / CVE List V5
Vulnerability Type
OS命令中使用的特殊元素转义处理不恰当(OS命令注入)
Source: CVE Program / CVE List V5
Vulnerability Title
Google TensorFlow 代码注入漏洞
Source: CNNVD (China National Vulnerability Database)
Vulnerability Description
Google TensorFlow是美国谷歌(Google)公司的一套用于机器学习的端到端开源平台。 Google TensorFlow 存在代码注入漏洞,该漏洞源于 saved_model_cli 工具容易受到代码注入的影响,因为它会在用户提供的字符串上调用 eval。 攻击者可以使用它在 CLI 工具运行的平台上运行任意代码。 不过,鉴于该工具始终是手动运行的,因此其影响并不严重。 我们通过添加一个默认为 True 的 safe 标志和对用户的明确警告来修补这个问题。
Source: CNNVD (China National Vulnerability Database)
CVSS Information
N/A
Source: CNNVD (China National Vulnerability Database)
Vulnerability Type
N/A
Source: CNNVD (China National Vulnerability Database)

Affected Products

Vendor Product Affected Versions CPE Subscribe
tensorflow tensorflow >= 2.6.0, < 2.6.1 -

II. Public POCs for CVE-2021-41228

# POC Description Source Link Shenlong Link
AI-Generated POC Premium

No public POC found.

Login to generate AI POC

III. Intelligence Information for CVE-2021-41228

请登录查看更多情报信息。

Patches & Fixes for CVE-2021-41228 (1)

Vendor Advisories for CVE-2021-41228 (1)

Same Patch Batch · tensorflow · 2021-11-05 · 34 CVEs total

CVE-2021-41208 8.8 HIGH Incomplete validation in boosted trees code
CVE-2021-41220 7.8 HIGH Use after free in `CollectiveReduceV2`
CVE-2021-41221 7.8 HIGH Access to invalid memory during shape inference in `Cudnn*` ops
CVE-2021-41214 7.8 HIGH Reference binding to `nullptr` in `tf.ragged.cross`
CVE-2021-41219 7.8 HIGH Undefined behavior via `nullptr` reference binding in sparse matrix multiplication
CVE-2021-41201 7.8 HIGH Unitialized access in `EinsumHelper::ParseEquation`
CVE-2021-41203 7.8 HIGH Missing validation during checkpoint loading
CVE-2021-41224 7.1 HIGH `SparseFillEmptyRows` heap OOB read
CVE-2021-41223 7.1 HIGH Heap OOB read in `FusedBatchNorm` kernels
CVE-2021-41226 7.1 HIGH Heap OOB read in `SparseBinCount`
CVE-2021-41212 7.1 HIGH Heap OOB read in `tf.ragged.cross`
CVE-2021-41211 7.1 HIGH Heap OOB read in shape inference for `QuantizeV2`
CVE-2021-41205 7.1 HIGH Heap OOB read in all `tf.raw_ops.QuantizeAndDequantizeV*` ops
CVE-2021-41210 7.1 HIGH Heap OOB read in `tf.raw_ops.SparseCountSparseOutput`
CVE-2021-41206 7.0 HIGH Incomplete validation of shapes in multiple TF ops
CVE-2021-41227 6.6 MEDIUM Arbitrary memory read in `ImmutableConst`
CVE-2021-41200 5.5 MEDIUM Incomplete validation in `tf.summary.create_file_writer`
CVE-2021-41197 5.5 MEDIUM Crashes due to overflow and `CHECK`-fail in ops with large tensor shapes
CVE-2021-41198 5.5 MEDIUM Overflow/crash in `tf.tile` when tiling tensor is large
CVE-2021-41199 5.5 MEDIUM Overflow/crash in `tf.image.resize` when size is large

Showing top 20 of 34 CVEs. View all on vendor page &rarr; →

IV. Related Vulnerabilities