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/nis-3.17.1/ypbind-mt-1.38/lib/clnt_udp.c Examining data/nis-3.17.1/ypbind-mt-1.38/lib/res_options.h Examining data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.c Examining data/nis-3.17.1/ypbind-mt-1.38/src/local.h Examining data/nis-3.17.1/ypbind-mt-1.38/src/ypbind_svc.c Examining data/nis-3.17.1/ypbind-mt-1.38/src/pthread_np.c Examining data/nis-3.17.1/ypbind-mt-1.38/src/ypbind_server.c Examining data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c Examining data/nis-3.17.1/ypbind-mt-1.38/src/log_msg.h Examining data/nis-3.17.1/ypbind-mt-1.38/src/ypbind_slp.c Examining data/nis-3.17.1/ypbind-mt-1.38/src/pthread_np.h Examining data/nis-3.17.1/ypbind-mt-1.38/src/ypbind.h Examining data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c Examining data/nis-3.17.1/ypbind-mt-1.38/src/ypbind_dbus_nm.c Examining data/nis-3.17.1/ypbind-mt-1.38/src/ypbind_xdr.c Examining data/nis-3.17.1/ypbind-mt-1.38/src/log_msg.c Examining data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c Examining data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswd_xdr.c Examining data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c Examining data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswd.h Examining data/nis-3.17.1/ypserv-2.19/yppush/yppush.c Examining data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c Examining data/nis-3.17.1/ypserv-2.19/lib/log_msg.c Examining data/nis-3.17.1/ypserv-2.19/lib/ypproc_match_2.c Examining data/nis-3.17.1/ypserv-2.19/lib/ypxfrd_xdr.c Examining data/nis-3.17.1/ypserv-2.19/lib/yp.h Examining data/nis-3.17.1/ypserv-2.19/lib/log_msg.h Examining data/nis-3.17.1/ypserv-2.19/lib/yp_db.h Examining data/nis-3.17.1/ypserv-2.19/lib/access.h Examining data/nis-3.17.1/ypserv-2.19/lib/compat.h Examining data/nis-3.17.1/ypserv-2.19/lib/yp_db.c Examining data/nis-3.17.1/ypserv-2.19/lib/securenets.c Examining data/nis-3.17.1/ypserv-2.19/lib/ypxfrd.h Examining data/nis-3.17.1/ypserv-2.19/lib/access.c Examining data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c Examining data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.h Examining data/nis-3.17.1/ypserv-2.19/lib/compat.c Examining data/nis-3.17.1/ypserv-2.19/ypserv/ypserv_xdr.c Examining data/nis-3.17.1/ypserv-2.19/ypserv/reg_slp.h Examining data/nis-3.17.1/ypserv-2.19/ypserv/reg_slp.c Examining data/nis-3.17.1/ypserv-2.19/ypserv/ypserv.c Examining data/nis-3.17.1/ypserv-2.19/ypserv/server.c Examining data/nis-3.17.1/ypserv-2.19/rpc.ypxfrd/ypxfrd_server.c Examining data/nis-3.17.1/ypserv-2.19/rpc.ypxfrd/ypxfrd.c Examining data/nis-3.17.1/ypserv-2.19/rpc.ypxfrd/ypxfrd_svc.c Examining data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr_clnt.c Examining data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr_xdr.c Examining data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.h Examining data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c Examining data/nis-3.17.1/ypserv-2.19/mknetid/mknetid.h Examining data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c Examining data/nis-3.17.1/ypserv-2.19/mknetid/mknetid.c Examining data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c Examining data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c Examining data/nis-3.17.1/ypserv-2.19/revnetgroup/hash.h Examining data/nis-3.17.1/ypserv-2.19/revnetgroup/getnetgrent.c Examining data/nis-3.17.1/ypserv-2.19/revnetgroup/hash.c Examining data/nis-3.17.1/yp-tools-2.9/lib/nicknames.c Examining data/nis-3.17.1/yp-tools-2.9/lib/ypbinderr_string.c Examining data/nis-3.17.1/yp-tools-2.9/lib/getline.h Examining data/nis-3.17.1/yp-tools-2.9/lib/getopt.h Examining data/nis-3.17.1/yp-tools-2.9/lib/getopt1.c Examining data/nis-3.17.1/yp-tools-2.9/lib/yp_all_host.c Examining data/nis-3.17.1/yp-tools-2.9/lib/getline.c Examining data/nis-3.17.1/yp-tools-2.9/lib/nicknames.h Examining data/nis-3.17.1/yp-tools-2.9/lib/yp_all_host.h Examining data/nis-3.17.1/yp-tools-2.9/lib/getopt.c Examining data/nis-3.17.1/yp-tools-2.9/lib/yp-tools.h Examining data/nis-3.17.1/yp-tools-2.9/lib/yp_xdr.c Examining data/nis-3.17.1/yp-tools-2.9/src/domainname.c Examining data/nis-3.17.1/yp-tools-2.9/src/ypset.c Examining data/nis-3.17.1/yp-tools-2.9/src/ypwhich.c Examining data/nis-3.17.1/yp-tools-2.9/src/ypmatch.c Examining data/nis-3.17.1/yp-tools-2.9/src/yppoll.c Examining data/nis-3.17.1/yp-tools-2.9/src/yppasswd_xdr.c Examining data/nis-3.17.1/yp-tools-2.9/src/yppasswd.h Examining data/nis-3.17.1/yp-tools-2.9/src/yptest.c Examining data/nis-3.17.1/yp-tools-2.9/src/ypserv_test.c Examining data/nis-3.17.1/yp-tools-2.9/src/ypcat.c Examining data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c Examining data/nis-3.17.1/debian/Old/domainname.c FINAL RESULTS: data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:417: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 (path_passwd_tmp, passwd_stat.st_mode); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:418: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 (path_passwd_tmp, passwd_stat.st_uid, passwd_stat.st_gid) == -1) data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:451:7: [5] (race) chmod: This accepts filename arguments; if an attacker can move those files, a race condition results. (CWE-362). Use fchmod( ) instead. chmod (path_shadow_tmp, shadow_stat.st_mode); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:452:11: [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_shadow_tmp, shadow_stat.st_uid, data/nis-3.17.1/debian/Old/domainname.c:34: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, argv[1]); data/nis-3.17.1/yp-tools-2.9/src/domainname.c:160:7: [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, argv[0]); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:349: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 (field, def); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:410:36: [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. && !strncmp (pwd->pw_passwd, crypt (pwdstr, pwd->pw_passwd), 13) data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:587:8: [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. if (execl (PASSWD_PROG, "passwd", user, NULL) == -1) data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:601:8: [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. if (execl (CHSH_PROG, "chsh", user, NULL) == -1) data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:616:8: [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. if (execl (CHFN_PROG, "chfn", user, NULL) == -1) data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:680: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. s = getpass (prompt); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:683:7: [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, pwd->pw_name); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:711:16: [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. if (strcmp (crypt (s, sane_passwd), sane_passwd)) data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:743: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. p = getpass (_("Please enter new password:")); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:767: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. p = getpass (_("Please retype new password:")); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:787:39: [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. yppwd.newpw.pw_passwd = strdup (crypt (buf, salt)); data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.c:222: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(bp, tbuf); data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.c:239:5: [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(LOG_NOTICE|LOG_AUTH, data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.c:270:5: [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(LOG_NOTICE|LOG_AUTH, data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.c:334: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(bp, qname); data/nis-3.17.1/ypbind-mt-1.38/src/log_msg.c:63:7: [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. vfprintf (stderr, fmt, ap); data/nis-3.17.1/ypbind-mt-1.38/src/log_msg.c:69:7: [4] (format) vsnprintf: 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. vsnprintf (msg, 512, fmt, ap); data/nis-3.17.1/ypbind-mt-1.38/src/log_msg.c:128:3: [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. vfprintf (logfp, fmt, ap); data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:142:3: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (path, "%s/%s.1", BINDINGDIR, domain_name); data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:144:3: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (path, "%s/%s.2", BINDINGDIR, domain_name); data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:160:3: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (path1, "%s/%s.1", BINDINGDIR, entry->domain); data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:161:3: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (path2, "%s/%s.2", BINDINGDIR, entry->domain); data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:446:7: [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 (domainlist[max_domains - 1].domain, domain); data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:201:16: [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. count = sscanf (cp, "domain %s broadcast", tmpdomain); data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:218:16: [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. count = sscanf (cp, "domain %s slp", tmpdomain); data/nis-3.17.1/ypserv-2.19/lib/compat.c:20: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 (s1, s2); data/nis-3.17.1/ypserv-2.19/lib/compat.c:34: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 (retval, s); data/nis-3.17.1/ypserv-2.19/lib/log_msg.c:30:7: [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. vfprintf (debug_output, fmt, ap); data/nis-3.17.1/ypserv-2.19/lib/log_msg.c:41:7: [4] (format) vsnprintf: 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. vsnprintf (msg, sizeof (msg), fmt, ap); data/nis-3.17.1/ypserv-2.19/lib/securenets.c:92:11: [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 (buf3, "%s %s", buf1, buf2) != 2) data/nis-3.17.1/ypserv-2.19/lib/yp_db.c:54:7: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (buf, "%s/%s", domain, map); data/nis-3.17.1/ypserv-2.19/lib/yp_db.c:97:7: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (buf, "%s/%s", domain, map); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:69:3: [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. sscanf (m, "%s", buf); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:77: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 (network, buf); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:117: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. sscanf (m, "%s", buf); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:125:7: [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 (netmask, buf); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:284: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. sscanf (buf3, "%s", buf2); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:345:3: [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. sscanf (buf3, "%s", buf2); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:434:3: [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. sscanf (buf3, "%s", buf2); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:479:3: [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. sscanf (buf3, "%s", buf2); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:575:6: [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. sscanf (d, "%s", buf2); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:577:6: [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. sscanf (m, "%s", buf2); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:580:6: [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. sscanf (s, "%s", buf2); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:93: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 (buffer, str1); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:94: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 (buffer, str2); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:124:3: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (filename, "%s~", dbmName); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.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 (key, cptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:290:5: [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 (key, cptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:350:5: [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 (key, cptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:357:7: [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 (key, nkey); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:366: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 (key, nkey); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:614: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 (masterName, optarg); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:135:7: [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(work->key,key); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:137:7: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf(work->val,"unix.%s@%s\t%s:%s",uid,domain,uid,gid); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:143:7: [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(user_liste[hkey]->key,key); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:146:7: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf(user_liste[hkey]->val,"unix.%s@%s\t%s:%s",uid,domain,uid,gid); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:196:7: [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(ptr,work->val); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:198:7: [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(ptr,grp); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:244:4: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf(work->val,"unix.%s@%s\t0:%s",host,domain,host); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:253:7: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf(host_liste[hkey]->val,"unix.%s@%s\t0:%s",host,domain,host); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:212:5: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (key, "%s.*", dat); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:217:5: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (key, "%s.%s", dat, domain); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:232:9: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (buf2, "%s,", val); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:246:6: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (buf, "%s,%s", val, work->key); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:269:9: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (buf2, "%s,", val); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:283:6: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (buf, "%s,%s", val, work->key); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:349: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 (work->key, key); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:350: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 (work->val, val); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:151:15: [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. if (strcmp (crypt (plain, crypted), crypted) == 0) data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:154:15: [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. if (strcmp (crypt (plain, root), root) == 0) data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:223:3: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (logbuf, "update %.12s (uid=%d) from host %s", data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:333:13: [4] (shell) execlp: 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. execlp (MAP_UPDATE_PATH, MAP_UPDATE, "shadow", NULL); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:335:13: [4] (shell) execlp: 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. execlp (MAP_UPDATE_PATH, MAP_UPDATE, "passwd", NULL); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:380:8: [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 (rootpass, spw->sp_pwdp); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:387: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 (rootpass, pw->pw_passwd); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:695:7: [4] (shell) execlp: 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. execlp (external_update_program, external_update_program, NULL); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:851:7: [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 (external_update_program, external_update_program, NULL); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:879: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 (parentmsg, yppw->newpw.pw_name); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:881: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 (parentmsg, yppw->oldpass); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:887:7: [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 (parentmsg, password); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:894:7: [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 (parentmsg, shell); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:901:7: [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(parentmsg, gcos); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:310:4: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (path_passwd, "%s/passwd", optarg); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:313:4: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (path_shadow, "%s/shadow", optarg); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:367:3: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (path_passwd_tmp, "%s.tmp", path_passwd); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:374:3: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (path_passwd_old, "%s.OLD", path_passwd); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:383:3: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (path_shadow_tmp, "%s.tmp", path_shadow); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:390:3: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (path_shadow_old, "%s.OLD", path_shadow); data/nis-3.17.1/ypserv-2.19/rpc.ypxfrd/ypxfrd_server.c:188:5: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (buf, "%s/%s", argp->xfrdomain, argp->xfrmap_filename); data/nis-3.17.1/ypserv-2.19/rpc.ypxfrd/ypxfrd_server.c:196: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 ((char *) &buf, R_OK) == -1) data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:236:7: [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 (server, hp->h_name); data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:494:5: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (mappath, "%s/%s/%s", YPMAPDIR, domainname, map); data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:270:5: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (mappath, "%s/%s/%s", YPMAPDIR, DomainName, current_map); data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:433:5: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (server, "%s", host); data/nis-3.17.1/ypserv-2.19/ypserv/reg_slp.c:119:4: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (str, "(domain=%s", dep->d_name); data/nis-3.17.1/ypserv-2.19/ypserv/reg_slp.c:139:4: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (cp, "%s,%s", str, dep->d_name); data/nis-3.17.1/ypserv-2.19/ypserv/reg_slp.c:163:7: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (cp, "%s)", str); data/nis-3.17.1/ypserv-2.19/ypserv/reg_slp.c:232:3: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (url, "service:ypserv://%s/", hname) < 0; data/nis-3.17.1/ypserv-2.19/ypserv/server.c:671:9: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (ypxfr_command, "%s/ypxfr", YPBINDIR); data/nis-3.17.1/ypserv-2.19/ypserv/server.c:676:11: [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 (ypxfr_command, "ypxfr", "--debug", "-d", data/nis-3.17.1/ypserv-2.19/ypserv/server.c:681:11: [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 (ypxfr_command, "ypxfr", "-d", argp->map_parms.domain, "-h", data/nis-3.17.1/ypserv-2.19/ypserv/server.c:1054: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, map); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:369:5: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (dbName_orig, "%s/%s/%s", path_ypdb, target_domain, map); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:378:5: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (dbName_temp, "%s/%s/%s~", path_ypdb, target_domain, map); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:455:7: [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 (master_host, resp_master.peer); data/nis-3.17.1/yp-tools-2.9/lib/getopt.c:215: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. char *getenv (); data/nis-3.17.1/yp-tools-2.9/lib/getopt.c:406:21: [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. posixly_correct = getenv ("POSIXLY_CORRECT"); data/nis-3.17.1/yp-tools-2.9/lib/getopt.c:972:1: [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. getopt (argc, argv, optstring) data/nis-3.17.1/yp-tools-2.9/lib/getopt.c:1002:11: [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. c = getopt (argc, argv, "abc:d:0123456789"); data/nis-3.17.1/yp-tools-2.9/lib/getopt.h:108:12: [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. extern int getopt (int argc, char *const *argv, const char *shortopts); data/nis-3.17.1/yp-tools-2.9/lib/getopt.h:110:12: [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. extern int getopt (int argc, char *const *argv, const char *shortopts); data/nis-3.17.1/yp-tools-2.9/lib/getopt.h:112:12: [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. extern int getopt_long (int argc, char *const *argv, const char *shortopts, data/nis-3.17.1/yp-tools-2.9/lib/getopt.h:124:12: [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. extern int getopt (); data/nis-3.17.1/yp-tools-2.9/lib/getopt.h:125:12: [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. extern int getopt_long (); data/nis-3.17.1/yp-tools-2.9/lib/getopt1.c:70:1: [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. getopt_long (argc, argv, options, long_options, opt_index) data/nis-3.17.1/yp-tools-2.9/lib/getopt1.c:126:11: [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. c = getopt_long (argc, argv, "abc:d:0123456789", data/nis-3.17.1/yp-tools-2.9/src/domainname.c:124:11: [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. c = getopt_long (argc, argv, "?", long_options, &option_index); data/nis-3.17.1/yp-tools-2.9/src/ypcat.c:140:11: [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. c = getopt_long (argc, argv, "d:h:ktx?", long_options, &option_index); data/nis-3.17.1/yp-tools-2.9/src/ypmatch.c:113:11: [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. c = getopt_long (argc, argv, "d:ktx?", long_options, &option_index); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:464:6: [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. c = random(); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:492: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 (time (NULL)); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:518:11: [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. c = getopt_long (argc, argv, data/nis-3.17.1/yp-tools-2.9/src/yppoll.c:122:11: [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. c = getopt_long (argc, argv, "d:h:?", long_options, &option_index); data/nis-3.17.1/yp-tools-2.9/src/ypserv_test.c:679:11: [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. c = getopt_long (argc, argv, "d:h:k:lm:?", long_options, &option_index); data/nis-3.17.1/yp-tools-2.9/src/ypset.c:179:11: [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. c = getopt_long (argc, argv, "d:h:?", long_options, &option_index); data/nis-3.17.1/yp-tools-2.9/src/yptest.c:230:11: [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. c = getopt_long (argc, argv, "d:h:m:u:q?", long_options, &option_index); data/nis-3.17.1/yp-tools-2.9/src/ypwhich.c:184:11: [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. c = getopt_long (argc, argv, "d:mtV:x?", long_options, &option_index); data/nis-3.17.1/ypserv-2.19/lib/compat.c:43:1: [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. getopt_long (int argc, char *const *argv, const char *shortopts, data/nis-3.17.1/ypserv-2.19/lib/compat.c:46:10: [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. return getopt (argc, argv, shortopts); data/nis-3.17.1/ypserv-2.19/lib/compat.h:44:5: [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. int getopt_long (int argc, char *const *argv, const char *shortopts, data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:573:11: [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. c = getopt_long (argc, argv, "abcd:hi:lm:o:rsu", long_options, &option_index); data/nis-3.17.1/ypserv-2.19/mknetid/mknetid.c:106:11: [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. c = getopt_long (argc, argv, "uvqh:g:p:d:n:", long_options, &option_index); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:82:11: [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. c = getopt_long (argc, argv, "uh", long_options, &option_index); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:277:9: [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. c=getopt_long (argc, argv, "e:p:s:uhvD:E:x:m", long_options, data/nis-3.17.1/ypserv-2.19/rpc.ypxfrd/ypxfrd.c:184:9: [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. c=getopt_long(argc, argv, "p:d:uh",long_options, &option_index); data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:630:11: [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. c = getopt_long (argc, argv, "d:hvm:pgi:", long_options, &option_index); data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:604:11: [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. c = getopt_long (argc, argv, "d:vh:ut:p:j:", long_options, &option_index); data/nis-3.17.1/ypserv-2.19/ypserv/ypserv.c:425:11: [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. c = getopt_long (argc, argv, "vdp:buh", long_options, &option_index); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:791:11: [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. c = getopt_long (argc, argv, "ufcd:h:p:s:C:S", long_options, &option_index); data/nis-3.17.1/debian/Old/domainname.c:19: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[256]; data/nis-3.17.1/yp-tools-2.9/lib/getopt.c:334:4: [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 (new_str, __getopt_nonoption_flags, nonoption_flags_max_len); data/nis-3.17.1/yp-tools-2.9/lib/getopt.c:446: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 (__getopt_nonoption_flags, orig_str, len); data/nis-3.17.1/yp-tools-2.9/lib/nicknames.c:61: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 (NICKNAMEFILE, "r"); data/nis-3.17.1/yp-tools-2.9/lib/yp_all_host.c:65:13: [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 key[resp.ypresp_all_u.val.key.keydat_len + 1]; data/nis-3.17.1/yp-tools-2.9/lib/yp_all_host.c:66:13: [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 val[resp.ypresp_all_u.val.val.valdat_len + 1]; data/nis-3.17.1/yp-tools-2.9/lib/yp_all_host.c:75:13: [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 (key, resp.ypresp_all_u.val.key.keydat_val, keylen); data/nis-3.17.1/yp-tools-2.9/lib/yp_all_host.c:77:13: [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 (val, resp.ypresp_all_u.val.val.valdat_val, vallen); data/nis-3.17.1/yp-tools-2.9/src/domainname.c:157:7: [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[strlen (argv[0]) + 1]; data/nis-3.17.1/yp-tools-2.9/src/domainname.c:186: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[256]; data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:255: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 *buffer, uidbuf[256], *ptr, *keyval; data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:318: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). pwd.pw_uid = atoi (val (strsep (&ptr, ":"))); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:319: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). pwd.pw_gid = atoi (val (strsep (&ptr, ":"))); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:454: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("/dev/urandom", O_RDONLY); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:672:7: [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[130]; data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:725:7: [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, salt[12], *p = NULL; data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:783:4: [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 (salt, "$1$"); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:792:7: [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 gecos[1024], *sp, new_gecos[1024]; data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:793:7: [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[254], location[254], office[254], phone[254]; data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:794:7: [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 oname[254], olocation[254], ooffice[254], ophone[254]; data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:830:7: [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_shell[PATH_MAX]; data/nis-3.17.1/yp-tools-2.9/src/yppoll.c:252:7: [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 (&clnt_saddr.sin_addr.s_addr,hent->h_addr_list[0], data/nis-3.17.1/yp-tools-2.9/src/ypset.c:123: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 (&ypsd.ypsetdom_binding.ypbind_binding_addr, &server_addr.s_addr, data/nis-3.17.1/yp-tools-2.9/src/ypwhich.c:201:21: [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). ypbind_version = atoi (optarg); data/nis-3.17.1/ypbind-mt-1.38/lib/clnt_udp.c:107:5: [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 cu_inbuf[1]; data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.c:96: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 *h_addr_ptrs[MAXADDRS + 1]; data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.c:99: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 *host_aliases[MAXALIASES]; data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.c:100: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 hostbuf[8*1024]; data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.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 tbuf[MAXDNAME+1]; data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.c:307:4: [2] (buffer) bcopy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. bcopy(cp, *hap++ = bp, n); data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.c:450: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 qbuf[MAXDNAME+1]; data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.c:455: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 hname2[MAXDNAME+1]; data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.c:463:8: [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. (void)sprintf(qbuf, "%u.%u.%u.%u.in-addr.arpa", data/nis-3.17.1/ypbind-mt-1.38/src/log_msg.c:55: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 msg[512]; data/nis-3.17.1/ypbind-mt-1.38/src/log_msg.c:98: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). if ((logfp = fopen (logfilename, "a+")) == NULL) data/nis-3.17.1/ypbind-mt-1.38/src/log_msg.c:111: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 date[128]; data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:78: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 domain[YPMAXDOMAIN + 1]; data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:137: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 (BINDINGDIR) + strlen (domain_name) + 10]; data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.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 path1[MAXPATHLEN + 1], path2[MAXPATHLEN + 1]; data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:178:7: [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 (&ybres.ypbind_resp_u.ypbind_bindinfo.ypbind_binding_addr, data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:180:7: [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 (&ybres.ypbind_resp_u.ypbind_bindinfo.ypbind_binding_port, data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:196:7: [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 (&ybres.ypbind_resp_u.ypbind_bindinfo.ypbind_binding_addr, data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:198:7: [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 (&ybres.ypbind_resp_u.ypbind_bindinfo.ypbind_binding_port, data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:220:13: [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 ((fd = open(path1, O_CREAT | O_RDWR | O_TRUNC, FILE_MODE )) != -1) data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:233:13: [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 ((fd = open(path2, O_CREAT | O_RDWR | O_TRUNC, FILE_MODE )) != -1) data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:266:4: [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(&(domainlist[i].ypset.addr), data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:269:4: [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(&(domainlist[i].ypset.port), data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:275: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. memcpy (&addr.sin_addr, &domainlist[i].ypset.addr, data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:277: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. memcpy (&addr.sin_port, &domainlist[i].ypset.port, data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:280:4: [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 (&domainlist[i].sin, &addr, sizeof (struct sockaddr_in)); data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:331:7: [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 (&result->ypbind_resp_u.ypbind_bindinfo.ypbind_binding_addr, data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:334:7: [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 (&result->ypbind_resp_u.ypbind_bindinfo.ypbind_binding_port, data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:345:7: [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 (&result->ypbind_resp_u.ypbind_bindinfo.ypbind_binding_addr, data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:347:7: [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 (&result->ypbind_resp_u.ypbind_bindinfo.ypbind_binding_port, data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:586:7: [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 (&entry->server[active].addr, hent->h_addr_list[0], data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:793:5: [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 cu_inbuf[1]; data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:842:7: [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 (&s_in.sin_addr, &(list->server[i].addr), data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:869:7: [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 (&pings[pings_count]->sin, &s_in, sizeof(struct sockaddr_in)); data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:905:7: [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 (&(cu->cu_raddr), &pings[i]->sin, sizeof (struct sockaddr_in)); data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:918: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 (&xid_lookup, &(cu->cu_inbuf), sizeof (u_int32_t)); data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:942:8: [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 (&(list->sin), &pings[i]->sin, sizeof(struct sockaddr_in)); data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:1018:7: [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 (&server_addr.sin_addr, &list->server[i].addr, data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:1058:4: [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 (&(list->server[i].port), &server_addr.sin_port, data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:1060:4: [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 (&(list->sin), &server_addr, sizeof (struct sockaddr_in)); data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:92: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[MAXPATHLEN]; data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:119: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 (configfile, "r"); data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:128:7: [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 tmpserver[81], tmpdomain[YPMAXDOMAIN + 1]; data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:334: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 pbuf[10], *ptr; data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:337:13: [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). lock_fd = open (_YPBIND_PIDFILE, O_CREAT | O_RDWR, data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:395:3: [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 (pbuf, "%ld\n", (long) getpid ()); data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:730:11: [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). port = atoi (argv[i]); data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:739:20: [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). ping_interval = atoi (argv[i]); data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:748:19: [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). logfile_flag = atoi (argv[i]); data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:760:22: [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). rebind_interval = atoi (argv[i]); data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:890:11: [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). j = open ("/dev/null", O_RDWR); data/nis-3.17.1/ypbind-mt-1.38/src/ypbind.h:52: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 ypbind_binding_addr[4]; data/nis-3.17.1/ypbind-mt-1.38/src/ypbind.h: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 ypbind_binding_port[2]; data/nis-3.17.1/ypbind-mt-1.38/src/ypbind.h:76: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 ypoldsetdom_domain[YPMAXDOMAIN]; data/nis-3.17.1/ypserv-2.19/lib/log_msg.c:39:7: [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 msg[512]; data/nis-3.17.1/ypserv-2.19/lib/securenets.c:52: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 buf1[128], buf2[128], buf3[128]; data/nis-3.17.1/ypserv-2.19/lib/securenets.c:72: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). if ((in = fopen (SECURENETS, "r")) == NULL) data/nis-3.17.1/ypserv-2.19/lib/securenets.c:109:4: [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 (buf1, "255.255.255.255"); data/nis-3.17.1/ypserv-2.19/lib/yp.h: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 ypbind_binding_addr[4]; data/nis-3.17.1/ypserv-2.19/lib/yp.h:195: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 ypbind_binding_port[2]; data/nis-3.17.1/ypserv-2.19/lib/yp_db.c:49: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 buf[MAXPATHLEN + 2]; data/nis-3.17.1/ypserv-2.19/lib/yp_db.c:93: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 buf[MAXPATHLEN + 2]; data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:63: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 buf[20]; data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:81:7: [2] (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 string. strcat (network, ".0.0.0"); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:86:2: [2] (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 string. strcat (network, "0.0.0"); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:89:4: [2] (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 string. strcat (network, ".0.0"); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:95:2: [2] (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 string. strcat (network, "0.0"); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:98:4: [2] (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 string. strcat (network, ".0"); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:129:4: [2] (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 string. strcat (netmask, ".0.0.0"); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:133:6: [2] (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 string. strcat (netmask, "0.0.0"); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:135:6: [2] (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 string. strcat (netmask, ".0.0"); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:139:6: [2] (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 string. strcat (netmask, "0.0"); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:141:6: [2] (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 string. strcat (netmask, ".0"); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:155:2: [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 (netmask, "255.0.0.0"); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:158:2: [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 (netmask, "255.255.0.0"); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:161:2: [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 (netmask, "255.255.255.0"); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:164:2: [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 (netmask, "255.255.255.255"); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:177: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 buf1[1025], buf2[1025], buf3[1025]; data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:183: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 (cp, "/ypserv.conf"); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:184: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). if ((in = fopen (filename, "r")) == NULL) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:591:33: [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). tmp->mangle = buf2[11] ? atoi(buf2 + 12) : 2; data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:596:33: [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). tmp->mangle = buf2[11] ? atoi(buf2 + 12) : 2; data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:112: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 orderNum[12]; data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:116:36: [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). input = strcmp (fileName, "-") ? fopen (fileName, "r") : stdin; data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:200:3: [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 (orderNum, "%ld", (long) tv.tv_sec); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:544: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 masterName[MAXHOSTNAMELEN + 1] = ""; data/nis-3.17.1/ypserv-2.19/mknetid/mknetid.c:154:15: [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 ((file = fopen (pwname, "r")) == NULL) data/nis-3.17.1/ypserv-2.19/mknetid/mknetid.c:193:15: [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 ((file = fopen (grpname, "r")) == NULL) data/nis-3.17.1/ypserv-2.19/mknetid/mknetid.c:228:15: [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 ((file = fopen (hostname, "r")) == NULL) data/nis-3.17.1/ypserv-2.19/mknetid/mknetid.c:268:15: [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 ((file = fopen (netidname, "r")) != NULL) data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:84: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 uid_liste[65535]; data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:104:8: [2] (integer) atol: 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). id = atol(uid); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:53: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 buffer[BUFSIZE + 1]; data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:106: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). debug_file = fopen ("/etc/netgroup", "rt"); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:123: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 buffer[1024]; data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:126: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). if ((fp = fopen (_PATH_SHELLS, "r")) == NULL) data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:394: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). if ((oldpf = fopen (path_passwd, "r")) == NULL) data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:410: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). if ((newpf = fopen (path_passwd_tmp, "w+")) == NULL) data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:429: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). if ((oldsf = fopen (path_shadow, "r")) != NULL) data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:440:20: [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 ((newsf = fopen (path_shadow_tmp, "w+")) == NULL) data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:751: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 childresponse[1024]; data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:880:3: [2] (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 string. strcat (parentmsg, " o:"); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:886:7: [2] (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 string. strcat (parentmsg, "p:"); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:893:7: [2] (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 string. strcat (parentmsg, "s:"); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:900:7: [2] (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 string. strcat(parentmsg, "g:"); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:121: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 pbuf[50], *ptr; data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:124: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 (_YPPASSWDD_PIDFILE, O_CREAT | O_RDWR, data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:165:3: [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 (pbuf, "%ld\n", (long) getpid ()); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:335:21: [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). my_port = atoi (optarg); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:443:11: [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). i = open("/dev/null", O_RDWR); data/nis-3.17.1/ypserv-2.19/rpc.ypxfrd/ypxfrd.c:201: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). my_port = atoi(optarg); data/nis-3.17.1/ypserv-2.19/rpc.ypxfrd/ypxfrd.c:254:6: [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). i = open("/dev/null", O_RDWR); data/nis-3.17.1/ypserv-2.19/rpc.ypxfrd/ypxfrd_server.c:51:19: [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 unsigned char buf[XFRBLOCKSIZE]; data/nis-3.17.1/ypserv-2.19/rpc.ypxfrd/ypxfrd_server.c:100: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 buf[MAXPATHLEN]; data/nis-3.17.1/ypserv-2.19/rpc.ypxfrd/ypxfrd_server.c:202:15: [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 ((file = open ((char *) &buf, O_RDONLY)) == -1) data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:95:7: [2] (buffer) bcopy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. bcopy ((char *) hent->h_addr_list[0], data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:145:7: [2] (buffer) bcopy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. bcopy ((char *) hent->h_addr_list[0], data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:169: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 hostname[MAXHOSTNAMELEN + 1]; data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:186:7: [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 addr[INADDRSZ]; data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:227:7: [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 addr[INADDRSZ]; data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:289: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). p_input = fopen (passwd, "r"); data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:296: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). s_input = fopen (shadow, "r"); data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:367: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 sgrbuf[BUFSIZ*4]; data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:403: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). g_input = fopen (group, "r"); data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:410: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). s_input = fopen (gshadow, "r"); data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:484: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 mappath[MAXPATHLEN + 2]; data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:558:7: [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 h_tmp[MAXHOSTNAMELEN+1]; data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:571:7: [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 addr[INADDRSZ]; data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:72: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 local_hostname[MAXHOSTNAMELEN + 2]; data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:260: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 mappath[MAXPATHLEN + 2]; data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:338:7: [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). i = atoi (val); data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:357: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 host[YPMAXPEER + 2]; data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:368:5: [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 (host, "%.*s", vallen, val); data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:415: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 server[YPMAXPEER + 2]; data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:616: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). timeout = atoi (optarg); data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:620:18: [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). maxchildren = atoi (optarg); data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:646: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). my_port = atoi (optarg); data/nis-3.17.1/ypserv-2.19/ypserv/reg_slp.c:68: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 hostname[1024]; data/nis-3.17.1/ypserv-2.19/ypserv/reg_slp.c:193: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 addr[INADDRSZ]; data/nis-3.17.1/ypserv-2.19/ypserv/server.c:65:2: [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(p, val->dptr, i); data/nis-3.17.1/ypserv-2.19/ypserv/server.c:66:2: [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(p + i, "x", 1); data/nis-3.17.1/ypserv-2.19/ypserv/server.c:72:2: [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(q, s, val->dsize - i); data/nis-3.17.1/ypserv-2.19/ypserv/server.c:653: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 g[30], t[30], p[30]; data/nis-3.17.1/ypserv-2.19/ypserv/server.c:657:13: [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). i = open ("/dev/null", O_RDWR); data/nis-3.17.1/ypserv-2.19/ypserv/server.c:1136:4: [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 (buf, val.dptr, val.dsize); data/nis-3.17.1/ypserv-2.19/ypserv/server.c:1138:23: [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). result->ordernum = atoi (buf); data/nis-3.17.1/ypserv-2.19/ypserv/ypserv.c:254: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 pbuf[10], *ptr; data/nis-3.17.1/ypserv-2.19/ypserv/ypserv.c:257: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 (_YPSERV_PIDFILE, O_CREAT | O_RDWR, data/nis-3.17.1/ypserv-2.19/ypserv/ypserv.c:315:3: [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 (pbuf, "%ld\n", (long) getpid ()); data/nis-3.17.1/ypserv-2.19/ypserv/ypserv.c:345: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). debug_output = fopen ("/var/yp/ypserv.log", "a"); data/nis-3.17.1/ypserv-2.19/ypserv/ypserv.c:438: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). my_port = atoi (optarg); data/nis-3.17.1/ypserv-2.19/ypserv/ypserv.c:490:11: [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). i = open ("/dev/null", O_RDWR); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:256:22: [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 ((ypxfrd_file = open (tmpname, O_RDWR | O_CREAT, S_IRUSR | S_IWUSR)) == -1) data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:350: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 dbName_orig[MAXPATHLEN + 1]; data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:351: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 dbName_temp[MAXPATHLEN + 1]; data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:408: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 (&sockaddr.sin_addr, h->h_addr, sizeof sockaddr.sin_addr); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:409: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 (&sockaddr_udp, &sockaddr, sizeof (sockaddr)); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:557:31: [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). localOrderNum = atoi (d); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:581:7: [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 orderNum[255]; data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:832: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). transid = atoi (optarg); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:833:21: [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). program_number = atoi (argv[optind++]); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:835:18: [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). remote_port = atoi (argv[optind++]); data/nis-3.17.1/debian/Old/domainname.c:37: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 (setdomainname(buf, strlen(buf)) < 0) { data/nis-3.17.1/yp-tools-2.9/lib/getline.c:95:24: [1] (buffer) getc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). register int c = getc (stream); data/nis-3.17.1/yp-tools-2.9/lib/getopt.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). extern int strlen (const char *); data/nis-3.17.1/yp-tools-2.9/lib/getopt.c:437: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). int len = nonoption_flags_max_len = strlen (orig_str); data/nis-3.17.1/yp-tools-2.9/lib/getopt.c:661: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). == (unsigned int) strlen (p->name)) data/nis-3.17.1/yp-tools-2.9/lib/getopt.c:685: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). nextchar += strlen (nextchar); data/nis-3.17.1/yp-tools-2.9/lib/getopt.c:715: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). nextchar += strlen (nextchar); data/nis-3.17.1/yp-tools-2.9/lib/getopt.c:731: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). nextchar += strlen (nextchar); data/nis-3.17.1/yp-tools-2.9/lib/getopt.c:736: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). nextchar += strlen (nextchar); data/nis-3.17.1/yp-tools-2.9/lib/getopt.c:847:51: [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 ((unsigned int) (nameend - nextchar) == strlen (p->name)) data/nis-3.17.1/yp-tools-2.9/lib/getopt.c:870: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). nextchar += strlen (nextchar); data/nis-3.17.1/yp-tools-2.9/lib/getopt.c:890: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). nextchar += strlen (nextchar); data/nis-3.17.1/yp-tools-2.9/lib/getopt.c:904: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). nextchar += strlen (nextchar); data/nis-3.17.1/yp-tools-2.9/lib/getopt.c:908: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). nextchar += strlen (nextchar); data/nis-3.17.1/yp-tools-2.9/src/domainname.c:157: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). char buf[strlen (argv[0]) + 1]; data/nis-3.17.1/yp-tools-2.9/src/domainname.c:163: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). if (setdomainname (buf, strlen (buf)) < 0) data/nis-3.17.1/yp-tools-2.9/src/ypmatch.c:190: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). res = yp_match (domainname, map, argv[i], strlen (argv[i]), data/nis-3.17.1/yp-tools-2.9/src/ypmatch.c:193:49: [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). res = yp_match (domainname, map, argv[i], strlen (argv[i]) + 1, data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:282: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). key.keydat.keydat_len = strlen (keyval); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:304:3: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy (buffer, resp.valdat.valdat_val, resp.valdat.valdat_len); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:351:5: [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 (field, ""); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:371:3: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy (field, gecos, size - 1); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:388: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 (pwdstr) < 6) && uid) data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:425: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). for (p = pwdstr + strlen (pwdstr) - 1, q = pwd->pw_name; data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:461:8: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). res = read (fd, &c, 1); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:669: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 ((pwd->pw_passwd != NULL && strlen (pwd->pw_passwd) > 0) || data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:681: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). hashpass = alloca (strlen (pwd->pw_name) + 3); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:695: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). passwdlen = strlen (pwd->pw_passwd); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:709:4: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy (sane_passwd, pwd->pw_passwd, passwdlen); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:750:4: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy (buf, p, 128); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:801:7: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy (gecos, pwd->pw_gecos, sizeof (gecos)); data/nis-3.17.1/yp-tools-2.9/src/yppasswd.c:821: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). sp = new_gecos + strlen (new_gecos); data/nis-3.17.1/yp-tools-2.9/src/yppoll.c:323: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). c[strlen(c)-1] = '\0'; data/nis-3.17.1/yp-tools-2.9/src/ypserv_test.c:298:62: [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). struct ypreq_key request1 = {domainname, "passwd.byname", {strlen(key), key}}; data/nis-3.17.1/yp-tools-2.9/src/ypserv_test.c:300:62: [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). struct ypreq_key request3 = {domainname, "passwd-byname", {strlen(key), key}}; data/nis-3.17.1/yp-tools-2.9/src/ypserv_test.c:301:64: [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). struct ypreq_key request4 = {"../../etc/", "passwd.byname", {strlen(key), key}}; data/nis-3.17.1/yp-tools-2.9/src/ypserv_test.c:523:62: [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). struct ypreq_key request1 = {domainname, "passwd.byname", {strlen(key), key}}; data/nis-3.17.1/yp-tools-2.9/src/ypserv_test.c:526:62: [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). struct ypreq_key request4 = {domainname, "passwd-byname", {strlen(key), key}}; data/nis-3.17.1/yp-tools-2.9/src/ypserv_test.c:527:64: [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). struct ypreq_key request5 = {"../../etc/", "passwd.byname", {strlen(key), key}}; data/nis-3.17.1/yp-tools-2.9/src/ypserv_test.c:528:49: [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). struct ypreq_key request6 = {domainname, "", {strlen(key), key}}; data/nis-3.17.1/yp-tools-2.9/src/ypserv_test.c:529:54: [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). struct ypreq_key request7 = {"", "passwd.byname", {strlen(key), key}}; data/nis-3.17.1/yp-tools-2.9/src/yptest.c:340: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). KeyLen = strlen (key); data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.c:163: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). n = strlen(bp) + 1; /* for the \0 */ data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.c:213: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). n = strlen(bp) + 1; /* for the \0 */ data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.c:217: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). n = strlen(tbuf) + 1; /* for the \0 */ data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.c:258: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). n = strlen(bp) + 1; /* for the \0 */ data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.c:288: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). nn = strlen(bp) + 1; /* for the \0 */ data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.c:333: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). n = strlen(qname) + 1; /* for the \0 */ data/nis-3.17.1/ypbind-mt-1.38/lib/dns_hosts.c:480:2: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy(hname2, hp->h_name, MAXDNAME); data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:137: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 (BINDINGDIR) + strlen (domain_name) + 10]; data/nis-3.17.1/ypbind-mt-1.38/src/serv_list.c:137:35: [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 (BINDINGDIR) + strlen (domain_name) + 10]; data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:146: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). n = strlen (buf); data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:163:14: [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 (cp[strlen (cp) - 1] == '\n') data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:164:5: [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) - 1] = '\0'; data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:184:16: [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. count = sscanf (cp, "domain %64s server %80s", tmpdomain, data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:243:12: [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. count = sscanf (cp, "ypserver %80s", tmpserver); data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:396: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). left = strlen (pbuf); data/nis-3.17.1/ypbind-mt-1.38/src/ypbind-mt.c:889:7: [1] (access) umask: Ensure that umask is given most restrictive possible setting (e.g., 066 or 077) (CWE-732). umask (0); data/nis-3.17.1/ypbind-mt-1.38/src/ypbind_dbus_nm.c:208: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). (old_owner && (strlen (old_owner) > 0)); data/nis-3.17.1/ypbind-mt-1.38/src/ypbind_dbus_nm.c:210: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). (new_owner && (strlen (new_owner) > 0)); data/nis-3.17.1/ypbind-mt-1.38/src/ypbind_slp.c:115: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). if (!hostp || strlen(hostp) < strlen("://") + 1) data/nis-3.17.1/ypbind-mt-1.38/src/ypbind_slp.c:115: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 (!hostp || strlen(hostp) < strlen("://") + 1) data/nis-3.17.1/ypbind-mt-1.38/src/ypbind_slp.c:121: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). hostp += strlen ("://"); data/nis-3.17.1/ypserv-2.19/lib/compat.c:21: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). return s1 + strlen (s2); data/nis-3.17.1/ypserv-2.19/lib/compat.c:29: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). int len = strlen (s) + 1; data/nis-3.17.1/ypserv-2.19/lib/compat.c:134:15: [1] (buffer) getc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). c = getc (stream); data/nis-3.17.1/ypserv-2.19/lib/yp_db.c:52: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 (domain) + strlen (map) < MAXPATHLEN) data/nis-3.17.1/ypserv-2.19/lib/yp_db.c:52: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 (domain) + strlen (map) < MAXPATHLEN) data/nis-3.17.1/ypserv-2.19/lib/yp_db.c:95: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 (domain) + strlen (map) < MAXPATHLEN) data/nis-3.17.1/ypserv-2.19/lib/yp_db.c:95: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 (domain) + strlen (map) < MAXPATHLEN) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:71: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). for (i = 0; i < strlen (buf); i++) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:85: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). if (network[strlen (network) - 1] == '.') data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:94: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). if (network[strlen (network) - 1] == '.') data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:103: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). if (network[strlen (network) - 1] == '.') data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:104:2: [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 (network, "0"); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:115: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 ((m != NULL) && (strlen (m) != 0)) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:119: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). for (i = 0; i < strlen (buf); i++) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:132: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). if (netmask[strlen (netmask) - 1] == '.') data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:138: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). if (netmask[strlen (netmask) - 1] == '.') data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:144: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). if (netmask[strlen (netmask) - 1] == '.') data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:145:6: [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 (netmask, "0"); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:180: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). char *filename = alloca (strlen (path) + sizeof ("/ypserv.conf") + 1); data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:191:15: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). while ((c = fgetc (in)) != (char) EOF) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:210: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). while (c != ':' && i <= strlen (buf1)) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:220: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). while ((buf1[i - 1] != ':') && (i <= strlen (buf1))) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:226: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). (i <= strlen (buf1))) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:259: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). while (c != ':' && i <= strlen (buf1)) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:269: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). while ((buf1[i - 1] != ':') && (i <= strlen (buf1))) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:277: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). (i <= strlen (buf1))) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:313: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). while (c != ':' && i <= strlen (buf1)) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:323: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). while ((buf1[i - 1] != ':') && (i <= strlen (buf1))) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:338: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). (i <= strlen (buf1))) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:370: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). (i <= strlen (buf1))) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:404: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). while (c != ':' && i <= strlen (buf1)) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:414: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). while ((buf1[i - 1] != ':') && (i <= strlen (buf1))) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:427: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). (i <= strlen (buf1))) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:456: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). while (c != ':' && i <= strlen (buf1)) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:466: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). while ((buf1[i - 1] != ':') && (i <= strlen (buf1))) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:472: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). (i <= strlen (buf1))) data/nis-3.17.1/ypserv-2.19/lib/ypserv_conf.c:536: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 (p != NULL && strlen (p) != 0) data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:91: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). char *buffer = alloca(strlen (str1) + strlen (str2) + 1); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:91: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). char *buffer = alloca(strlen (str1) + strlen (str2) + 1); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:123: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). filename = calloc (1, strlen (dbmName) + 3); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:139: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). kdat.dsize = strlen (kdat.dptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:141: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). vdat.dsize = strlen (vdat.dptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:148: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). kdat.dsize = strlen (kdat.dptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:150: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). vdat.dsize = strlen (vdat.dptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:157: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). kdat.dsize = strlen (kdat.dptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:159: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). vdat.dsize = strlen (vdat.dptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:166: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). kdat.dsize = strlen (kdat.dptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:168: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). vdat.dsize = strlen (vdat.dptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:175: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). kdat.dsize = strlen (kdat.dptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:177: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). vdat.dsize = strlen (vdat.dptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:184: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). kdat.dsize = strlen (kdat.dptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:186: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). vdat.dsize = strlen (vdat.dptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:193: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). kdat.dsize = strlen (kdat.dptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:195: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). vdat.dsize = strlen (vdat.dptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:202: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). kdat.dsize = strlen (kdat.dptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:204: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). vdat.dsize = strlen (vdat.dptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:226: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). n = strlen (key); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:249: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). if (strlen (key) == 0) data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:256: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 (key); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:282: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 (key) + strlen (cptr) < keylen) data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:282: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). if (strlen (key) + strlen (cptr) < keylen) data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:297:14: [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 (key); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:308: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). while (key[strlen (key) - 1] == '\\') data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:324: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). n = strlen (nkey); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:335: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). key[strlen (key) - 1] = '\0'; data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:341: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 (key); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:345: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 (key, " "); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:349: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). if (len + 1 + strlen (cptr) < keylen) data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.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). if (strlen (key) == 0) data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:401: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 (cptr) != 0) data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:409: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 (check_limit && strlen (key) > YPMAXRECORD) data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:414: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). kdat.dsize = strlen (key); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:417: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 (check_limit && strlen (cptr) > YPMAXRECORD) data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:422: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). vdat.dsize = strlen (cptr); data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:613: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 (optarg) <= MAXHOSTNAMELEN) data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:655: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 (masterName) == 0) data/nis-3.17.1/ypserv-2.19/makedbm/makedbm.c:668:9: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy (masterName, hp->h_name, MAXHOSTNAMELEN); data/nis-3.17.1/ypserv-2.19/mknetid/mknetid.c:213: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 (line[strlen (line) - 1] == '\n') data/nis-3.17.1/ypserv-2.19/mknetid/mknetid.c:214: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). line[strlen (line) - 1] = '\0'; data/nis-3.17.1/ypserv-2.19/mknetid/mknetid.c:250: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). while (host != NULL && strlen (host) == 0) data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:115: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 = 0; i < strlen(key); i++) data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:134: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). work->key = xmalloc(strlen(key)+1); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:136: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). work->val = xmalloc(strlen(domain)+2*strlen(uid)+strlen(gid)+100); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:136: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). work->val = xmalloc(strlen(domain)+2*strlen(uid)+strlen(gid)+100); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:136:56: [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). work->val = xmalloc(strlen(domain)+2*strlen(uid)+strlen(gid)+100); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:142: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). user_liste[hkey]->key = xmalloc(strlen(key)+1); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:145: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). user_liste[hkey]->val = xmalloc(strlen(domain)+2*strlen(uid)+strlen(gid)+10); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:145:56: [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). user_liste[hkey]->val = xmalloc(strlen(domain)+2*strlen(uid)+strlen(gid)+10); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:145:68: [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). user_liste[hkey]->val = xmalloc(strlen(domain)+2*strlen(uid)+strlen(gid)+10); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.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). for(i = 0; i < strlen(key); i++) data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:195: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). ptr = xmalloc(strlen(work->val)+strlen(grp)+5); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:195: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). ptr = xmalloc(strlen(work->val)+strlen(grp)+5); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:197:7: [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(ptr,","); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:216: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 = 0; i < strlen(host); i++) data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:243: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). work->val = xmalloc(strlen(host)*2+strlen(domain)+20); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:243: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). work->val = xmalloc(strlen(host)*2+strlen(domain)+20); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:252: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). host_liste[hkey]->val = xmalloc(strlen(host)*2+strlen(domain)+20); data/nis-3.17.1/ypserv-2.19/mknetid/netid_hash.c:252:54: [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). host_liste[hkey]->val = xmalloc(strlen(host)*2+strlen(domain)+20); data/nis-3.17.1/ypserv-2.19/revnetgroup/getnetgrent.c:170: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). realend = start + strlen (outval); data/nis-3.17.1/ypserv-2.19/revnetgroup/hash.c:71: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). int length = strlen (key); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:128: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). if (strlen (buffer) == 0) data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:135: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). while (buffer[strlen (buffer) - 1] == '\\') data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:139: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). s = fgets (&buffer[strlen (buffer) - 1], data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:140: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). BUFSIZE - strlen (buffer), debug_file); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:142: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). s = fgets (&buffer[strlen (buffer) - 1], data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:143: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). BUFSIZE - strlen (buffer), stdin); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:211: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). key = malloc (strlen (dat) + 3); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:216: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). key = malloc (strlen (dat) + strlen (domain) + 2); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:216: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). key = malloc (strlen (dat) + strlen (domain) + 2); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:231: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). buf2 = malloc (strlen (val) + 2); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:245: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). buf = malloc (strlen (work->key) + strlen (val) + 2); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:245: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). buf = malloc (strlen (work->key) + strlen (val) + 2); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:268: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). buf2 = malloc (strlen (val) + 2); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:282: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). buf = malloc (strlen (work->key) + strlen (val) + 2); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:282: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). buf = malloc (strlen (work->key) + strlen (val) + 2); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:347: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). work->key = malloc (strlen (key) + 1); data/nis-3.17.1/ypserv-2.19/revnetgroup/revnetgroup.c:348: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). work->val = malloc (strlen (val) + 1); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:215: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). logbuf = alloca (60 + strlen (yppw->newpw.pw_name) + data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:216: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). strlen (inet_ntoa (rqhost->sin_addr))); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:379: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). rootpass = alloca (strlen (spw->sp_pwdp) + 1); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:386: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). rootpass = alloca (strlen (pw->pw_passwd) + 1); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:764: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). logbuf = alloca (60 + strlen (yppw->newpw.pw_name)); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:865: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). msglen = strlen (yppw->newpw.pw_name) + strlen (yppw->oldpass) + 10; data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:865: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). msglen = strlen (yppw->newpw.pw_name) + strlen (yppw->oldpass) + 10; data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:867: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). msglen += strlen (password) + 3; data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:869: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). msglen += strlen (shell) + 3; data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:871: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). msglen += strlen (gcos) + 3; data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:882:3: [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 (parentmsg, " "); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:888:7: [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 (parentmsg, " "); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/update.c:895:7: [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 (parentmsg, " "); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:166: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). left = strlen (pbuf); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:309: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). path_passwd = malloc (strlen (optarg) + 8); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:312: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). path_shadow = malloc (strlen (optarg) + 8); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:361: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). path_passwd_tmp = malloc (strlen (path_passwd) + 5); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:368: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). path_passwd_old = malloc (strlen (path_passwd) + 5); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:377: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). path_shadow_tmp = malloc (strlen (path_shadow) + 5); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:384: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). path_shadow_old = malloc (strlen (path_shadow) + 5); data/nis-3.17.1/ypserv-2.19/rpc.yppasswdd/yppasswdd.c:442:7: [1] (access) umask: Ensure that umask is given most restrictive possible setting (e.g., 066 or 077) (CWE-732). umask(0); data/nis-3.17.1/ypserv-2.19/rpc.ypxfrd/ypxfrd.c:253:2: [1] (access) umask: Ensure that umask is given most restrictive possible setting (e.g., 066 or 077) (CWE-732). umask(0); data/nis-3.17.1/ypserv-2.19/rpc.ypxfrd/ypxfrd_server.c:56:18: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if ((len = read (file, &buf, XFRBLOCKSIZE)) != -1) data/nis-3.17.1/ypserv-2.19/rpc.ypxfrd/ypxfrd_server.c:182: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). if (strncmp (argp->xfrmap, argp->xfrmap_filename, strlen (argp->xfrmap)) data/nis-3.17.1/ypserv-2.19/rpc.ypxfrd/ypxfrd_server.c:186: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 (argp->xfrdomain) + strlen (argp->xfrmap_filename) + 2 data/nis-3.17.1/ypserv-2.19/rpc.ypxfrd/ypxfrd_server.c:186: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 (strlen (argp->xfrdomain) + strlen (argp->xfrmap_filename) + 2 data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:178:7: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy (hostname, param, sizeof (hostname)); data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:235: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). server = alloca (strlen (hp->h_name) + 1); data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:493: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 (YPMAPDIR) + strlen (domainname) + strlen (map) + 3 < MAXPATHLEN) data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:493: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). if (strlen (YPMAPDIR) + strlen (domainname) + strlen (map) + 3 < MAXPATHLEN) data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:493:49: [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 (YPMAPDIR) + strlen (domainname) + strlen (map) + 3 < MAXPATHLEN) data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:513: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). dkey.dsize = strlen (dkey.dptr); data/nis-3.17.1/ypserv-2.19/yphelper/yphelper.c:524:7: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy (val, dval.dptr, dval.dsize); data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:269: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 (YPMAPDIR) + strlen (DomainName) + strlen (current_map) + 3 < MAXPATHLEN) data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:269: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). if (strlen (YPMAPDIR) + strlen (DomainName) + strlen (current_map) + 3 < MAXPATHLEN) data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:269:49: [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 (YPMAPDIR) + strlen (DomainName) + strlen (current_map) + 3 < MAXPATHLEN) data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:289: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). dkey.dsize = strlen (dkey.dptr); data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:300:7: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy (val, dval.dptr, dval.dsize); data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:327: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). for (i = 0; i < strlen (val); ++i) data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:432: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 (host) < YPMAXPEER) data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:671: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). if (strlen(DomainName) == 0) data/nis-3.17.1/ypserv-2.19/yppush/yppush.c:696:4: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy (local_hostname, hp->h_name, MAXHOSTNAMELEN); data/nis-3.17.1/ypserv-2.19/ypserv/reg_slp.c:113: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). str = malloc (9 + strlen (dep->d_name)); data/nis-3.17.1/ypserv-2.19/ypserv/reg_slp.c:133: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). cp = malloc (strlen (str) + strlen (dep->d_name) + 2); data/nis-3.17.1/ypserv-2.19/ypserv/reg_slp.c:133: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). cp = malloc (strlen (str) + strlen (dep->d_name) + 2); data/nis-3.17.1/ypserv-2.19/ypserv/reg_slp.c:157: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). cp = malloc (strlen (str) + 2); data/nis-3.17.1/ypserv-2.19/ypserv/reg_slp.c:226: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). url = malloc(strlen(hname) + 19); data/nis-3.17.1/ypserv-2.19/ypserv/server.c:579: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). if ((size_t)val.dsize != strlen (argp->map_parms.peer) || data/nis-3.17.1/ypserv-2.19/ypserv/server.c:584:8: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy (buf, val.dptr, val.dsize); data/nis-3.17.1/ypserv-2.19/ypserv/server.c:656:9: [1] (access) umask: Ensure that umask is given most restrictive possible setting (e.g., 066 or 077) (CWE-732). umask (0); data/nis-3.17.1/ypserv-2.19/ypserv/server.c:1049: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). char *buf = alloca (strlen (domain) + strlen (map) + 3); data/nis-3.17.1/ypserv-2.19/ypserv/server.c:1049: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). char *buf = alloca (strlen (domain) + strlen (map) + 3); data/nis-3.17.1/ypserv-2.19/ypserv/server.c:1159: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). int len = strlen (map); data/nis-3.17.1/ypserv-2.19/ypserv/server.c:1170: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). int len = strlen (map); data/nis-3.17.1/ypserv-2.19/ypserv/ypserv.c:316: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). left = strlen (pbuf); data/nis-3.17.1/ypserv-2.19/ypserv/ypserv.c:489:7: [1] (access) umask: Ensure that umask is given most restrictive possible setting (e.g., 066 or 077) (CWE-732). umask (0); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:368: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 (path_ypdb) + strlen (target_domain) + strlen (map) + 3 < MAXPATHLEN) data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:368: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). if (strlen (path_ypdb) + strlen (target_domain) + strlen (map) + 3 < MAXPATHLEN) data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:368: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). if (strlen (path_ypdb) + strlen (target_domain) + strlen (map) + 3 < MAXPATHLEN) data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:377: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 (path_ypdb) + strlen (target_domain) + strlen (map) + 4 < MAXPATHLEN) data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:377: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). if (strlen (path_ypdb) + strlen (target_domain) + strlen (map) + 4 < MAXPATHLEN) data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:377: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). if (strlen (path_ypdb) + strlen (target_domain) + strlen (map) + 4 < MAXPATHLEN) data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:454: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). master_host = alloca (strlen (resp_master.peer) + 1); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:536: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). inKey.dsize = strlen (inKey.dptr); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:555:8: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy (d, inVal.dptr, inVal.dsize); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:597: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). outKey.dsize = strlen (outKey.dptr); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:599: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). outData.dsize = strlen (outData.dptr); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:609: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). outKey.dsize = strlen (outKey.dptr); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:611: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). outData.dsize = strlen (outData.dptr); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:626: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). req_key.key.keydat_len = strlen ("YP_INTERDOMAIN"); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:641: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). outKey.dsize = strlen (outKey.dptr); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:660: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). req_key.key.keydat_len = strlen ("YP_SECURE"); data/nis-3.17.1/ypserv-2.19/ypxfr/ypxfr.c:675: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). outKey.dsize = strlen (outKey.dptr); ANALYSIS SUMMARY: Hits = 584 Lines analyzed = 23915 in approximately 0.78 seconds (30534 lines/second) Physical Source Lines of Code (SLOC) = 18338 Hits@level = [0] 335 [1] 253 [2] 186 [3] 34 [4] 107 [5] 4 Hits@level+ = [0+] 919 [1+] 584 [2+] 331 [3+] 145 [4+] 111 [5+] 4 Hits/KSLOC@level+ = [0+] 50.1145 [1+] 31.8464 [2+] 18.05 [3+] 7.90708 [4+] 6.053 [5+] 0.218126 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.