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/netkit-rwall-0.17/version.h
Examining data/netkit-rwall-0.17/rpc.rwalld/daemon.c
Examining data/netkit-rwall-0.17/rpc.rwalld/daemon.h
Examining data/netkit-rwall-0.17/rpc.rwalld/rwalld.c
Examining data/netkit-rwall-0.17/rwall/rwall.c

FINAL RESULTS:

data/netkit-rwall-0.17/rpc.rwalld/rwalld.c:184:9:  [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.
		pfp = popen(WALL_CMD, "w");
data/netkit-rwall-0.17/rwall/rwall.c:129:8:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	(void)strcpy(tmpname, _PATH_TMP);
data/netkit-rwall-0.17/rwall/rwall.c:137:15:  [4] (misc) getlogin:
  It's often easy to fool getlogin. Sometimes it does not work at all,
  because some program messed up the utmp file. Often, it gives only the
  first 8 characters of the login name. The user currently logged in on the
  controlling tty of our program need not be the user who started it. Avoid
  getlogin() for security-related purposes (CWE-807). Use getpwuid(geteuid())
  and extract the desired information instead.
	if (!(whom = getlogin()))
data/netkit-rwall-0.17/rpc.rwalld/daemon.c:63:7:  [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(_PATH_DEVNULL, O_RDWR, 0);
data/netkit-rwall-0.17/rwall/rwall.c:127: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 hostname[MAXHOSTNAMELEN], lbuf[100], tmpname[32];
data/netkit-rwall-0.17/rwall/rwall.c:130:8:  [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.
	(void)strcat(tmpname, "/wall.XXXXXX");
data/netkit-rwall-0.17/rwall/rwall.c:131:13:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
	if (!(fd = mkstemp(tmpname)) || !(fp = fdopen(fd, "r+"))) {

ANALYSIS SUMMARY:

Hits = 7
Lines analyzed = 493 in approximately 0.07 seconds (7420 lines/second)
Physical Source Lines of Code (SLOC) = 295
Hits@level = [0]  16 [1]   0 [2]   4 [3]   0 [4]   3 [5]   0
Hits@level+ = [0+]  23 [1+]   7 [2+]   7 [3+]   3 [4+]   3 [5+]   0
Hits/KSLOC@level+ = [0+] 77.9661 [1+] 23.7288 [2+] 23.7288 [3+] 10.1695 [4+] 10.1695 [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.