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/vsftpd-3.0.3/privops.h
Examining data/vsftpd-3.0.3/ftppolicy.h
Examining data/vsftpd-3.0.3/standalone.h
Examining data/vsftpd-3.0.3/seccompsandbox.c
Examining data/vsftpd-3.0.3/twoprocess.c
Examining data/vsftpd-3.0.3/main.c
Examining data/vsftpd-3.0.3/prelogin.h
Examining data/vsftpd-3.0.3/ftpcodes.h
Examining data/vsftpd-3.0.3/sysstr.c
Examining data/vsftpd-3.0.3/hash.c
Examining data/vsftpd-3.0.3/privsock.c
Examining data/vsftpd-3.0.3/oneprocess.c
Examining data/vsftpd-3.0.3/filestr.c
Examining data/vsftpd-3.0.3/hash.h
Examining data/vsftpd-3.0.3/parseconf.h
Examining data/vsftpd-3.0.3/opts.h
Examining data/vsftpd-3.0.3/twoprocess.h
Examining data/vsftpd-3.0.3/logging.h
Examining data/vsftpd-3.0.3/features.h
Examining data/vsftpd-3.0.3/ipaddrparse.c
Examining data/vsftpd-3.0.3/sslslave.c
Examining data/vsftpd-3.0.3/prelogin.c
Examining data/vsftpd-3.0.3/ptracesandbox.c
Examining data/vsftpd-3.0.3/tcpwrap.h
Examining data/vsftpd-3.0.3/ssl.c
Examining data/vsftpd-3.0.3/ftpdataio.h
Examining data/vsftpd-3.0.3/tcpwrap.c
Examining data/vsftpd-3.0.3/ftpcmdio.c
Examining data/vsftpd-3.0.3/seccompsandbox.h
Examining data/vsftpd-3.0.3/secutil.h
Examining data/vsftpd-3.0.3/sslslave.h
Examining data/vsftpd-3.0.3/defs.h
Examining data/vsftpd-3.0.3/filestr.h
Examining data/vsftpd-3.0.3/postprivparent.h
Examining data/vsftpd-3.0.3/netstr.h
Examining data/vsftpd-3.0.3/netstr.c
Examining data/vsftpd-3.0.3/secutil.c
Examining data/vsftpd-3.0.3/ascii.c
Examining data/vsftpd-3.0.3/sysstr.h
Examining data/vsftpd-3.0.3/strlist.h
Examining data/vsftpd-3.0.3/banner.c
Examining data/vsftpd-3.0.3/session.h
Examining data/vsftpd-3.0.3/ascii.h
Examining data/vsftpd-3.0.3/strlist.c
Examining data/vsftpd-3.0.3/port/cmsg_extras.h
Examining data/vsftpd-3.0.3/port/hpux_bogons.h
Examining data/vsftpd-3.0.3/port/solaris_bogons.h
Examining data/vsftpd-3.0.3/port/dirfd_extras.h
Examining data/vsftpd-3.0.3/port/porting_junk.h
Examining data/vsftpd-3.0.3/port/tru64_bogons.h
Examining data/vsftpd-3.0.3/port/irix_bogons.h
Examining data/vsftpd-3.0.3/port/aix_bogons.h
Examining data/vsftpd-3.0.3/secbuf.h
Examining data/vsftpd-3.0.3/ssl.h
Examining data/vsftpd-3.0.3/readwrite.h
Examining data/vsftpd-3.0.3/postprivparent.c
Examining data/vsftpd-3.0.3/banner.h
Examining data/vsftpd-3.0.3/postlogin.h
Examining data/vsftpd-3.0.3/dummyinc/openssl/ssl.h
Examining data/vsftpd-3.0.3/dummyinc/crypt.h
Examining data/vsftpd-3.0.3/dummyinc/utmpx.h
Examining data/vsftpd-3.0.3/dummyinc/security/pam_appl.h
Examining data/vsftpd-3.0.3/dummyinc/sys/sendfile.h
Examining data/vsftpd-3.0.3/dummyinc/sys/capability.h
Examining data/vsftpd-3.0.3/dummyinc/sys/prctl.h
Examining data/vsftpd-3.0.3/dummyinc/shadow.h
Examining data/vsftpd-3.0.3/secbuf.c
Examining data/vsftpd-3.0.3/filesize.h
Examining data/vsftpd-3.0.3/utility.c
Examining data/vsftpd-3.0.3/readwrite.c
Examining data/vsftpd-3.0.3/opts.c
Examining data/vsftpd-3.0.3/ls.h
Examining data/vsftpd-3.0.3/ipaddrparse.h
Examining data/vsftpd-3.0.3/ptracesandbox.h
Examining data/vsftpd-3.0.3/ftpcmdio.h
Examining data/vsftpd-3.0.3/ftpdataio.c
Examining data/vsftpd-3.0.3/oneprocess.h
Examining data/vsftpd-3.0.3/utility.h
Examining data/vsftpd-3.0.3/vsftpver.h
Examining data/vsftpd-3.0.3/ftppolicy.c
Examining data/vsftpd-3.0.3/privsock.h
Examining data/vsftpd-3.0.3/privops.c
Examining data/vsftpd-3.0.3/sysdeputil.h
Examining data/vsftpd-3.0.3/builddefs.h
Examining data/vsftpd-3.0.3/standalone.c
Examining data/vsftpd-3.0.3/features.c
Examining data/vsftpd-3.0.3/sysdeputil.c
Examining data/vsftpd-3.0.3/str.c
Examining data/vsftpd-3.0.3/str.h
Examining data/vsftpd-3.0.3/access.c
Examining data/vsftpd-3.0.3/access.h
Examining data/vsftpd-3.0.3/parseconf.c
Examining data/vsftpd-3.0.3/postlogin.c
Examining data/vsftpd-3.0.3/tunables.c
Examining data/vsftpd-3.0.3/tunables.h
Examining data/vsftpd-3.0.3/ls.c
Examining data/vsftpd-3.0.3/sysutil.c
Examining data/vsftpd-3.0.3/sysutil.h
Examining data/vsftpd-3.0.3/logging.c

