RDMA/bnxt_re: Clear VM_MAYWRITE on DBR/toggle page mmap
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
RDMA/bnxt_re: Clear VM_MAYWRITE on DBR/toggle page mmap
bnxt_re_mmap() rejects VM_WRITE for the DBR_PAGE and TOGGLE_PAGE mmap flags, but a read-only mapping can still retain VM_MAYWRITE. nd later be upgraded with mprotect(PROT_WRITE). This can bypass the write check that only runs at mmap time.
Clear VM_MAYWRITE before vm_insert_page() in the shared DBR/toggle-page branch, matching the existing policy that userspace writes are not expected for these pages.
From the CVE record · Linux
The Linux kernel's bnxt_re mmap path rejects writable DBR and toggle-page mappings but can leave read-only mappings eligible for later write access. A local userspace process can use mprotect(PROT_WRITE) to bypass the write check performed at mmap time.
Engineers running Linux kernels with the affected RDMA/bnxt_re code should check their versions; affected versions were not specified.