summaryrefslogtreecommitdiff
path: root/net/nsh
diff options
context:
space:
mode:
authorGuvenc Gulce <guvenc@linux.ibm.com>2021-01-12 17:21:22 +0100
committerJakub Kicinski <kuba@kernel.org>2021-01-12 20:22:01 -0800
commit8a4465368964b4fbaf084760c94c7aabf61059fb (patch)
tree06a00842a100de9d64eaac60c872e98a060714db /net/nsh
parent25fe2c9c4cd2e97c5f5b69f3aefe69aad3057936 (diff)
downloadlinux-8a4465368964b4fbaf084760c94c7aabf61059fb.tar.gz
linux-8a4465368964b4fbaf084760c94c7aabf61059fb.tar.bz2
linux-8a4465368964b4fbaf084760c94c7aabf61059fb.zip
net/smc: use memcpy instead of snprintf to avoid out of bounds read
Using snprintf() to convert not null-terminated strings to null terminated strings may cause out of bounds read in the source string. Therefore use memcpy() and terminate the target string with a null afterwards. Fixes: a3db10efcc4c ("net/smc: Add support for obtaining SMCR device list") Signed-off-by: Guvenc Gulce <guvenc@linux.ibm.com> Signed-off-by: Karsten Graul <kgraul@linux.ibm.com> Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'net/nsh')
0 files changed, 0 insertions, 0 deletions