CVE-2023-53578

Description

An uninitialized memory access flaw was found in the Linux kernel's QRTR (Qualcomm IPC Router) protocol in the transmit resume handling. When processing RESUME_TX messages, if the packet size is smaller than the expected control structure, the qrtr_tx_resume function reads uninitialized memory from the skb buffer. This can lead to unpredictable behavior, kernel warnings from KMSAN (Kernel Memory Sanitizer), and potential crashes, causing denial of service.

Statement

QRTR is a message-based IPC mechanism used in Qualcomm SoCs to communicate between processors and subsystems. The protocol uses control messages for flow control, including QRTR_TYPE_RESUME_TX packets that signal readiness to receive more data. The qrtr_tx_resume function expects these packets to contain at least a full qrtr_ctrl_pkt structure and reads fields from that structure. Meanwhile, qrtr_endpoint_post allocates an skb of size 'size' (from the received message) and sets skb->len to match. When a malformed or crafted message arrives with type QRTR_TYPE_RESUME_TX but size less than sizeof(struct qrtr_ctrl_pkt), the allocated skb doesn't contain enough initialized data. When qrtr_tx_resume tries to access fields of the control packet, it reads beyond the initialized portion into whatever random data happened to be in that memory.

Common Vulnerability Scoring System (CVSS) Score Details

Info alert:Important note

CVSS scores for open source components depend on vendor-specific factors (e.g. version or build chain). Therefore, Red Hat's score and impact rating can be different from NVD and other vendors. Red Hat remains the authoritative CVE Naming Authority (CNA) source for its products and services (see Red Hat classifications).

CVSS v3 Score Breakdown

Red HatNVDcve.org
Base Score5.57.8N/A
Attack VectorLocalLocalN/A
Attack ComplexityLowLowN/A
Privileges RequiredLowLowN/A
User InteractionNoneNoneN/A
ScopeUnchangedUnchangedN/A
ConfidentialityNoneHighN/A
Integrity ImpactNoneHighN/A
Availability ImpactHighHighN/A

Vector

Red Hat: CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H

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

Understanding the Weakness (CWE)

Integrity,Availability,Confidentiality

Technical Impact: DoS: Crash, Exit, or Restart; Execute Unauthorized Code or Commands; Read Memory; Modify Memory

If the incorrect calculation is used in the context of memory allocation, then the software may create a buffer that is smaller or larger than expected. If the allocated buffer is smaller than expected, this could lead to an out-of-bounds read or write (CWE-119), possibly causing a crash, allowing arbitrary code execution, or exposing sensitive data.

Frequently Asked Questions

Want to get errata notifications? Sign up here.