]> git.ipfire.org Git - thirdparty/shadow.git/commit
lib/chkname.c: Take NUL byte into account
authorTobias Stoeckmann <tobias@stoeckmann.org>
Sat, 3 Feb 2024 00:07:58 +0000 (01:07 +0100)
committerSerge Hallyn <serge@hallyn.com>
Sun, 4 Feb 2024 23:03:12 +0000 (17:03 -0600)
commit403a2e3771be6b1c0c6fc16b2be65b4d36f759ab
tree7d2370ed5140025e73fba955b26e88ab0d315216
parent37b02a5f883f042161075ab6ebe8a58c297622b8
lib/chkname.c: Take NUL byte into account

The _SC_LOGIN_NAME_MAX value includes space for the NUL byte. The length
of name must smaller than this value to be valid.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
lib/chkname.c
tests/unit/test_chkname.c