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/nmzmail-1.1/src/util.h
Examining data/nmzmail-1.1/src/nmzmail.c
Examining data/nmzmail-1.1/src/util.c

FINAL RESULTS:

data/nmzmail-1.1/src/nmzmail.c:289:2:  [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.
	execvp("mknmz", args);
data/nmzmail-1.1/src/util.c:48:3:  [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.
		execvp(file, argv);
data/nmzmail-1.1/src/nmzmail.c:45: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.
	home = getenv("HOME");
data/nmzmail-1.1/src/nmzmail.c:54:14:  [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, "b:r:in:")) != -1) {
data/nmzmail-1.1/src/nmzmail.c:39: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  nmz_base[BUF_LEN];
data/nmzmail-1.1/src/nmzmail.c:40: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  nmz_result[BUF_LEN];
data/nmzmail-1.1/src/nmzmail.c:41: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  nmz_index[BUF_LEN];
data/nmzmail-1.1/src/nmzmail.c:42: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 *mail_dirs[MAX_MAIL_DIRS];
data/nmzmail-1.1/src/nmzmail.c:66: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).
				result_limit = atoi(optarg);
data/nmzmail-1.1/src/nmzmail.c:130: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  nmz_history[BUF_LEN];
data/nmzmail-1.1/src/nmzmail.c:153: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[BUF_LEN];
data/nmzmail-1.1/src/nmzmail.c:197: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[BUF_LEN];
data/nmzmail-1.1/src/nmzmail.c:218: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[BUF_LEN], buf1[BUF_LEN], result_limit_str[BUF_LEN];
data/nmzmail-1.1/src/nmzmail.c:221: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 *args[32];
data/nmzmail-1.1/src/nmzmail.c:272: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 *args[MAX_MAIL_DIRS + 10];
data/nmzmail-1.1/src/nmzmail.c:57:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
				strncpy(nmz_base, optarg, sizeof(nmz_base));
data/nmzmail-1.1/src/nmzmail.c:96:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(nmz_result, result, sizeof(nmz_result));

ANALYSIS SUMMARY:

Hits = 17
Lines analyzed = 373 in approximately 0.02 seconds (18770 lines/second)
Physical Source Lines of Code (SLOC) = 292
Hits@level = [0]  18 [1]   2 [2]  11 [3]   2 [4]   2 [5]   0
Hits@level+ = [0+]  35 [1+]  17 [2+]  15 [3+]   4 [4+]   2 [5+]   0
Hits/KSLOC@level+ = [0+] 119.863 [1+] 58.2192 [2+] 51.3699 [3+] 13.6986 [4+] 6.84932 [5+]   0
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.