linux-stable/tools/net/ynl/lib
Jakub Kicinski 15d2540e0d tools: ynl: check for overflow of constructed messages
Donald points out that we don't check for overflows.
Stash the length of the message on nlmsg_pid (nlmsg_seq would
do as well). This allows the attribute helpers to remain
self-contained (no extra arguments). Also let the put
helpers continue to return nothing. The error is checked
only in (newly introduced) ynl_msg_end().

Reviewed-by: Donald Hunter <donald.hunter@gmail.com>
Link: https://lore.kernel.org/r/20240305185000.964773-1-kuba@kernel.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2024-03-07 11:01:31 -08:00
..
__init__.py tools/net/ynl: Add support for create flags 2023-08-27 17:17:10 -07:00
.gitignore tools: net: add __pycache__ to gitignore 2023-02-24 11:55:47 -08:00
Makefile tools: ynl: remove __pycache__ during clean 2024-03-06 12:05:10 +00:00
nlspec.py tools: ynl: correct typo and docstring 2024-02-06 18:56:19 -08:00
ynl-priv.h tools: ynl: check for overflow of constructed messages 2024-03-07 11:01:31 -08:00
ynl.c tools: ynl: check for overflow of constructed messages 2024-03-07 11:01:31 -08:00
ynl.h tools: ynl: check for overflow of constructed messages 2024-03-07 11:01:31 -08:00
ynl.py tools: ynl: support debug printing messages 2024-03-06 12:07:44 +00:00