Loading
nvme_tcp: psk_cpy might not be NULL-terminated
Fixed issue found by Klocwork scan. psk_cpy might not be NULL-terminanted, if length of psk_in is SPDK_TLS_PSK_MAX_LEN. Then after copy: memcpy(psk_cpy, psk_in, strlen(psk_in)); the psk_cpy buffer might be filled up to the last character, not leaving space for NULL terminating the string. Change-Id: Ie09163af9890fee2de774a2b3e12aa8226c52e91 Signed-off-by:Marcin Spiewak <marcin.spiewak@intel.com> Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/18255 Reviewed-by:
Tomasz Zawadzki <tomasz.zawadzki@intel.com> Community-CI: Mellanox Build Bot Tested-by:
SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by:
Konrad Sztyber <konrad.sztyber@intel.com> Reviewed-by:
Krzysztof Karas <krzysztof.karas@intel.com>