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/apg-2.2.3.dfsg.1/apgbfm.c
Examining data/apg-2.2.3.dfsg.1/bloom.c
Examining data/apg-2.2.3.dfsg.1/bloom.h
Examining data/apg-2.2.3.dfsg.1/cast/cast.c
Examining data/apg-2.2.3.dfsg.1/cast/cast.h
Examining data/apg-2.2.3.dfsg.1/cast/cast_sboxes.h
Examining data/apg-2.2.3.dfsg.1/errors.c
Examining data/apg-2.2.3.dfsg.1/errs.h
Examining data/apg-2.2.3.dfsg.1/getopt.c
Examining data/apg-2.2.3.dfsg.1/getopt.h
Examining data/apg-2.2.3.dfsg.1/owntypes.h
Examining data/apg-2.2.3.dfsg.1/pronpass.c
Examining data/apg-2.2.3.dfsg.1/pronpass.h
Examining data/apg-2.2.3.dfsg.1/randpass.c
Examining data/apg-2.2.3.dfsg.1/randpass.h
Examining data/apg-2.2.3.dfsg.1/sha/sha.c
Examining data/apg-2.2.3.dfsg.1/sha/sha.h
Examining data/apg-2.2.3.dfsg.1/restrict.h
Examining data/apg-2.2.3.dfsg.1/rnd.h
Examining data/apg-2.2.3.dfsg.1/smbl.h
Examining data/apg-2.2.3.dfsg.1/convert.c
Examining data/apg-2.2.3.dfsg.1/convert.h
Examining data/apg-2.2.3.dfsg.1/bfconvert/bfconvert.c
Examining data/apg-2.2.3.dfsg.1/rnd.c
Examining data/apg-2.2.3.dfsg.1/apg.c
Examining data/apg-2.2.3.dfsg.1/restrict.c

FINAL RESULTS:

data/apg-2.2.3.dfsg.1/apg.c:376:8:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	      fprintf (stdout, (" %s"), spell_pass_string);
data/apg-2.2.3.dfsg.1/apg.c:416:4:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	  fprintf (stdout, (" %s"), spell_pass_string);
data/apg-2.2.3.dfsg.1/apg.c:486:8:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	      fprintf (stdout, (" %s"), spell_pass_string);
data/apg-2.2.3.dfsg.1/apg.c:521:4:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	  fprintf (stdout, (" %s"), spell_pass_string);
data/apg-2.2.3.dfsg.1/apg.c:575:16:  [4] (misc) getpass:
  This function is obsolete and not portable. It was in SUSv2 but removed by
  POSIX.2. What it does exactly varies considerably between systems,
  particularly in where its prompt is displayed and where it gets its data
  (e.g., /dev/tty, stdin, stderr, etc.). In addition, some implementations
  overflow buffers. (CWE-676, CWE-120, CWE-20). Make the specific calls to do
  exactly what you want. If you continue to use it, or write your own, be
  sure to zero the password as soon as possible to avoid leaving the
  cleartext password visible in the process' address space.
 seq = (char *)getpass("(eg. your old password):>");
