mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-03 17:51:57 +09:00
iscsi-target: Fix tfc_tpg_nacl_auth_cit configfs length overflow
commit 0fbfc46fb0 upstream.
This patch fixes a potential buffer overflow while processing
iscsi_node_auth input for configfs attributes within NodeACL
tfc_tpg_nacl_auth_cit context.
Signed-off-by: Joern Engel <joern@logfs.org>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
fff9887938
commit
a5d56a2217
@@ -474,7 +474,7 @@ static ssize_t __iscsi_##prefix##_store_##name( \
|
||||
if (!capable(CAP_SYS_ADMIN)) \
|
||||
return -EPERM; \
|
||||
\
|
||||
snprintf(auth->name, PAGE_SIZE, "%s", page); \
|
||||
snprintf(auth->name, sizeof(auth->name), "%s", page); \
|
||||
if (!strncmp("NULL", auth->name, 4)) \
|
||||
auth->naf_flags &= ~flags; \
|
||||
else \
|
||||
|
||||
Reference in New Issue
Block a user