nfc: llcp: fix WKS SAP hijacking via prefix match in nfc_llcp_wks_sap()
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ d646960f7986fefb460a2b062d5ccc8ccfeacc3a · < f234197f3bda3aea5d4b1e591d6bcb3660a8b3fc| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
nfc: llcp: fix WKS SAP hijacking via prefix match in nfc_llcp_wks_sap()
nfc_llcp_wks_sap() compares only service_name_len bytes, so a short service_name like "u" matches longer WKS strings like "urn:nfc:sn:snep". Fix by requiring exact length match before strncmp().
From the CVE record · Linux
The Linux kernel’s NFC LLCP code can match a short service name against a longer WKS service name because it checks only the shorter name’s length. This can allow WKS SAP hijacking; the input does not specify whether exploitation requires local or network access, authentication, or user interaction.
Anyone running a Linux kernel with the affected NFC LLCP code should check their kernel version; affected versions are not specified.