freebsd_amp_hwpstate/usr.bin/gcore
Conrad Meyer 6a4b635383 Fix buffer overrun in gcore(1) NT_PRPSINFO
Use size of destination buffer, rather than a constant that may or may not
correspond to the source buffer, to restrict the length of copied strings.  In
particular, pr_fname has 16+1 characters but MAXCOMLEN is 18+1.

Use strlcpy instead of strncpy to ensure the result is nul-terminated.  This
seems to be what is expected of these fields.

Reported by:	Coverity
CIDs:		1011302, 1011378
Sponsored by:	EMC / Isilon Storage Division
2016-05-11 15:31:31 +00:00
..
Makefile
Makefile.depend
elf32core.c
elfcore.c Fix buffer overrun in gcore(1) NT_PRPSINFO 2016-05-11 15:31:31 +00:00
extern.h
gcore.1
gcore.c