Amazon Linux 2:golang (ALAS-2022-1830)

critical Nessus 插件 ID 163918

简介

远程 Amazon Linux 2 主机缺少安全更新。

描述

远程主机上安装的 golang 版本低于 1.18.3-1。因此,它受到 ALAS2-2022-1830 公告中提及的多个漏洞影响。

- 适用于 Go 的 golang.org/x/crypto/ssh 组件 v0.0.0-20201203163018-be400aefbc4c 以及之前的所有版本中存在 nil 指针取消引用问题,允许远程攻击者针对 SSH 服务器发动拒绝服务攻击。(CVE-2020-29652)

- 如果自定义 TokenReader(针对 xml.NewTokenDecoder)在元素中间返回 EOF,则低于 1.15.9 的 Go 和低于 1.16.1 的 1.16.x 中的 encoding/xml 会出现无限循环。此问题会发生在 Decode、DecodeElement 或 Skip 方法中。(CVE-2021-27918)

- 在 Go 1.16.x 的 1.16.1 之前版本中,archive/zip 允许攻击者在对任何文件名开头出现 ../ 的 ZIP 存档尝试使用 Reader.Open API 时造成程序拒绝服务(发生错误)。(CVE-2021-27919)

- 在低于 1.15.13 的 Go 版本以及低于 1.16.5 的 1.16.x 版本中,用于 DNS 查找的函数未验证来自 DNS 服务器的回复,因此返回值可能包含不符合 RFC1035 格式的不安全注入(例如 XSS)。(CVE-2021-33195)

- 在 Go 语言 1.15.13 版本前以及 1.16.5 之前的 1.16.x 版本中,反向代理的部分配置(来自 net/http/httputil)导致攻击者能够终止任意标头。
(CVE-2021-33197)

- 在 Go 语言 1.15.13 版本前以及 1.16.5 之前的 1.16.x 版本中,大指数 math/big.Rat SetString 或 UnmarshalText 方法可能会出现错误。 (CVE-2021-33198)

- 在低于 1.15.15 的 Go 版本和低于 1.16.7 的 1.16.x 版本中存在争用条件,可在 ErrAbortHandler 中止时导致 net/http/httputil ReverseProxy 错误。(CVE-2021-36221)

- 在 Go 1.16.9 之前版本以及 Go 1.17.x 至 1.17.2 版本中使用 GOARCH=wasm GOOS=js 时,通过大型参数从 WASM 模块调用函数会产生缓冲区溢出问题。(CVE-2021-38297)

- 在 Go 1.16.8 之前版本和 1.17.x 至 1.17.1 版本中,archive/zip 中的一个构建的 archive 标头(错误地指定存在许多文件)可能会造成 NewReader 或 OpenReader 错误。注意:此问题是因对 CVE-2021-33196 的修复不完整所致。(CVE-2021-39293)

- Go 1.16.14 之前版本以及 Go 1.17.x 至 1.17.7 版本的 math/big 的 Rat.SetString 中存在溢出漏洞,该漏洞可能导致不受控制的内存消耗问题。(CVE-2022-23772)

- Go 1.16.14 之前版本和 1.17.x 至 1.17.7 版本中的 cmd/go 可能会错误地将分支名称解读为版本标记。如果执行者能够创建分支但不能创建标签,则这可能导致错误控制访问权限。(CVE-2022-23773)

- Go 1.16.14 之前版本以及 Go 1.17.x 至 1.17.7 版本的 crypto/elliptic 中的 Curve.IsOnCurve 在 big.Int 值不是有效字段元素的情况下,可能会错误地返回 true。(CVE-2022-23806)

- 在 Go 1.17.9 之前版本以及 1.18.x 的 1.18.1 之前版本中,encoding/pem 允许通过大量 PEM 数据造成解码堆栈溢出。(CVE-2022-24675)