data/apg-2.2.3.dfsg.1/apg.c:667:10:  [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.
 return (crypt(p, salt));
data/apg-2.2.3.dfsg.1/pronpass.c:1412:18:  [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 (word, new_syllable);
data/apg-2.2.3.dfsg.1/pronpass.c:1416:22:  [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 (hyphenated_word, syllable_for_hyph);
data/apg-2.2.3.dfsg.1/pronpass.c:1420:22:  [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 (hyphenated_word, new_syllable);
data/apg-2.2.3.dfsg.1/pronpass.c:1446:18:  [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).
          (void) strcat (word, new_syllable);
data/apg-2.2.3.dfsg.1/pronpass.c:1451:22:  [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).
              (void) strcat (hyphenated_word, syllable_for_hyph);
data/apg-2.2.3.dfsg.1/pronpass.c:1455:22:  [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).
              (void) strcat (hyphenated_word, new_syllable);
data/apg-2.2.3.dfsg.1/pronpass.c:1736:23:  [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 (syllable, rules[saved_pair[1]].unit_code);
data/apg-2.2.3.dfsg.1/pronpass.c:2050:23:  [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).
               (void) strcat (syllable, rules[unit].unit_code);
data/apg-2.2.3.dfsg.1/apg.c:158: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 delim[2]={0x0d,0x0a};
data/apg-2.2.3.dfsg.1/apg.c:211:19:  [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).
      algorithm = atoi (apg_optarg);
data/apg-2.2.3.dfsg.1/apg.c:225:24:  [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).
      min_substr_len = atoi (apg_optarg);
data/apg-2.2.3.dfsg.1/apg.c:257:24:  [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).
      number_of_pass = atoi (apg_optarg);
data/apg-2.2.3.dfsg.1/apg.c:261: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).
      min_pass_length = (USHORT) atoi (apg_optarg);
data/apg-2.2.3.dfsg.1/apg.c:265: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).
      max_pass_length = (USHORT) atoi (apg_optarg);
data/apg-2.2.3.dfsg.1/apg.c:333:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
         (void) memcpy ((void *)crypt_string,
data/apg-2.2.3.dfsg.1/apg.c:444:16:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
         (void)memcpy ((void *)crypt_string,
data/apg-2.2.3.dfsg.1/apg.c:577:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  (void)memcpy((void *)&prom[0], (void *)seq, (int)strlen(seq));
data/apg-2.2.3.dfsg.1/apg.c:579:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  (void)memcpy((void *)&prom[0], (void *)seq, sizeof(prom));
data/apg-2.2.3.dfsg.1/apg.c:600:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  (void)memcpy((void *)&prom[0], (void *)seq, (int)strlen(seq));
data/apg-2.2.3.dfsg.1/apg.c:602:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  (void)memcpy((void *)&prom[0], (void *)seq, sizeof(prom));
data/apg-2.2.3.dfsg.1/apg.c:665: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 salt[11];
data/apg-2.2.3.dfsg.1/apgbfm.c:118:15:  [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).
         wc = atoi(apg_optarg);
data/apg-2.2.3.dfsg.1/apgbfm.c:175:25:  [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).
     if ( (f_dictfile = fopen(dictfile,"r")) == NULL)
data/apg-2.2.3.dfsg.1/apgbfm.c:232:25:  [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).
     if ( (f_dictfile = fopen(dictfile,"r")) == NULL)
data/apg-2.2.3.dfsg.1/apgbfm.c:277:25:  [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).
     if ( (f_dictfile = fopen(dictfile,"r")) == NULL)
data/apg-2.2.3.dfsg.1/bfconvert/bfconvert.c:63:4:  [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 id[5];           /* filter ID      */
data/apg-2.2.3.dfsg.1/bfconvert/bfconvert.c:64:4:  [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 version[3];      /* filter version */
data/apg-2.2.3.dfsg.1/bfconvert/bfconvert.c:70:4:  [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 id[8];           /* ID          */
data/apg-2.2.3.dfsg.1/bfconvert/bfconvert.c:94:15:  [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).
 if ((old_f = fopen (argv[1], "r")) == NULL)
data/apg-2.2.3.dfsg.1/bfconvert/bfconvert.c:99:15:  [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).
 if ((new_f = fopen (argv[2], "w")) == NULL)
data/apg-2.2.3.dfsg.1/bloom.c:165:8:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
 (void)memcpy ((void *) tmp_word, (void *) word, strlen(word));
data/apg-2.2.3.dfsg.1/bloom.c:219:11:  [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).
 if ((f = fopen (f_name, mode)) == NULL)
data/apg-2.2.3.dfsg.1/bloom.c:347:11:  [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).
 if ((f = fopen (f_name, "w+")) == NULL)
data/apg-2.2.3.dfsg.1/bloom.c:409:20:  [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 ( (h_val *)memcpy( (void *)b, (void *)&cs[0], SHA_DIGESTSIZE));
data/apg-2.2.3.dfsg.1/bloom.h:74: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 id[5];           /* filter ID      */
data/apg-2.2.3.dfsg.1/bloom.h:75: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 version[3];      /* filter version */
data/apg-2.2.3.dfsg.1/convert.c:47:1:  [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 let[26] =
data/apg-2.2.3.dfsg.1/convert.c:54:1:  [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 clet[26] =
data/apg-2.2.3.dfsg.1/convert.c:107:10:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
   (void)memcpy((void *)&tmp, (void *)syllable, sizeof(tmp));
data/apg-2.2.3.dfsg.1/convert.c:111:16:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
         (void)memcpy ((void *)syllable, (void *)&clet[i], 1);
data/apg-2.2.3.dfsg.1/convert.c:137:14:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
       (void)memcpy ((void *)syllable, (void *)tmp, 1);
data/apg-2.2.3.dfsg.1/convert.c:163:14:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
       (void)memcpy ((void *)syllable, (void *)tmp, 1);
data/apg-2.2.3.dfsg.1/convert.c:239:16:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
         (void)memcpy((void*)h_syllable, (void*)ssn[i].name, strlen(ssn[i].name));
data/apg-2.2.3.dfsg.1/convert.c:244:14:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
       (void)memcpy((void*)h_syllable, (void*)syllable, strlen(syllable));
data/apg-2.2.3.dfsg.1/convert.c:392:14:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
      (void) memcpy((void *)tmp_ptr, (void *)cs[j].name, strlen(cs[j].name));
data/apg-2.2.3.dfsg.1/convert.c:395:14:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
      (void) memcpy((void *)(tmp_ptr), (void *)&hyphen, 1);
data/apg-2.2.3.dfsg.1/convert.c:402:10:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  (void) memcpy((void *)(tmp_ptr), (void *)&zero, 1);
data/apg-2.2.3.dfsg.1/pronpass.c:52: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    unit_code[5];
data/apg-2.2.3.dfsg.1/restrict.c:67:14:  [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).
 if ( (dct = fopen(dict,"r")) == NULL)
data/apg-2.2.3.dfsg.1/rnd.c:147:8:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
 (void)memcpy ( (void *)&I[0], (void *)&hash[0], sizeof(I));
data/apg-2.2.3.dfsg.1/rnd.c:154:8:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
 (void)memcpy ( (void *)&Xi[0], (void *)&hash[0], sizeof(Xi));        /* Xi=Ek( I (+) s ) */
data/apg-2.2.3.dfsg.1/rnd.c:162:8:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
 (void)memcpy ( (void *)&__rnd_seed[0], (void *)&hash[0],
data/apg-2.2.3.dfsg.1/rnd.c:192: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(APG_DEVRANDOM, O_RDONLY)) != -1)
data/apg-2.2.3.dfsg.1/rnd.c:199:18:  [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).
 else if ( (fd = open(APG_DEVURANDOM, O_RDONLY)) != -1)
data/apg-2.2.3.dfsg.1/apg.c:387: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).
	    write (0, (void*) out_pass, strlen(out_pass));
data/apg-2.2.3.dfsg.1/apg.c:427:30:  [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).
	write (0, (void*) out_pass, strlen(out_pass));
data/apg-2.2.3.dfsg.1/apg.c:493:36:  [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).
	    write (0, (void*)pass_string, strlen(pass_string));
data/apg-2.2.3.dfsg.1/apg.c:528: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).
	write (0, (void*)pass_string, strlen(pass_string));
data/apg-2.2.3.dfsg.1/apg.c:576: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).
 if (strlen(seq) < sizeof(prom))
data/apg-2.2.3.dfsg.1/apg.c:577:52:  [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).
  (void)memcpy((void *)&prom[0], (void *)seq, (int)strlen(seq));
data/apg-2.2.3.dfsg.1/apg.c:599: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).
 if (strlen(seq) < sizeof (prom))
data/apg-2.2.3.dfsg.1/apg.c:600:52:  [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).
  (void)memcpy((void *)&prom[0], (void *)seq, (int)strlen(seq));
data/apg-2.2.3.dfsg.1/apg.c:686: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).
 for(i=0; i < strlen(opt);i++)
data/apg-2.2.3.dfsg.1/apg.c:713: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).
 str_length = strlen(s_mode);
data/apg-2.2.3.dfsg.1/apgbfm.c:368: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).
 for(i=0; i < strlen(opt);i++)
data/apg-2.2.3.dfsg.1/bloom.c:165:50:  [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).
 (void)memcpy ((void *) tmp_word, (void *) word, strlen(word));
data/apg-2.2.3.dfsg.1/bloom.c:407:41:  [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).
 apg_shaUpdate (&context, (BYTE *)word, strlen(word));
data/apg-2.2.3.dfsg.1/convert.c:80: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).
 int str_len = strlen(word);
data/apg-2.2.3.dfsg.1/convert.c:134: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).
 if ( strlen (syllable) == 1 )
data/apg-2.2.3.dfsg.1/convert.c:160: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).
 if ( strlen (syllable) == 1 )
