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/gkdebconf-2.1.0/src/cbs.c
Examining data/gkdebconf-2.1.0/src/cbs.h
Examining data/gkdebconf-2.1.0/src/config.c
Examining data/gkdebconf-2.1.0/src/config.h
Examining data/gkdebconf-2.1.0/src/debconf.c
Examining data/gkdebconf-2.1.0/src/debconf.h
Examining data/gkdebconf-2.1.0/src/defines.h
Examining data/gkdebconf-2.1.0/src/files.c
Examining data/gkdebconf-2.1.0/src/files.h
Examining data/gkdebconf-2.1.0/src/interface.c
Examining data/gkdebconf-2.1.0/src/interface.h
Examining data/gkdebconf-2.1.0/src/main.c
Examining data/gkdebconf-2.1.0/system.h

FINAL RESULTS:

data/gkdebconf-2.1.0/src/debconf.c:305: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 (frontend, user_data);
data/gkdebconf-2.1.0/src/debconf.c:348:7:  [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 (gkterm, PREFIX);
data/gkdebconf-2.1.0/src/debconf.c:349:7:  [4] (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).
      strcat (gkterm, GKTERM);
data/gkdebconf-2.1.0/src/debconf.c:369:12:  [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.
  cmdret = system (call_command);
data/gkdebconf-2.1.0/src/files.c:146:13:  [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.
  if ((fd = popen(cmd->str, "r")) == NULL)
data/gkdebconf-2.1.0/src/files.c:159:11:  [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(s, str + 9);
data/gkdebconf-2.1.0/src/interface.c:638:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
  sprintf (msg,
data/gkdebconf-2.1.0/system.h:182:9:  [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.
#define getopt system_getopt
data/gkdebconf-2.1.0/system.h:184:8:  [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.
#undef getopt
data/gkdebconf-2.1.0/system.h:186: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/gkdebconf-2.1.0/src/interface.c:636: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 msg[1024];
data/gkdebconf-2.1.0/src/files.c:96: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).
          bzero (point, strlen(point));
data/gkdebconf-2.1.0/src/files.c:160: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).
          if (s[strlen(s)-1] == '\n')
data/gkdebconf-2.1.0/src/files.c:161: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).
            s[strlen(s)-1] = '\0';
data/gkdebconf-2.1.0/src/files.c:178: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).
                  int str_len = strlen(str);
data/gkdebconf-2.1.0/src/files.c:228: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).
      if (strlen(data) != 0)
data/gkdebconf-2.1.0/src/interface.c:577: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).
      if (strlen(package) == 0)
data/gkdebconf-2.1.0/system.h:221: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).
# define NLENGTH(direct) (strlen((direct)->d_name))

ANALYSIS SUMMARY:

Hits = 18
Lines analyzed = 2204 in approximately 0.08 seconds (29332 lines/second)
Physical Source Lines of Code (SLOC) = 1296
Hits@level = [0]   3 [1]   7 [2]   1 [3]   3 [4]   7 [5]   0
Hits@level+ = [0+]  21 [1+]  18 [2+]  11 [3+]  10 [4+]   7 [5+]   0
Hits/KSLOC@level+ = [0+] 16.2037 [1+] 13.8889 [2+] 8.48765 [3+] 7.71605 [4+] 5.40123 [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.