- Go 1.16.15 之前版本以及 Go 1.17.x 至 1.17.8 版本中的 regexp.Compile 允许通过深度嵌套的表达式耗尽堆栈。(CVE-2022-24921)

- 在 Go 1.17.9 之前版本以及 1.18.x 的 1.18.1 之前版本中,crypto/elliptic 的通用 P-256 特征允许通过长标量输入造成错误。(CVE-2022-28327)

请注意,Nessus 尚未测试这些问题,而是只依据应用程序自我报告的版本号进行判断。

解决方案

运行 'yum update golang' 以更新系统。

另见

https://alas.aws.amazon.com/AL2/ALAS-2022-1830.html

https://alas.aws.amazon.com/cve/html/CVE-2020-29652.html

https://alas.aws.amazon.com/cve/html/CVE-2021-27918.html

https://alas.aws.amazon.com/cve/html/CVE-2021-27919.html

https://alas.aws.amazon.com/cve/html/CVE-2021-33195.html

https://alas.aws.amazon.com/cve/html/CVE-2021-33197.html

https://alas.aws.amazon.com/cve/html/CVE-2021-33198.html

https://alas.aws.amazon.com/cve/html/CVE-2021-36221.html

https://alas.aws.amazon.com/cve/html/CVE-2021-38297.html

https://alas.aws.amazon.com/cve/html/CVE-2021-39293.html

https://alas.aws.amazon.com/cve/html/CVE-2022-23772.html

https://alas.aws.amazon.com/cve/html/CVE-2022-23773.html

https://alas.aws.amazon.com/cve/html/CVE-2022-23806.html

https://alas.aws.amazon.com/cve/html/CVE-2022-24675.html

https://alas.aws.amazon.com/cve/html/CVE-2022-24921.html

https://alas.aws.amazon.com/cve/html/CVE-2022-28327.html

插件详情

严重性: Critical

ID: 163918

文件名: al2_ALAS-2022-1830.nasl

版本: 1.6

类型: local

代理: unix

发布时间: 2022/8/8

最近更新时间: 2023/12/8

支持的传感器: Agentless Assessment, Frictionless Assessment Agent, Frictionless Assessment AWS, Nessus Agent, Nessus

风险信息

VPR

风险因素: Medium

分数: 5.9

CVSS v2

风险因素: High

基本分数: 7.5

时间分数: 5.9

矢量: CVSS2#AV:N/AC:L/Au:N/C:P/I:P/A:P

CVSS 分数来源: CVE-2021-38297

CVSS v3

风险因素: Critical

基本分数: 9.8

时间分数: 8.8

矢量: CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

时间矢量: CVSS:3.0/E:P/RL:O/RC:C

漏洞信息

CPE: p-cpe:/a:amazon:linux:golang, p-cpe:/a:amazon:linux:golang-bin, p-cpe:/a:amazon:linux:golang-docs, p-cpe:/a:amazon:linux:golang-misc, p-cpe:/a:amazon:linux:golang-race, p-cpe:/a:amazon:linux:golang-shared, p-cpe:/a:amazon:linux:golang-src, p-cpe:/a:amazon:linux:golang-tests, cpe:/o:amazon:linux:2

必需的 KB 项: Host/local_checks_enabled, Host/AmazonLinux/release, Host/AmazonLinux/rpm-list

可利用: true

易利用性: Exploits are available

补丁发布日期: 2022/7/28

漏洞发布日期: 2020/12/17

参考资料信息

CVE: CVE-2020-29652, CVE-2021-27918, CVE-2021-27919, CVE-2021-33195, CVE-2021-33197, CVE-2021-33198, CVE-2021-36221, CVE-2021-38297, CVE-2021-39293, CVE-2022-23772, CVE-2022-23773, CVE-2022-23806, CVE-2022-24675, CVE-2022-24921, CVE-2022-28327

IAVB: 2021-B-0040-S, 2021-B-0069-S, 2022-B-0008-S, 2022-B-0011-S, 2023-B-0080-S