orangefs: skip leading spaces before parsing client debug masks
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ f7be4ee07fb72a516563bc2870ef41fa589a964a · < 116d14f29a0524853c9316f32a2ac06cff5d4bf6| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
orangefs: skip leading spaces before parsing client debug masks
orangefs_prepare_cdm_array() sizes each client debug keyword buffer with strcspn(cds_head, " "), but then parses the keyword with %s. The %s conversion skips leading whitespace, while strcspn() does not.
If a client debug entry starts with a space, the allocation can be sized for an empty keyword while sscanf() copies the following non-empty token. This can write past the end of the allocated keyword buffer.
Skip leading spaces before computing the keyword length so the allocation matches the string parsed by sscanf().
From the CVE record · Linux
The Linux kernel’s orangefs client debug mask parser can allocate too little space for a keyword when an entry begins with a space. Parsing the following token can then write past the allocated buffer. The input does not establish who can supply such an entry or whether authentication or user interaction is required.
Engineers running Linux kernels with orangefs should check their kernel’s status; affected versions are not specified.