FINAL RESULTS:

data/vsftpd-3.0.3/sysutil.c:1557:10:  [5] (race) chmod:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchmod( ) instead.
  return chmod(p_filename, mode);
data/vsftpd-3.0.3/sysutil.c:1617:12:  [5] (race) readlink:
  This accepts filename arguments; if an attacker can move those files or
  change the link content, a race condition results. Also, it does not
  terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach.
  retval = readlink(p_filename, p_dest, bufsiz - 1);
data/vsftpd-3.0.3/dummyinc/crypt.h:4:14:  [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.
extern char* crypt(const char*, const char*);
data/vsftpd-3.0.3/sysdeputil.c:299:19:  [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.
      p_crypted = crypt(str_getbuf(p_pass_str), p_spwd->sp_pwdp);
data/vsftpd-3.0.3/sysdeputil.c:307: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.
  p_crypted = crypt(str_getbuf(p_pass_str), p_pwd->pw_passwd);
data/vsftpd-3.0.3/sysutil.c:1028: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(resolved, resolved_dir);
data/vsftpd-3.0.3/sysutil.c:1031: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(resolved+dir_len+1, filename);
data/vsftpd-3.0.3/sysutil.c:1305:16:  [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.
  int retval = access(p_filename, W_OK);
data/vsftpd-3.0.3/sysutil.c:995:29:  [3] (buffer) realpath:
  This function does not protect against buffer overflows, and some
  implementations can overflow internally (CWE-120/CWE-785!). Ensure that the
  destination buffer is at least of size MAXPATHLEN, andto protect against
  implementation problems, the input argument should also be checked to
  ensure it is no larger than MAXPATHLEN.
    char *const  resolved = realpath(path, NULL);
data/vsftpd-3.0.3/sysutil.c:1008:22:  [3] (buffer) realpath:
  This function does not protect against buffer overflows, and some
  implementations can overflow internally (CWE-120/CWE-785!). Ensure that the
  destination buffer is at least of size MAXPATHLEN, andto protect against
  implementation problems, the input argument should also be checked to
  ensure it is no larger than MAXPATHLEN.
      resolved_dir = realpath(".", NULL);
data/vsftpd-3.0.3/sysutil.c:1015:22:  [3] (buffer) realpath:
  This function does not protect against buffer overflows, and some
  implementations can overflow internally (CWE-120/CWE-785!). Ensure that the
  destination buffer is at least of size MAXPATHLEN, andto protect against
  implementation problems, the input argument should also be checked to
  ensure it is no larger than MAXPATHLEN.
      resolved_dir = realpath(original_dir, NULL);
data/vsftpd-3.0.3/sysutil.c:2439:5:  [3] (random) srand:
  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.
    srand((unsigned)tv.tv_usec);
data/vsftpd-3.0.3/sysutil.c:2572:16:  [3] (misc) chroot:
  chroot can be very helpful, but is hard to use correctly (CWE-250, CWE-22).
  Make sure the program immediately chdir("/"), closes file descriptors, and
  drops root privileges, and that all necessary files (and no more!) are in
  the new root.
  int retval = chroot(p_root_path);
data/vsftpd-3.0.3/sysutil.c:2764:10:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
  return getenv(p_var);
data/vsftpd-3.0.3/ipaddrparse.c:64: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 items[4];
data/vsftpd-3.0.3/postlogin.c:976: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.
  unsigned char vals[6];
data/vsftpd-3.0.3/ptracesandbox.c:570: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(p_out, &pt_ret, sizeof(long));
data/vsftpd-3.0.3/ptracesandbox.c:574: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(p_out, &pt_ret, len);
data/vsftpd-3.0.3/str.c:383: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 ministr[2];
data/vsftpd-3.0.3/str.c:393: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 ministr[2];
data/vsftpd-3.0.3/str.c:461: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 look_str[2];
data/vsftpd-3.0.3/sysdeputil.c:1016: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).
  s_zero_fd = open("/dev/zero", O_RDWR);
data/vsftpd-3.0.3/sysdeputil.c:1045: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 cmsgbuf[CMSG_SPACE(sizeof(send_fd))];
data/vsftpd-3.0.3/sysdeputil.c:1082: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 cmsgbuf[CMSG_SPACE(sizeof(recv_fd))];
data/vsftpd-3.0.3/sysutil.c:799:10:  [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).
  return atoi(p_str);
data/vsftpd-3.0.3/sysutil.c:836: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 ulong_buf[32];
data/vsftpd-3.0.3/sysutil.c:844: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 filesize_buf[32];
data/vsftpd-3.0.3/sysutil.c:861: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 double_buf[32];
data/vsftpd-3.0.3/sysutil.c:869: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 octal_buf[32];
data/vsftpd-3.0.3/sysutil.c:1092:18:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  return (char *)memcpy(new, p_str, p_len);
data/vsftpd-3.0.3/sysutil.c:1119: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(p_dest, p_src, size);
data/vsftpd-3.0.3/sysutil.c:1232:10:  [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).
  return open(p_filename, vsf_sysutil_translate_openmode(mode) | O_NONBLOCK);
data/vsftpd-3.0.3/sysutil.c:1239:10:  [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).
  return open(p_filename, O_CREAT | O_EXCL | O_WRONLY | O_APPEND,
data/vsftpd-3.0.3/sysutil.c:1246:10:  [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).
  return open(p_filename, O_CREAT | O_WRONLY | O_NONBLOCK, mode);
data/vsftpd-3.0.3/sysutil.c:1253:10:  [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).
  return open(p_filename, O_CREAT | O_WRONLY | O_NONBLOCK | O_APPEND, mode);
data/vsftpd-3.0.3/sysutil.c:1383: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 perms[11];
data/vsftpd-3.0.3/sysutil.c:1422: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 datebuf[64];
data/vsftpd-3.0.3/sysutil.c:1455: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 datebuf[15];
data/vsftpd-3.0.3/sysutil.c:1523: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 intbuf[32];
data/vsftpd-3.0.3/sysutil.c:2130: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 pattern[12] =
data/vsftpd-3.0.3/sysutil.c:2148: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 ret[16] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0xFF, 0xFF };
data/vsftpd-3.0.3/sysutil.c:2282: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 inaddr_buf[64];
data/vsftpd-3.0.3/sysutil.c:2609: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("/dev/null", O_RDWR, 0)) < 0)
data/vsftpd-3.0.3/sysutil.c:2630: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 tzbuf[sizeof("+HHMM!")];
data/vsftpd-3.0.3/sysutil.c:2648: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 envtz[sizeof("TZ=UTC-hh:mm")];
data/vsftpd-3.0.3/sysutil.c:2691: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 datebuf[64];
data/vsftpd-3.0.3/sysutil.c:2807: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 yr[5];
data/vsftpd-3.0.3/sysutil.c:2808: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 mon[3];
data/vsftpd-3.0.3/sysutil.c:2809: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 day[3];
data/vsftpd-3.0.3/sysutil.c:2819: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 hr[3];
data/vsftpd-3.0.3/sysutil.c:2820: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 mins[3];
data/vsftpd-3.0.3/sysutil.c:2821: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 sec[3];
data/vsftpd-3.0.3/sysutil.c:364:18:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    int retval = read(fd, p_buf, size);
data/vsftpd-3.0.3/sysutil.c:1021: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).
    size_t  dir_len = strlen(resolved_dir);
data/vsftpd-3.0.3/sysutil.c:1027:38:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    resolved = (char*)malloc(dir_len+strlen(filename)+2);
data/vsftpd-3.0.3/sysutil.c:1068:16:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
  size_t ret = strlen(p_text);
data/vsftpd-3.0.3/sysutil.c:1129:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
  strncpy(p_dest, p_src, maxsize);
data/vsftpd-3.0.3/sysutil.c:2589:10:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
  (void) umask(s_current_umask);
data/vsftpd-3.0.3/sysutil.h:307:41:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
void vsf_sysutil_set_umask(unsigned int umask);

ANALYSIS SUMMARY:

Hits = 59
Lines analyzed = 20330 in approximately 0.43 seconds (46822 lines/second)
Physical Source Lines of Code (SLOC) = 16632
Hits@level = [0]  17 [1]   7 [2]  38 [3]   6 [4]   6 [5]   2
Hits@level+ = [0+]  76 [1+]  59 [2+]  52 [3+]  14 [4+]   8 [5+]   2
Hits/KSLOC@level+ = [0+] 4.5695 [1+] 3.54738 [2+] 3.1265 [3+] 0.841751 [4+] 0.481 [5+] 0.12025
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.