PT-2021-22018 · Google+6 · Go+6

Ben Lubar

·

Published

2021-10-12

·

Updated

2025-09-29

·

CVE-2021-38297

CVSS v3.1

9.8

Critical

VectorAV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Name of the Vulnerable Software and Affected Versions: Go versions prior to 1.16.9 Go versions 1.17.x prior to 1.17.2
Description: The issue is a buffer overflow that occurs when large arguments are passed in a function invocation from a WASM module, specifically when using GOARCH=wasm and GOOS=js. This can cause portions of the module to be overwritten with data from the arguments.
Recommendations: For Go versions prior to 1.16.9, update to version 1.16.9 or later. For Go versions 1.17.x prior to 1.17.2, update to version 1.17.2 or later. As a temporary workaround, consider rebuilding any modules and replacing the wasm exec.js file as described in the official Go documentation. Restrict the use of large arguments in function invocations from WASM modules to minimize the risk of exploitation.

Exploit

Fix

Buffer Overflow

Found an issue in the description? Have something to add? Feel free to write us 👾

Weakness Enumeration

Related Identifiers

ALSA-2022:1819
ALSA-2022_1819
ALSA-2022_5775
ALSA-2022_5799
ALSA-2022_7548
ALSA-2022_7648
ALSA-2022_7950
ALSA-2022_8098
ALSA-2022_8250
ALSA-2023_2177
ALSA-2023_2193
ALSA-2023_2236
ALSA-2023_2253
ALSA-2023_2282
ALSA-2023_2283
ALSA-2023_2367
ALSA-2023_2758
ALSA-2023_2785
ALSA-2023_2802
ALSA-2024_2180
ALSA-2025_16880
ALT-PU-2021-3019
ALT-PU-2021-3222
ALT-PU-2022-1243
ALT-PU-2022-2873
AZL-6450
BIT-GOLANG-2021-38297
CESA-2022_1819
CVE-2021-38297
DLA-3395-1
DLA-3395-2
ELSA-2022-1819
GO-2022-0247
MGASA-2021-0475
OESA-2021-1402
OPENSUSE-SU-2021:1420-1
OPENSUSE-SU-2021:3487-1
OPENSUSE-SU-2021:3488-1
OPENSUSE-SU-2021_1420-1
OPENSUSE-SU-2021_3487-1
OPENSUSE-SU-2021_3488-1
OPENSUSE-SU-2024:11567-1
OPENSUSE-SU-2024:11568-1
OPENSUSE-SU-2024:12758-1
OPENSUSE-SU-2024:12759-1
RHSA-2022:0432
RHSA-2022:1819
RHSA-2022_1819
RLSA-2022:1819
RLSA-2022_1819
SUSE-SU-2021:3487-1
SUSE-SU-2021:3488-1
SUSE-SU-2021_3487-1
SUSE-SU-2021_3488-1
SUSE-SU-2023:0600-1
SUSE-SU-2023:0601-1
SUSE-SU-2023:0602-1
SUSE-SU-2023:0603-1
SUSE-SU-2023_0600-1
SUSE-SU-2023_0601-1
SUSE-SU-2023_0602-1
SUSE-SU-2023_0603-1

Affected Products

Alt Linux
Almalinux
Centos
Go
Red Hat
Rocky Linux
Suse