data/apg-2.2.3.dfsg.1/convert.c:233: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).
 if (strlen(syllable) == 1)
data/apg-2.2.3.dfsg.1/convert.c:239:62:  [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).
         (void)memcpy((void*)h_syllable, (void*)ssn[i].name, strlen(ssn[i].name));
data/apg-2.2.3.dfsg.1/convert.c:244:57:  [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).
       (void)memcpy((void*)h_syllable, (void*)syllable, strlen(syllable));
data/apg-2.2.3.dfsg.1/convert.c:367: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).
  int word_len = strlen(word);
data/apg-2.2.3.dfsg.1/convert.c:377:29:  [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_length = s_length + strlen(cs[j].name) + 1;
data/apg-2.2.3.dfsg.1/convert.c:392:58:  [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).
      (void) memcpy((void *)tmp_ptr, (void *)cs[j].name, strlen(cs[j].name));
data/apg-2.2.3.dfsg.1/convert.c:393: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).
      tmp_ptr = tmp_ptr + strlen(cs[j].name);
data/apg-2.2.3.dfsg.1/pronpass.c:1367:24:  [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).
     syllable_length = strlen (new_syllable);
data/apg-2.2.3.dfsg.1/pronpass.c:1447:18:  [1] (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 character.
          (void) strcat (hyphenated_word, "-");
data/apg-2.2.3.dfsg.1/pronpass.c:1475:17:  [1] (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). Risk is low because the source is a constant character.
         (void) strcpy (word, "");
data/apg-2.2.3.dfsg.1/pronpass.c:1476:17:  [1] (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). Risk is low because the source is a constant character.
         (void) strcpy (hyphenated_word, "");
data/apg-2.2.3.dfsg.1/pronpass.c:1699:13:  [1] (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). Risk is low because the source is a constant character.
     (void) strcpy (syllable, "");
data/apg-2.2.3.dfsg.1/pronpass.c:1737: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).
               length_left -= strlen (syllable);
