# CVE-2021-47642: video: fbdev: nvidiafb: Use strscpy() to prevent buffer overflow

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** HIGH 7.8
- **CVSS:** 7.8 (v3.1, NVD) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: High; Integrity impact: High; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.34% (percentile 20, 2026-11-26)
- **CWE:** CWE-787
- **Published:** 2025-02-26T01:54:13.193Z
- **Modified:** 2026-06-17T04:18:13.623Z

## Who should check

- Anyone running Linux \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 47e5533adf118afaf06d25a3e2aaaab89371b1c5; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 580e5d3815474b8349250c25c16416585a72c7fe; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 72dd5c46a152136712a55bf026a9aa8c1b12b60d; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 055cdd2e7b992921424d4daaa285ced787fb205f; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 08dff482012758935c185532b1ad7d584785a86e; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 9ff2f7294ab0f011cd4d1b7dcd9a07d8fdf72834; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 6a5226e544ac043bb2d8dc1bfe8920d02282f7cd; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 41baa86b6c802cdc6ab8ff2d46c083c9be93de81; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 37a1a2e6eeeb101285cd34e12e48a881524701aa
- Anyone running Linux 2.6.12

## Description

In the Linux kernel, the following vulnerability has been resolved:

video: fbdev: nvidiafb: Use strscpy() to prevent buffer overflow

Coverity complains of a possible buffer overflow. However,
given the 'static' scope of nvidia\_setup\_i2c\_bus() it looks
like that can't happen after examiniing the call sites.

CID 19036 (\#1 of 1): Copy into fixed size buffer (STRING\_OVERFLOW)
1. fixed\_size\_dest: You might overrun the 48-character fixed-size string
  chan-\>adapter.name by copying name without checking the length.
2. parameter\_as\_source: Note: This defect has an elevated risk because the
  source argument is a parameter of the current function.
 89        strcpy(chan-\>adapter.name, name);

Fix this warning by using strscpy() which will silence the warning and
prevent any future buffer overflows should the names used to identify the
channel become much longer.

## Affected and fixed versions

- Linux: \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 47e5533adf118afaf06d25a3e2aaaab89371b1c5; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 580e5d3815474b8349250c25c16416585a72c7fe; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 72dd5c46a152136712a55bf026a9aa8c1b12b60d; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 055cdd2e7b992921424d4daaa285ced787fb205f; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 08dff482012758935c185532b1ad7d584785a86e; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 9ff2f7294ab0f011cd4d1b7dcd9a07d8fdf72834; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 6a5226e544ac043bb2d8dc1bfe8920d02282f7cd; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 41baa86b6c802cdc6ab8ff2d46c083c9be93de81; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 37a1a2e6eeeb101285cd34e12e48a881524701aa (cvelist)
- Linux: 2.6.12 (cvelist)

## Mitigation

- Upgrade Linux to 37a1a2e6eeeb101285cd34e12e48a881524701aa or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2021-47642. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2021-47642.md
Affected: Linux >= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, < 47e5533adf118afaf06d25a3e2aaaab89371b1c5; >= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, < 580e5d3815474b8349250c25c16416585a72c7fe; >= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, < 72dd5c46a152136712a55bf026a9aa8c1b12b60d; >= 1da177e4c3f41524e886b7f…
Fixed in: Linux 47e5533adf118afaf06d25a3e2aaaab89371b1c5, Linux 580e5d3815474b8349250c25c16416585a72c7fe, Linux 72dd5c46a152136712a55bf026a9aa8c1b12b60d, Linux 055cdd2e7b992921424d4daaa285ced787fb205f, Linux 08dff482012758935c185532b1ad7d584785a86e, Linux 9ff2f7294ab0f011cd4d1b7dcd9a07d8fdf72834, Linux 6a522…

Steps:
1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2021-47642 being exploited?

There is no confirmed exploitation: CVE-2021-47642 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.34% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2021-47642?

High: CVSS 7.8 (v3.1, scored by NVD). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2021-47642?

Linux \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 47e5533adf118afaf06d25a3e2aaaab89371b1c5; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 580e5d3815474b8349250c25c16416585a72c7fe; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 72dd5c46a152136712a55bf026a9aa8c1b12b60d; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 055cdd2e7b992921424d4daaa285ced787fb205f; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 08dff482012758935c185532b1ad7d584785a86e; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 9ff2f7294ab0f011cd4d1b7dcd9a07d8fdf72834; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 6a5226e544ac043bb2d8dc1bfe8920d02282f7cd; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 41baa86b6c802cdc6ab8ff2d46c083c9be93de81; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 37a1a2e6eeeb101285cd34e12e48a881524701aa; Linux 2.6.12.

### Is there a fix for CVE-2021-47642?

Yes. Fixed in Linux 47e5533adf118afaf06d25a3e2aaaab89371b1c5, Linux 580e5d3815474b8349250c25c16416585a72c7fe, Linux 72dd5c46a152136712a55bf026a9aa8c1b12b60d, Linux 055cdd2e7b992921424d4daaa285ced787fb205f, Linux 08dff482012758935c185532b1ad7d584785a86e, Linux 9ff2f7294ab0f011cd4d1b7dcd9a07d8fdf72834, Linux 6a5226e544ac043bb2d8dc1bfe8920d02282f7cd, Linux 41baa86b6c802cdc6ab8ff2d46c083c9be93de81, Linux 37a1a2e6eeeb101285cd34e12e48a881524701aa. Upgrade Linux to 37a1a2e6eeeb101285cd34e12e48a881524701aa or later.

### How do I check if I'm affected by CVE-2021-47642?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- patch: <https://git.kernel.org/stable/c/47e5533adf118afaf06d25a3e2aaaab89371b1c5>
- patch: <https://git.kernel.org/stable/c/580e5d3815474b8349250c25c16416585a72c7fe>
- patch: <https://git.kernel.org/stable/c/72dd5c46a152136712a55bf026a9aa8c1b12b60d>
- patch: <https://git.kernel.org/stable/c/055cdd2e7b992921424d4daaa285ced787fb205f>
- patch: <https://git.kernel.org/stable/c/08dff482012758935c185532b1ad7d584785a86e>
- patch: <https://git.kernel.org/stable/c/9ff2f7294ab0f011cd4d1b7dcd9a07d8fdf72834>
- patch: <https://git.kernel.org/stable/c/6a5226e544ac043bb2d8dc1bfe8920d02282f7cd>
- patch: <https://git.kernel.org/stable/c/41baa86b6c802cdc6ab8ff2d46c083c9be93de81>
- patch: <https://git.kernel.org/stable/c/37a1a2e6eeeb101285cd34e12e48a881524701aa>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2021-47642>

HTML: <https://flawdb.com/CVE-2021-47642> · JSON: <https://flawdb.com/api/v1/entries/CVE-2021-47642>
