CVE-2024-38621 Affecting python-perf package, versions <0:4.14.35-2047.540.4.1.el7uek


Severity

Recommended
high

Based on Oracle Linux security rating.

Threat Intelligence

EPSS
0.04% (15th 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-ORACLE7-PYTHONPERF-7678001
  • published14 Aug 2024
  • disclosed21 Jun 2024

Introduced: 21 Jun 2024

CVE-2024-38621  (opens in a new tab)

How to fix?

Upgrade Oracle:7 python-perf to version 0:4.14.35-2047.540.4.1.el7uek or higher.
This issue was patched in ELSA-2024-12611.

NVD Description

Note: Versions mentioned in the description apply only to the upstream python-perf package and not the python-perf package as distributed by Oracle. See How to fix? for Oracle:7 relevant fixed versions and status.

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

media: stk1160: fix bounds checking in stk1160_copy_video()

The subtract in this condition is reversed. The ->length is the length of the buffer. The ->bytesused is how many bytes we have copied thus far. When the condition is reversed that means the result of the subtraction is always negative but since it's unsigned then the result is a very high positive value. That means the overflow check is never true.

Additionally, the ->bytesused doesn't actually work for this purpose because we're not writing to "buf->mem + buf->bytesused". Instead, the math to calculate the destination where we are writing is a bit involved. You calculate the number of full lines already written, multiply by two, skip a line if necessary so that we start on an odd numbered line, and add the offset into the line.

To fix this buffer overflow, just take the actual destination where we are writing, if the offset is already out of bounds print an error and return. Otherwise, write up to buf->length bytes.

CVSS Scores

version 3.1