data/apg-2.2.3.dfsg.1/pronpass.c:1765: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).
          length_left -= (short int) strlen (rules[unit].unit_code);
data/apg-2.2.3.dfsg.1/pronpass.c:2019:42:  [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).
              length_left += (short int) strlen (rules[unit].unit_code);
data/apg-2.2.3.dfsg.1/pronpass.c:2056:23:  [1] (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). Risk is low because the source is a constant character.
               (void) strcpy (&syllable[strlen (syllable) -
data/apg-2.2.3.dfsg.1/pronpass.c:2056:41:  [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).
               (void) strcpy (&syllable[strlen (syllable) -
data/apg-2.2.3.dfsg.1/pronpass.c:2057: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).
                        strlen (rules[last_unit].unit_code)],"");
data/apg-2.2.3.dfsg.1/pronpass.c:2058: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).
               length_left += (short int) strlen (rules[last_unit].unit_code);
data/apg-2.2.3.dfsg.1/restrict.c:75: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).
   if(strlen(tmp) != strlen(pass)) continue;
data/apg-2.2.3.dfsg.1/restrict.c:75:22:  [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(tmp) != strlen(pass)) continue;
data/apg-2.2.3.dfsg.1/restrict.c:76: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).
   else if (strncmp(tmp, pass, strlen(pass)) == 0)
data/apg-2.2.3.dfsg.1/restrict.c:141: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).
 int len = strlen(password); /* string length                      */
data/apg-2.2.3.dfsg.1/restrict.c:265: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).
 if (strlen(char_string) > 93)
data/apg-2.2.3.dfsg.1/rnd.c:194:4:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
   read(fd, (void *)&drs[0], 8);
data/apg-2.2.3.dfsg.1/rnd.c:201:4:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
   read(fd, &drs[0], 8);

ANALYSIS SUMMARY:

Hits = 102
Lines analyzed = 7074 in approximately 0.25 seconds (28113 lines/second)
Physical Source Lines of Code (SLOC) = 4869
Hits@level = [0] 131 [1]  42 [2]  46 [3]   0 [4]  14 [5]   0
Hits@level+ = [0+] 233 [1+] 102 [2+]  60 [3+]  14 [4+]  14 [5+]   0
Hits/KSLOC@level+ = [0+] 47.8538 [1+] 20.9489 [2+] 12.3229 [3+] 2.87533 [4+] 2.87533 [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.