# CVE-2026-53043: ocfs2/dlm: validate qr_numregions in dlm_match_regions()

- Severity: Critical 9.1 (CVSS:3.1, scored by Linux) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.51%, higher than 45% of CVEs (2026-12-01)
- Published: 2026-06-24T16:29:49.480Z
- Modified: 2026-08-05T12:32:50.728Z
- Weaknesses: CWE-787
- Assigned by: Linux

## Description

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

ocfs2/dlm: validate qr_numregions in dlm_match_regions()

Patch series "ocfs2/dlm: fix two bugs in dlm_match_regions()".

In dlm_match_regions(), the qr_numregions field from a DLM_QUERY_REGION
network message is used to drive loops over the qr_regions buffer without
sufficient validation.  This series fixes two issues:

- Patch 1 adds a bounds check to reject messages where qr_numregions
  exceeds O2NM_MAX_REGIONS. The o2net layer only validates message
  byte length; it does not constrain field values, so a crafted message
  can set qr_numregions up to 255 and trigger out-of-bounds reads past
  the 1024-byte qr_regions buffer.

- Patch 2 fixes an off-by-one in the local-vs-remote comparison loop,
  which uses '<=' instead of '<', reading one entry past the valid range
  even when qr_numregions is within bounds.


This patch (of 2):

The qr_numregions field from a DLM_QUERY_REGION network message is used
directly as loop bounds in dlm_match_regions() without checking against
O2NM_MAX_REGIONS.  Since qr_regions is sized for at most O2NM_MAX_REGIONS
(32) entries, a crafted message with qr_numregions > 32 causes
out-of-bounds reads past the qr_regions buffer.

Add a bounds check for qr_numregions before entering the loops.

(As written by CVE List.)

## Affected

- Linux Linux: from ea2034416b54700e30371f2ad6517cbb94674083 before d3d5efade0c79dac1cac98c0cb1115432f804439; from ea2034416b54700e30371f2ad6517cbb94674083 before f69551139caf6d24242a0ad049ee46b264e3aee0; from ea2034416b54700e30371f2ad6517cbb94674083 before 1f8b91275912cd428289c1fb424bebd7ff5302bd; from ea2034416b54700e30371f2ad6517cbb94674083 before f37de46149db49abd2b24f4f0c5a88cf4dfb5f47; from ea2034416b54700e30371f2ad6517cbb94674083 before 6c6e8fc3c007319981647b410c29bb5775048551; from ea2034416b54700e30371f2ad6517cbb94674083 before 3f474c33ebc2e2ca3fcb587d7de4375348f13373; from ea2034416b54700e30371f2ad6517cbb94674083 before 3c2d0de23ae4be22b6c18e8f0915be74d3b5fb21; from ea2034416b54700e30371f2ad6517cbb94674083 before 7ab3fbb01bc6d79091bc375e5235d360cd9b78be; 2.6.37 (not affected: before 2.6.37; from 5.10.258 up to 5.10.*; from 5.15.209 up to 5.15.*; from 6.1.175 up to 6.1.*; from 6.6.141 up to 6.6.*; from 6.12.91 up to 6.12.*; from 6.18.33 up to 6.18.*; from 7.0.10 up to 7.0.*; from 7.1 up to *)
- linux linux_kernel: from 2.6.37 before 5.10.258; from 5.11 before 5.15.209; from 5.16 before 6.1.175; from 6.2 before 6.6.141; from 6.7 before 6.12.91; from 6.13 before 6.18.33; from 6.19 before 7.0.10

## References

- <https://git.kernel.org/stable/c/d3d5efade0c79dac1cac98c0cb1115432f804439> (patch)
- <https://git.kernel.org/stable/c/f69551139caf6d24242a0ad049ee46b264e3aee0> (patch)
- <https://git.kernel.org/stable/c/1f8b91275912cd428289c1fb424bebd7ff5302bd> (patch)
- <https://git.kernel.org/stable/c/f37de46149db49abd2b24f4f0c5a88cf4dfb5f47> (patch)
- <https://git.kernel.org/stable/c/6c6e8fc3c007319981647b410c29bb5775048551> (patch)
- <https://git.kernel.org/stable/c/3f474c33ebc2e2ca3fcb587d7de4375348f13373> (patch)
- <https://git.kernel.org/stable/c/3c2d0de23ae4be22b6c18e8f0915be74d3b5fb21> (patch)
- <https://git.kernel.org/stable/c/7ab3fbb01bc6d79091bc375e5235d360cd9b78be> (patch)

## Sources

- CVE List: [CVE-2026-53043](https://www.cve.org/CVERecord?id=CVE-2026-53043), CVE Terms of Use, modified 2026-08-05
- NVD: [CVE-2026-53043](https://nvd.nist.gov/vuln/detail/CVE-2026-53043), Public domain, modified 2026-07-14

---

Page: https://cve.day/CVE-2026-53043 · Whole record: https://cve.day/CVE-2026-53043.json · Rebuilt by cve.day 2026-11-25T22:59:25.670Z
