Linux kernel buffer overflow in ALSA OSS sequencer reads
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 · < 20b8520d1ef996173065f7abdde47b99136c0785| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
ALSA: seq: oss: Reject reads that cannot fit the next event
snd_seq_oss_read() checks whether the next queued OSS sequencer event fits in the remaining userspace buffer before removing it from the read queue.
The check is inverted. It currently stops when the event is smaller than the remaining buffer, so a normal 4-byte event is not copied for an 8-byte read buffer. Conversely, an 8-byte event can be copied for a smaller read count.
Break only when the remaining userspace buffer is smaller than the next event, and report -EINVAL if no complete event has been copied. This prevents an undersized read from looking like end-of-file while leaving the event queued for a later read with a large enough buffer.
From the CVE record · Linux
The Linux kernel’s ALSA OSS sequencer uses an inverted buffer-size check when reading queued events. A local reader can encounter an undersized read that appears to be end-of-file, while the event remains queued; an event may also be copied when the read count is too small. No authentication requirement is specified.
Engineers running Linux kernels with the ALSA OSS sequencer should check their exposure; affected versions are not specified.