Flawfinder version 2.0.10, (C) 2001-2019 David A. Wheeler.
Number of rules (primarily dangerous function names) in C/C++ ruleset: 223
Examining data/shadow-4.8.1/libmisc/chkname.h
Examining data/shadow-4.8.1/libmisc/xgetXXbyYY.c
Examining data/shadow-4.8.1/libmisc/isexpired.c
Examining data/shadow-4.8.1/libmisc/myname.c
Examining data/shadow-4.8.1/libmisc/age.c
Examining data/shadow-4.8.1/libmisc/pam_pass_non_interactive.c
Examining data/shadow-4.8.1/libmisc/pwdcheck.c
Examining data/shadow-4.8.1/libmisc/cleanup.c
Examining data/shadow-4.8.1/libmisc/find_new_sub_gids.c
Examining data/shadow-4.8.1/libmisc/entry.c
Examining data/shadow-4.8.1/libmisc/mail.c
Examining data/shadow-4.8.1/libmisc/getdate.c
Examining data/shadow-4.8.1/libmisc/strtoday.c
Examining data/shadow-4.8.1/libmisc/motd.c
Examining data/shadow-4.8.1/libmisc/ulimit.c
Examining data/shadow-4.8.1/libmisc/yesno.c
Examining data/shadow-4.8.1/libmisc/basename.c
Examining data/shadow-4.8.1/libmisc/pam_pass.c
Examining data/shadow-4.8.1/libmisc/list.c
Examining data/shadow-4.8.1/libmisc/setugid.c
Examining data/shadow-4.8.1/libmisc/cleanup_user.c
Examining data/shadow-4.8.1/libmisc/prefix_flag.c
Examining data/shadow-4.8.1/libmisc/getdate.h
Examining data/shadow-4.8.1/libmisc/xgetspnam.c
Examining data/shadow-4.8.1/libmisc/xmalloc.c
Examining data/shadow-4.8.1/libmisc/chowntty.c
Examining data/shadow-4.8.1/libmisc/getgr_nam_gid.c
Examining data/shadow-4.8.1/libmisc/failure.h
Examining data/shadow-4.8.1/libmisc/btrfs.c
Examining data/shadow-4.8.1/libmisc/log.c
Examining data/shadow-4.8.1/libmisc/console.c
Examining data/shadow-4.8.1/libmisc/sub.c
Examining data/shadow-4.8.1/libmisc/env.c
Examining data/shadow-4.8.1/libmisc/idmapping.h
Examining data/shadow-4.8.1/libmisc/valid.c
Examining data/shadow-4.8.1/libmisc/rlogin.c
Examining data/shadow-4.8.1/libmisc/shell.c
Examining data/shadow-4.8.1/libmisc/find_new_sub_uids.c
Examining data/shadow-4.8.1/libmisc/getrange.c
Examining data/shadow-4.8.1/libmisc/find_new_uid.c
Examining data/shadow-4.8.1/libmisc/cleanup_group.c
Examining data/shadow-4.8.1/libmisc/idmapping.c
Examining data/shadow-4.8.1/libmisc/limits.c
Examining data/shadow-4.8.1/libmisc/copydir.c
Examining data/shadow-4.8.1/libmisc/utmp.c
Examining data/shadow-4.8.1/libmisc/addgrps.c
Examining data/shadow-4.8.1/libmisc/ttytype.c
Examining data/shadow-4.8.1/libmisc/remove_tree.c
Examining data/shadow-4.8.1/libmisc/user_busy.c
Examining data/shadow-4.8.1/libmisc/xgetpwnam.c
Examining data/shadow-4.8.1/libmisc/sulog.c
Examining data/shadow-4.8.1/libmisc/find_new_gid.c
Examining data/shadow-4.8.1/libmisc/loginprompt.c
Examining data/shadow-4.8.1/libmisc/failure.c
Examining data/shadow-4.8.1/libmisc/salt.c
Examining data/shadow-4.8.1/libmisc/setupenv.c
Examining data/shadow-4.8.1/libmisc/hushed.c
Examining data/shadow-4.8.1/libmisc/xgetgrgid.c
Examining data/shadow-4.8.1/libmisc/xgetgrnam.c
Examining data/shadow-4.8.1/libmisc/obscure.c
Examining data/shadow-4.8.1/libmisc/pwd_init.c
Examining data/shadow-4.8.1/libmisc/chowndir.c
Examining data/shadow-4.8.1/libmisc/root_flag.c
Examining data/shadow-4.8.1/libmisc/tz.c
Examining data/shadow-4.8.1/libmisc/gettime.c
Examining data/shadow-4.8.1/libmisc/pwd2spwd.c
Examining data/shadow-4.8.1/libmisc/audit_help.c
Examining data/shadow-4.8.1/libmisc/xgetpwuid.c
Examining data/shadow-4.8.1/libmisc/chkname.c
Examining data/shadow-4.8.1/contrib/adduser-old.c
Examining data/shadow-4.8.1/contrib/adduser.c
Examining data/shadow-4.8.1/contrib/pwdauth.c
Examining data/shadow-4.8.1/src/login_nopam.c
Examining data/shadow-4.8.1/src/suauth.c
Examining data/shadow-4.8.1/src/faillog.c
Examining data/shadow-4.8.1/src/pwunconv.c
Examining data/shadow-4.8.1/src/userdel.c
Examining data/shadow-4.8.1/src/chfn.c
Examining data/shadow-4.8.1/src/expiry.c
Examining data/shadow-4.8.1/src/passwd.c
Examining data/shadow-4.8.1/src/grpconv.c
Examining data/shadow-4.8.1/src/sulogin.c
Examining data/shadow-4.8.1/src/groupdel.c
Examining data/shadow-4.8.1/src/pwck.c
Examining data/shadow-4.8.1/src/newgrp.c
Examining data/shadow-4.8.1/src/gpasswd.c
Examining data/shadow-4.8.1/src/pwconv.c
Examining data/shadow-4.8.1/src/grpck.c
Examining data/shadow-4.8.1/src/newuidmap.c
Examining data/shadow-4.8.1/src/chpasswd.c
Examining data/shadow-4.8.1/src/groups.c
Examining data/shadow-4.8.1/src/su.c
Examining data/shadow-4.8.1/src/newusers.c
Examining data/shadow-4.8.1/src/chgpasswd.c
Examining data/shadow-4.8.1/src/chsh.c
Examining data/shadow-4.8.1/src/lastlog.c
Examining data/shadow-4.8.1/src/logoutd.c
Examining data/shadow-4.8.1/src/id.c
Examining data/shadow-4.8.1/src/chage.c
Examining data/shadow-4.8.1/src/vipw.c
Examining data/shadow-4.8.1/src/usermod.c
Examining data/shadow-4.8.1/src/groupmems.c
Examining data/shadow-4.8.1/src/nologin.c
Examining data/shadow-4.8.1/src/grpunconv.c
Examining data/shadow-4.8.1/src/groupmod.c
Examining data/shadow-4.8.1/src/newgidmap.c
Examining data/shadow-4.8.1/src/groupadd.c
Examining data/shadow-4.8.1/src/cppw.c
Examining data/shadow-4.8.1/src/useradd.c
Examining data/shadow-4.8.1/src/login.c
Examining data/shadow-4.8.1/lib/sssd.h
Examining data/shadow-4.8.1/lib/defines.h
Examining data/shadow-4.8.1/lib/get_gid.c
Examining data/shadow-4.8.1/lib/shadowmem.c
Examining data/shadow-4.8.1/lib/pwio.c
Examining data/shadow-4.8.1/lib/subordinateio.h
Examining data/shadow-4.8.1/lib/nscd.h
Examining data/shadow-4.8.1/lib/sgetpwent.c
Examining data/shadow-4.8.1/lib/fields.c
Examining data/shadow-4.8.1/lib/shadowio.h
Examining data/shadow-4.8.1/lib/port.h
Examining data/shadow-4.8.1/lib/faillog.h
Examining data/shadow-4.8.1/lib/fputsx.c
Examining data/shadow-4.8.1/lib/encrypt.c
Examining data/shadow-4.8.1/lib/groupmem.c
Examining data/shadow-4.8.1/lib/get_pid.c
Examining data/shadow-4.8.1/lib/prototypes.h
Examining data/shadow-4.8.1/lib/get_uid.c
Examining data/shadow-4.8.1/lib/sgetspent.c
Examining data/shadow-4.8.1/lib/sgetgrent.c
Examining data/shadow-4.8.1/lib/utent.c
Examining data/shadow-4.8.1/lib/sssd.c
Examining data/shadow-4.8.1/lib/groupio.c
Examining data/shadow-4.8.1/lib/tcbfuncs.h
Examining data/shadow-4.8.1/lib/getulong.c
Examining data/shadow-4.8.1/lib/pwio.h
Examining data/shadow-4.8.1/lib/commonio.h
Examining data/shadow-4.8.1/lib/port.c
Examining data/shadow-4.8.1/lib/pwauth.h
Examining data/shadow-4.8.1/lib/gshadow_.h
Examining data/shadow-4.8.1/lib/nscd.c
Examining data/shadow-4.8.1/lib/groupio.h
Examining data/shadow-4.8.1/lib/pwmem.c
Examining data/shadow-4.8.1/lib/tcbfuncs.c
Examining data/shadow-4.8.1/lib/getlong.c
Examining data/shadow-4.8.1/lib/spawn.c
Examining data/shadow-4.8.1/lib/pwauth.c
Examining data/shadow-4.8.1/lib/shadow.c
Examining data/shadow-4.8.1/lib/subordinateio.c
Examining data/shadow-4.8.1/lib/selinux.c
Examining data/shadow-4.8.1/lib/lockpw.c
Examining data/shadow-4.8.1/lib/getdef.h
Examining data/shadow-4.8.1/lib/exitcodes.h
Examining data/shadow-4.8.1/lib/semanage.c
Examining data/shadow-4.8.1/lib/gshadow.c
Examining data/shadow-4.8.1/lib/sgroupio.h
Examining data/shadow-4.8.1/lib/pam_defs.h
Examining data/shadow-4.8.1/lib/getdef.c
Examining data/shadow-4.8.1/lib/commonio.c
Examining data/shadow-4.8.1/lib/sgroupio.c
Examining data/shadow-4.8.1/lib/shadowio.c

FINAL RESULTS:

data/shadow-4.8.1/contrib/adduser-old.c:166:4:  [5] (buffer) gets:
  Does not check for buffer overflows (CWE-120, CWE-20). Use fgets() instead.
			gets(uname);
data/shadow-4.8.1/contrib/adduser-old.c:186:3:  [5] (buffer) gets:
  Does not check for buffer overflows (CWE-120, CWE-20). Use fgets() instead.
		gets(person);
data/shadow-4.8.1/contrib/adduser-old.c:195:4:  [5] (buffer) gets:
  Does not check for buffer overflows (CWE-120, CWE-20). Use fgets() instead.
			gets(foo);
data/shadow-4.8.1/contrib/adduser-old.c:227:3:  [5] (buffer) gets:
  Does not check for buffer overflows (CWE-120, CWE-20). Use fgets() instead.
		gets(dir);
data/shadow-4.8.1/contrib/adduser-old.c:237:3:  [5] (buffer) gets:
  Does not check for buffer overflows (CWE-120, CWE-20). Use fgets() instead.
		gets(shell);
data/shadow-4.8.1/contrib/adduser-old.c:242:3:  [5] (buffer) gets:
  Does not check for buffer overflows (CWE-120, CWE-20). Use fgets() instead.
		gets(foo);
data/shadow-4.8.1/contrib/adduser-old.c:246:3:  [5] (buffer) gets:
  Does not check for buffer overflows (CWE-120, CWE-20). Use fgets() instead.
		gets(foo);
data/shadow-4.8.1/contrib/adduser-old.c:253:3:  [5] (buffer) gets:
  Does not check for buffer overflows (CWE-120, CWE-20). Use fgets() instead.
		gets(foo);
data/shadow-4.8.1/contrib/adduser-old.c:259:3:  [5] (buffer) gets:
  Does not check for buffer overflows (CWE-120, CWE-20). Use fgets() instead.
		gets(foo);
data/shadow-4.8.1/contrib/adduser-old.c:271:3:  [5] (buffer) gets:
  Does not check for buffer overflows (CWE-120, CWE-20). Use fgets() instead.
		gets(foo);
