CVE-2026-142812: media: rc: fintek-cir: process a full RX buffer instead of overflowing it
In the Linux kernel, the following vulnerability has been resolved:
media: rc: fintek-cir: process a full RX buffer instead of overflowing it
fintekgetrxirdata() drains the CIR RX FIFO into fintek->buf[], which holds RXBUFLEN (32) bytes, for as long as CIRSTATUS reports pending RX data:
do { sample = fintekcirregread(fintek, CIRRXDATA); ... fintek->buf[fintek->pkts] = sample; fintek->pkts++; ... } while (status & rxirqs);
Nothing bounds fintek->pkts. If the hardware reports data for more than RXBUFLEN reads in one interrupt, the loop writes past the end of buf[], starting with the pkts counter that follows it in struct fintekdev.
Hand a full buffer to fintekprocessrxirdata(), which parses the samples and resets fintek->pkts, before storing the next sample. This keeps the parser state consistent and drops no samples. The loop still relies on the status register to terminate.
The driver does not document the hardware FIFO depth, so it is not known whether a working device can trigger this.
Found by static analysis tool CodeQL.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Compensating control
In the fintek CIR RX handler, process the samples and reset fintek->pkts when the RX buffer is full, before storing the next sample.