CVE-2025-40189

Source
https://cve.org/CVERecord?id=CVE-2025-40189
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2025-40189.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2025-40189
Downstream
Published
2025-11-12T21:56:30.575Z
Modified
2025-12-05T10:23:53.634016Z
Summary
net: usb: lan78xx: Fix lost EEPROM read timeout error(-ETIMEDOUT) in lan78xx_read_raw_eeprom
Details

In the Linux kernel, the following vulnerability has been resolved:

net: usb: lan78xx: Fix lost EEPROM read timeout error(-ETIMEDOUT) in lan78xxreadraw_eeprom

Syzbot reported read of uninitialized variable BUG with following call stack.

lan78xx 8-1:1.0 (unnamed net_device) (uninitialized): EEPROM read operation timeout

BUG: KMSAN: uninit-value in lan78xxreadeeprom drivers/net/usb/lan78xx.c:1095 [inline] BUG: KMSAN: uninit-value in lan78xxinitmacaddress drivers/net/usb/lan78xx.c:1937 [inline] BUG: KMSAN: uninit-value in lan78xxreset+0x999/0x2cd0 drivers/net/usb/lan78xx.c:3241 lan78xxreadeeprom drivers/net/usb/lan78xx.c:1095 [inline] lan78xxinitmacaddress drivers/net/usb/lan78xx.c:1937 [inline] lan78xxreset+0x999/0x2cd0 drivers/net/usb/lan78xx.c:3241 lan78xxbind+0x711/0x1690 drivers/net/usb/lan78xx.c:3766 lan78xxprobe+0x225c/0x3310 drivers/net/usb/lan78xx.c:4707

Local variable sig.i.i created at: lan78xxreadeeprom drivers/net/usb/lan78xx.c:1092 [inline] lan78xxinitmacaddress drivers/net/usb/lan78xx.c:1937 [inline] lan78xxreset+0x77e/0x2cd0 drivers/net/usb/lan78xx.c:3241 lan78xx_bind+0x711/0x1690 drivers/net/usb/lan78xx.c:3766

The function lan78xxreadraw_eeprom failed to properly propagate EEPROM read timeout errors (-ETIMEDOUT). In the fallthrough path, it first attempted to restore the pin configuration for LED outputs and then returned only the status of that restore operation, discarding the original timeout error.

As a result, callers could mistakenly treat the data buffer as valid even though the EEPROM read had actually timed out with no data or partial data.

To fix this, handle errors in restoring the LED pin configuration separately. If the restore succeeds, return any prior EEPROM timeout error correctly to the caller.

Database specific
{
    "cna_assigner": "Linux",
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/40xxx/CVE-2025-40189.json"
}
References

Affected packages

Git / git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git

Affected ranges

Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
8b1b2ca83b200fa46fdfb81e80ad5fe34537e6d4
Fixed
a72a7c4f675080a324d4c2167bd2314d968279f1
Fixed
49bdb63ff64469a6de8ea901aef123c75be9bbe7

Affected versions

v6.*
v6.13
v6.13-rc2
v6.13-rc3
v6.13-rc4
v6.13-rc5
v6.13-rc6
v6.13-rc7
v6.14
v6.14-rc1
v6.14-rc2
v6.14-rc3
v6.14-rc4
v6.14-rc5
v6.14-rc6
v6.14-rc7
v6.15
v6.15-rc1
v6.15-rc2
v6.15-rc3
v6.15-rc4
v6.15-rc5
v6.15-rc6
v6.15-rc7
v6.16
v6.16-rc1
v6.16-rc2
v6.16-rc3
v6.16-rc4
v6.16-rc5
v6.16-rc6
v6.16-rc7
v6.17
v6.17-rc1
v6.17-rc2
v6.17-rc3
v6.17-rc4
v6.17-rc5
v6.17-rc6
v6.17-rc7
v6.17.1
v6.17.2
v6.17.3

Database specific

source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2025-40189.json"

Linux / Kernel

Package

Name
Kernel

Affected ranges

Type
ECOSYSTEM
Events
Introduced
6.14.0
Fixed
6.17.4

Database specific

source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2025-40189.json"