nanoMODBUS Client-Side Out-of-Bounds Write via object_length in recv_read_device_identification_res()
Default status is the baseline for the product, each version can override it (e.g. patched versions marked unaffected).
| Vendor | Product | Default status | Versions | ||||||
|---|---|---|---|---|---|---|---|---|---|
| debevv | nanoMODBUS | unaffected |
|
No data.
No data.
| Vendor | Product | Versions | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|
| Debevv | Nanomodbus |
|
No CVSS v4.0
No CVSS v3.0
No CVSS v2
This CVE is not in the KEV list.
Exploit prediction score: < 1% (0.385% probability within 30 days)
| Type | Values Removed | Values Added |
|---|---|---|
| Description | nanoMODBUS through v1.23.0 contains an out-of-bounds write in the Modbus client-side recv_read_device_identification_res() function (FC 0x2B/MEI 0x0E, Read Device Identification) in nanomodbus.c. The server-supplied object_length field (0-246) is validated only against the remaining PDU size (res_size_left) and is never validated against the caller-supplied buffers_length parameter. After copying data with strncpy(buffers_out[buf_index], str, buffers_length), the code unconditionally writes a NUL terminator at buffers_out[buf_index][object_length]. When a malicious or compromised Modbus server sends a response with object_length greater than or equal to the client's buffers_length, this NUL write lands past the end of the caller-provided buffer, corrupting adjacent stack or heap memory on the client. | nanoMODBUS through v1.23.0 contains an out-of-bounds write in the Modbus client-side recv_read_device_identification_res function (FC 0x2B/MEI 0x0E, Read Device Identification) in nanomodbus.c. The server-supplied object_length field (0-246) is validated only against the remaining PDU size (res_size_left) and is never validated against the caller-supplied buffers_length parameter. |
| Title | nanoMODBUS - Client-Side Out-of-Bounds Write via object_length in recv_read_device_identification_res() | nanoMODBUS Client-Side Out-of-Bounds Write via object_length in recv_read_device_identification_res() |
| Type | Values Removed | Values Added |
|---|---|---|
| Title | nanoMODBUS Client-Side Out-of-Bounds Write via object_length in recv_read_device_identification_res() | nanoMODBUS - Client-Side Out-of-Bounds Write via object_length in recv_read_device_identification_res() |
| Type | Values Removed | Values Added |
|---|---|---|
| First Time appeared |
Debevv
Debevv nanomodbus |
|
| Vendors & Products |
Debevv
Debevv nanomodbus |
| Type | Values Removed | Values Added |
|---|---|---|
| Metrics |
ssvc
|
| Type | Values Removed | Values Added |
|---|---|---|
| Metrics |
cvssV3_1
|
cvssV3_1
|
| Type | Values Removed | Values Added |
|---|---|---|
| Description | nanoMODBUS through v1.23.0 contains an out-of-bounds write in the Modbus client-side recv_read_device_identification_res() function (FC 0x2B/MEI 0x0E, Read Device Identification) in nanomodbus.c. The server-supplied object_length field (0-246) is validated only against the remaining PDU size (res_size_left) and is never validated against the caller-supplied buffers_length parameter. After copying data with strncpy(buffers_out[buf_index], str, buffers_length), the code unconditionally writes a NUL terminator at buffers_out[buf_index][object_length]. When a malicious or compromised Modbus server sends a response with object_length greater than or equal to the client's buffers_length, this NUL write lands past the end of the caller-provided buffer, corrupting adjacent stack or heap memory on the client. | |
| Title | nanoMODBUS Client-Side Out-of-Bounds Write via object_length in recv_read_device_identification_res() | |
| Weaknesses | CWE-787 | |
| References |
| |
| Metrics |
cvssV3_1
|