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/tcp-wrappers-7.6.q/miscd.c
Examining data/tcp-wrappers-7.6.q/fromhost.c
Examining data/tcp-wrappers-7.6.q/strcasecmp.c
Examining data/tcp-wrappers-7.6.q/hosts_ctl.c
Examining data/tcp-wrappers-7.6.q/environ.c
Examining data/tcp-wrappers-7.6.q/patchlevel.h
Examining data/tcp-wrappers-7.6.q/ptx.c
Examining data/tcp-wrappers-7.6.q/vfprintf.c
Examining data/tcp-wrappers-7.6.q/tli-sequent.c
Examining data/tcp-wrappers-7.6.q/tli-sequent.h
Examining data/tcp-wrappers-7.6.q/diag.c
Examining data/tcp-wrappers-7.6.q/ncr.c
Examining data/tcp-wrappers-7.6.q/myvsyslog.c
Examining data/tcp-wrappers-7.6.q/mystdarg.h
Examining data/tcp-wrappers-7.6.q/setenv.c
Examining data/tcp-wrappers-7.6.q/inetcf.h
Examining data/tcp-wrappers-7.6.q/refuse.c
Examining data/tcp-wrappers-7.6.q/scaffold.h
Examining data/tcp-wrappers-7.6.q/tli.c
Examining data/tcp-wrappers-7.6.q/weak_symbols.c
Examining data/tcp-wrappers-7.6.q/eval.c
Examining data/tcp-wrappers-7.6.q/shell_cmd.c
Examining data/tcp-wrappers-7.6.q/percent_m.c
Examining data/tcp-wrappers-7.6.q/scaffold.c
Examining data/tcp-wrappers-7.6.q/tcpd.h
Examining data/tcp-wrappers-7.6.q/fix_options.c
Examining data/tcp-wrappers-7.6.q/socket.c
Examining data/tcp-wrappers-7.6.q/workarounds.c
Examining data/tcp-wrappers-7.6.q/clean_exit.c
Examining data/tcp-wrappers-7.6.q/hosts_access.c
Examining data/tcp-wrappers-7.6.q/misc.c
Examining data/tcp-wrappers-7.6.q/options.c
Examining data/tcp-wrappers-7.6.q/percent_x.c
Examining data/tcp-wrappers-7.6.q/rfc931.c
Examining data/tcp-wrappers-7.6.q/tcpd.c
Examining data/tcp-wrappers-7.6.q/update.c
Examining data/tcp-wrappers-7.6.q/fakelog.c
Examining data/tcp-wrappers-7.6.q/safe_finger.c
Examining data/tcp-wrappers-7.6.q/tcpdchk.c
Examining data/tcp-wrappers-7.6.q/tcpdmatch.c
Examining data/tcp-wrappers-7.6.q/try-from.c
Examining data/tcp-wrappers-7.6.q/inetcf.c

FINAL RESULTS:

