1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-12-16 01:53:51 +01:00
Marian Buschsieweke 7a738d0e0b
sys/net/nanocoap: fix buffer overflow in separate response handling
When RFC 8974 support (module `nanocoap_token_ext`) is in use, the
request token may be longer than the buffer in the separate response
context is large. This adds a check to not overflow the buffer.

Sadly, this is an API change: Preparing the separate response context
can actually fail, so we need to report this with a return value.

The example application has been adapted to only proceed if the separate
reply context could have been prepared, and rather directly emit a
reset message if the token exceeds the static buffer.

Co-authored-by: benpicco <benpicco@googlemail.com>
2024-12-12 14:28:28 +01:00
..
2023-01-13 13:58:07 +01:00
2022-09-14 15:05:25 +02:00
2023-04-26 00:53:14 +02:00
2023-02-23 16:44:24 +01:00
2022-09-14 15:05:25 +02:00
2024-01-17 16:05:12 +01:00
2021-12-15 12:41:36 +01:00
2023-01-13 13:58:07 +01:00
2024-11-13 16:01:34 +01:00
2024-10-18 13:14:04 +02:00
2022-12-19 13:03:45 +01:00
2023-06-05 19:09:11 +02:00
2023-01-13 13:58:07 +01:00
2022-11-22 13:39:35 +01:00
2023-05-26 15:04:36 +02:00
2024-02-09 15:24:22 +01:00
2023-05-31 12:55:53 +02:00
2022-02-12 18:30:58 +01:00
2023-08-08 09:09:12 +02:00
2024-05-15 11:20:38 +02:00
2024-06-07 12:05:43 +02:00