]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Don't run strcmp() against strings stored in user memory.
authorjhb <jhb@FreeBSD.org>
Mon, 27 Apr 2020 18:04:42 +0000 (18:04 +0000)
committerjhb <jhb@FreeBSD.org>
Mon, 27 Apr 2020 18:04:42 +0000 (18:04 +0000)
commit7cd0c41207f94e5d0994763d6dd88927500f285d
tree50821170c04ef5c88fdba9d5c83288706174e3d6
parentca9eb9ea4d91eaf69de09b836381ab4a52ff1d62
Don't run strcmp() against strings stored in user memory.

Instead, copy the strings into a temporary buffer on the stack and
run strcmp on the copies.

Reviewed by: brooks, kib
Obtained from: CheriBSD
MFC after: 1 week
Sponsored by: DARPA
Differential Revision: https://reviews.freebsd.org/D24567
sys/dev/iscsi_initiator/isc_subr.c