data/shadow-4.8.1/lib/commonio.c:276:6:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
	if (chown (name, sb->st_mode) != 0) {
data/shadow-4.8.1/lib/commonio.c:286:6:  [5] (race) chmod:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchmod( ) instead.
	if (chmod (name, sb->st_mode & 0664) != 0) {
data/shadow-4.8.1/lib/defines.h:248:16:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
#define LCHOWN chown
data/shadow-4.8.1/lib/tcbfuncs.c:141:8:  [5] (race) readlink:
  This accepts filename arguments; if an attacker can move those files or
  change the link content, a race condition results. Also, it does not
  terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach.
	ret = readlink (path, link, sizeof (link) - 1);
data/shadow-4.8.1/lib/tcbfuncs.c:227:7:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
		if (chown (dir, 0, st.st_gid) != 0) {
data/shadow-4.8.1/lib/tcbfuncs.c:233:7:  [5] (race) chmod:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchmod( ) instead.
		if (chmod (dir, 0711) != 0) {
data/shadow-4.8.1/lib/tcbfuncs.c:472:6:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
	if (chown (tcbdir, 0, 0) != 0) {
data/shadow-4.8.1/lib/tcbfuncs.c:478:6:  [5] (race) chmod:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchmod( ) instead.
	if (chmod (tcbdir, 0700) != 0) {
data/shadow-4.8.1/lib/tcbfuncs.c:504:7:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
		if (chown (shadow, user_newid, filemode.st_gid) != 0) {
data/shadow-4.8.1/lib/tcbfuncs.c:510:7:  [5] (race) chmod:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchmod( ) instead.
		if (chmod (shadow, filemode.st_mode & 07777) != 0) {
data/shadow-4.8.1/lib/tcbfuncs.c:520:6:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
	if (chown (tcbdir, user_newid, dirmode.st_gid) != 0) {
data/shadow-4.8.1/lib/tcbfuncs.c:579:6:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
	if (chown (shadow, 0, authgid) != 0) {
data/shadow-4.8.1/lib/tcbfuncs.c:585:6:  [5] (race) chmod:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchmod( ) instead.
	if (chmod (shadow, (mode_t) ((authgid == shadowgid) ? 0600 : 0640)) != 0) {
data/shadow-4.8.1/lib/tcbfuncs.c:591:6:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
	if (chown (dir, 0, authgid) != 0) {
data/shadow-4.8.1/lib/tcbfuncs.c:597:6:  [5] (race) chmod:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchmod( ) instead.
	if (chmod (dir, (mode_t) ((authgid == shadowgid) ? 02700 : 02710)) != 0) {
data/shadow-4.8.1/libmisc/copydir.c:498:10:  [5] (race) chmod:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchmod( ) instead.
	    || (chmod (dst, statp->st_mode) != 0)
data/shadow-4.8.1/libmisc/copydir.c:539:12:  [5] (race) readlink:
  This accepts filename arguments; if an attacker can move those files or
  change the link content, a race condition results. Also, it does not
  terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach.
		nchars = readlink (filename, buffer, size);
data/shadow-4.8.1/libmisc/copydir.c:699:10:  [5] (race) chmod:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchmod( ) instead.
	    || (chmod (dst, statp->st_mode & 07777) != 0)
data/shadow-4.8.1/libmisc/copydir.c:836:22:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
def_chown_if_needed (chown, const char *)
data/shadow-4.8.1/libmisc/user_busy.c:121:15:  [5] (race) readlink:
  This accepts filename arguments; if an attacker can move those files or
  change the link content, a race condition results. Also, it does not
  terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach.
	if ((llen1 = readlink (path, buf, sizeof(buf))) == -1)
data/shadow-4.8.1/libmisc/user_busy.c:124:15:  [5] (race) readlink:
  This accepts filename arguments; if an attacker can move those files or
  change the link content, a race condition results. Also, it does not
  terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach.
	if ((llen2 = readlink ("/proc/self/ns/user", buf2, sizeof(buf2))) == -1)
data/shadow-4.8.1/src/cppw.c:98:10:  [5] (race) chmod:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchmod( ) instead.
	    || (chmod (dest, sb->st_mode) != 0)
data/shadow-4.8.1/src/cppw.c:99:10:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
	    || (chown (dest, sb->st_uid, sb->st_gid) != 0)) {
data/shadow-4.8.1/src/newusers.c:1226:15:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
			} else if (chown (newpw.pw_dir,
data/shadow-4.8.1/src/pwconv.c:311:7:  [5] (race) chmod:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchmod( ) instead.
	if ((chmod (PASSWD_FILE "-", 0600) != 0) && (errno != ENOENT)) {
data/shadow-4.8.1/src/useradd.c:2151:9:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
				if (chown (path, 0, 0) < 0) {
data/shadow-4.8.1/src/useradd.c:2156:9:  [5] (race) chmod:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchmod( ) instead.
				if (chmod (path, 0755) < 0) {
data/shadow-4.8.1/src/useradd.c:2165:10:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
		(void) chown (prefix_user_home, user_id, user_gid);
data/shadow-4.8.1/src/useradd.c:2168:3:  [5] (race) chmod:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchmod( ) instead.
		chmod (prefix_user_home, mode);
data/shadow-4.8.1/src/vipw.c:150:10:  [5] (race) chmod:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchmod( ) instead.
	    || (chmod (backup, sb->st_mode) != 0)
data/shadow-4.8.1/src/vipw.c:151:10:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
	    || (chown (backup, sb->st_uid, sb->st_gid) != 0)) {
data/shadow-4.8.1/contrib/adduser-old.c:189:4:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
			strcpy(person,uname);
data/shadow-4.8.1/contrib/adduser-old.c:229:4:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
			sprintf(dir,"%s/%s",DEFAULT_HOME,uname);
data/shadow-4.8.1/contrib/adduser-old.c:233:5:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
				sprintf(dir+strlen(dir),"%s",uname);
data/shadow-4.8.1/contrib/adduser-old.c:239:4:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
			sprintf(shell,"%s",DEFAULT_SHELL);
data/shadow-4.8.1/contrib/adduser-old.c:280:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(cmd,"%s -g %d -d %s -s %s -c \"%s\" -m -k /etc/skel %s",
data/shadow-4.8.1/contrib/adduser-old.c:283:5:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
	if(system(cmd)){
data/shadow-4.8.1/contrib/adduser-old.c:288:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(cmd,"%s -m %d -M %d -W %d -I %d %s", CHAGE_PATH,
data/shadow-4.8.1/contrib/adduser-old.c:291:5:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
	if(system(cmd)){
data/shadow-4.8.1/contrib/adduser-old.c:296:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(cmd,"%s %s",PASSWD_PATH,uname);
data/shadow-4.8.1/contrib/adduser-old.c:297:2:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
	system(cmd);
data/shadow-4.8.1/contrib/adduser.c:242:4:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	  strcpy (person, usrname);
data/shadow-4.8.1/contrib/adduser.c:296:8:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	      sprintf (dir, "%s/%s", DEFAULT_HOME, usrname);
data/shadow-4.8.1/contrib/adduser.c:299:6:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	    sprintf (dir+strlen(dir), "%s", usrname);
data/shadow-4.8.1/contrib/adduser.c:304:4:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	  sprintf (dir, "%s/%s", DEFAULT_HOME, usrname);
data/shadow-4.8.1/contrib/adduser.c:311:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf (shell, "%s", DEFAULT_SHELL);
data/shadow-4.8.1/contrib/adduser.c:330:5:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		  sprintf (shell, "%s", DEFAULT_SHELL);
data/shadow-4.8.1/contrib/adduser.c:403:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
  sprintf (cmd, "%s -g %d -d %s -s %s -c \"%s\" -m -k /etc/skel %s",
data/shadow-4.8.1/contrib/adduser.c:406:7:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
  if (system (cmd))
data/shadow-4.8.1/contrib/adduser.c:426:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
  sprintf (cmd, "%s -m %d -M %d -W %d -I %d %s", CHAGE_PATH,
data/shadow-4.8.1/contrib/adduser.c:429:7:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
  if (system (cmd))
data/shadow-4.8.1/contrib/adduser.c:441:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
  sprintf (cmd, "%s -p %s -u %s", EDQUOTA_PATH, QUOTA_DEFAULT, usrname);
data/shadow-4.8.1/contrib/adduser.c:443:7:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
  if (system (cmd))
data/shadow-4.8.1/contrib/adduser.c:455:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
  sprintf (cmd, "%s %s", PASSWD_PATH, usrname);
data/shadow-4.8.1/contrib/adduser.c:456:7:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
  if (system (cmd))
data/shadow-4.8.1/contrib/adduser.c:465:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
  sprintf (cmd, "%s -e %s", PASSWD_PATH, usrname);
data/shadow-4.8.1/contrib/adduser.c:466:7:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
  if (system (cmd))
data/shadow-4.8.1/contrib/pwdauth.c:102:9:  [4] (crypto) crypt:
  The crypt functions use a poor one-way hashing algorithm; since they only
  accept passwords of 8 characters or fewer and only a two-byte salt, they
  are excessively vulnerable to dictionary attacks given today's faster
  computing equipment (CWE-327). Use a different algorithm, such as SHA-256,
  with a larger, non-repeating salt.
#define crypt pw_encrypt
data/shadow-4.8.1/contrib/pwdauth.c:137:15:  [4] (misc) getlogin:
  It's often easy to fool getlogin. Sometimes it does not work at all,
  because some program messed up the utmp file. Often, it gives only the
  first 8 characters of the login name. The user currently logged in on the
  controlling tty of our program need not be the user who started it. Avoid
  getlogin() for security-related purposes (CWE-807). Use getpwuid(geteuid())
  and extract the desired information instead.
	char *name = getlogin();
data/shadow-4.8.1/contrib/pwdauth.c:192:20:  [4] (crypto) crypt:
  The crypt functions use a poor one-way hashing algorithm; since they only
  accept passwords of 8 characters or fewer and only a two-byte salt, they
  are excessively vulnerable to dictionary attacks given today's faster
  computing equipment (CWE-327). Use a different algorithm, such as SHA-256,
  with a larger, non-repeating salt.
		result = (strcmp(crypt(pass, cp), cp) == 0);
data/shadow-4.8.1/lib/commonio.c:375:10:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	return (access (db->filename, F_OK) == 0);
data/shadow-4.8.1/lib/defines.h:188:3:  [4] (format) syslog:
  If syslog's format strings can be influenced by an attacker, they can be
  exploited (CWE-134). Use a constant format string for syslog.
		syslog x ;						\
data/shadow-4.8.1/lib/defines.h:195:19:  [4] (format) syslog:
  If syslog's format strings can be influenced by an attacker, they can be
  exploited (CWE-134). Use a constant format string for syslog.
#define SYSLOG(x) syslog x
data/shadow-4.8.1/lib/encrypt.c:48:7:  [4] (crypto) crypt:
  The crypt functions use a poor one-way hashing algorithm; since they only
  accept passwords of 8 characters or fewer and only a two-byte salt, they
  are excessively vulnerable to dictionary attacks given today's faster
  computing equipment (CWE-327). Use a different algorithm, such as SHA-256,
  with a larger, non-repeating salt.
	cp = crypt (clear, salt);
data/shadow-4.8.1/lib/encrypt.c:94:2:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	strcpy (cipher, cp);
data/shadow-4.8.1/lib/gshadow.c:409:6:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
					strcpy (save_name, sgrp->sg_name);
data/shadow-4.8.1/lib/gshadow.c:473:2:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	strcpy (cp, sgrp->sg_name);
data/shadow-4.8.1/lib/gshadow.c:477:2:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	strcpy (cp, sgrp->sg_passwd);
data/shadow-4.8.1/lib/gshadow.c:491:3:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
		strcpy (cp, sgrp->sg_adm[i]);
data/shadow-4.8.1/lib/gshadow.c:507:3:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
		strcpy (cp, sgrp->sg_mem[i]);
data/shadow-4.8.1/lib/nscd.c:28:10:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		(void) fprintf (stderr, _(MSG_NSCD_FLUSH_CACHE_FAILED), Prog);
data/shadow-4.8.1/lib/nscd.c:48:10:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		(void) fprintf (stderr, _(MSG_NSCD_FLUSH_CACHE_FAILED), Prog);
data/shadow-4.8.1/lib/pwauth.c:163:3:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
		snprintf (prompt, sizeof prompt, cp, user);
data/shadow-4.8.1/lib/pwauth.c:164:11:  [4] (misc) getpass:
  This function is obsolete and not portable. It was in SUSv2 but removed by
  POSIX.2. What it does exactly varies considerably between systems,
  particularly in where its prompt is displayed and where it gets its data
  (e.g., /dev/tty, stdin, stderr, etc.). In addition, some implementations
  overflow buffers. (CWE-676, CWE-120, CWE-20). Make the specific calls to do
  exactly what you want. If you continue to use it, or write your own, be
  sure to zero the password as soon as possible to avoid leaving the
  cleartext password visible in the process' address space.
		clear = getpass (prompt);
data/shadow-4.8.1/lib/pwauth.c:197:11:  [4] (misc) getpass:
  This function is obsolete and not portable. It was in SUSv2 but removed by
  POSIX.2. What it does exactly varies considerably between systems,
  particularly in where its prompt is displayed and where it gets its data
  (e.g., /dev/tty, stdin, stderr, etc.). In addition, some implementations
  overflow buffers. (CWE-676, CWE-120, CWE-20). Make the specific calls to do
  exactly what you want. If you continue to use it, or write your own, be
  sure to zero the password as soon as possible to avoid leaving the
  cleartext password visible in the process' address space.
		clear = getpass (prompt);
data/shadow-4.8.1/lib/selinux.c:105:28:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
__attribute__((__format__ (printf, 2, 3)))
data/shadow-4.8.1/lib/sgetgrent.c:124:2:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	strcpy (grpbuf, buf);
data/shadow-4.8.1/lib/sgetpwent.c:72:2:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	strcpy (pwdbuf, buf);
data/shadow-4.8.1/lib/sgetspent.c:66:2:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	strcpy (spwbuf, string);
data/shadow-4.8.1/lib/shadow.c:143:2:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	strcpy (spwbuf, string);
data/shadow-4.8.1/lib/shadow.c:517:5:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
				strcpy (save_name, sp->sp_namp);
data/shadow-4.8.1/lib/sssd.c:49:10:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		(void) fprintf (stderr, _(MSG_SSSD_FLUSH_CACHE_FAILED), Prog);
data/shadow-4.8.1/lib/sssd.c:66:10:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		(void) fprintf (stderr, _(MSG_SSSD_FLUSH_CACHE_FAILED), Prog);
data/shadow-4.8.1/lib/subordinateio.c:89:2:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	strcpy (rangebuf, line);
data/shadow-4.8.1/libmisc/addgrps.c:65:2:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	strcpy (buf, list);
data/shadow-4.8.1/libmisc/age.c:138:10:  [4] (shell) execl:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
		(void) execl (PASSWD_PROGRAM, PASSWD_PROGRAM, pw->pw_name, (char *) 0);
data/shadow-4.8.1/libmisc/btrfs.c:42:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access(cmd, X_OK)) {
data/shadow-4.8.1/libmisc/chowndir.c:80:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access (root, F_OK) != 0) {
data/shadow-4.8.1/libmisc/copydir.c:129:6:  [4] (format) vfprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	if (vfprintf (stderr, fmt, ap) != 0) {
data/shadow-4.8.1/libmisc/copydir.c:242:7:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
		if (access (dst_root, F_OK) == 0) {
data/shadow-4.8.1/libmisc/copydir.c:267:10:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (   (access (src_root, F_OK) != 0)
data/shadow-4.8.1/libmisc/copydir.c:268:10:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	    || (access (dst_root, F_OK) != 0)) {
data/shadow-4.8.1/libmisc/failure.c:60:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access (FAILLOG_FILE, F_OK) != 0) {
data/shadow-4.8.1/libmisc/failure.c:163:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access (FAILLOG_FILE, F_OK) != 0) {
data/shadow-4.8.1/libmisc/failure.c:277:9:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	(void) printf (ngettext ("%d failure since last login.\n"
data/shadow-4.8.1/libmisc/failure.c:319:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access (ftmp, F_OK) != 0) {
data/shadow-4.8.1/libmisc/getdate.c:811:21:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
#  define YYFPRINTF fprintf
data/shadow-4.8.1/libmisc/hushed.c:80:11:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
		return (access (buf, F_OK) == 0);
data/shadow-4.8.1/libmisc/limits.c:476:7:  [4] (buffer) sscanf:
  The scanf() family's %s operation, without a limit specification, permits
  buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a
  different input function.
		if (sscanf (buf, "%s%[ACDFIKLMNOPRSTUacdfiklmnoprstu0-9 \t-]",
data/shadow-4.8.1/libmisc/limits.c:479:5:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
				strcpy (limits, tempbuf);
data/shadow-4.8.1/libmisc/limits.c:482:5:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
				strcpy (deflimits, tempbuf);
data/shadow-4.8.1/libmisc/limits.c:489:6:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
					strcpy (limits, tempbuf);
data/shadow-4.8.1/libmisc/limits.c:500:3:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
		strcpy (limits, deflimits);	/* use the default limits */
data/shadow-4.8.1/libmisc/loginprompt.c:102:3:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		printf (prompt, buf);
data/shadow-4.8.1/libmisc/myname.c:47:19:  [4] (misc) getlogin:
  It's often easy to fool getlogin. Sometimes it does not work at all,
  because some program messed up the utmp file. Often, it gives only the
  first 8 characters of the login name. The user currently logged in on the
  controlling tty of our program need not be the user who started it. Avoid
  getlogin() for security-related purposes (CWE-807). Use getpwuid(geteuid())
  and extract the desired information instead.
	const char *cp = getlogin ();
data/shadow-4.8.1/libmisc/obscure.c:185:2:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	strcpy (wrapped, oldmono);
data/shadow-4.8.1/libmisc/obscure.c:186:2:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
	strcat (wrapped, oldmono);
data/shadow-4.8.1/libmisc/root_flag.c:103:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access (newroot, F_OK) != 0) {
data/shadow-4.8.1/libmisc/salt.c:255:2:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
	strcat (salt, l64a (random()));
data/shadow-4.8.1/libmisc/salt.c:257:3:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
		strcat (salt, l64a (random()));
data/shadow-4.8.1/libmisc/salt.c:281:2:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
	strcat (salt, l64a (random()));
data/shadow-4.8.1/libmisc/salt.c:283:3:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
		strcat (salt, l64a (random()));
data/shadow-4.8.1/libmisc/salt.c:334:3:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
		strcat(result, BCRYPT_salt_rounds((int *)arg));
data/shadow-4.8.1/libmisc/salt.c:339:3:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
		strcat(result, SHA_salt_rounds((int *)arg));
data/shadow-4.8.1/libmisc/salt.c:343:3:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
		strcat(result, SHA_salt_rounds((int *)arg));
data/shadow-4.8.1/libmisc/shell.c:81:9:  [4] (shell) execle:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
	(void) execle (file, arg, (char *) 0, envp);
data/shadow-4.8.1/libmisc/shell.c:84:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access (file, R_OK|X_OK) == 0) {
data/shadow-4.8.1/libmisc/shell.c:89:10:  [4] (shell) execle:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
		(void) execle (SHELL, "sh", "-", file, (char *)0, envp);
data/shadow-4.8.1/libmisc/ttytype.c:60:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access (typefile, F_OK) != 0) {
data/shadow-4.8.1/libmisc/tz.c:66:3:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
		strcpy (tzbuf, def_tz);
data/shadow-4.8.1/libmisc/utmp.c:236:3:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
		strcpy (hostname, host);
data/shadow-4.8.1/libmisc/utmp.c:381:3:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
		strcpy (hostname, host);
data/shadow-4.8.1/libmisc/xmalloc.c:67:9:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	return strcpy (xmalloc (strlen (str) + 1), str);
data/shadow-4.8.1/src/chfn.c:249:4:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
			strcat (extra, in);
data/shadow-4.8.1/src/chfn.c:254:3:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
		strcpy (out, in);
data/shadow-4.8.1/src/chfn.c:562:3:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
		strcat (slop, cp);
data/shadow-4.8.1/src/chsh.c:539:14:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	        || (access (loginsh, X_OK) != 0))) {
data/shadow-4.8.1/src/chsh.c:545:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access (loginsh, F_OK) != 0) {
data/shadow-4.8.1/src/chsh.c:547:13:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	} else if (access (loginsh, X_OK) != 0) {
data/shadow-4.8.1/src/cppw.c:142:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access (file, F_OK) != 0) {
data/shadow-4.8.1/src/gpasswd.c:912:8:  [4] (misc) getpass:
  This function is obsolete and not portable. It was in SUSv2 but removed by
  POSIX.2. What it does exactly varies considerably between systems,
  particularly in where its prompt is displayed and where it gets its data
  (e.g., /dev/tty, stdin, stderr, etc.). In addition, some implementations
  overflow buffers. (CWE-676, CWE-120, CWE-20). Make the specific calls to do
  exactly what you want. If you continue to use it, or write your own, be
  sure to zero the password as soon as possible to avoid leaving the
  cleartext password visible in the process' address space.
		cp = getpass (_("New Password: "));
data/shadow-4.8.1/src/gpasswd.c:919:8:  [4] (misc) getpass:
  This function is obsolete and not portable. It was in SUSv2 but removed by
  POSIX.2. What it does exactly varies considerably between systems,
  particularly in where its prompt is displayed and where it gets its data
  (e.g., /dev/tty, stdin, stderr, etc.). In addition, some implementations
  overflow buffers. (CWE-676, CWE-120, CWE-20). Make the specific calls to do
  exactly what you want. If you continue to use it, or write your own, be
  sure to zero the password as soon as possible to avoid leaving the
  cleartext password visible in the process' address space.
		cp = getpass (_("Re-enter new password: "));
data/shadow-4.8.1/src/groups.c:114:8:  [4] (misc) getlogin:
  It's often easy to fool getlogin. Sometimes it does not work at all,
  because some program messed up the utmp file. Often, it gives only the
  first 8 characters of the login name. The user currently logged in on the
  controlling tty of our program need not be the user who started it. Avoid
  getlogin() for security-related purposes (CWE-807). Use getpwuid(geteuid())
  and extract the desired information instead.
	char *getlogin ();
data/shadow-4.8.1/src/groups.c:201:13:  [4] (misc) getlogin:
  It's often easy to fool getlogin. Sometimes it does not work at all,
  because some program messed up the utmp file. Often, it gives only the
  first 8 characters of the login name. The user currently logged in on the
  controlling tty of our program need not be the user who started it. Avoid
  getlogin() for security-related purposes (CWE-807). Use getpwuid(geteuid())
  and extract the desired information instead.
		logname = getlogin ();
data/shadow-4.8.1/src/grpck.c:416:3:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		printf (fmt_info, groupname, members[i]);
data/shadow-4.8.1/src/grpck.c:417:3:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		printf (fmt_prompt, members[i]);
data/shadow-4.8.1/src/login.c:248:26:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if ((NULL != fname) && (access (fname, F_OK) == 0)) {
data/shadow-4.8.1/src/logoutd.c:251:4:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
			strcat (tty_name, ut->ut_line);
data/shadow-4.8.1/src/newgrp.c:182:8:  [4] (misc) getpass:
  This function is obsolete and not portable. It was in SUSv2 but removed by
  POSIX.2. What it does exactly varies considerably between systems,
  particularly in where its prompt is displayed and where it gets its data
  (e.g., /dev/tty, stdin, stderr, etc.). In addition, some implementations
  overflow buffers. (CWE-676, CWE-120, CWE-20). Make the specific calls to do
  exactly what you want. If you continue to use it, or write your own, be
  sure to zero the password as soon as possible to avoid leaving the
  cleartext password visible in the process' address space.
		cp = getpass (_("Password: "));
data/shadow-4.8.1/src/newgrp.c:264:26:  [4] (misc) getlogin:
  It's often easy to fool getlogin. Sometimes it does not work at all,
  because some program messed up the utmp file. Often, it gives only the
  first 8 characters of the login name. The user currently logged in on the
  controlling tty of our program need not be the user who started it. Avoid
  getlogin() for security-related purposes (CWE-807). Use getpwuid(geteuid())
  and extract the desired information instead.
	const char *loginname = getlogin ();
data/shadow-4.8.1/src/newgrp.c:768:3:  [4] (shell) execl:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
		execl (SHELL, "sh", "-c", command, (char *) 0);
data/shadow-4.8.1/src/newusers.c:1217:11:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
		    && (access (newpw.pw_dir, F_OK) != 0)) {
data/shadow-4.8.1/src/nologin.c:44:9:  [4] (misc) getlogin:
  It's often easy to fool getlogin. Sometimes it does not work at all,
  because some program messed up the utmp file. Often, it gives only the
  first 8 characters of the login name. The user currently logged in on the
  controlling tty of our program need not be the user who started it. Avoid
  getlogin() for security-related purposes (CWE-807). Use getpwuid(geteuid())
  and extract the desired information instead.
	user = getlogin ();
data/shadow-4.8.1/src/passwd.c:230:11:  [4] (misc) getpass:
  This function is obsolete and not portable. It was in SUSv2 but removed by
  POSIX.2. What it does exactly varies considerably between systems,
  particularly in where its prompt is displayed and where it gets its data
  (e.g., /dev/tty, stdin, stderr, etc.). In addition, some implementations
  overflow buffers. (CWE-676, CWE-120, CWE-20). Make the specific calls to do
  exactly what you want. If you continue to use it, or write your own, be
  sure to zero the password as soon as possible to avoid leaving the
  cleartext password visible in the process' address space.
		clear = getpass (_("Old password: "));
data/shadow-4.8.1/src/passwd.c:309:8:  [4] (misc) getpass:
  This function is obsolete and not portable. It was in SUSv2 but removed by
  POSIX.2. What it does exactly varies considerably between systems,
  particularly in where its prompt is displayed and where it gets its data
  (e.g., /dev/tty, stdin, stderr, etc.). In addition, some implementations
  overflow buffers. (CWE-676, CWE-120, CWE-20). Make the specific calls to do
  exactly what you want. If you continue to use it, or write your own, be
  sure to zero the password as soon as possible to avoid leaving the
  cleartext password visible in the process' address space.
		cp = getpass (_("New password: "));
data/shadow-4.8.1/src/passwd.c:336:8:  [4] (misc) getpass:
  This function is obsolete and not portable. It was in SUSv2 but removed by
  POSIX.2. What it does exactly varies considerably between systems,
  particularly in where its prompt is displayed and where it gets its data
  (e.g., /dev/tty, stdin, stderr, etc.). In addition, some implementations
  overflow buffers. (CWE-676, CWE-120, CWE-20). Make the specific calls to do
  exactly what you want. If you continue to use it, or write your own, be
  sure to zero the password as soon as possible to avoid leaving the
  cleartext password visible in the process' address space.
		cp = getpass (_("Re-enter new password: "));
data/shadow-4.8.1/src/passwd.c:551:3:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
		strcat (newpw, cp);
data/shadow-4.8.1/src/pwck.c:529:19:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
			if (!quiet && (access (pwd->pw_dir, F_OK) != 0)) {
data/shadow-4.8.1/src/pwck.c:544:11:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
		    && (access (pwd->pw_shell, F_OK) != 0)) {
data/shadow-4.8.1/src/pwck.c:904:3:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		printf (changed ?
data/shadow-4.8.1/src/su.c:253:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access (shellname, R_OK|X_OK) == 0) {
data/shadow-4.8.1/src/su.c:828:11:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
			(void) strcpy (name, root_pw->pw_name);
data/shadow-4.8.1/src/su.c:1172:3:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
		strcpy (arg0 + 1, cp);
data/shadow-4.8.1/src/sulogin.c:133:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access (PASSWD_FILE, F_OK) == -1) {	/* must be a password file! */
data/shadow-4.8.1/src/sulogin.c:205:8:  [4] (misc) getpass:
  This function is obsolete and not portable. It was in SUSv2 but removed by
  POSIX.2. What it does exactly varies considerably between systems,
  particularly in where its prompt is displayed and where it gets its data
  (e.g., /dev/tty, stdin, stderr, etc.). In addition, some implementations
  overflow buffers. (CWE-676, CWE-120, CWE-20). Make the specific calls to do
  exactly what you want. If you continue to use it, or write your own, be
  sure to zero the password as soon as possible to avoid leaving the
  cleartext password visible in the process' address space.
		cp = getpass (_(
data/shadow-4.8.1/src/sulogin.c:222:4:  [4] (shell) execl:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
			execl (PATH_TELINIT, "telinit", RUNLEVEL, (char *) 0);
data/shadow-4.8.1/src/useradd.c:606:4:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
			fprintf (ofp, DGROUP "%u\n", (unsigned int) def_group);
data/shadow-4.8.1/src/useradd.c:609:4:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
			fprintf (ofp, DHOME "%s\n", def_home);
data/shadow-4.8.1/src/useradd.c:612:4:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
			fprintf (ofp, DINACT "%ld\n", def_inactive);
data/shadow-4.8.1/src/useradd.c:615:4:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
			fprintf (ofp, DEXPIRE "%s\n", def_expire);
data/shadow-4.8.1/src/useradd.c:618:4:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
			fprintf (ofp, DSHELL "%s\n", def_shell);
data/shadow-4.8.1/src/useradd.c:621:4:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
			fprintf (ofp, DSKEL "%s\n", def_template);
data/shadow-4.8.1/src/useradd.c:625:4:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
			fprintf (ofp,
data/shadow-4.8.1/src/useradd.c:641:3:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		fprintf (ofp, DGROUP "%u\n", (unsigned int) def_group);
data/shadow-4.8.1/src/useradd.c:643:3:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		fprintf (ofp, DHOME "%s\n", def_home);
data/shadow-4.8.1/src/useradd.c:645:3:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		fprintf (ofp, DINACT "%ld\n", def_inactive);
data/shadow-4.8.1/src/useradd.c:647:3:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		fprintf (ofp, DEXPIRE "%s\n", def_expire);
data/shadow-4.8.1/src/useradd.c:649:3:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		fprintf (ofp, DSHELL "%s\n", def_shell);
data/shadow-4.8.1/src/useradd.c:651:3:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		fprintf (ofp, DSKEL "%s\n", def_template);
data/shadow-4.8.1/src/useradd.c:654:3:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		fprintf (ofp, DCREATE_MAIL_SPOOL "%s\n", def_create_mail_spool);
data/shadow-4.8.1/src/useradd.c:1343:17:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
				         || access(optarg, X_OK) != 0)) {
data/shadow-4.8.1/src/useradd.c:1870:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access (FAILLOG_FILE, F_OK) != 0) {
data/shadow-4.8.1/src/useradd.c:1897:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access (LASTLOG_FILE, F_OK) != 0) {
data/shadow-4.8.1/src/useradd.c:1931:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access(pam_tally2, X_OK) == -1)
data/shadow-4.8.1/src/useradd.c:1946:3:  [4] (shell) execl:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
		execl(pam_tally2, pname, "--user", user_name, "--reset", "--quiet", NULL);
data/shadow-4.8.1/src/useradd.c:2076:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access (prefix_user_home, F_OK) != 0) {
data/shadow-4.8.1/src/useradd.c:2106:4:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
			strcat (path, cp);
data/shadow-4.8.1/src/useradd.c:2107:8:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
			if (access (path, F_OK) != 0) {
data/shadow-4.8.1/src/useradd.c:2211:4:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
			sprintf (file, "%s/%s/%s", prefix, spool, user_name);
data/shadow-4.8.1/src/useradd.c:2213:4:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
			sprintf (file, "%s/%s", spool, user_name);
data/shadow-4.8.1/src/userdel.c:853:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access (mailfile, F_OK) != 0) {
data/shadow-4.8.1/src/userdel.c:968:2:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
	snprintf (buf, buflen, TCB_DIR "/%s", user_name);
data/shadow-4.8.1/src/usermod.c:465:3:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
		strcat (buf, pw_pass);
data/shadow-4.8.1/src/usermod.c:1775:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access (prefix_user_newhome, F_OK) == 0) {
data/shadow-4.8.1/src/usermod.c:1885:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access (LASTLOG_FILE, F_OK) != 0) {
data/shadow-4.8.1/src/usermod.c:1952:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access (FAILLOG_FILE, F_OK) != 0) {
data/shadow-4.8.1/src/vipw.c:226:3:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
		snprintf (fileedit, sizeof fileedit,
data/shadow-4.8.1/src/vipw.c:239:6:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (access (file, F_OK) != 0) {
data/shadow-4.8.1/src/vipw.c:321:12:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
		status = system (buf);
data/shadow-4.8.1/src/vipw.c:566:4:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
			printf (MSG_WARN_EDIT_OTHER_FILE,
data/shadow-4.8.1/src/vipw.c:573:5:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
				printf (MSG_WARN_EDIT_OTHER_FILE,
data/shadow-4.8.1/src/vipw.c:583:4:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
			printf (MSG_WARN_EDIT_OTHER_FILE,
data/shadow-4.8.1/src/vipw.c:592:5:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
				printf (MSG_WARN_EDIT_OTHER_FILE,
data/shadow-4.8.1/lib/commonio.c:98:7:  [3] (buffer) realpath:
  This function does not protect against buffer overflows, and some
  implementations can overflow internally (CWE-120/CWE-785!). Ensure that the
  destination buffer is at least of size MAXPATHLEN, andto protect against
  implementation problems, the input argument should also be checked to
  ensure it is no larger than MAXPATHLEN.
		r = realpath (new, NULL);
data/shadow-4.8.1/lib/commonio.c:100:7:  [3] (buffer) realpath:
  This function does not protect against buffer overflows, and some
  implementations can overflow internally (CWE-120/CWE-785!). Ensure that the
  destination buffer is at least of size MAXPATHLEN, andto protect against
  implementation problems, the input argument should also be checked to
  ensure it is no larger than MAXPATHLEN.
		r = realpath (new, resolved_path);
data/shadow-4.8.1/lib/defines.h:388:31:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
#  define shadow_getenv(name) getenv(name)
data/shadow-4.8.1/libmisc/mail.c:58:12:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	mailbox = getenv ("MAILDIR");
data/shadow-4.8.1/libmisc/mail.c:78:12:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	mailbox = getenv ("MAIL");
data/shadow-4.8.1/libmisc/root_flag.c:117:6:  [3] (misc) chroot:
  chroot can be very helpful, but is hard to use correctly (CWE-250, CWE-22).
  Make sure the program immediately chdir("/"), closes file descriptors, and
  drops root privileges, and that all necessary files (and no more!) are in
  the new root.
	if (chroot (newroot) != 0) {
data/shadow-4.8.1/libmisc/salt.c:79:3:  [3] (random) srandom:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
		srandom (tv.tv_sec ^ tv.tv_usec ^ getpid ());
data/shadow-4.8.1/libmisc/salt.c:112:37:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
	drand = (double) (max - min + 1) * random () / RANDOM_MAX;
data/shadow-4.8.1/libmisc/salt.c:255:22:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
	strcat (salt, l64a (random()));
data/shadow-4.8.1/libmisc/salt.c:257:23:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
		strcat (salt, l64a (random()));
data/shadow-4.8.1/libmisc/salt.c:281:22:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
	strcat (salt, l64a (random()));
data/shadow-4.8.1/libmisc/salt.c:283:23:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
		strcat (salt, l64a (random()));
data/shadow-4.8.1/libmisc/sub.c:70:10:  [3] (misc) chroot:
  chroot can be very helpful, but is hard to use correctly (CWE-250, CWE-22).
  Make sure the program immediately chdir("/"), closes file descriptors, and
  drops root privileges, and that all necessary files (and no more!) are in
  the new root.
	    || (chroot (pw->pw_dir) != 0)) {
data/shadow-4.8.1/libmisc/ttytype.c:53:6:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	if (getenv ("TERM") != NULL) {
data/shadow-4.8.1/src/chage.c:408:14:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt_long (argc, argv, "d:E:hiI:lm:M:R:W:",
data/shadow-4.8.1/src/chfn.c:286:14:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt_long (argc, argv, "f:h:o:r:R:uw:",
data/shadow-4.8.1/src/chgpasswd.c:176:14:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt_long (argc, argv,
data/shadow-4.8.1/src/chpasswd.c:170:14:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt_long (argc, argv,
data/shadow-4.8.1/src/chsh.c:212:14:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt_long (argc, argv, "hR:s:",
data/shadow-4.8.1/src/cppw.c:218:17:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((flag = getopt (argc, argv, "ghps")) != EOF) {
data/shadow-4.8.1/src/expiry.c:99:14:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt_long (argc, argv, "cfh",
data/shadow-4.8.1/src/faillog.c:592:15:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
		while ((c = getopt_long (argc, argv, "ahl:m:rR:t:u:",
data/shadow-4.8.1/src/gpasswd.c:244:14:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt_long (argc, argv, "a:A:d:ghM:Q:rR",
data/shadow-4.8.1/src/groupadd.c:397:14:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt_long (argc, argv, "fg:hK:op:rR:P:",
data/shadow-4.8.1/src/groupdel.c:331:14:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt_long (argc, argv, "hfR:P:",
data/shadow-4.8.1/src/groupmems.c:402:14:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt_long (argc, argv, "a:d:g:hlpR:",
data/shadow-4.8.1/src/groupmod.c:391:14:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt_long (argc, argv, "g:hn:op:R:P:",
data/shadow-4.8.1/src/grpck.c:207:14:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt_long (argc, argv, "hqrR:s",
data/shadow-4.8.1/src/grpconv.c:123:14:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt_long (argc, argv, "hR:",
data/shadow-4.8.1/src/grpunconv.c:123:14:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt_long (argc, argv, "hR:",
data/shadow-4.8.1/src/lastlog.c:327:15:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
		while ((c = getopt_long (argc, argv, "b:ChR:St:u:", longopts,
data/shadow-4.8.1/src/login.c:306:17:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((flag = getopt (argc, argv, "d:fh:pr:")) != EOF) {
data/shadow-4.8.1/src/login.c:382:8:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	tmp = getenv ("LANG");
data/shadow-4.8.1/src/login.c:391:8:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	tmp = getenv ("TZ");
data/shadow-4.8.1/src/login.c:407:8:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	tmp = getenv ("HZ");
data/shadow-4.8.1/src/login.c:684:10:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
			tmp = getenv ("TERM");
data/shadow-4.8.1/src/login.c:1156:6:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	if (getenv ("IFS")) {	/* don't export user IFS ... */
data/shadow-4.8.1/src/newgrp.c:797:7:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	cp = getenv ("SHELL");
data/shadow-4.8.1/src/newusers.c:638:14:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt_long (argc, argv,
data/shadow-4.8.1/src/nologin.c:49:22:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	char *ssh_origcmd = getenv("SSH_ORIGINAL_COMMAND");
data/shadow-4.8.1/src/passwd.c:791:15:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
		while ((c = getopt_long (argc, argv, "adehi:kln:qr:R:Suw:x:",
data/shadow-4.8.1/src/pwck.c:190:14:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt_long (argc, argv, "behqrR:s",
data/shadow-4.8.1/src/pwconv.c:153:14:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt_long (argc, argv, "hR:",
data/shadow-4.8.1/src/pwunconv.c:115:14:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt_long (argc, argv, "hR:",
data/shadow-4.8.1/src/su.c:782:14:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt_long (argc, argv, "c:hlmps:",
data/shadow-4.8.1/src/su.c:850:8:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
		cp = getenv ("TERM");
data/shadow-4.8.1/src/su.c:863:8:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
		cp = getenv ("COLORTERM");
data/shadow-4.8.1/src/su.c:887:8:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
		cp = getenv ("DISPLAY");
data/shadow-4.8.1/src/su.c:891:8:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
		cp = getenv ("XAUTHORITY");
data/shadow-4.8.1/src/su.c:912:6:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	if (getenv ("IFS") != NULL) {	/* don't export user IFS ... */
data/shadow-4.8.1/src/su.c:1011:14:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
		shellstr = getenv ("SHELL");
data/shadow-4.8.1/src/useradd.c:1144:15:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
		while ((c = getopt_long (argc, argv,
data/shadow-4.8.1/src/userdel.c:1043:15:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
		while ((c = getopt_long (argc, argv,
data/shadow-4.8.1/src/usermod.c:1026:15:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
		while ((c = getopt_long (argc, argv,
data/shadow-4.8.1/src/vipw.c:291:11:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	editor = getenv ("VISUAL");
data/shadow-4.8.1/src/vipw.c:293:12:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
		editor = getenv ("EDITOR");
data/shadow-4.8.1/src/vipw.c:512:15:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
		while ((c = getopt_long (argc, argv,
data/shadow-4.8.1/contrib/adduser-old.c:122:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char foo[32];			
data/shadow-4.8.1/contrib/adduser-old.c:123:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char uname[9],person[32],dir[32],shell[32];
data/shadow-4.8.1/contrib/adduser-old.c:127:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char cmd[255];
data/shadow-4.8.1/contrib/adduser-old.c:200:14:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
					group = atoi(foo);
data/shadow-4.8.1/contrib/adduser-old.c:243:12:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		min_pass=atoi(foo);
data/shadow-4.8.1/contrib/adduser-old.c:248:15:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			max_pass = atoi(foo);
data/shadow-4.8.1/contrib/adduser-old.c:254:15:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		warn_pass = atoi(foo);
data/shadow-4.8.1/contrib/adduser-old.c:260:14:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		user_die = atoi(foo);
data/shadow-4.8.1/contrib/adduser.c:152:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
  char foo[32];
data/shadow-4.8.1/contrib/adduser.c:153:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
  char usrname[32], person[32], dir[32], shell[32];
data/shadow-4.8.1/contrib/adduser.c:157:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
  char cmd[255];
data/shadow-4.8.1/contrib/adduser.c:257:13:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		  group = atoi (foo);
data/shadow-4.8.1/contrib/adduser.c:345:17:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
	    min_pass = atoi (foo);
data/shadow-4.8.1/contrib/adduser.c:351:17:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
	    max_pass = atoi (foo);
data/shadow-4.8.1/contrib/adduser.c:358:16:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
	  warn_pass = atoi (foo);
data/shadow-4.8.1/contrib/adduser.c:366:15:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
	  user_die = atoi (foo);
data/shadow-4.8.1/contrib/pwdauth.c:113:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char buf[128];
data/shadow-4.8.1/contrib/pwdauth.c:212:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char myname[32];
data/shadow-4.8.1/contrib/pwdauth.c:274:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char *arg[3];
data/shadow-4.8.1/contrib/pwdauth.c:275:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char *env[1];
data/shadow-4.8.1/lib/commonio.c:93:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char resolved_path[PATH_MAX];
data/shadow-4.8.1/lib/commonio.c:143:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[32];
data/shadow-4.8.1/lib/commonio.c:145:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open (file, O_CREAT | O_TRUNC | O_WRONLY, 0600);
data/shadow-4.8.1/lib/commonio.c:181:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open (lock, O_RDWR);
data/shadow-4.8.1/lib/commonio.c:265:7:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fp = fopen (name, mode);
data/shadow-4.8.1/lib/commonio.c:503:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char lock[1024];
data/shadow-4.8.1/lib/commonio.c:636:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open (db->filename,
data/shadow-4.8.1/lib/commonio.c:932:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[1024];
data/shadow-4.8.1/lib/commonio.h:111:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char filename[1024];
data/shadow-4.8.1/lib/defines.h:73:11:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
#  define memcpy(d, s, n) bcopy((s), (d), (n))
data/shadow-4.8.1/lib/defines.h:73:27:  [2] (buffer) bcopy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
#  define memcpy(d, s, n) bcopy((s), (d), (n))
data/shadow-4.8.1/lib/encrypt.c:45:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char cipher[128];
data/shadow-4.8.1/lib/encrypt.c:79:12:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
				static char nummethod[4] = "$x$";
data/shadow-4.8.1/lib/faillog.h:48:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char fail_line[12];	/* last failure occured here */
data/shadow-4.8.1/lib/fields.c:91:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char newf[200];
data/shadow-4.8.1/lib/getdef.c:492:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[1024], *name, *value, *s;
data/shadow-4.8.1/lib/getdef.c:540:7:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fp = fopen (def_fname, "r");
data/shadow-4.8.1/lib/gshadow.c:118:12:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		shadow = fopen (SGROUP_FILE, "r");
data/shadow-4.8.1/lib/gshadow.c:136:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char *fields[FIELDS];
data/shadow-4.8.1/lib/gshadow.c:377:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char save_name[16];
data/shadow-4.8.1/lib/port.c:87:11:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		ports = fopen (PORTS, "r");
data/shadow-4.8.1/lib/port.c:120:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char buf[BUFSIZ];	/* some space for stuff              */
data/shadow-4.8.1/lib/port.c:121:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char *ttys[PORT_TTY + 1];	/* some pointers to tty names     */
data/shadow-4.8.1/lib/port.c:122:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char *users[PORT_IDS + 1];	/* some pointers to user ids     */
data/shadow-4.8.1/lib/pwauth.c:73:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char prompt[1024];
data/shadow-4.8.1/lib/pwauth.c:81:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char challenge_info[40];
data/shadow-4.8.1/lib/pwauth.c:166:11:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
			static char c[1];
data/shadow-4.8.1/lib/pwauth.c:199:11:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
			static char c[1];
data/shadow-4.8.1/lib/sgetgrent.c:107:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char *grpfields[NFIELDS];
data/shadow-4.8.1/lib/sgetpwent.c:60:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char pwdbuf[1024];
data/shadow-4.8.1/lib/sgetpwent.c:63:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char *fields[NFIELDS];
data/shadow-4.8.1/lib/sgetspent.c:51:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char spwbuf[1024];
data/shadow-4.8.1/lib/sgetspent.c:53:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char *fields[FIELDS];
data/shadow-4.8.1/lib/shadow.c:102:12:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		shadow = fopen (SHADOW_FILE, "r");
data/shadow-4.8.1/lib/shadow.c:129:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char spwbuf[BUFSIZ];
data/shadow-4.8.1/lib/shadow.c:131:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char *fields[FIELDS];
data/shadow-4.8.1/lib/shadow.c:356:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[BUFSIZ];
data/shadow-4.8.1/lib/shadow.c:392:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[BUFSIZ];
data/shadow-4.8.1/lib/shadow.c:487:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[BUFSIZ];
data/shadow-4.8.1/lib/shadow.c:488:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char save_name[16];
data/shadow-4.8.1/lib/subordinateio.c:78:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char rangebuf[1024];
data/shadow-4.8.1/lib/subordinateio.c:81:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char *fields[NFIELDS];
data/shadow-4.8.1/lib/subordinateio.c:226:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
        char           owner_uid_string[33] = "";
data/shadow-4.8.1/lib/subordinateio.c:236:9:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
        sprintf(owner_uid_string, "%lu", (unsigned long int)owner_uid);
data/shadow-4.8.1/lib/tcbfuncs.c:111:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char link[8192];
data/shadow-4.8.1/lib/tcbfuncs.c:571:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open (shadow, O_RDWR | O_CREAT | O_TRUNC, 0600);
data/shadow-4.8.1/lib/utent.c:55:18:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		if ((utmp_fd = open (_UTMP_FILE, O_RDWR)) == -1)
data/shadow-4.8.1/lib/utent.c:56:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
			utmp_fd = open (_UTMP_FILE, O_RDONLY);
data/shadow-4.8.1/libmisc/addgrps.c:59:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[1024];
data/shadow-4.8.1/libmisc/console.c:53:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[1024], *s;
data/shadow-4.8.1/libmisc/console.c:91:7:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fp = fopen (cons, "r");
data/shadow-4.8.1/libmisc/copydir.c:739:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[1024];
data/shadow-4.8.1/libmisc/copydir.c:742:8:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	ifd = open (src, O_RDONLY);
data/shadow-4.8.1/libmisc/copydir.c:751:8:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	ofd = open (dst, O_WRONLY | O_CREAT | O_TRUNC, statp->st_mode & 07777);
data/shadow-4.8.1/libmisc/env.c:194:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char variable[1024];
data/shadow-4.8.1/libmisc/failure.c:64:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open (FAILLOG_FILE, O_RDWR);
data/shadow-4.8.1/libmisc/failure.c:167:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open (FAILLOG_FILE, failed?O_RDONLY:O_RDWR);
data/shadow-4.8.1/libmisc/failure.c:237:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char lasttimeb[256];
data/shadow-4.8.1/libmisc/failure.c:323:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open (ftmp, O_WRONLY | O_APPEND);
data/shadow-4.8.1/libmisc/getdate.c:133:65:  [2] (buffer) bcopy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
#if !defined (HAVE_BCOPY) && defined (HAVE_MEMCPY) && !defined (bcopy)
data/shadow-4.8.1/libmisc/getdate.c:134:10:  [2] (buffer) bcopy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
# define bcopy(from, to, len) memcpy ((to), (from), (len))
data/shadow-4.8.1/libmisc/getdate.c:134:31:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
# define bcopy(from, to, len) memcpy ((to), (from), (len))
data/shadow-4.8.1/libmisc/getdate.c:1060:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
  char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
data/shadow-4.8.1/libmisc/getdate.c:1249:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
  char yymsgbuf[128];
data/shadow-4.8.1/libmisc/getdate.c:2467:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
  char buff[20];
data/shadow-4.8.1/libmisc/getdate.c:2656:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
  char buff[MAX_BUFF_LEN + 1];
data/shadow-4.8.1/libmisc/hushed.c:54:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[BUFSIZ];
data/shadow-4.8.1/libmisc/hushed.c:88:7:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fp = fopen (hushfile, "r");
data/shadow-4.8.1/libmisc/limits.c:427:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[1024];
data/shadow-4.8.1/libmisc/limits.c:428:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char name[1024];
data/shadow-4.8.1/libmisc/limits.c:429:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char limits[1024];
data/shadow-4.8.1/libmisc/limits.c:430:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char deflimits[1024];
data/shadow-4.8.1/libmisc/limits.c:431:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char tempbuf[1024];
data/shadow-4.8.1/libmisc/limits.c:441:8:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fil = fopen (LIMITS_FILE, "r");
data/shadow-4.8.1/libmisc/log.c:67:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open (LASTLOG_FILE, O_RDWR);
data/shadow-4.8.1/libmisc/loginprompt.c:59:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[1024];
data/shadow-4.8.1/libmisc/loginprompt.c:62:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char *envp[MAX_ENV];
data/shadow-4.8.1/libmisc/loginprompt.c:92:9:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
			fp = fopen (fname, "r");
data/shadow-4.8.1/libmisc/motd.c:69:8:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fp = fopen (motdfile, "r");
data/shadow-4.8.1/libmisc/prefix_flag.c:166:8:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fg = fopen(group_db_file, "rt");
data/shadow-4.8.1/libmisc/prefix_flag.c:186:8:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fg = fopen(group_db_file, "rt");
data/shadow-4.8.1/libmisc/prefix_flag.c:206:8:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fg = fopen(passwd_db_file, "rt");
data/shadow-4.8.1/libmisc/prefix_flag.c:226:8:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fg = fopen(passwd_db_file, "rt");
data/shadow-4.8.1/libmisc/prefix_flag.c:246:8:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fg = fopen(spw_db_file, "rt");
data/shadow-4.8.1/libmisc/prefix_flag.c:270:13:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fp_pwent = fopen(passwd_db_file, "rt");
data/shadow-4.8.1/libmisc/prefix_flag.c:301:13:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fp_grent = fopen(group_db_file, "rt");
data/shadow-4.8.1/libmisc/rlogin.c:134:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char remote_name[32];
data/shadow-4.8.1/libmisc/salt.c:39:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char buf[8];
data/shadow-4.8.1/libmisc/salt.c:136:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char rounds_prefix[18]; /* Max size: rounds=999999999$ */
data/shadow-4.8.1/libmisc/salt.c:195:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char rounds_prefix[4]; /* Max size: 31$ */
data/shadow-4.8.1/libmisc/salt.c:250:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char salt[32];
data/shadow-4.8.1/libmisc/salt.c:274:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char salt[32];
data/shadow-4.8.1/libmisc/salt.c:314:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char result[40];
data/shadow-4.8.1/libmisc/setupenv.c:70:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[1024];
data/shadow-4.8.1/libmisc/setupenv.c:73:7:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fp = fopen (filename, "r");
data/shadow-4.8.1/libmisc/shell.c:56:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char arg0[1024];
data/shadow-4.8.1/libmisc/strtoday.c:175:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char slop[2];
data/shadow-4.8.1/libmisc/sulog.c:80:7:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fp = fopen (sulog_file, "a+");
data/shadow-4.8.1/libmisc/ttytype.c:47:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[BUFSIZ];
data/shadow-4.8.1/libmisc/ttytype.c:50:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char type[1024] = "";
data/shadow-4.8.1/libmisc/ttytype.c:51:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char port[1024];
data/shadow-4.8.1/libmisc/ttytype.c:64:7:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fp = fopen (typefile, "r");
data/shadow-4.8.1/libmisc/tz.c:55:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char tzbuf[BUFSIZ];
data/shadow-4.8.1/libmisc/tz.c:58:7:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fp = fopen (fname, "r");
data/shadow-4.8.1/libmisc/user_busy.c:115:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char path[41];
data/shadow-4.8.1/libmisc/user_busy.c:116:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[512], buf2[512];
data/shadow-4.8.1/libmisc/user_busy.c:138:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char status[40];
data/shadow-4.8.1/libmisc/user_busy.c:139:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char line[1024];
data/shadow-4.8.1/libmisc/user_busy.c:144:10:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	sfile = fopen (status, "r");
data/shadow-4.8.1/libmisc/user_busy.c:189:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char task_path[22];
data/shadow-4.8.1/libmisc/user_busy.c:190:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char root_path[22];
data/shadow-4.8.1/libmisc/utmp.c:59:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char full_tty[200];
data/shadow-4.8.1/libmisc/utmp.c:61:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char tmptty[sizeof (full_tty)+1];
data/shadow-4.8.1/libmisc/utmp.c:127:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy (ret, ut, sizeof (*ret));
data/shadow-4.8.1/libmisc/utmp.c:155:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy (ret, ut, sizeof (*ret));
data/shadow-4.8.1/libmisc/utmp.c:175:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open (filename, O_APPEND | O_WRONLY, 0);
data/shadow-4.8.1/libmisc/utmp.c:189:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open (filename, O_APPEND | O_WRONLY, 0);
data/shadow-4.8.1/libmisc/utmp.c:293:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
				memcpy (&(utent->ut_addr),
data/shadow-4.8.1/libmisc/yesno.c:54:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[80];
data/shadow-4.8.1/src/chage.c:80:8:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static char user_name[BUFSIZ] = "";
data/shadow-4.8.1/src/chage.c:187:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[200];
data/shadow-4.8.1/src/chage.c:207:3:  [2] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant string.
		strcpy (buf, "-1");
data/shadow-4.8.1/src/chage.c:238:3:  [2] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant string.
		strcpy (buf, "-1");
data/shadow-4.8.1/src/chage.c:262:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[80];
data/shadow-4.8.1/src/chage.c:263:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char format[80];
data/shadow-4.8.1/src/chfn.c:60:8:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static char fullnm[BUFSIZ];
data/shadow-4.8.1/src/chfn.c:61:8:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static char roomno[BUFSIZ];
data/shadow-4.8.1/src/chfn.c:62:8:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static char workph[BUFSIZ];
data/shadow-4.8.1/src/chfn.c:63:8:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static char homeph[BUFSIZ];
data/shadow-4.8.1/src/chfn.c:64:8:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static char slop[BUFSIZ];
data/shadow-4.8.1/src/chfn.c:523:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char old_gecos[BUFSIZ];	/* buffer for old GECOS fields       */
data/shadow-4.8.1/src/chfn.c:629:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char new_gecos[BUFSIZ];	/* buffer for new GECOS fields       */
data/shadow-4.8.1/src/chgpasswd.c:418:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[BUFSIZ];
data/shadow-4.8.1/src/chpasswd.c:413:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[BUFSIZ];
data/shadow-4.8.1/src/chsh.c:63:8:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static char loginsh[BUFSIZ];	/* Name of new login shell */
data/shadow-4.8.1/src/chsh.c:158:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[BUFSIZ];
data/shadow-4.8.1/src/chsh.c:172:7:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fp = fopen (SHELLS_FILE, "r");
data/shadow-4.8.1/src/cppw.c:70:9:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	bkfp = fopen (dest, "w");
data/shadow-4.8.1/src/cppw.c:135:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char filenew[1024];
data/shadow-4.8.1/src/cppw.c:170:6:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	f = fopen (in_file, "r");
data/shadow-4.8.1/src/faillog.c:116:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char ptime[80];
data/shadow-4.8.1/src/faillog.c:689:10:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fail = fopen (FAILLOG_FILE, "r+");
data/shadow-4.8.1/src/faillog.c:691:10:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fail = fopen (FAILLOG_FILE, "r");
data/shadow-4.8.1/src/gpasswd.c:401:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[1024];
data/shadow-4.8.1/src/gpasswd.c:516:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[1024];
data/shadow-4.8.1/src/gpasswd.c:525:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[1024];
data/shadow-4.8.1/src/gpasswd.c:535:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[1024];
data/shadow-4.8.1/src/gpasswd.c:650:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[1024];
data/shadow-4.8.1/src/gpasswd.c:899:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char pass[BUFSIZ];
data/shadow-4.8.1/src/lastlog.c:109:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char ptime[80];
data/shadow-4.8.1/src/lastlog.c:233:3:  [2] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant string.
		strcpy (ll.ll_host, "localhost");
data/shadow-4.8.1/src/lastlog.c:235:3:  [2] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant string.
		strcpy (ll.ll_line, "lastlog");
data/shadow-4.8.1/src/lastlog.c:426:16:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	lastlogfile = fopen (LASTLOG_FILE, (Cflg || Sflg)?"r+":"r");
data/shadow-4.8.1/src/login.c:106:8:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static char tmsg[256];
data/shadow-4.8.1/src/login.c:255:10:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		nlfp = fopen (fname, "r");
data/shadow-4.8.1/src/login.c:531:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char tty[BUFSIZ];
data/shadow-4.8.1/src/login.c:534:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char term[128] = "";
data/shadow-4.8.1/src/login.c:537:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char ptime[80];
data/shadow-4.8.1/src/login.c:548:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char fromhost[512];
data/shadow-4.8.1/src/login.c:753:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char hostn[256];
data/shadow-4.8.1/src/login.c:754:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char loginprompt[256];	/* That's one hell of a prompt :) */
data/shadow-4.8.1/src/login_nopam.c:79:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char line[BUFSIZ];
data/shadow-4.8.1/src/login_nopam.c:92:7:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fp = fopen (TABLE, "r");
data/shadow-4.8.1/src/login_nopam.c:179:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char name[MAXHOSTNAMELEN + 1] = "";
data/shadow-4.8.1/src/login_nopam.c:196:10:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		static char domain[MAXHOSTNAMELEN + 1];
data/shadow-4.8.1/src/logoutd.c:73:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char user[sizeof (ut->ut_user) + 1];
data/shadow-4.8.1/src/logoutd.c:114:14:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	mesg_file = fopen (HUP_MESG_FILE, "r");
data/shadow-4.8.1/src/logoutd.c:155:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char user[sizeof (ut->ut_user) + 1];	/* terminating NUL */
data/shadow-4.8.1/src/logoutd.c:156:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char tty_name[sizeof (ut->ut_line) + 6];	/* /dev/ + NUL */
data/shadow-4.8.1/src/logoutd.c:246:5:  [2] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant string.
				strcpy (tty_name, "/dev/");
data/shadow-4.8.1/src/logoutd.c:256:8:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
			    open (tty_name, O_WRONLY | O_NDELAY | O_NOCTTY);
data/shadow-4.8.1/src/newgidmap.c:100:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char *policy, policy_buffer[4096];
data/shadow-4.8.1/src/newgidmap.c:166:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char proc_dir_name[32];
data/shadow-4.8.1/src/newgidmap.c:201:16:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	proc_dir_fd = open(proc_dir_name, O_DIRECTORY);
data/shadow-4.8.1/src/newgrp.c:64:8:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static char audit_buf[80];
data/shadow-4.8.1/src/newuidmap.c:97:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char proc_dir_name[32];
data/shadow-4.8.1/src/newuidmap.c:131:16:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	proc_dir_fd = open(proc_dir_name, O_DIRECTORY);
data/shadow-4.8.1/src/newusers.c:230:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char *members[1];
data/shadow-4.8.1/src/newusers.c:333:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char *admins[1];
data/shadow-4.8.1/src/newusers.c:715:4:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
			char buf[BUFSIZ];
data/shadow-4.8.1/src/newusers.c:1025:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[BUFSIZ];
data/shadow-4.8.1/src/newusers.c:1026:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char *fields[8];
data/shadow-4.8.1/src/passwd.c:120:8:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static char crypt_passwd[256];
data/shadow-4.8.1/src/passwd.c:213:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char orig[200];		/* Original password */
data/shadow-4.8.1/src/passwd.c:214:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char pass[200];		/* New password */
data/shadow-4.8.1/src/passwd.c:448:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	static char buf[80];
data/shadow-4.8.1/src/su.c:101:8:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static char name[BUFSIZ];
data/shadow-4.8.1/src/su.c:102:8:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static char caller_name[BUFSIZ];
data/shadow-4.8.1/src/su.c:108:8:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static char kill_msg[256];
data/shadow-4.8.1/src/su.c:109:8:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static char wait_msg[256];
data/shadow-4.8.1/src/su.c:821:11:  [2] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant string.
			(void) strcpy (name, "root");
data/shadow-4.8.1/src/su.c:1121:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		int fd = open ("/dev/tty", O_RDWR);
data/shadow-4.8.1/src/suauth.c:70:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char temp[1024];
data/shadow-4.8.1/src/suauth.c:75:22:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	if (!(authfile_fd = fopen (SUAUTHFILE, "r"))) {
data/shadow-4.8.1/src/sulogin.c:54:8:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static char name[BUFSIZ];
data/shadow-4.8.1/src/sulogin.c:55:8:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static char pass[BUFSIZ];
data/shadow-4.8.1/src/sulogin.c:122:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		if (open (argv[1], O_RDWR) >= 0) {
data/shadow-4.8.1/src/sulogin.c:179:9:  [2] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant string.
	(void) strcpy (name, "root");	/* KLUDGE!!! */
data/shadow-4.8.1/src/useradd.c:351:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[1024];
data/shadow-4.8.1/src/useradd.c:370:7:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fp = fopen (default_file, "r");
data/shadow-4.8.1/src/useradd.c:517:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[1024];
data/shadow-4.8.1/src/useradd.c:561:8:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
	ofd = mkstemp (new_file);
data/shadow-4.8.1/src/useradd.c:582:8:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	ifp = fopen (default_file, "r");
data/shadow-4.8.1/src/useradd.c:1876:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open (FAILLOG_FILE, O_RDWR);
data/shadow-4.8.1/src/useradd.c:1909:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open (LASTLOG_FILE, O_RDWR);
data/shadow-4.8.1/src/useradd.c:2077:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char path[strlen (prefix_user_home) + 2];
data/shadow-4.8.1/src/useradd.c:2214:8:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fd = open (file, O_CREAT | O_WRONLY | O_TRUNC | O_EXCL, 0);
data/shadow-4.8.1/src/userdel.c:776:8:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	const char *argv[3];
data/shadow-4.8.1/src/usermod.c:626:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char new_exp[16], old_exp[16];
data/shadow-4.8.1/src/usermod.c:1895:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open (LASTLOG_FILE, O_RDWR);
data/shadow-4.8.1/src/usermod.c:1956:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open (FAILLOG_FILE, O_RDWR);
data/shadow-4.8.1/src/usermod.c:2043:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open (mailfile, O_RDONLY | O_NONBLOCK, 0);
data/shadow-4.8.1/src/vipw.c:119:9:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	bkfp = fopen (backup, "w");
data/shadow-4.8.1/src/vipw.c:213:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char filebackup[1024], fileedit[1024];
data/shadow-4.8.1/src/vipw.c:277:6:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	f = fopen (file, "r");
data/shadow-4.8.1/src/vipw.c:418:7:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		f = fopen (fileedit, "r");
data/shadow-4.8.1/contrib/adduser-old.c:167:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			if(!strlen(uname)) {
data/shadow-4.8.1/contrib/adduser-old.c:187:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		if (!strlen(person)) {
data/shadow-4.8.1/contrib/adduser-old.c:196:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			if (!strlen(foo))
data/shadow-4.8.1/contrib/adduser-old.c:228:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		if (!strlen(dir)) { /* hit return */
data/shadow-4.8.1/contrib/adduser-old.c:232:12:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			if (dir[strlen(dir)-1]=='/')
data/shadow-4.8.1/contrib/adduser-old.c:233:17:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
				sprintf(dir+strlen(dir),"%s",uname);
data/shadow-4.8.1/contrib/adduser-old.c:238:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		if (!strlen(shell))
data/shadow-4.8.1/contrib/adduser-old.c:247:7:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		if (strlen(foo) > 1)
data/shadow-4.8.1/contrib/adduser.c:205:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	  if (!strlen (usrname))
data/shadow-4.8.1/contrib/adduser.c:214:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	  if (strlen (usrname) > MAX_USRNAME)
data/shadow-4.8.1/contrib/adduser.c:239:12:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
      if (!strlen (person))
data/shadow-4.8.1/contrib/adduser.c:253:13:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	      if (!strlen (foo))
data/shadow-4.8.1/contrib/adduser.c:294:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	  if (!strlen (dir))
data/shadow-4.8.1/contrib/adduser.c:298:17:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	  else if (dir[strlen (dir) - 1] == '/')
data/shadow-4.8.1/contrib/adduser.c:299:19:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	    sprintf (dir+strlen(dir), "%s", usrname);
data/shadow-4.8.1/contrib/adduser.c:310:12:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
      if (!strlen (shell))
data/shadow-4.8.1/contrib/adduser.c:342:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	  if (strlen (foo) > 1)
data/shadow-4.8.1/contrib/adduser.c:350:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	  if (strlen (foo) > 1)
data/shadow-4.8.1/contrib/adduser.c:489:15:  [1] (buffer) getc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
  while ((c = getc (stdin)) != EOF && (c != '\n') && (++i < maxlen))
data/shadow-4.8.1/contrib/pwdauth.c:118:15:  [1] (buffer) getc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	while ((ch = getc(fp)) != EOF && ch != '\0' && ch != '\n') {
data/shadow-4.8.1/contrib/pwdauth.c:226:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(myname, pw->pw_name, sizeof myname - 1);
data/shadow-4.8.1/contrib/pwdauth.c:298:30:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	write(pipe_fd[1], password, strlen(password));
data/shadow-4.8.1/lib/commonio.c:157:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = (ssize_t) strlen (buf) + 1;
data/shadow-4.8.1/lib/commonio.c:192:8:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	len = read (fd, buf, sizeof (buf) - 1);
data/shadow-4.8.1/lib/commonio.c:264:9:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
	mask = umask (0777);
data/shadow-4.8.1/lib/commonio.c:266:9:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
	(void) umask (mask);
data/shadow-4.8.1/lib/commonio.c:319:15:  [1] (buffer) getc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		while ((c = getc (fp)) != EOF) {
data/shadow-4.8.1/lib/commonio.c:390:13:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	file_len = strlen(db->filename) + 11;/* %lu max size */
data/shadow-4.8.1/lib/commonio.c:391:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	lock_file_len = strlen(db->filename) + 6; /* sizeof ".lock" */
data/shadow-4.8.1/lib/commonio.c:689:10:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			len = strlen (buf);
data/shadow-4.8.1/lib/defines.h:113:31:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
#define strzero(s) memzero(s, strlen(s))	/* warning: evaluates twice */
data/shadow-4.8.1/lib/defines.h:299:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	(strncpy((A), (B), sizeof(A) - 1), (A)[sizeof(A) - 1] = '\0')
data/shadow-4.8.1/lib/encrypt.c:60:45:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if ((NULL != salt) && (salt[0] == '$') && (strlen (cp) <= 13))
data/shadow-4.8.1/lib/encrypt.c:90:6:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strlen (cp) != 13) {
data/shadow-4.8.1/lib/fields.c:126:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy (buf, cp, maxsize - 1);
data/shadow-4.8.1/lib/getdef.c:457:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen(file) + strlen(sysconfdir) + 2;
data/shadow-4.8.1/lib/getdef.c:457:23:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen(file) + strlen(sysconfdir) + 2;
data/shadow-4.8.1/lib/getdef.c:464:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen(file) + strlen(vendordir) + 2;
data/shadow-4.8.1/lib/getdef.c:464:23:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen(file) + strlen(vendordir) + 2;
data/shadow-4.8.1/lib/getdef.c:559:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		for (i = (int) strlen (buf) - 1; i >= 0; --i) {
data/shadow-4.8.1/lib/groupio.c:336:17:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	new_line_len = strlen (gr1->line) + strlen (gr2->line) +1;
data/shadow-4.8.1/lib/groupio.c:336:38:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	new_line_len = strlen (gr1->line) + strlen (gr2->line) +1;
data/shadow-4.8.1/lib/groupmem.c:94:30:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		memzero (grent->gr_passwd, strlen (grent->gr_passwd));
data/shadow-4.8.1/lib/gshadow.c:139:15:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	size_t len = strlen (string) + 1;
data/shadow-4.8.1/lib/gshadow.c:150:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy (sgrbuf, string, len);
data/shadow-4.8.1/lib/gshadow.c:249:10:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			len = strlen (buf);
data/shadow-4.8.1/lib/gshadow.c:399:11:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
				      strlen (name), &nis_val,
data/shadow-4.8.1/lib/gshadow.c:411:19:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
					nis_keylen = strlen (save_name);
data/shadow-4.8.1/lib/gshadow.c:455:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	size = strlen (sgrp->sg_name) + strlen (sgrp->sg_passwd) + 10;
data/shadow-4.8.1/lib/gshadow.c:455:34:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	size = strlen (sgrp->sg_name) + strlen (sgrp->sg_passwd) + 10;
data/shadow-4.8.1/lib/gshadow.c:457:11:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		size += strlen (sgrp->sg_adm[i]) + 1;
data/shadow-4.8.1/lib/gshadow.c:460:11:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		size += strlen (sgrp->sg_mem[i]) + 1;
data/shadow-4.8.1/lib/gshadow.c:474:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	cp += strlen (cp);
data/shadow-4.8.1/lib/gshadow.c:478:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	cp += strlen (cp);
data/shadow-4.8.1/lib/gshadow.c:492:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		cp += strlen (cp);
data/shadow-4.8.1/lib/gshadow.c:508:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		cp += strlen (cp);
data/shadow-4.8.1/lib/port.c:175:6:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	buf[strlen (buf) - 1] = 0;
data/shadow-4.8.1/lib/pwmem.c:98:30:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		memzero (pwent->pw_passwd, strlen (pwent->pw_passwd));
data/shadow-4.8.1/lib/sgetgrent.c:112:6:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strlen (buf) + 1 > size) {
data/shadow-4.8.1/lib/sgetgrent.c:117:10:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		size = strlen (buf) + 1000;	/* at least: strlen(buf) + 1 */
data/shadow-4.8.1/lib/sgetpwent.c:70:6:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strlen (buf) >= sizeof pwdbuf)
data/shadow-4.8.1/lib/sgetspent.c:63:6:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strlen (string) >= sizeof spwbuf) {
data/shadow-4.8.1/lib/sgroupio.c:154:30:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		memzero (sgent->sg_passwd, strlen (sgent->sg_passwd));
data/shadow-4.8.1/lib/shadow.c:141:6:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strlen (string) >= sizeof spwbuf)
data/shadow-4.8.1/lib/shadow.c:507:17:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		              strlen (name), &nis_val, &nis_vallen) == 0) {
data/shadow-4.8.1/lib/shadow.c:519:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
				nis_keylen = strlen (save_name);
data/shadow-4.8.1/lib/shadowmem.c:84:28:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		memzero (spent->sp_pwdp, strlen (spent->sp_pwdp));
data/shadow-4.8.1/lib/subordinateio.c:87:6:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strlen (line) >= sizeof rangebuf)
data/shadow-4.8.1/lib/utent.c:86:6:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	if (read (utmp_fd, &utmp_buf, sizeof utmp_buf) != sizeof utmp_buf)
data/shadow-4.8.1/libmisc/addgrps.c:61:6:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strlen (list) >= sizeof (buf)) {
data/shadow-4.8.1/libmisc/chkname.c:107:6:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strlen (name) > USER_NAME_MAX_LENGTH) {
data/shadow-4.8.1/libmisc/chkname.c:121:10:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	    && (strlen (name) > GROUP_NAME_MAX_LENGTH)) {
data/shadow-4.8.1/libmisc/chowndir.c:117:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		ent_name_len = strlen (root) + strlen (ent->d_name) + 2;
data/shadow-4.8.1/libmisc/chowndir.c:117:34:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		ent_name_len = strlen (root) + strlen (ent->d_name) + 2;
data/shadow-4.8.1/libmisc/console.c:73:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy (buf, cons, sizeof (buf));
data/shadow-4.8.1/libmisc/console.c:101:7:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		buf[strlen (buf) - 1] = '\0';
data/shadow-4.8.1/libmisc/copydir.c:198:12:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	src_len = strlen (src_orig);
data/shadow-4.8.1/libmisc/copydir.c:199:12:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	dst_len = strlen (dst_orig);
data/shadow-4.8.1/libmisc/copydir.c:200:13:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	name_len = strlen (name);
data/shadow-4.8.1/libmisc/copydir.c:297:21:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			size_t src_len = strlen (ent->d_name) + 2;
data/shadow-4.8.1/libmisc/copydir.c:298:21:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			size_t dst_len = strlen (ent->d_name) + 2;
data/shadow-4.8.1/libmisc/copydir.c:299:15:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			src_len += strlen (src_root);
data/shadow-4.8.1/libmisc/copydir.c:300:15:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			dst_len += strlen (dst_root);
data/shadow-4.8.1/libmisc/copydir.c:597:34:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strncmp (oldlink, src_orig, strlen (src_orig)) == 0) {
data/shadow-4.8.1/libmisc/copydir.c:598:16:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		size_t len = strlen (dst_orig) + strlen (oldlink) - strlen (src_orig) + 1;
data/shadow-4.8.1/libmisc/copydir.c:598:36:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		size_t len = strlen (dst_orig) + strlen (oldlink) - strlen (src_orig) + 1;
data/shadow-4.8.1/libmisc/copydir.c:598:55:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		size_t len = strlen (dst_orig) + strlen (oldlink) - strlen (src_orig) + 1;
data/shadow-4.8.1/libmisc/copydir.c:602:30:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		                 oldlink + strlen (src_orig));
data/shadow-4.8.1/libmisc/copydir.c:778:16:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	while ((cnt = read (ifd, buf, sizeof buf)) > 0) {
data/shadow-4.8.1/libmisc/env.c:96:16:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		size_t len = strlen (string) + strlen (value) + 2;
data/shadow-4.8.1/libmisc/env.c:96:34:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		size_t len = strlen (string) + strlen (value) + 2;
data/shadow-4.8.1/libmisc/env.c:198:7:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		if (strlen (*argv) >= sizeof variable) {
data/shadow-4.8.1/libmisc/env.c:213:29:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
				if (strncmp (*argv, *p, strlen (*p)) == 0) {
data/shadow-4.8.1/libmisc/env.c:219:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
				strncpy (variable, *argv, (size_t)(cp - *argv));
data/shadow-4.8.1/libmisc/env.c:249:29:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			if (strncmp (*cur, *bad, strlen (*bad)) == 0) {
data/shadow-4.8.1/libmisc/env.c:261:29:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			if (strncmp (*cur, *bad, strlen (*bad)) != 0) {
data/shadow-4.8.1/libmisc/failure.c:79:10:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	    || (read (fd, (char *) fl, sizeof *fl) != (ssize_t) sizeof *fl)) {
data/shadow-4.8.1/libmisc/failure.c:101:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy (fl->fail_line, tty, sizeof fl->fail_line);
data/shadow-4.8.1/libmisc/failure.c:189:10:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	    || (read (fd, (char *) fl, sizeof *fl) != (ssize_t) sizeof *fl)) {
data/shadow-4.8.1/libmisc/getdate.c:957:21:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
#   define yystrlen strlen
data/shadow-4.8.1/libmisc/getdate.c:2368:7:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
  if (strlen (buff) == 3)
data/shadow-4.8.1/libmisc/getdate.c:2370:12:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
  else if (strlen (buff) == 4 && buff[3] == '.')
data/shadow-4.8.1/libmisc/getdate.c:2413:7:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
  i = strlen (buff) - 1;
data/shadow-4.8.1/libmisc/hushed.c:93:7:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		buf[strlen (buf) - 1] = '\0';
data/shadow-4.8.1/libmisc/limits.c:140:9:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
	(void) umask ((mode_t) mask);
data/shadow-4.8.1/libmisc/limits.c:522:14:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
			tmpmask = umask (0777);
data/shadow-4.8.1/libmisc/limits.c:524:11:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
			(void) umask (tmpmask);
data/shadow-4.8.1/libmisc/limits.c:599:13:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
					(void) umask ((mode_t) mask);
data/shadow-4.8.1/libmisc/log.c:93:6:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	if (read (fd, (void *) &newlog, sizeof newlog) != (ssize_t) sizeof newlog) {
data/shadow-4.8.1/libmisc/log.c:103:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy (newlog.ll_line, line, sizeof newlog.ll_line);
data/shadow-4.8.1/libmisc/log.c:105:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy (newlog.ll_host, host, sizeof newlog.ll_host);
data/shadow-4.8.1/libmisc/loginprompt.c:94:17:  [1] (buffer) getc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
				while ((i = getc (fp)) != EOF) {
data/shadow-4.8.1/libmisc/loginprompt.c:160:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
				size_t len = strlen (nvar) + 32;
data/shadow-4.8.1/libmisc/mail.c:61:16:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		size_t len = strlen (mailbox) + 5;
data/shadow-4.8.1/libmisc/motd.c:71:16:  [1] (buffer) getc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
			while ((c = getc (fp)) != EOF) {
data/shadow-4.8.1/libmisc/obscure.c:57:6:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	i = strlen (new);
data/shadow-4.8.1/libmisc/obscure.c:82:6:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strlen (new) >= 8) {
data/shadow-4.8.1/libmisc/obscure.c:184:21:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	wrapped = xmalloc (strlen (oldmono) * 2 + 1);
data/shadow-4.8.1/libmisc/obscure.c:234:11:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	oldlen = strlen (old);
data/shadow-4.8.1/libmisc/obscure.c:235:11:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	newlen = strlen (new);
data/shadow-4.8.1/libmisc/pam_pass_non_interactive.c:119:12:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			        strlen (responses[count].resp));
data/shadow-4.8.1/libmisc/prefix_flag.c:107:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(prefix) + strlen(PASSWD_FILE) + 2;
data/shadow-4.8.1/libmisc/prefix_flag.c:107:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(prefix) + strlen(PASSWD_FILE) + 2;
data/shadow-4.8.1/libmisc/prefix_flag.c:112:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(prefix) + strlen(GROUP_FILE) + 2;
data/shadow-4.8.1/libmisc/prefix_flag.c:112:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(prefix) + strlen(GROUP_FILE) + 2;
data/shadow-4.8.1/libmisc/prefix_flag.c:118:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(prefix) + strlen(SGROUP_FILE) + 2;
data/shadow-4.8.1/libmisc/prefix_flag.c:118:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(prefix) + strlen(SGROUP_FILE) + 2;
data/shadow-4.8.1/libmisc/prefix_flag.c:127:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(prefix) + strlen(SHADOW_FILE) + 2;
data/shadow-4.8.1/libmisc/prefix_flag.c:127:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(prefix) + strlen(SHADOW_FILE) + 2;
data/shadow-4.8.1/libmisc/prefix_flag.c:133:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(prefix) + strlen("/etc/subuid") + 2;
data/shadow-4.8.1/libmisc/prefix_flag.c:133:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(prefix) + strlen("/etc/subuid") + 2;
data/shadow-4.8.1/libmisc/prefix_flag.c:138:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(prefix) + strlen("/etc/subgid") + 2;
data/shadow-4.8.1/libmisc/prefix_flag.c:138:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(prefix) + strlen("/etc/subgid") + 2;
data/shadow-4.8.1/libmisc/prefix_flag.c:147:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(prefix) + strlen("/etc/login.defs") + 2;
data/shadow-4.8.1/libmisc/prefix_flag.c:147:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(prefix) + strlen("/etc/login.defs") + 2;
data/shadow-4.8.1/libmisc/pwd_init.c:101:2:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
	umask (077);
data/shadow-4.8.1/libmisc/remove_tree.c:76:20:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		size_t new_len = strlen (root) + strlen (ent->d_name) + 2;
data/shadow-4.8.1/libmisc/remove_tree.c:76:36:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		size_t new_len = strlen (root) + strlen (ent->d_name) + 2;
data/shadow-4.8.1/libmisc/rlogin.c:116:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		if (read (0, buf, 1) != 1) {
data/shadow-4.8.1/libmisc/salt.c:258:11:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	} while (strlen (salt) < BCRYPT_SALT_SIZE);
data/shadow-4.8.1/libmisc/salt.c:284:11:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	} while (strlen (salt) < salt_size);
data/shadow-4.8.1/libmisc/salt.c:357:28:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	assert (sizeof (result) > strlen (result) + salt_len);
data/shadow-4.8.1/libmisc/salt.c:360:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
		strncat (result, gensalt_bcrypt (),
data/shadow-4.8.1/libmisc/salt.c:361:24:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
				 sizeof (result) - strlen (result) - 1);
data/shadow-4.8.1/libmisc/salt.c:365:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
		strncat (result, gensalt (salt_len),
data/shadow-4.8.1/libmisc/salt.c:366:23:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			 sizeof (result) - strlen (result) - 1);
data/shadow-4.8.1/libmisc/setupenv.c:56:15:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	size_t len = strlen (dirname) + strlen (filename) + 2;
data/shadow-4.8.1/libmisc/setupenv.c:56:34:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	size_t len = strlen (dirname) + strlen (filename) + 2;
data/shadow-4.8.1/libmisc/sulog.c:71:12:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
	oldmask = umask (077);
data/shadow-4.8.1/libmisc/sulog.c:81:9:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
	(void) umask (oldmask);
data/shadow-4.8.1/libmisc/ttytype.c:79:11:  [1] (buffer) sscanf:
  It's unclear if the %s limit in the format string is small enough
  (CWE-120). Check that the limit is sufficiently small, or use a different
  input function.
		if (   (sscanf (buf, "%1023s %1023s", type, port) == 2)
data/shadow-4.8.1/libmisc/tz.c:68:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		tzbuf[strlen (tzbuf) - 1] = '\0';
data/shadow-4.8.1/libmisc/ulimit.c:57:6:  [1] (obsolete) ulimit:
  This C routine is considered obsolete (as opposed to the shell command by
  the same name, which is NOT obsolete) (CWE-676). Use getrlimit(2),
  setrlimit(2), and sysconf(3) instead.
	if (ulimit (UL_SETFSIZE, blocks) != -1) {
data/shadow-4.8.1/libmisc/utmp.c:71:11:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			(void) strncpy (tmptty, tname, sizeof tmptty);
data/shadow-4.8.1/libmisc/utmp.c:235:32:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		hostname = (char *) xmalloc (strlen (host) + 1);
data/shadow-4.8.1/libmisc/utmp.c:241:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy (hostname, ut->ut_host, sizeof (ut->ut_host));
data/shadow-4.8.1/libmisc/utmp.c:260:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy (utent->ut_line, line,      sizeof (utent->ut_line));
data/shadow-4.8.1/libmisc/utmp.c:263:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy (utent->ut_id, ut->ut_id, sizeof (utent->ut_id));
data/shadow-4.8.1/libmisc/utmp.c:266:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy (utent->ut_id, line + 3, sizeof (utent->ut_id));
data/shadow-4.8.1/libmisc/utmp.c:270:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy (utent->ut_name, name,      sizeof (utent->ut_name));
data/shadow-4.8.1/libmisc/utmp.c:273:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy (utent->ut_user, name,      sizeof (utent->ut_user));
data/shadow-4.8.1/libmisc/utmp.c:278:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy (utent->ut_host, hostname, sizeof (utent->ut_host));
data/shadow-4.8.1/libmisc/utmp.c:281:27:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		utent->ut_syslen = MIN (strlen (hostname),
data/shadow-4.8.1/libmisc/utmp.c:380:32:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		hostname = (char *) xmalloc (strlen (host) + 1);
data/shadow-4.8.1/libmisc/utmp.c:387:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy (hostname, ut->ut_host, sizeof (ut->ut_host));
data/shadow-4.8.1/libmisc/utmp.c:403:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy (utxent->ut_line, line,      sizeof (utxent->ut_line));
data/shadow-4.8.1/libmisc/utmp.c:406:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy (utxent->ut_id, ut->ut_id, sizeof (utxent->ut_id));
data/shadow-4.8.1/libmisc/utmp.c:409:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy (utxent->ut_id, line + 3, sizeof (utxent->ut_id));
data/shadow-4.8.1/libmisc/utmp.c:412:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy (utxent->ut_name, name,      sizeof (utxent->ut_name));
data/shadow-4.8.1/libmisc/utmp.c:414:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy (utxent->ut_user, name,      sizeof (utxent->ut_user));
data/shadow-4.8.1/libmisc/utmp.c:418:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy (utxent->ut_host, hostname, sizeof (utxent->ut_host));
data/shadow-4.8.1/libmisc/utmp.c:421:28:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		utxent->ut_syslen = MIN (strlen (hostname),
data/shadow-4.8.1/libmisc/xmalloc.c:67:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	return strcpy (xmalloc (strlen (str) + 1), str);
data/shadow-4.8.1/src/chfn.c:246:5:  [1] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused). Risk is low because the
  source is a constant character.
				strcat (extra, ",");
data/shadow-4.8.1/src/chfn.c:559:4:  [1] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused). Risk is low because the
  source is a constant character.
			strcat (slop, ",");
data/shadow-4.8.1/src/chfn.c:730:7:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if ((strlen (fullnm) + strlen (roomno) + strlen (workph) +
data/shadow-4.8.1/src/chfn.c:730:25:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if ((strlen (fullnm) + strlen (roomno) + strlen (workph) +
data/shadow-4.8.1/src/chfn.c:730:43:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if ((strlen (fullnm) + strlen (roomno) + strlen (workph) +
data/shadow-4.8.1/src/chfn.c:731:7:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	     strlen (homeph) + strlen (slop)) > (unsigned int) 80) {
data/shadow-4.8.1/src/chfn.c:731:25:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	     strlen (homeph) + strlen (slop)) > (unsigned int) 80) {
data/shadow-4.8.1/src/cppw.c:69:9:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
	mask = umask (077);
data/shadow-4.8.1/src/cppw.c:71:9:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
	(void) umask (mask);
data/shadow-4.8.1/src/cppw.c:77:14:  [1] (buffer) getc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	while ((c = getc (fp)) != EOF) {
data/shadow-4.8.1/src/groupmod.c:549:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	                      + strlen (info_group.audit_msg);
data/shadow-4.8.1/src/groupmod.c:552:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	                      + strlen (info_gshadow.audit_msg);
data/shadow-4.8.1/src/groupmod.c:555:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	                      + strlen (info_passwd.audit_msg);
data/shadow-4.8.1/src/groupmod.c:558:25:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	                 511 - strlen (info_group.audit_msg),
data/shadow-4.8.1/src/groupmod.c:563:25:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	                 511 - strlen (info_group.audit_msg),
data/shadow-4.8.1/src/groupmod.c:567:25:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	                 511 - strlen (info_group.audit_msg),
data/shadow-4.8.1/src/groupmod.c:572:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings. Risk is low because the source is a
  constant string.
		strncat (info_group.action, ", new name: ",
data/shadow-4.8.1/src/groupmod.c:573:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		         511 - strlen (info_group.audit_msg));
data/shadow-4.8.1/src/groupmod.c:574:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
		strncat (info_group.action, group_newname,
data/shadow-4.8.1/src/groupmod.c:575:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		         511 - strlen (info_group.audit_msg));
data/shadow-4.8.1/src/groupmod.c:578:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings. Risk is low because the source is a
  constant string.
		strncat (info_gshadow.action, ", new name: ",
data/shadow-4.8.1/src/groupmod.c:579:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		         511 - strlen (info_gshadow.audit_msg));
data/shadow-4.8.1/src/groupmod.c:580:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
		strncat (info_gshadow.action, group_newname,
data/shadow-4.8.1/src/groupmod.c:581:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		         511 - strlen (info_gshadow.audit_msg));
data/shadow-4.8.1/src/groupmod.c:584:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings. Risk is low because the source is a
  constant string.
		strncat (info_passwd.action, ", new name: ",
data/shadow-4.8.1/src/groupmod.c:585:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		         511 - strlen (info_passwd.audit_msg));
data/shadow-4.8.1/src/groupmod.c:586:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
		strncat (info_passwd.action, group_newname,
data/shadow-4.8.1/src/groupmod.c:587:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		         511 - strlen (info_passwd.audit_msg));
data/shadow-4.8.1/src/groupmod.c:590:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings. Risk is low because the source is a
  constant string.
		strncat (info_group.action, ", new password",
data/shadow-4.8.1/src/groupmod.c:591:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		         511 - strlen (info_group.audit_msg));
data/shadow-4.8.1/src/groupmod.c:594:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings. Risk is low because the source is a
  constant string.
		strncat (info_gshadow.action, ", new password",
data/shadow-4.8.1/src/groupmod.c:595:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		         511 - strlen (info_gshadow.audit_msg));
data/shadow-4.8.1/src/groupmod.c:599:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings. Risk is low because the source is a
  constant string.
		strncat (info_group.action, ", new gid: ",
data/shadow-4.8.1/src/groupmod.c:600:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		         511 - strlen (info_group.audit_msg));
data/shadow-4.8.1/src/groupmod.c:601:38:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		(void) snprintf (info_group.action+strlen (info_group.action),
data/shadow-4.8.1/src/groupmod.c:602:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		                 511 - strlen (info_group.audit_msg),
data/shadow-4.8.1/src/groupmod.c:605:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings. Risk is low because the source is a
  constant string.
		strncat (info_passwd.action, ", new gid: ",
data/shadow-4.8.1/src/groupmod.c:606:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		         511 - strlen (info_passwd.audit_msg));
data/shadow-4.8.1/src/groupmod.c:607:39:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		(void) snprintf (info_passwd.action+strlen (info_passwd.action),
data/shadow-4.8.1/src/groupmod.c:608:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		                 511 - strlen (info_passwd.audit_msg),
data/shadow-4.8.1/src/login.c:258:16:  [1] (buffer) getc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
			while ((c = getc (nlfp)) != EOF) {
data/shadow-4.8.1/src/login.c:295:30:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		if (argv[arg][0] == '-' && strlen (argv[arg]) > 2) {
data/shadow-4.8.1/src/login.c:424:30:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	write (STDERR_FILENO, tmsg, strlen (tmsg));
data/shadow-4.8.1/src/login.c:648:9:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
	(void) umask (getdef_num ("UMASK", GETDEF_DEFAULT_UMASK));
data/shadow-4.8.1/src/login.c:762:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
			strncpy (loginprompt, _("login: "),
data/shadow-4.8.1/src/login_nopam.c:99:16:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			end = (int) strlen (line) - 1;
data/shadow-4.8.1/src/login_nopam.c:301:13:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		str_len = strlen (string);
data/shadow-4.8.1/src/login_nopam.c:302:13:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		tok_len = strlen (tok);
data/shadow-4.8.1/src/login_nopam.c:311:32:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	} else if (   (tok[(tok_len = strlen (tok)) - 1] == '.') /* network */
data/shadow-4.8.1/src/logoutd.c:79:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy (user, ut->ut_user, sizeof (ut->ut_user));
data/shadow-4.8.1/src/logoutd.c:117:15:  [1] (buffer) getc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		while ((c = getc (mesg_file)) != EOF) {
data/shadow-4.8.1/src/logoutd.c:269:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			strncpy (user, ut->ut_user, sizeof (user) - 1);
data/shadow-4.8.1/src/newgidmap.c:133:6:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	if (read(setgroups_fd, policy_buffer, sizeof(policy_buffer)) < 0) {
data/shadow-4.8.1/src/newgidmap.c:139:38:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (!strncmp(policy_buffer, policy, strlen(policy)))
data/shadow-4.8.1/src/passwd.c:548:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		char *newpw = xmalloc (strlen (cp) + 2);
data/shadow-4.8.1/src/passwd.c:550:3:  [1] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant character.
		strcpy (newpw, "!");
data/shadow-4.8.1/src/su.c:186:42:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		(void) write (STDERR_FILENO, kill_msg, strlen (kill_msg));
data/shadow-4.8.1/src/su.c:188:42:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		(void) write (STDERR_FILENO, wait_msg, strlen (wait_msg));
data/shadow-4.8.1/src/su.c:646:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy (name, tmp_name, sizeof(name) - 1);
data/shadow-4.8.1/src/su.c:1170:19:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		arg0 = xmalloc (strlen (cp) + 2);
data/shadow-4.8.1/src/suauth.c:95:22:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		if (temp[endline = strlen (temp) - 1] != '\n') {
data/shadow-4.8.1/src/useradd.c:109:41:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
#define	VALID(s)	(strcspn (s, ":\n") == strlen (s))
data/shadow-4.8.1/src/useradd.c:338:37:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
#define MATCH(x,y) (strncmp((x),(y),strlen(y)) == 0)
data/shadow-4.8.1/src/useradd.c:358:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(prefix) + strlen(USER_DEFAULTS_FILE) + 2;
data/shadow-4.8.1/src/useradd.c:358:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(prefix) + strlen(USER_DEFAULTS_FILE) + 2;
data/shadow-4.8.1/src/useradd.c:460:11:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
				len = strlen(prefix) + strlen(cp) + 2;
data/shadow-4.8.1/src/useradd.c:460:28:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
				len = strlen(prefix) + strlen(cp) + 2;
data/shadow-4.8.1/src/useradd.c:534:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen(prefix) + strlen(NEW_USER_FILE) + 2;
data/shadow-4.8.1/src/useradd.c:534:25:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen(prefix) + strlen(NEW_USER_FILE) + 2;
data/shadow-4.8.1/src/useradd.c:546:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(prefix) + strlen(USER_DEFAULTS_FILE) + 2;
data/shadow-4.8.1/src/useradd.c:546:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(prefix) + strlen(USER_DEFAULTS_FILE) + 2;
data/shadow-4.8.1/src/useradd.c:1463:17:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			size_t len = strlen (def_home) + strlen (user_name) + 2;
data/shadow-4.8.1/src/useradd.c:1463:37:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			size_t len = strlen (def_home) + strlen (user_name) + 2;
data/shadow-4.8.1/src/useradd.c:1473:17:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			size_t len = strlen(prefix) + strlen(user_home) + 2;
data/shadow-4.8.1/src/useradd.c:1473:34:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			size_t len = strlen(prefix) + strlen(user_home) + 2;
data/shadow-4.8.1/src/useradd.c:2077:13:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		char path[strlen (prefix_user_home) + 2];
data/shadow-4.8.1/src/useradd.c:2105:4:  [1] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused). Risk is low because the
  source is a constant character.
			strcat (path, "/");
data/shadow-4.8.1/src/useradd.c:2113:23:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
				if (subvolflg && (strlen(prefix_user_home) - (int)strlen(path)) <= 1) {
data/shadow-4.8.1/src/useradd.c:2113:55:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
				if (subvolflg && (strlen(prefix_user_home) - (int)strlen(path)) <= 1) {
data/shadow-4.8.1/src/useradd.c:2122:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
					btrfs_check[strlen(path) - strlen(cp) - 1] = '\0';
data/shadow-4.8.1/src/useradd.c:2122:33:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
					btrfs_check[strlen(path) - strlen(cp) - 1] = '\0';
data/shadow-4.8.1/src/useradd.c:2209:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		file = alloca (strlen (prefix) + strlen (spool) + strlen (user_name) + 2);
data/shadow-4.8.1/src/useradd.c:2209:36:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		file = alloca (strlen (prefix) + strlen (spool) + strlen (user_name) + 2);
data/shadow-4.8.1/src/useradd.c:2209:53:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		file = alloca (strlen (prefix) + strlen (spool) + strlen (user_name) + 2);
data/shadow-4.8.1/src/userdel.c:792:31:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	return (   (strncmp (s2, s1, strlen (s1)) == 0)
data/shadow-4.8.1/src/userdel.c:793:29:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	        && (   ('\0' == s2[strlen (s1)])
data/shadow-4.8.1/src/userdel.c:794:29:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	            || ('/'  == s2[strlen (s1)])));
data/shadow-4.8.1/src/userdel.c:840:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen (prefix) + strlen (maildir) + strlen (user_name) + 2;
data/shadow-4.8.1/src/userdel.c:840:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen (prefix) + strlen (maildir) + strlen (user_name) + 2;
data/shadow-4.8.1/src/userdel.c:840:45:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen (prefix) + strlen (maildir) + strlen (user_name) + 2;
data/shadow-4.8.1/src/userdel.c:955:37:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	size_t buflen = (sizeof TCB_DIR) + strlen (user_name) + 2;
data/shadow-4.8.1/src/userdel.c:1165:17:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			size_t len = strlen(prefix) + strlen(pwd->pw_dir) + 2;
data/shadow-4.8.1/src/userdel.c:1165:34:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			size_t len = strlen(prefix) + strlen(pwd->pw_dir) + 2;
data/shadow-4.8.1/src/usermod.c:99:41:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
#define	VALID(s)	(strcspn (s, ":\n") == strlen (s))
data/shadow-4.8.1/src/usermod.c:217:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
		strncpy (buf, "never", maxsize);
data/shadow-4.8.1/src/usermod.c:456:24:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		char *buf = xmalloc (strlen (pw_pass) + 2);
data/shadow-4.8.1/src/usermod.c:464:3:  [1] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant character.
		strcpy (buf, "!");
data/shadow-4.8.1/src/usermod.c:1257:16:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		size_t len = strlen(prefix) + strlen(user_home) + 2;
data/shadow-4.8.1/src/usermod.c:1257:33:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		size_t len = strlen(prefix) + strlen(user_home) + 2;
data/shadow-4.8.1/src/usermod.c:1263:10:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			len = strlen(prefix) + strlen(user_newhome) + 2;
data/shadow-4.8.1/src/usermod.c:1263:27:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			len = strlen(prefix) + strlen(user_newhome) + 2;
data/shadow-4.8.1/src/usermod.c:1905:10:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	    && (read (fd, &ll, sizeof ll) == (ssize_t) sizeof ll)) {
data/shadow-4.8.1/src/usermod.c:1921:11:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		    && (read (fd, &ll, sizeof ll) == (ssize_t) sizeof ll)) {
data/shadow-4.8.1/src/usermod.c:1966:10:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	    && (read (fd, (char *) &fl, sizeof fl) == (ssize_t) sizeof fl)) {
data/shadow-4.8.1/src/usermod.c:1982:11:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		    && (read (fd, &fl, sizeof fl) == (ssize_t) sizeof fl)) {
data/shadow-4.8.1/src/usermod.c:2024:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen (prefix) + strlen (maildir) + strlen (user_name) + 2;
data/shadow-4.8.1/src/usermod.c:2024:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen (prefix) + strlen (maildir) + strlen (user_name) + 2;
data/shadow-4.8.1/src/usermod.c:2024:45:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen (prefix) + strlen (maildir) + strlen (user_name) + 2;
data/shadow-4.8.1/src/usermod.c:2079:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen (prefix) + strlen (maildir) + strlen (user_newname) + 2;
data/shadow-4.8.1/src/usermod.c:2079:27:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen (prefix) + strlen (maildir) + strlen (user_newname) + 2;
data/shadow-4.8.1/src/usermod.c:2079:46:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen (prefix) + strlen (maildir) + strlen (user_newname) + 2;
data/shadow-4.8.1/src/vipw.c:118:9:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
	mask = umask (077);
data/shadow-4.8.1/src/vipw.c:120:9:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
	(void) umask (mask);
data/shadow-4.8.1/src/vipw.c:127:15:  [1] (buffer) getc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		while ((c = getc (fp)) != EOF) {
data/shadow-4.8.1/src/vipw.c:318:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		buf = (char *) malloc (strlen (editor) + strlen (fileedit) + 2);
data/shadow-4.8.1/src/vipw.c:318:44:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		buf = (char *) malloc (strlen (editor) + strlen (fileedit) + 2);
data/shadow-4.8.1/src/vipw.c:319:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		snprintf (buf, strlen (editor) + strlen (fileedit) + 2,
data/shadow-4.8.1/src/vipw.c:319:36:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		snprintf (buf, strlen (editor) + strlen (fileedit) + 2,
data/shadow-4.8.1/src/vipw.c:431:23:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		to_rename = malloc (strlen (file) + 2);
data/shadow-4.8.1/src/vipw.c:435:24:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		snprintf (to_rename, strlen (file) + 2, "%s+", file);

ANALYSIS SUMMARY:

Hits = 789
Lines analyzed = 52641 in approximately 1.73 seconds (30341 lines/second)
Physical Source Lines of Code (SLOC) = 33744
Hits@level = [0] 1315 [1] 293 [2] 236 [3]  57 [4] 162 [5]  41
Hits@level+ = [0+] 2104 [1+] 789 [2+] 496 [3+] 260 [4+] 203 [5+]  41
Hits/KSLOC@level+ = [0+] 62.3518 [1+] 23.3819 [2+] 14.6989 [3+] 7.70507 [4+] 6.01588 [5+] 1.21503
Dot directories skipped = 1 (--followdotdir overrides)
Minimum risk level = 1
Not every hit is necessarily a security vulnerability.
There may be other security vulnerabilities; review your code!
See 'Secure Programming HOWTO'
(https://dwheeler.com/secure-programs) for more information.