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/wuzzah-0.53/hashtable/hashtable.c
Examining data/wuzzah-0.53/hashtable/hashtable.h
Examining data/wuzzah-0.53/buddies.c
Examining data/wuzzah-0.53/buddies.h
Examining data/wuzzah-0.53/common.h
Examining data/wuzzah-0.53/includes.h
Examining data/wuzzah-0.53/write.c
Examining data/wuzzah-0.53/write.h
Examining data/wuzzah-0.53/getopt/getopt.c
Examining data/wuzzah-0.53/getopt/getopt.h
Examining data/wuzzah-0.53/getopt/getopt1.c
Examining data/wuzzah-0.53/utmpx/utmpx-wrapper.h
Examining data/wuzzah-0.53/utmpx/utmpx-wrapper.c
Examining data/wuzzah-0.53/event.c
Examining data/wuzzah-0.53/event.h
Examining data/wuzzah-0.53/wuzzah.c

FINAL RESULTS:

data/wuzzah-0.53/event.c:40:16:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
		cmd_result = system(command);
data/wuzzah-0.53/write.c:29:7:  [4] (shell) popen:
  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.
	dest=popen(cmd, "w");
data/wuzzah-0.53/getopt/getopt.c:210: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/wuzzah-0.53/getopt/getopt.c:401: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/wuzzah-0.53/getopt/getopt.c:967: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/wuzzah-0.53/getopt/getopt.c:997: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/wuzzah-0.53/getopt/getopt.h:104: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/wuzzah-0.53/getopt/getopt.h:106: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/wuzzah-0.53/getopt/getopt.h:108: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/wuzzah-0.53/getopt/getopt.h:120: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/wuzzah-0.53/getopt/getopt.h:121: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/wuzzah-0.53/getopt/getopt1.c:66: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/wuzzah-0.53/getopt/getopt1.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, "abc:d:0123456789",
data/wuzzah-0.53/wuzzah.c:119: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.
		c=getopt_long(ac, av, "ac:f:Fhi:m:nopqs:u:vw", 
data/wuzzah-0.53/wuzzah.c:145: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.
		homedir=getenv("HOME");
data/wuzzah-0.53/buddies.c:51: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).
	else buds=fopen(fn, "r");
data/wuzzah-0.53/buddies.c:163: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(recptr->u, u,
data/wuzzah-0.53/buddies.c:241: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(hname, 
data/wuzzah-0.53/buddies.c:254: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(hname, 
data/wuzzah-0.53/buddies.c:260: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(&in, 
data/wuzzah-0.53/getopt/getopt.c:329: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/wuzzah-0.53/getopt/getopt.c:441: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/wuzzah-0.53/utmpx/utmpx-wrapper.c:7: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).
	ut_fd = open(_PATH_UTMP, O_RDONLY);
data/wuzzah-0.53/write.c:9:5:  [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(totalpath, O_WRONLY);
data/wuzzah-0.53/wuzzah.c:127:34:  [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).
		case 'i': conf->sleep_interval=atoi(optarg); break;
data/wuzzah-0.53/buddies.c:8: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).
	for(i=0;i<strlen(c);i++){
data/wuzzah-0.53/buddies.c:19: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).
	for(i=0;i<strlen(c);i++){
data/wuzzah-0.53/buddies.c:66: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).
		len=strlen(line_buf);
data/wuzzah-0.53/buddies.c:221: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).
	for(i=0;i<strlen(fmt_string);i++){
data/wuzzah-0.53/buddies.c:223: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).
		else if(i < strlen(fmt_string) - 1){
data/wuzzah-0.53/buddies.c:301:6:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	amt=read(buf_fd[0], out_str, sizeof(char)*(buf_size));
data/wuzzah-0.53/buddies.c:308: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).
	int i=0, num_args=1, cmd_len=strlen(cmdline);
data/wuzzah-0.53/buddies.c:345: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).
	len=strlen(line_buf);
data/wuzzah-0.53/getopt/getopt.c:234: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/wuzzah-0.53/getopt/getopt.c:432: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/wuzzah-0.53/getopt/getopt.c:656: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/wuzzah-0.53/getopt/getopt.c:680: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/wuzzah-0.53/getopt/getopt.c:710: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/wuzzah-0.53/getopt/getopt.c:726: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/wuzzah-0.53/getopt/getopt.c:731: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/wuzzah-0.53/getopt/getopt.c:842: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/wuzzah-0.53/getopt/getopt.c:865: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/wuzzah-0.53/getopt/getopt.c:885: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/wuzzah-0.53/getopt/getopt.c:899: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/wuzzah-0.53/getopt/getopt.c:903: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/wuzzah-0.53/utmpx/utmpx-wrapper.c:12:17:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	int amt_read = read(ut_fd, &cur, sizeof(STRUCT_UTMPX));
data/wuzzah-0.53/utmpx/utmpx-wrapper.h:69: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).
#      define UTMPX_HOSTLEN(u) (strlen((u)->ut_host))
data/wuzzah-0.53/utmpx/utmpx-wrapper.h:73:31:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
#    define UTMPX_HOSTLEN(u) (strlen("hostname not retrievable"))
data/wuzzah-0.53/utmpx/utmpx-wrapper.h:94: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).
#      define UTMPX_HOSTLEN(u) (strlen((u)->ut_host))
data/wuzzah-0.53/utmpx/utmpx-wrapper.h:98:31:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
#    define UTMPX_HOSTLEN(u) (strlen("hostname not retrievable"))
data/wuzzah-0.53/write.c:4: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).
	int fd, len=strlen(path)+strlen(_PATH_DEV)+1;
