freebsd-nq/libexec/getty
Stefan Eßer 71bc4af6ed Fix potential buffer overflow and undefined behavior.
The buffer allocated in read_chat() could be 1 element too short, if the
chatstr parameter passed in is 1 or 3 charachters long (e.g. "a" or "a b").
The allocation of the pointer array does not account for the terminating
NULL pointer in that case.

Overlapping source and destination strings are undefined in strcpy().
Instead of moving a string to the left by one character just increment the
char pointer before it is assigned to the results array.

MFC after:	2 weeks
2019-01-26 20:43:28 +00:00
..
chat.c Fix potential buffer overflow and undefined behavior. 2019-01-26 20:43:28 +00:00
extern.h Sprinkle static; avoid nested externs. 2018-02-04 19:05:13 +00:00
getty.8 .Xr pstat(8), so that people have a chance to learn how to get a list 2018-03-02 14:16:19 +00:00
gettytab Move gettytab to libexec/getty/ 2018-09-05 15:25:23 +00:00
gettytab.5 Fix gettytab(5) to document f0, f1, and f2 as unsupported; they've been gone 2018-02-26 17:51:18 +00:00
gettytab.h General further adoption of SPDX licensing ID tags. 2017-11-20 19:49:47 +00:00
init.c Initialize all the fields. This is one of the steps required to bump WARNS. 2018-02-04 13:58:31 +00:00
main.c Prevent getty(8) from looping indefinitely if the device node doesn't 2018-02-25 20:15:06 +00:00
Makefile Move gettytab to libexec/getty/ 2018-09-05 15:25:23 +00:00
Makefile.depend DIRDEPS_BUILD: Update dependencies. 2017-10-31 00:07:04 +00:00
pathnames.h General further adoption of SPDX licensing ID tags. 2017-11-20 19:49:47 +00:00
subr.c Build getty(8) with WARNS=6. 2018-02-21 15:57:24 +00:00
ttys.5 Remove pointless comment. 2018-08-03 10:59:05 +00:00