data/tcp-wrappers-7.6.q/diag.c:41:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(fmt, "%s: %s, line %d: %s",
data/tcp-wrappers-7.6.q/diag.c:44:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(fmt, "%s: %s", tag, format);
data/tcp-wrappers-7.6.q/environ.c:17:14:  [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).
extern char *strcpy();
data/tcp-wrappers-7.6.q/environ.c:130: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(destination + l_name + 1, value);
data/tcp-wrappers-7.6.q/eval.c:49: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(request->user, unknown);
data/tcp-wrappers-7.6.q/eval.c:62: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(host->addr, unknown);
data/tcp-wrappers-7.6.q/eval.c:75: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(host->name, unknown);
data/tcp-wrappers-7.6.q/eval.c:136:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(both, "%s@%s", request->user, hostinfo);
data/tcp-wrappers-7.6.q/eval.c:153:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(both, "%s@%s", daemon, host);
data/tcp-wrappers-7.6.q/fakelog.c:37:5:  [4] (format) vprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    vprintf(percent_m(buf, fmt), ap);
data/tcp-wrappers-7.6.q/fakelog.c:46:14:  [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.
void VARARGS(syslog, int, severity)
data/tcp-wrappers-7.6.q/hosts_access.c:315:9:  [4] (buffer) fscanf:
  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.
	while (fscanf(fp, "%s", tok) == 1 && !(match = host_match(tok, host)))
data/tcp-wrappers-7.6.q/inetcf.c:88:6:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	    fprintf(stderr, percent_m(buf, "open %s: %m\n"), conf);
data/tcp-wrappers-7.6.q/inetcf.c:237:6:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	    sprintf(daemon, "%s/%s", REAL_DAEMON_DIR, arg0);
data/tcp-wrappers-7.6.q/inetcf.c:253:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(daemon, "%s/%s", REAL_DAEMON_DIR, arg0);
data/tcp-wrappers-7.6.q/inetcf.c:289: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(ip->name, name);
data/tcp-wrappers-7.6.q/miscd.c:114:5:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
    sprintf(path, "%s/miscd", REAL_DAEMON_DIR);
data/tcp-wrappers-7.6.q/miscd.c:116:12:  [4] (shell) execv:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
    (void) execv(path, argv);
data/tcp-wrappers-7.6.q/myvsyslog.c:29:5:  [4] (format) vsprintf:
  Potential format string problem (CWE-134). Make format string constant.
    vsprintf(obuf, percent_m(fbuf, format), ap);
data/tcp-wrappers-7.6.q/options.c:234:5:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
    sprintf(path, "%s/%s", value, eval_daemon(request));
data/tcp-wrappers-7.6.q/options.c:359:2:  [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("/bin/sh", "sh", "-c", value, (char *) 0);
data/tcp-wrappers-7.6.q/options.c:464:13:  [4] (shell) execl:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
	    (void) execl("/bin/sh", "sh", "-c", value, (char *) 0);
data/tcp-wrappers-7.6.q/percent_m.c:33: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(bp, strerror(errno));
data/tcp-wrappers-7.6.q/percent_m.c:36: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(bp, sys_errlist[errno]);
data/tcp-wrappers-7.6.q/safe_finger.c:197:9:  [4] (shell) execvp:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
	(void) execvp(argv[0], argv);
data/tcp-wrappers-7.6.q/scaffold.c:251: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(dest, unknown);
data/tcp-wrappers-7.6.q/scaffold.c:274:10:  [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).
	strrchr(strcpy(buf, path), '/')[0] = 0;
data/tcp-wrappers-7.6.q/setenv.c:32:5:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
    sprintf(cp, "%s=%s", name, value);
data/tcp-wrappers-7.6.q/shell_cmd.c:132:9:  [4] (shell) execl:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
	(void) execl("/bin/sh", "sh", "-c", command, (char *) 0);
data/tcp-wrappers-7.6.q/socket.c:74:9:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
        sprintf(dot_name, "%s.", name);
data/tcp-wrappers-7.6.q/socket.c:241: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(host->name, paranoid);	/* name is bad, clobber it */
data/tcp-wrappers-7.6.q/socket.c:335: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(host->name, paranoid);		/* name is bad, clobber it */
data/tcp-wrappers-7.6.q/socket.c:417: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(host->name, paranoid);		/* name is bad, clobber it */
data/tcp-wrappers-7.6.q/tcpd.c:66:2:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	strcpy(path, argv[0]);
data/tcp-wrappers-7.6.q/tcpd.c:69:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(path, "%s/%s", REAL_DAEMON_DIR, argv[0]);
data/tcp-wrappers-7.6.q/tcpd.c:133:12:  [4] (shell) execv:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
    (void) execv(path, argv);
data/tcp-wrappers-7.6.q/tcpdchk.c:303: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(buf, list);
data/tcp-wrappers-7.6.q/tcpdchk.c:324: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(buf, list);
data/tcp-wrappers-7.6.q/tcpdchk.c:352: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(buf, list);
data/tcp-wrappers-7.6.q/update.c:108: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(request->daemon, unknown);
data/tcp-wrappers-7.6.q/vfprintf.c:23:9:  [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.
int     vfprintf(fp, format, ap)
data/tcp-wrappers-7.6.q/vfprintf.c:91:12:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		count += fprintf(fp, fmt, va_arg(ap, char *));
data/tcp-wrappers-7.6.q/vfprintf.c:99:16:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		    count += fprintf(fp, fmt, va_arg(ap, long));
data/tcp-wrappers-7.6.q/vfprintf.c:101:16:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		    count += fprintf(fp, fmt, va_arg(ap, int));
data/tcp-wrappers-7.6.q/vfprintf.c:106:12:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		count += fprintf(fp, fmt, va_arg(ap, double));
data/tcp-wrappers-7.6.q/vfprintf.c:120:1:  [4] (format) vprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
vprintf(format, ap)
data/tcp-wrappers-7.6.q/vfprintf.c:124:13:  [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.
    return (vfprintf(stdout, format, ap));
data/tcp-wrappers-7.6.q/environ.c:65:9:  [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(name)
data/tcp-wrappers-7.6.q/environ.c:209:11:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	    cp = getenv(argv[0]);
data/tcp-wrappers-7.6.q/setenv.c:25:13:  [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/tcp-wrappers-7.6.q/setenv.c:28:25:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
    if (clobber == 0 && getenv(name) != 0)
data/tcp-wrappers-7.6.q/tcpdchk.c:128:17:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    while ((c = getopt(argc, argv, "adi:v")) != EOF) {
data/tcp-wrappers-7.6.q/tcpdmatch.c:93:18:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    while ((ch = getopt(argc, argv, "di:")) != EOF) {
data/tcp-wrappers-7.6.q/diag.c:38: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    fmt[BUFSIZ];
data/tcp-wrappers-7.6.q/environ.c:25:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
#define memcpy(d,s,l) bcopy(s,d,l)
data/tcp-wrappers-7.6.q/environ.c:25:23:  [2] (buffer) bcopy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
#define memcpy(d,s,l) bcopy(s,d,l)
data/tcp-wrappers-7.6.q/environ.c:27:14:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
extern char *memcpy();
data/tcp-wrappers-7.6.q/environ.c:143: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(new, old, old_len);
data/tcp-wrappers-7.6.q/eval.c:109:12:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    static char port[16];
data/tcp-wrappers-7.6.q/eval.c:111:9:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
        sprintf(port, "%u",
data/tcp-wrappers-7.6.q/eval.c:128:12:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    static char both[2 * STRING_LENGTH];
data/tcp-wrappers-7.6.q/eval.c:148:12:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    static char both[2 * STRING_LENGTH];
data/tcp-wrappers-7.6.q/fakelog.c:35: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    buf[BUFSIZ];
data/tcp-wrappers-7.6.q/fix_options.c:39:14:  [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.
    unsigned char optbuf[BUFFER_SIZE / 3], *cp;
data/tcp-wrappers-7.6.q/fix_options.c:40: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    lbuf[BUFFER_SIZE], *lp;
data/tcp-wrappers-7.6.q/fix_options.c:123:6:  [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(lp, " %2.2x", *cp);
data/tcp-wrappers-7.6.q/hosts_access.c:153: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    sv_list[BUFLEN];		/* becomes list of daemons */
data/tcp-wrappers-7.6.q/hosts_access.c:166: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 ((fp = fopen(table, "r")) != 0) {
data/tcp-wrappers-7.6.q/hosts_access.c:205:6:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	    char    cmd[BUFSIZ];
data/tcp-wrappers-7.6.q/hosts_access.c:310: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    tok[BUFSIZ];
data/tcp-wrappers-7.6.q/hosts_access.c:314: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 ((fp = fopen(path, "r")) != 0) {
data/tcp-wrappers-7.6.q/hosts_access.c:526: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).
    if ((mask_len = atoi(mask_tok)) < 0 || mask_len > 128)
data/tcp-wrappers-7.6.q/inetcf.c:54: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    name[1];
data/tcp-wrappers-7.6.q/inetcf.c:66: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    buf[BUFSIZ];
data/tcp-wrappers-7.6.q/inetcf.c:87:12:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	if ((fp = fopen(conf, "r")) == 0) {
data/tcp-wrappers-7.6.q/inetcf.c:92:37:  [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).
	for (i = 0; inet_files[i] && (fp = fopen(inet_files[i], "r")) == 0; i++)
data/tcp-wrappers-7.6.q/inetcf.c:172: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    daemon[BUFSIZ];
data/tcp-wrappers-7.6.q/misc.c:121: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).
    maskbits = atoi(str);
data/tcp-wrappers-7.6.q/miscd.c:51: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    path[MAXPATHNAMELEN];
data/tcp-wrappers-7.6.q/myvsyslog.c:26: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    fbuf[BUFSIZ];
data/tcp-wrappers-7.6.q/myvsyslog.c:27: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    obuf[3 * STRING_LENGTH];
data/tcp-wrappers-7.6.q/options.c:146: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    bf[BUFSIZ];
data/tcp-wrappers-7.6.q/options.c:227: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    path[MAXPATHNAMELEN];
data/tcp-wrappers-7.6.q/options.c:228: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    ibuf[BUFSIZ];
data/tcp-wrappers-7.6.q/options.c:229: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    obuf[2 * BUFSIZ];
data/tcp-wrappers-7.6.q/options.c:235: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 ((fp = fopen(path, "r")) != 0) {
data/tcp-wrappers-7.6.q/options.c:241: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(ibuf, "\r\n");
data/tcp-wrappers-7.6.q/percent_m.c:38: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(bp, "Unknown error %d", errno);
data/tcp-wrappers-7.6.q/percent_x.c:84: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(bp, expansion, expansion_len);
data/tcp-wrappers-7.6.q/ptx.c:87: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    buf[BUFSIZ];
data/tcp-wrappers-7.6.q/rfc931.c:91: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    user[256];			/* XXX */
data/tcp-wrappers-7.6.q/rfc931.c:92: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    buffer[512];		/* XXX */
data/tcp-wrappers-7.6.q/rfc931.c:158:6:  [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(&our_query_sin, our_sin, alen);
data/tcp-wrappers-7.6.q/rfc931.c:159:6:  [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(&rmt_query_sin, rmt_sin, alen);
data/tcp-wrappers-7.6.q/safe_finger.c:175:29:  [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 (fstat(i, &st) == -1 && open("/dev/null", 2) != i)
data/tcp-wrappers-7.6.q/scaffold.c:53:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char   *addr_list[1];
data/tcp-wrappers-7.6.q/scaffold.c:76: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(hb->host.h_addr_list[count], addr, hp->h_length);
data/tcp-wrappers-7.6.q/scaffold.c:126:12:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    static char *addr_list[2];
data/tcp-wrappers-7.6.q/scaffold.c:191: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(&sin, res->ai_addr, res->ai_addrlen);
data/tcp-wrappers-7.6.q/scaffold.c:194: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((char *) &sin.sin_addr, addr, sizeof(sin.sin_addr));
data/tcp-wrappers-7.6.q/scaffold.c:261: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    buf[BUFSIZ];
data/tcp-wrappers-7.6.q/shell_cmd.c:127:9:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    if (open("/dev/null", 2) != 0) {
data/tcp-wrappers-7.6.q/socket.c:63: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    dot_name[MAXHOSTNAMELEN + 1];
data/tcp-wrappers-7.6.q/socket.c:103: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    buf[BUFSIZ];
data/tcp-wrappers-7.6.q/socket.c:427: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    buf[BUFSIZ];
data/tcp-wrappers-7.6.q/tcpd.c:52: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    path[MAXPATHNAMELEN];
data/tcp-wrappers-7.6.q/tcpd.h:31: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    name[STRING_LENGTH];	/* access via eval_hostname(host) */
data/tcp-wrappers-7.6.q/tcpd.h:32: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    addr[STRING_LENGTH];	/* access via eval_hostaddr(host) */
data/tcp-wrappers-7.6.q/tcpd.h:46: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    user[STRING_LENGTH];	/* access via eval_user(request) */
data/tcp-wrappers-7.6.q/tcpd.h:47: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    daemon[STRING_LENGTH];	/* access via eval_daemon(request) */
data/tcp-wrappers-7.6.q/tcpd.h:48: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    pid[10];			/* access via eval_pid(request) */
data/tcp-wrappers-7.6.q/tcpdchk.c:224: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    sv_list[BUFLEN];		/* becomes list of daemons */
data/tcp-wrappers-7.6.q/tcpdchk.c:227: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    buf[BUFSIZ];
data/tcp-wrappers-7.6.q/tcpdchk.c:233:14:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    if (fp = fopen(table, "r")) {
data/tcp-wrappers-7.6.q/tcpdchk.c:298: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    buf[BUFLEN];
data/tcp-wrappers-7.6.q/tcpdchk.c:319: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    buf[BUFLEN];
data/tcp-wrappers-7.6.q/tcpdchk.c:347: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    buf[BUFLEN];
data/tcp-wrappers-7.6.q/tcpdchk.c:459: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    buf[BUFSIZ];
data/tcp-wrappers-7.6.q/tcpdchk.c:485:12:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	if ((fp = fopen(pat, "r")) != 0) {
data/tcp-wrappers-7.6.q/tcpdchk.c:506: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).
		|| ((mask_len = atoi(mask)) < 0 || mask_len > 128)))
data/tcp-wrappers-7.6.q/tcpdmatch.c:193:6:  [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_sin, res->ai_addr, res->ai_addrlen);
data/tcp-wrappers-7.6.q/tcpdmatch.c:196:6:  [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((char *) &server_sin.sin_addr, addr,
data/tcp-wrappers-7.6.q/tcpdmatch.c:269: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(&client_sin, res->ai_addr, res->ai_addrlen);
data/tcp-wrappers-7.6.q/tcpdmatch.c:298: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((char *) &client_sin.sin_addr, addr,
data/tcp-wrappers-7.6.q/tcpdmatch.c:337: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    buf[BUFSIZ];
data/tcp-wrappers-7.6.q/tli-sequent.c:134:6:  [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(&client,
data/tcp-wrappers-7.6.q/tli-sequent.c:150:12:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    static char buf[40];
data/tcp-wrappers-7.6.q/tli-sequent.c:154:6:  [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(buf, "Unknown TLI error %d", t_errno);
data/tcp-wrappers-7.6.q/tli-sequent.c:161:6:  [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(buf, "Unknown UNIX error %d", errno);
data/tcp-wrappers-7.6.q/tli.c:326:12:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    static char buf[40];
data/tcp-wrappers-7.6.q/tli.c:330:6:  [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(buf, "Unknown TLI error %d", t_errno);
data/tcp-wrappers-7.6.q/tli.c:337:6:  [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(buf, "Unknown UNIX error %d", errno);
data/tcp-wrappers-7.6.q/try-from.c:45: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    buf[BUFSIZ];
data/tcp-wrappers-7.6.q/update.c:109: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(request->pid, "%d", getpid());
data/tcp-wrappers-7.6.q/vfprintf.c:28: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    fmt[BUFSIZ];		/* format specifier */
data/tcp-wrappers-7.6.q/vfprintf.c:63: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(fmtp, "%d", va_arg(ap, int));
data/tcp-wrappers-7.6.q/vfprintf.c:73: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(fmtp, "%d", va_arg(ap, int));
data/tcp-wrappers-7.6.q/workarounds.c:205:12:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    static char mydomain[MAXHOSTNAMELEN];
data/tcp-wrappers-7.6.q/workarounds.c:244: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(*n_addr_list++, (char *) &addr, hp->h_length);
data/tcp-wrappers-7.6.q/workarounds.c:250:6:  [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(*n_addr_list++, *o_addr_list, hp->h_length);
data/tcp-wrappers-7.6.q/environ.c:18:14:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
extern char *strncpy();
data/tcp-wrappers-7.6.q/environ.c:43:13:  [1] (buffer) equal:
  Function does not check the second iterator for over-read conditions
  (CWE-126). This function is often discouraged by most C++ coding standards
  in favor of its safer alternatives provided since C++14. Consider using a
  form of this function that checks the second iterator before potentially
  overflowing it.
    char   *equal;
data/tcp-wrappers-7.6.q/environ.c:46: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).
    return ((equal == 0) ? strlen(name) : (equal - name));
data/tcp-wrappers-7.6.q/environ.c:80:22:  [1] (buffer) equal:
  Function does not check the second iterator for over-read conditions
  (CWE-126). This function is often discouraged by most C++ coding standards
  in favor of its safer alternatives provided since C++14. Consider using a
  form of this function that checks the second iterator before potentially
  overflowing it.
    char   *value = (equal ? equal : "");
data/tcp-wrappers-7.6.q/environ.c:80:30:  [1] (buffer) equal:
  Function does not check the second iterator for over-read conditions
  (CWE-126). This function is often discouraged by most C++ coding standards
  in favor of its safer alternatives provided since C++14. Consider using a
  form of this function that checks the second iterator before potentially
  overflowing it.
    char   *value = (equal ? equal : "");
data/tcp-wrappers-7.6.q/environ.c:117: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).
    l_nameval = l_name + strlen(value) + 1;
data/tcp-wrappers-7.6.q/environ.c:124:33:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    destination = (envp != 0 && strlen(*envp) >= l_nameval) ?
data/tcp-wrappers-7.6.q/environ.c:128:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
    strncpy(destination, name, l_name);
data/tcp-wrappers-7.6.q/eval.c:118:2:  [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(port, "0");
data/tcp-wrappers-7.6.q/hosts_access.c:170: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 (sv_list[strlen(sv_list) - 1] != '\n') {
data/tcp-wrappers-7.6.q/hosts_access.c:388: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(string) - strlen(tok);
data/tcp-wrappers-7.6.q/hosts_access.c:388: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).
	n = strlen(string) - strlen(tok);
data/tcp-wrappers-7.6.q/hosts_access.c:394: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).
    } else if (tok[(n = strlen(tok)) - 1] == '.') {	/* prefix */
data/tcp-wrappers-7.6.q/hosts_access.c:403:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen(tok);
data/tcp-wrappers-7.6.q/hosts_access.c:514:11:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    len = strlen(net_tok);
data/tcp-wrappers-7.6.q/inetcf.c:282:58:  [1] (buffer) strlen:
  Does not handle 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 inet_ent *) malloc(sizeof(struct inet_ent) + strlen(name));
data/tcp-wrappers-7.6.q/misc.c:38: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).
	got = strlen(ptr);
data/tcp-wrappers-7.6.q/miscd.c:56:5:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
    umask(DAEMON_UMASK);
data/tcp-wrappers-7.6.q/options.c:236:15:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	while ((ch = fgetc(fp)) == 0)
data/tcp-wrappers-7.6.q/options.c:243: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).
	    write(request->fd, obuf, strlen(obuf));
data/tcp-wrappers-7.6.q/options.c:320:12:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
    (void) umask(mask);
data/tcp-wrappers-7.6.q/percent_m.c:41: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).
	    bp += strlen(bp);
data/tcp-wrappers-7.6.q/rfc931.c:212:10:  [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.
		    && sscanf(buffer, "%u , %u : USERID :%*[^:]:%255s",
data/tcp-wrappers-7.6.q/safe_finger.c:107:17:  [1] (buffer) getchar:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    while ((c = getchar()) != EOF) {
data/tcp-wrappers-7.6.q/setenv.c:30:22:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    if ((cp = malloc(strlen(name) + strlen(value) + 2)) == 0)
data/tcp-wrappers-7.6.q/setenv.c:30:37:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    if ((cp = malloc(strlen(name) + strlen(value) + 2)) == 0)
data/tcp-wrappers-7.6.q/socket.c:71: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).
    if (strchr(name, '.') == 0 || strlen(name) >= MAXHOSTNAMELEN - 1) {
data/tcp-wrappers-7.6.q/tcpd.c:57:5:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
    umask(DAEMON_UMASK);
data/tcp-wrappers-7.6.q/tcpd.h:60:27:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
#define STRN_CPY(d,s,l)	{ strncpy((d),(s),(l)); (d)[(l)-1] = 0; }
data/tcp-wrappers-7.6.q/tcpdchk.c:237: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 (sv_list[strlen(sv_list) - 1] != '\n') {
data/tcp-wrappers-7.6.q/tcpdchk.c:382: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).
    } else if (pat[strlen(pat) - 1] == '.') {
data/tcp-wrappers-7.6.q/tcpdchk.c:416: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).
    } else if (pat[strlen(pat) - 1] == '.') {
data/tcp-wrappers-7.6.q/tcpdchk.c:439:11:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    len = strlen(pat);
data/tcp-wrappers-7.6.q/tcpdchk.c:522: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).
	if (pat[strlen(pat) - 1] == '.') {
data/tcp-wrappers-7.6.q/tcpdchk.c:532:17:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	} else if (pat[strlen(pat) - 1] != '.') {
data/tcp-wrappers-7.6.q/vfprintf.c:64: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).
		fmtp += strlen(fmtp);
data/tcp-wrappers-7.6.q/vfprintf.c:74: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).
		fmtp += strlen(fmtp);
data/tcp-wrappers-7.6.q/workarounds.c:92:28:  [1] (buffer) getc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    while (len > 1 && (c = getc(fp)) != EOF) {

ANALYSIS SUMMARY:

Hits = 178
Lines analyzed = 7123 in approximately 0.27 seconds (26261 lines/second)
Physical Source Lines of Code (SLOC) = 4580
Hits@level = [0]  58 [1]  38 [2]  87 [3]   6 [4]  47 [5]   0
Hits@level+ = [0+] 236 [1+] 178 [2+] 140 [3+]  53 [4+]  47 [5+]   0
Hits/KSLOC@level+ = [0+] 51.5284 [1+] 38.8646 [2+] 30.5677 [3+] 11.5721 [4+] 10.262 [5+]   0
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.