data/wuzzah-0.53/write.c:4: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).
	int fd, len=strlen(path)+strlen(_PATH_DEV)+1;
data/wuzzah-0.53/write.c:7:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(totalpath, _PATH_DEV, strlen(_PATH_DEV)+1);
data/wuzzah-0.53/write.c:7: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).
	strncpy(totalpath, _PATH_DEV, strlen(_PATH_DEV)+1);
data/wuzzah-0.53/write.c:8:2:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
	strncat(totalpath, path, strlen(path)+1);
data/wuzzah-0.53/write.c:8: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).
	strncat(totalpath, path, strlen(path)+1);
data/wuzzah-0.53/write.c:18: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).
	int cmdlen=(strlen("write ")+strlen(user)+1+strlen(line)+1);
data/wuzzah-0.53/write.c:18: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).
	int cmdlen=(strlen("write ")+strlen(user)+1+strlen(line)+1);
data/wuzzah-0.53/write.c:18: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).
	int cmdlen=(strlen("write ")+strlen(user)+1+strlen(line)+1);
data/wuzzah-0.53/wuzzah.c:149: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(homedir)+1+strlen(g_default_infile); // 1 for '/'
data/wuzzah-0.53/wuzzah.c:149:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			len=strlen(homedir)+1+strlen(g_default_infile); // 1 for '/'
data/wuzzah-0.53/wuzzah.c:151:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			strncpy(conf->infile, homedir, strlen(homedir)+1);
data/wuzzah-0.53/wuzzah.c:151: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).
			strncpy(conf->infile, homedir, strlen(homedir)+1);
data/wuzzah-0.53/wuzzah.c:152:4:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings. Risk is low because the source is a
  constant character.
			strncat(conf->infile, "/", 1);
data/wuzzah-0.53/wuzzah.c:153:4:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
			strncat(conf->infile, g_default_infile,
data/wuzzah-0.53/wuzzah.c:154: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).
				strlen(g_default_infile));
data/wuzzah-0.53/wuzzah.c:167: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).
	int c=0, i=0, j=0, num_args=1, len=strlen(str), procd_str_pipe[2];
data/wuzzah-0.53/wuzzah.c:261:5:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		c=fgetc(p_read);
data/wuzzah-0.53/wuzzah.c:264:6:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
			c=fgetc(p_read);
data/wuzzah-0.53/wuzzah.c:282:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
		strncpy(g_config.whoami, "dumbass", 8);
data/wuzzah-0.53/wuzzah.c:284:47:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		g_config.whoami=(char*)malloc(sizeof(char)*(strlen(pwd->pw_name)+1));
data/wuzzah-0.53/wuzzah.c:285:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(g_config.whoami, pwd->pw_name, (strlen(pwd->pw_name)+1));
data/wuzzah-0.53/wuzzah.c:285: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).
		strncpy(g_config.whoami, pwd->pw_name, (strlen(pwd->pw_name)+1));
data/wuzzah-0.53/wuzzah.c:290: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).
	int i=0, len=strlen(line);
data/wuzzah-0.53/wuzzah.c:294: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).
	buf=(char*)malloc(sizeof(char)*(strlen(line)+1));
data/wuzzah-0.53/wuzzah.c:298:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			strncpy(buf, head, i);
data/wuzzah-0.53/wuzzah.c:301:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			strncpy(buf, head, strlen(head));
data/wuzzah-0.53/wuzzah.c:301: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).
			strncpy(buf, head, strlen(head));
data/wuzzah-0.53/wuzzah.c:302: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).
			buf[strlen(head)]='\0';

ANALYSIS SUMMARY:

Hits = 79
Lines analyzed = 2723 in approximately 0.09 seconds (29584 lines/second)
Physical Source Lines of Code (SLOC) = 1830
Hits@level = [0]  79 [1]  54 [2]  10 [3]  13 [4]   2 [5]   0
Hits@level+ = [0+] 158 [1+]  79 [2+]  25 [3+]  15 [4+]   2 [5+]   0
Hits/KSLOC@level+ = [0+] 86.3388 [1+] 43.1694 [2+] 13.6612 [3+] 8.19672 [4+] 1.0929 [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.