Overview
CVE-2026-142971 affects the Linux kernel USB serial driver for Garmin GPS devices. The flaw is in nat_receive(), which processes data written by userspace to a Garmin TTY device such as /dev/ttyUSBn when the driver is operating in MODE_NATIVE mode.
The weakness is a missing bounds check on packet data length. A crafted packet can cause the kernel to allocate a one-byte buffer and then read four bytes from it. Under Kernel Address Sanitizer (KASAN), this produces a slab-out-of-bounds report; on systems without KASAN, the behavior may instead result in an unvalidated read of adjacent slab data.
The supplied advisory material rates the issue as low severity. No CVSS vector, CISA KEV listing, or evidence of active exploitation is provided in the context. The attack path is local and depends on access to the affected TTY node and native protocol mode.
Affected systems
The vulnerable component is:
- Linux kernel component:
drivers/usb/serial/garmin_gps.c
- Driver: USB serial
garmin_gps
- Mode involved:
MODE_NATIVE
- Entry path:
garmin_write()andnat_receive()
- Demonstrated test kernel: Linux 7.3.0-rc3
The issue was reproduced with an emulated Garmin USB GPS device identified by USB IDs 091e:0003 using QEMU with dummy_hcd and raw-gadget. The supplied context does not provide a complete list of affected stable or distribution releases, so exact package scope cannot be determined from the available information.
Systems are potentially affected when they contain the vulnerable driver implementation and expose the Garmin serial device to a local user or process with write access.
Technical details
The driver first copies incoming bytes into garmin_data_p->inbuffer until garmin_data_p->insize reaches the 12-byte GARMIN_PKTHDR_LENGTH. It then calculates the total packet size using:
len = GARMIN_PKTHDR_LENGTH + getDataLength(garmin_data_p->inbuffer);
getDataLength() returns a signed int derived from the four-byte little-endian length field through __le32_to_cpup(). A value such as 0xfffffff5 represents -11. The resulting calculation is:
12 + (-11) = 1
At this point, the length is not checked against the valid packet range. The subsequent comparison garmin_data_p->insize >= len succeeds because 12 >= 1, allowing garmin_write_bulk(port, inbuffer, 1, 0) to proceed.
That function allocates a one-byte buffer using kmemdup() and calls getLayerId(buffer), which reads four bytes from the buffer. The callback path performs another four-byte read after the URB completes. The resulting three-byte over-read is reported as:
BUG: KASAN: slab-out-of-bounds in garmin_write_bulk.constprop.0+0x3eb/0x500
The supplied call trace reaches the issue through serial_write, n_tty_write, file_tty_write.isra.0, and vfs_write, confirming that the trigger is a normal userspace write to the TTY device.
Mitigation
The upstream fix validates the unsigned 32-bit data length as soon as the 12-byte header is available. The data length must satisfy:
dlen >= GPS_IN_BUFSIZ - GARMIN_PKTHDR_LENGTH
Invalid packets cause nat_receive() to reset insize and return -EINVPKT. This prevents garmin_write_bulk() from being called unless the complete packet satisfies:
12 <= len < GPS_IN_BUFSIZ
For environments unable to update immediately, the following measures reduce exposure:
- Prevent the
garmin_gpsmodule from loading, for example through module configuration that blocks automatic loading ofgarmin_gps.
- Restrict ownership and write permissions for the relevant
/dev/ttyUSB*node to trusted users and services.
- Avoid native-mode Garmin workflows on unpatched kernels.
- Use KASAN or comparable slab diagnostics where available, and monitor kernel logs for
KASAN: slab-out-of-bounds in garmin_write_bulkand relatedgarmin_write_bulk.constprop.0traces.
The upstream fix should be verified against the kernel version and branch used by the host or distribution. The supplied sources do not identify a complete stable-branch backport matrix.
Expert insight
This is primarily an input-validation defect whose impact depends on local device access and kernel configuration. The resulting primitive is a narrow out-of-bounds slab read, and the available material does not establish a write primitive, control-flow hijack, privilege escalation, or reliable disclosure of sensitive kernel information.
The most realistic risks are local denial of service on KASAN-enabled systems and unintended disclosure of adjacent heap bytes on systems where the invalid read proceeds without a diagnostic abort. Its practical exposure is reduced by the need to enter MODE_NATIVE through the driver's private ioctl and write a malformed packet to the Garmin TTY node. Systems without Garmin USB serial devices or without access to the corresponding device node are not directly exposed through this path.
Actionable recommendations
- Update the Linux kernel or vendor kernel package containing the upstream
garmin_gpsvalidation fix.
- Confirm that the fix is present in the deployed kernel branch rather than assuming that the absence of a distro advisory means the system is unaffected.
- Restrict access to Garmin serial device nodes so untrusted local users and processes cannot write to them.
- Block the
garmin_gpsmodule where the device is unnecessary and native-mode Garmin workflows are not required.
- Monitor kernel logs for KASAN slab-out-of-bounds reports associated with
garmin_write_bulk.
- Treat any crash involving
garmin_write_bulkas a possible indicator of malformed input reaching the driver and review the relevant TTY access path.
منابع
- nvd.nist.gov/vuln/detail/CVE-2026-142971
- git.kernel.org/stable/c/40d8518dd43dd0edcd83a347f1854058b123c7ba
- git.kernel.org/stable/c/4eb2cba206a3d23094b698c7f32c91f05dd04d49
- git.kernel.org/stable/c/c6e790c0b9166e91d1c5d638c14f24c7b6dcec9e
- git.kernel.org/stable/c/ca783a2d55b3361493917ad4a3573715ba902503
- git.kernel.org/stable/c/f4565811b80e8302eb3a25b01fa9d3dc803bbd16
- git.kernel.org/stable/c/f669abbb186f8de34c775855c64e8659ecb365a1