CyberSecBulletin
CVE-2023-52515NVD status: Modified

Linux: Use After Free

CVE-2023-52515 is a high-severity use after free vulnerability in Linux, with a CVSS 3.1 base score of 7.8 out of 10. It can be exploited with local access to the system by an attacker with a low-privileged account, without any action from a user. The record lists versions 26788a5b48d9d5cd3283d777d238631c8cd7495a, b9bdffb3f9aaeff8379c83f5449c6b42cb71c2b5, 2b298f9181582270d5e95774e5a6c7a7fb5b1206 as the first without the flaw, so updating Linux to one of those releases or later removes the exposure. There is no confirmed exploitation so far. EPSS estimates a 0.61% chance of exploitation within 30 days, which is low compared with other CVEs.

Next patch cycle

High severity with no evidence of exploitation so far.

What to do

  1. Update Linux to 26788a5b48d9d5cd3283d777d238631c8cd7495a or b9bdffb3f9aaeff8379c83f5449c6b42cb71c2b5 or 2b298f9181582270d5e95774e5a6c7a7fb5b1206 or 05a10b316adaac1f322007ca9a0383b410d759cc, whichever matches your release line, or a later version.
  2. Update Linux Kernel to 5.10.199 or 5.15.136 or 6.1.57 or 6.5.7, whichever matches your release line, or a later version.

Affected products and versions

VendorProductAffected versionsFixed in
LinuxLinuxd8536670916a685df116b5c2cb256573fd25e4e3 up to, but not including, 26788a5b48d9d5cd3283d777d238631c8cd7495a; d8536670916a685df116b5c2cb256573fd25e4e3 up to, but not including, b9bdffb3f9aaeff8379c83f5449c6b42cb71c2b5; d8536670916a685df116b5c2cb256573fd25e4e3 up to, but not including, 2b298f9181582270d5e95774e5a6c7a7fb5b1206; d8536670916a685df116b5c2cb256573fd25e4e3 up to, but not including, 05a10b316adaac1f322007ca9a0383b410d759cc; d8536670916a685df116b5c2cb256573fd25e4e3 up to, but not including, e193b7955dfad68035b983a0011f4ef3590c85eb; 738589592a04180e39b6fb5fe8205d85b7dc69f6; 0575df129e2eb4a801beae0e6e041787480f42b9; 22fb582405002812d8fb89d0ed1264e97d3d25ad; and 8 more ranges26788a5b48d9d5cd3283d777d238631c8cd7495a, b9bdffb3f9aaeff8379c83f5449c6b42cb71c2b5, 2b298f9181582270d5e95774e5a6c7a7fb5b1206, 05a10b316adaac1f322007ca9a0383b410d759cc, e193b7955dfad68035b983a0011f4ef3590c85eb, 3.1
LinuxLinux Kernel3.7 up to, but not including, 5.10.199; 5.11 up to, but not including, 5.15.136; 5.16 up to, but not including, 6.1.57; 6.2 up to, but not including, 6.5.7; 6.65.10.199, 5.15.136, 6.1.57, 6.5.7

Version data comes from the organisation that assigned the CVE. Confirm against the vendor advisory before deciding you are unaffected.

How the severity score breaks down

Attack vector
LocalThe attacker needs local access or must trick a user into running something.
Attack complexity
LowNo special conditions are needed; the attack works reliably.
Privileges required
LowA basic user account is enough.
User interaction
NoneNo action by a victim is required.
Scope
UnchangedImpact stays within the vulnerable component.
Confidentiality
HighAll data handled by the component can be read.
Integrity
HighData or code can be modified at will.
Availability
HighThe component can be taken down completely.

Vector: CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H. Scored by NVD.

Scoring systemScoreSeverityScored by
CVSS 3.19.8CriticalCNA
CVSS 3.17.8HighNVD

Official description

In the Linux kernel, the following vulnerability has been resolved: RDMA/srp: Do not call scsi_done() from srp_abort() After scmd_eh_abort_handler() has called the SCSI LLD eh_abort_handler callback, it performs one of the following actions: * Call scsi_queue_insert(). * Call scsi_finish_command(). * Call scsi_eh_scmd_add(). Hence, SCSI abort handlers must not call scsi_done(). Otherwise all the above actions would trigger a use-after-free. Hence remove the scsi_done() call from srp_abort(). Keep the srp_free_req() call before returning SUCCESS because we may not see the command again if SUCCESS is returned.

Source: the CVE record as published by its numbering authority, via NVD and CVE.org.

The underlying weakness: Use After Free

The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. Any operations using the original pointer are no longer valid because the memory belongs to the code that operates on the new pointer.

How developers prevent this class of flaw

  • Choose a language that provides automatic memory management.
  • When freeing pointers, be sure to set them to NULL once they are freed. However, the utilization of multiple or complex data structures may lower the usefulness of this strategy.

More Use After Free vulnerabilities (CWE-416)

Timeline

  1. CVE record published.
  2. CISA published its SSVC assessment (exploitation: none, automatable: no, technical impact: partial).
  3. Record last changed materially (score, affected products, status or references).

References

Recent Use After Free vulnerabilities

Spotted an error? Tell us.