Buffer Overflow Affecting riot-os/riot package, versions [0,]


Severity

Recommended
0.0
high
0
10

CVSS assessment made by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
0.05% (18th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk IDSNYK-UNMANAGED-RIOTOSRIOT-6751220
  • published1 May 2024
  • disclosed1 May 2024
  • credit0xdea

Introduced: 1 May 2024

CVE-2024-32018  (opens in a new tab)
CWE-120  (opens in a new tab)

How to fix?

There is no fixed version for riot-os/riot.

Overview

Affected versions of this package are vulnerable to Buffer Overflow due to the reliance on assertions that are not present in non-debug builds, an attacker can write past the end of a fixed-length buffer by providing a larger len value than expected. This vulnerability arises in the context where assertions, intended as a safeguard against untrusted input, are omitted, leading to insufficient input validation. Specifically, in the nimble_scanlist_update function, the len parameter is checked through an assertion and then used in a memcpy() operation. If an attacker supplies a len value that exceeds the buffer size while assertions are disabled, it could result in writing outside the bounds of the e->ad buffer. This scenario opens up the possibility for various malicious outcomes, ranging from causing a denial of service to executing arbitrary code, depending on the nature of the overflow and the attacker's intent. This issue remains unaddressed, and users are encouraged to implement manual len checks as a temporary countermeasure.

Workaround

This vulnerability can be mitigated by adding manual len checking to ensure that the length does not exceed the expected bounds before performing memory operations.

References

CVSS Scores

version 3.1