Linux: tty: tty_port: restore TTY_IO_ERROR on activation failure
What fixes it
- 16032c980d8f71642fcdc99309c571df3fcf3328LinuxCVE List
- 34d4f67472ef7a744970b772a8565ddc727788e2LinuxCVE List
- 7021acc84c2e0add77a1a33152e3a1e428fdbfdbLinuxCVE List
- 6388409b711eb91b14fa075a4d861ccc4df1cfe7LinuxCVE List
- 56964f6a31238fb41d5830bb42520c5b10ff7d8fLinuxCVE List
A fixed version on one release line is not the upgrade target for every line. Check your exact version and any vendor backports.
Description
In the Linux kernel, the following vulnerability has been resolved:
tty: tty_port: restore TTY_IO_ERROR on activation failure
Make sure to restore the TTY_IO_ERROR flag if activation fails to prevent I/O attempts on a port that is gone or powered down.
This specifically avoids issues like kernel panic due to unclocked accesses or NULL-pointer dereferences when accessing powered down or deregistered ports when a TTY ioctl races with hangup and open.
Note that the flag is set again in tty_port_close() but not restoring it on activation failure leaves a window where drivers fail to handle the ioctl-hangup race.
Text from CVE List
Affected versions 12
- Linuxaffected: a9a37ec33a1b3e66b260ac1c29bff0aec8b89ae4 before 16032c980d8f71642fcdc99309c571df3fcf3328CVE List
- Linuxaffected: a9a37ec33a1b3e66b260ac1c29bff0aec8b89ae4 before 34d4f67472ef7a744970b772a8565ddc727788e2CVE List
- Linuxaffected: a9a37ec33a1b3e66b260ac1c29bff0aec8b89ae4 before 7021acc84c2e0add77a1a33152e3a1e428fdbfdbCVE List
- Linuxaffected: a9a37ec33a1b3e66b260ac1c29bff0aec8b89ae4 before 6388409b711eb91b14fa075a4d861ccc4df1cfe7CVE List
- Linuxaffected: a9a37ec33a1b3e66b260ac1c29bff0aec8b89ae4 before 56964f6a31238fb41d5830bb42520c5b10ff7d8fCVE List
- Linuxaffected: 2.6.33CVE List
- Linuxunaffected: all versions before 2.6.33CVE List
- Linuxunaffected: 6.6.160 through 6.6.*CVE List
- Linuxunaffected: 6.12.113 through 6.12.*CVE List
- Linuxunaffected: 6.18.56 through 6.18.*CVE List
- Linuxunaffected: 7.2.10 through 7.2.*CVE List
- Linuxunaffected: 7.3CVE List
References 5
- git.kernel.org/stable/c/16032c980d8f71642fcdc99309c571df3fcf3328Referencevia CVE List
- git.kernel.org/stable/c/34d4f67472ef7a744970b772a8565ddc727788e2Referencevia CVE List
- git.kernel.org/stable/c/7021acc84c2e0add77a1a33152e3a1e428fdbfdbReferencevia CVE List
- git.kernel.org/stable/c/6388409b711eb91b14fa075a4d861ccc4df1cfe7Referencevia CVE List
- git.kernel.org/stable/c/56964f6a31238fb41d5830bb42520c5b10ff7d8fReferencevia CVE List