登录
注册
开源
企业版
高校版
搜索
帮助中心
使用条款
关于我们
开源
企业版
高校版
私有云
模力方舟
登录
注册
9月20日,Gitee × 模力方舟来成都了!聚焦 AI 应用在开发范式、算力架构、交互设计、硬件选型等跨场景创新实践,点击立即报名~
代码拉取完成,页面将自动刷新
捐赠
捐赠前请先登录
取消
前往登录
扫描微信二维码支付
取消
支付完成
支付提示
将跳转至支付宝完成支付
确定
取消
Watch
不关注
关注所有动态
仅关注版本发行动态
关注但不提醒动态
132
Star
0
Fork
73
src-openEuler
/
rust
代码
Issues
14
Pull Requests
0
Wiki
统计
流水线
服务
JavaDoc
PHPDoc
质量分析
Jenkins for Gitee
腾讯云托管
腾讯云 Serverless
悬镜安全
阿里云 SAE
Codeblitz
SBOM
我知道了,不再自动展开
更新失败,请稍后重试!
移除标识
内容风险标识
本任务被
标识为内容中包含有代码安全 Bug 、隐私泄露等敏感信息,仓库外成员不可访问
CVE-2024-24576
已拒绝
#I9FBQX
CVE和安全问题
openeuler-ci-bot
拥有者
创建于
2024-04-10 02:45
一、漏洞信息 漏洞编号:[CVE-2024-24576](https://nvd.nist.gov/vuln/detail/CVE-2024-24576) 漏洞归属组件:[rust](https://gitee.com/src-openeuler/rust) 漏洞归属的版本:1.29.1,1.45.2,1.51.0,1.53.0,1.57.0,1.58.1,1.60.0,1.64.0,1.67.1,1.68.0,1.69.0,1.70.0,1.71.0,1.71.1,1.74.0 CVSS V3.0分值: BaseScore:10.0 Critical Vector:CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H 漏洞简述: Rust is a programming language. The Rust Security Response WG was notified that the Rust standard library prior to version 1.77.2 did not properly escape arguments when invoking batch files (with the `bat` and `cmd` extensions) on Windows using the `Command`. An attacker able to control the arguments passed to the spawned process could execute arbitrary shell commands by bypassing the escaping. The severity of this vulnerability is critical for those who invoke batch files on Windows with untrusted arguments. No other platform or use is affected.The `Command::arg` and `Command::args` APIs state in their documentation that the arguments will be passed to the spawned process as-is, regardless of the content of the arguments, and will not be evaluated by a shell. This means it should be safe to pass untrusted input as an argument.On Windows, the implementation of this is more complex than other platforms, because the Windows API only provides a single string containing all the arguments to the spawned process, and it s up to the spawned process to split them. Most programs use the standard C run-time argv, which in practice results in a mostly consistent way arguments are splitted.One exception though is `cmd.exe` (used among other things to execute batch files), which has its own argument splitting logic. That forces the standard library to implement custom escaping for arguments passed to batch files. Unfortunately it was reported that our escaping logic was not thorough enough, and it was possible to pass malicious arguments that would result in arbitrary shell execution.Due to the complexity of `cmd.exe`, we didn t identify a solution that would correctly escape arguments in all cases. To maintain our API guarantees, we improved the robustness of the escaping code, and changed the `Command` API to return an `InvalidInput` error when it cannot safely escape an argument. This error will be emitted when spawning the process.The fix is included in Rust 1.77.2. Note that the new escaping logic for batch files errs on the conservative side, and could reject valid arguments. Those who implement the escaping themselves or only handle trusted inputs on Windows can also use the `CommandExt::raw_arg` method to bypass the standard library s escaping logic. 漏洞公开时间:2024-04-10 02:15:08 漏洞创建时间:2024-04-10 02:45:36 漏洞详情参考链接: https://nvd.nist.gov/vuln/detail/CVE-2024-24576 <details> <summary>更多参考(点击展开)</summary> | 参考来源 | 参考链接 | 来源链接 | | ------- | -------- | -------- | | security-advisories.github.com | https://doc.rust-lang.org/std/io/enum.ErrorKind.html#variant.InvalidInput | | | security-advisories.github.com | https://doc.rust-lang.org/std/os/windows/process/trait.CommandExt.html#tymethod.raw_arg | | | security-advisories.github.com | https://doc.rust-lang.org/std/process/struct.Command.html | | | security-advisories.github.com | https://doc.rust-lang.org/std/process/struct.Command.html#method.arg | | | security-advisories.github.com | https://doc.rust-lang.org/std/process/struct.Command.html#method.args | | | security-advisories.github.com | https://github.com/rust-lang/rust/issues | | | security-advisories.github.com | https://github.com/rust-lang/rust/security/advisories/GHSA-q455-m56c-85mh | | | security-advisories.github.com | https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/N323QAEEUVTJ354BTVQ7UB6LYXUX2BCL/ | | | security-advisories.github.com | https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/RPH3PF7DVSS2LVIRLW254VWUPVKJN46P/ | | | security-advisories.github.com | https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/W7WRFOIAZXYUPGXGR5UEEW7VTTOD4SZ3/ | | | security-advisories.github.com | https://www.rust-lang.org/policies/security | | | ubuntu | https://github.com/rust-lang/rust/security/advisories/GHSA-q455-m56c-85mh | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://doc.rust-lang.org/std/io/enum.ErrorKind.html#variant.InvalidInput | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://doc.rust-lang.org/std/os/windows/process/trait.CommandExt.html#tymethod.raw_arg | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://doc.rust-lang.org/std/process/struct.Command.html | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://doc.rust-lang.org/std/process/struct.Command.html#method.arg | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://doc.rust-lang.org/std/process/struct.Command.html#method.args | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://github.com/rust-lang/rust/issues | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://www.rust-lang.org/policies/security | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://www.cve.org/CVERecord?id=CVE-2024-24576 | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://nvd.nist.gov/vuln/detail/CVE-2024-24576 | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://launchpad.net/bugs/cve/CVE-2024-24576 | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://security-tracker.debian.org/tracker/CVE-2024-24576 | https://ubuntu.com/security/CVE-2024-24576 | | debian | | https://security-tracker.debian.org/tracker/CVE-2024-24576 | | cve_search | | https://github.com/rust-lang/rust/security/advisories/GHSA-q455-m56c-85mh | | cve_search | | https://doc.rust-lang.org/std/io/enum.ErrorKind.html#variant.InvalidInput | | cve_search | | https://doc.rust-lang.org/std/os/windows/process/trait.CommandExt.html#tymethod.raw_arg | | cve_search | | https://doc.rust-lang.org/std/process/struct.Command.html | | cve_search | | https://doc.rust-lang.org/std/process/struct.Command.html#method.arg | | cve_search | | https://doc.rust-lang.org/std/process/struct.Command.html#method.args | | cve_search | | https://github.com/rust-lang/rust/issues | | cve_search | | https://www.rust-lang.org/policies/security | | cve_search | | https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/W7WRFOIAZXYUPGXGR5UEEW7VTTOD4SZ3/ | | cve_search | | https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/RPH3PF7DVSS2LVIRLW254VWUPVKJN46P/ | | cve_search | | https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/N323QAEEUVTJ354BTVQ7UB6LYXUX2BCL/ | | amazon_linux_explore | https://access.redhat.com/security/cve/CVE-2024-24576 | https://explore.alas.aws.amazon.com/CVE-2024-24576.html | | amazon_linux_explore | https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2024-24576 | https://explore.alas.aws.amazon.com/CVE-2024-24576.html | | security-advisories.github.com | https://www.kb.cert.org/vuls/id/123335 | | | ubuntu | https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2024-24576 | https://ubuntu.com/security/CVE-2024-24576 | </details> 漏洞分析指导链接: https://gitee.com/openeuler/cve-manager/blob/master/cve-vulner-manager/doc/md/manual.md 漏洞数据来源: openBrain开源漏洞感知系统 漏洞补丁信息: <details> <summary>详情(点击展开)</summary> 无 </details> 二、漏洞分析结构反馈 影响性分析说明: openEuler评分: 10.0 Vector:CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H 受影响版本排查(受影响/不受影响): 1.master(1.53.0): 2.openEuler-20.03-LTS-SP1(1.51.0): 3.openEuler-20.03-LTS-SP4(1.51.0): 4.openEuler-22.03-LTS(1.60.0): 5.openEuler-22.03-LTS-Next(1.64.0): 6.openEuler-22.03-LTS-SP1(1.60.0): 7.openEuler-22.03-LTS-SP2(1.64.0): 8.openEuler-22.03-LTS-SP3(1.64.0): 9.openEuler-24.03-LTS: 10.openEuler-24.03-LTS-Next: 修复是否涉及abi变化(是/否): 1.master(1.53.0): 2.openEuler-20.03-LTS-SP1(1.51.0): 3.openEuler-20.03-LTS-SP4(1.51.0): 4.openEuler-22.03-LTS(1.60.0): 5.openEuler-22.03-LTS-Next(1.64.0): 6.openEuler-22.03-LTS-SP1(1.60.0): 7.openEuler-22.03-LTS-SP2(1.64.0): 8.openEuler-22.03-LTS-SP3(1.64.0): 9.openEuler-24.03-LTS: 10.openEuler-24.03-LTS-Next:
一、漏洞信息 漏洞编号:[CVE-2024-24576](https://nvd.nist.gov/vuln/detail/CVE-2024-24576) 漏洞归属组件:[rust](https://gitee.com/src-openeuler/rust) 漏洞归属的版本:1.29.1,1.45.2,1.51.0,1.53.0,1.57.0,1.58.1,1.60.0,1.64.0,1.67.1,1.68.0,1.69.0,1.70.0,1.71.0,1.71.1,1.74.0 CVSS V3.0分值: BaseScore:10.0 Critical Vector:CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H 漏洞简述: Rust is a programming language. The Rust Security Response WG was notified that the Rust standard library prior to version 1.77.2 did not properly escape arguments when invoking batch files (with the `bat` and `cmd` extensions) on Windows using the `Command`. An attacker able to control the arguments passed to the spawned process could execute arbitrary shell commands by bypassing the escaping. The severity of this vulnerability is critical for those who invoke batch files on Windows with untrusted arguments. No other platform or use is affected.The `Command::arg` and `Command::args` APIs state in their documentation that the arguments will be passed to the spawned process as-is, regardless of the content of the arguments, and will not be evaluated by a shell. This means it should be safe to pass untrusted input as an argument.On Windows, the implementation of this is more complex than other platforms, because the Windows API only provides a single string containing all the arguments to the spawned process, and it s up to the spawned process to split them. Most programs use the standard C run-time argv, which in practice results in a mostly consistent way arguments are splitted.One exception though is `cmd.exe` (used among other things to execute batch files), which has its own argument splitting logic. That forces the standard library to implement custom escaping for arguments passed to batch files. Unfortunately it was reported that our escaping logic was not thorough enough, and it was possible to pass malicious arguments that would result in arbitrary shell execution.Due to the complexity of `cmd.exe`, we didn t identify a solution that would correctly escape arguments in all cases. To maintain our API guarantees, we improved the robustness of the escaping code, and changed the `Command` API to return an `InvalidInput` error when it cannot safely escape an argument. This error will be emitted when spawning the process.The fix is included in Rust 1.77.2. Note that the new escaping logic for batch files errs on the conservative side, and could reject valid arguments. Those who implement the escaping themselves or only handle trusted inputs on Windows can also use the `CommandExt::raw_arg` method to bypass the standard library s escaping logic. 漏洞公开时间:2024-04-10 02:15:08 漏洞创建时间:2024-04-10 02:45:36 漏洞详情参考链接: https://nvd.nist.gov/vuln/detail/CVE-2024-24576 <details> <summary>更多参考(点击展开)</summary> | 参考来源 | 参考链接 | 来源链接 | | ------- | -------- | -------- | | security-advisories.github.com | https://doc.rust-lang.org/std/io/enum.ErrorKind.html#variant.InvalidInput | | | security-advisories.github.com | https://doc.rust-lang.org/std/os/windows/process/trait.CommandExt.html#tymethod.raw_arg | | | security-advisories.github.com | https://doc.rust-lang.org/std/process/struct.Command.html | | | security-advisories.github.com | https://doc.rust-lang.org/std/process/struct.Command.html#method.arg | | | security-advisories.github.com | https://doc.rust-lang.org/std/process/struct.Command.html#method.args | | | security-advisories.github.com | https://github.com/rust-lang/rust/issues | | | security-advisories.github.com | https://github.com/rust-lang/rust/security/advisories/GHSA-q455-m56c-85mh | | | security-advisories.github.com | https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/N323QAEEUVTJ354BTVQ7UB6LYXUX2BCL/ | | | security-advisories.github.com | https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/RPH3PF7DVSS2LVIRLW254VWUPVKJN46P/ | | | security-advisories.github.com | https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/W7WRFOIAZXYUPGXGR5UEEW7VTTOD4SZ3/ | | | security-advisories.github.com | https://www.rust-lang.org/policies/security | | | ubuntu | https://github.com/rust-lang/rust/security/advisories/GHSA-q455-m56c-85mh | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://doc.rust-lang.org/std/io/enum.ErrorKind.html#variant.InvalidInput | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://doc.rust-lang.org/std/os/windows/process/trait.CommandExt.html#tymethod.raw_arg | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://doc.rust-lang.org/std/process/struct.Command.html | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://doc.rust-lang.org/std/process/struct.Command.html#method.arg | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://doc.rust-lang.org/std/process/struct.Command.html#method.args | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://github.com/rust-lang/rust/issues | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://www.rust-lang.org/policies/security | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://www.cve.org/CVERecord?id=CVE-2024-24576 | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://nvd.nist.gov/vuln/detail/CVE-2024-24576 | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://launchpad.net/bugs/cve/CVE-2024-24576 | https://ubuntu.com/security/CVE-2024-24576 | | ubuntu | https://security-tracker.debian.org/tracker/CVE-2024-24576 | https://ubuntu.com/security/CVE-2024-24576 | | debian | | https://security-tracker.debian.org/tracker/CVE-2024-24576 | | cve_search | | https://github.com/rust-lang/rust/security/advisories/GHSA-q455-m56c-85mh | | cve_search | | https://doc.rust-lang.org/std/io/enum.ErrorKind.html#variant.InvalidInput | | cve_search | | https://doc.rust-lang.org/std/os/windows/process/trait.CommandExt.html#tymethod.raw_arg | | cve_search | | https://doc.rust-lang.org/std/process/struct.Command.html | | cve_search | | https://doc.rust-lang.org/std/process/struct.Command.html#method.arg | | cve_search | | https://doc.rust-lang.org/std/process/struct.Command.html#method.args | | cve_search | | https://github.com/rust-lang/rust/issues | | cve_search | | https://www.rust-lang.org/policies/security | | cve_search | | https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/W7WRFOIAZXYUPGXGR5UEEW7VTTOD4SZ3/ | | cve_search | | https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/RPH3PF7DVSS2LVIRLW254VWUPVKJN46P/ | | cve_search | | https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/N323QAEEUVTJ354BTVQ7UB6LYXUX2BCL/ | | amazon_linux_explore | https://access.redhat.com/security/cve/CVE-2024-24576 | https://explore.alas.aws.amazon.com/CVE-2024-24576.html | | amazon_linux_explore | https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2024-24576 | https://explore.alas.aws.amazon.com/CVE-2024-24576.html | | security-advisories.github.com | https://www.kb.cert.org/vuls/id/123335 | | | ubuntu | https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2024-24576 | https://ubuntu.com/security/CVE-2024-24576 | </details> 漏洞分析指导链接: https://gitee.com/openeuler/cve-manager/blob/master/cve-vulner-manager/doc/md/manual.md 漏洞数据来源: openBrain开源漏洞感知系统 漏洞补丁信息: <details> <summary>详情(点击展开)</summary> 无 </details> 二、漏洞分析结构反馈 影响性分析说明: openEuler评分: 10.0 Vector:CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H 受影响版本排查(受影响/不受影响): 1.master(1.53.0): 2.openEuler-20.03-LTS-SP1(1.51.0): 3.openEuler-20.03-LTS-SP4(1.51.0): 4.openEuler-22.03-LTS(1.60.0): 5.openEuler-22.03-LTS-Next(1.64.0): 6.openEuler-22.03-LTS-SP1(1.60.0): 7.openEuler-22.03-LTS-SP2(1.64.0): 8.openEuler-22.03-LTS-SP3(1.64.0): 9.openEuler-24.03-LTS: 10.openEuler-24.03-LTS-Next: 修复是否涉及abi变化(是/否): 1.master(1.53.0): 2.openEuler-20.03-LTS-SP1(1.51.0): 3.openEuler-20.03-LTS-SP4(1.51.0): 4.openEuler-22.03-LTS(1.60.0): 5.openEuler-22.03-LTS-Next(1.64.0): 6.openEuler-22.03-LTS-SP1(1.60.0): 7.openEuler-22.03-LTS-SP2(1.64.0): 8.openEuler-22.03-LTS-SP3(1.64.0): 9.openEuler-24.03-LTS: 10.openEuler-24.03-LTS-Next:
评论 (
10
)
登录
后才可以发表评论
状态
已拒绝
待办的
已挂起
进行中
已完成
已拒绝
负责人
未设置
标签
CVE/UNFIXED
sig/sig-Rust
未设置
项目
未立项任务
未立项任务
里程碑
未关联里程碑
未关联里程碑
Pull Requests
未关联
未关联
关联的 Pull Requests 被合并后可能会关闭此 issue
分支
未关联
分支 (31)
标签 (26)
master
openEuler-24.03-LTS-SP1
openEuler-25.09
openEuler-24.03-LTS-Next
openEuler-24.03-LTS-SP2
openEuler-25.03
openEuler-22.03-LTS-SP3
openEuler-22.03-LTS-SP4
openEuler-22.03-LTS-SP1
openEuler-24.09
openEuler-20.03-LTS-SP4
openEuler-24.03-LTS
sync-pr129-openEuler-24.03-LTS-to-master
openEuler-22.03-LTS-Next
openEuler-20.03-LTS-SP1
openEuler-22.03-LTS-SP2
openEuler-22.03-LTS
openEuler-23.09
openEuler-23.03
openEuler-22.03-LTS-LoongArch
openEuler-22.09
openEuler-20.03-LTS-SP3
openEuler-20.03-LTS
openEuler-20.03-LTS-SP2
openEuler-21.09
openEuler-20.03-LTS-Next
openEuler-21.03
openEuler-20.09
20.09
openEuler1.0
openEuler1.0-base
openEuler-24.03-LTS-SP2-release
openEuler-24.03-LTS-SP1-update-20250516
openEuler-25.03-release
openEuler-22.03-LTS-SP3-update-20250307
openEuler-22.03-LTS-SP4-update-20250307
openEuler-24.03-LTS-SP1-release
openEuler-24.09-release
openEuler-22.03-LTS-SP4-release
openEuler-24.03-LTS-release
openEuler-22.03-LTS-SP3-release
openEuler-23.09-rc5
openEuler-22.03-LTS-SP1-release
openEuler-22.09-release
openEuler-22.09-rc5
openEuler-22.09-20220829
openEuler-22.03-LTS-20220331
openEuler-22.03-LTS-round5
openEuler-22.03-LTS-round3
openEuler-22.03-LTS-round2
openEuler-22.03-LTS-round1
openEuler-20.03-LTS-SP3-release
openEuler-20.03-LTS-SP2-20210624
openEuler-21.03-20210330
openEuler-20.09-20200929
openEuler-20.03-LTS-20200606
openEuler-20.03-LTS-tag
开始日期   -   截止日期
-
置顶选项
不置顶
置顶等级:高
置顶等级:中
置顶等级:低
优先级
不指定
严重
主要
次要
不重要
预计工期
(小时)
参与者(1)
1
https://gitee.com/src-openeuler/rust.git
git@gitee.com:src-openeuler/rust.git
src-openeuler
rust
rust
点此查找更多帮助
搜索帮助
Git 命令在线学习
如何在 Gitee 导入 GitHub 仓库
Git 仓库基础操作
企业版和社区版功能对比
SSH 公钥设置
如何处理代码冲突
仓库体积过大,如何减小?
如何找回被删除的仓库数据
Gitee 产品配额说明
GitHub仓库快速导入Gitee及同步更新
什么是 Release(发行版)
将 PHP 项目自动发布到 packagist.org
仓库举报
回到顶部
登录提示
该操作需登录 Gitee 帐号,请先登录后再操作。
立即登录
没有帐号,去注册