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/cgilib-0.6/aux.c
Examining data/cgilib-0.6/aux.h
Examining data/cgilib-0.6/cgi.c
Examining data/cgilib-0.6/cgi.h
Examining data/cgilib-0.6/cgitest.c
Examining data/cgilib-0.6/cookies.c
Examining data/cgilib-0.6/jumpto.c

FINAL RESULTS:

data/cgilib-0.6/aux.c:98:4:  [4] (format) vprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	  vprintf (format, args);
data/cgilib-0.6/aux.c:102:4:  [4] (format) vfprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	  vfprintf (stderr, format, args);
data/cgilib-0.6/aux.c:141: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 (line, buf);
data/cgilib-0.6/cgi.c:160:5:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
    sprintf (crlfboundary, "\r\n%s", boundary);
data/cgilib-0.6/cgi.c:431:4:  [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(cp, line);
data/cgilib-0.6/cgi.c:451:7:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		    sprintf (name, "%s\r\n%s", result[index]->value, xp);
data/cgilib-0.6/cgi.c:521:6:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	    sprintf (line, "%s", esp);
data/cgilib-0.6/cgi.c:537: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 (line, tmp);
data/cgilib-0.6/cgi.c:544: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 (line, tmp);
data/cgilib-0.6/cgi.c:636:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf (sptr, "%s\n%s", result[k]->value, value);
data/cgilib-0.6/cgi.c:712:2:  [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 (res[i], parms->vars[i]->name);
data/cgilib-0.6/cgi.c:740:2:  [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 (res[i], parms->files[i]->name);
data/cgilib-0.6/cgitest.c:60:5:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    printf (HTML_FORMCONTENT HTML_SUBMIT);
data/cgilib-0.6/cgitest.c:67:5:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    printf (HTML_FORMCONTENT HTML_SUBMIT);
data/cgilib-0.6/cgitest.c:74:5:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    printf (HTML_FORMCONTENT HTML_SUBMIT);
data/cgilib-0.6/cgitest.c:81:5:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    printf (HTML_FORMCONTENT HTML_SUBMIT);
data/cgilib-0.6/cgitest.c:88:5:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    printf (HTML_FORMCONTENT HTML_SUBMIT);
data/cgilib-0.6/cgitest.c:95:5:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    printf (HTML_FORMCONTENT);
data/cgilib-0.6/cgitest.c:97:5:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    printf (HTML_SUBMIT);
data/cgilib-0.6/cgitest.c:218:6:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	    printf (HTML_CSS HTML_HEAD);
data/cgilib-0.6/cgitest.c:225:6:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	    printf (HTML_CSS HTML_HEAD);
data/cgilib-0.6/cgitest.c:229:6:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	    printf (HTML_CSS HTML_HEAD);
data/cgilib-0.6/cgitest.c:239:2:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	printf (HTML_CSS HTML_HEAD);
data/cgilib-0.6/cgitest.c:243:5:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    printf (HTML_FOOT);
data/cgilib-0.6/cookies.c:159:6:  [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 (res[i], parms->cookies[i]->name);
data/cgilib-0.6/cgi.c:487:10:  [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.
    cp = getenv("CONTENT_TYPE");
data/cgilib-0.6/cgi.c:499:10:  [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.
    cp = getenv("REQUEST_METHOD");
data/cgilib-0.6/cgi.c:502:10:  [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.
    ip = getenv("CONTENT_LENGTH");
data/cgilib-0.6/cgi.c:517:8:  [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.
	esp = getenv("QUERY_STRING");
data/cgilib-0.6/cgitest.c:210:17:  [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.
    path_info = getenv("PATH_INFO");
data/cgilib-0.6/cookies.c:34:33:  [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.
    if ((curpos = http_cookie = getenv ("HTTP_COOKIE")) == NULL)
data/cgilib-0.6/jumpto.c:52:18:  [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.
    server_url = getenv("SERVER_URL");
data/cgilib-0.6/aux.c:120: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 buf[BUFSIZE];
data/cgilib-0.6/cgi.c:154:11:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
    FILE *tmpfile;
data/cgilib-0.6/cgi.c:169:15:  [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 (template)) == -1) {
data/cgilib-0.6/cgi.c:188:18:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
		    putc (*cp, tmpfile);
data/cgilib-0.6/cgi.c:192:15:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
	    putc (c, tmpfile);
data/cgilib-0.6/cgi.c:206:32:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
                    putc (*cp, tmpfile);
data/cgilib-0.6/cgi.c:215:16:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
	    fputc (c, tmpfile);
data/cgilib-0.6/cgi.c:222:13:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
    fclose (tmpfile);
data/cgilib-0.6/cgi.c:241:11:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
    char *tmpfile;
data/cgilib-0.6/cgi.c:291:12:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
		    if (!tmpfile) {
data/cgilib-0.6/cgi.c:299:68:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
		    cgiDebugOutput (2, "Wrote %s (%s) to file: %s", name, fname, tmpfile);
data/cgilib-0.6/cgi.c:303:12:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
			unlink (tmpfile);
data/cgilib-0.6/cgi.c:304:10:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
			free (tmpfile);
data/cgilib-0.6/cgi.c:313:16:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
			    unlink (tmpfile);
data/cgilib-0.6/cgi.c:314:14:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
			    free (tmpfile);
data/cgilib-0.6/cgi.c:325:20:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
			file->tmpfile = tmpfile;
data/cgilib-0.6/cgi.c:337:13:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
				unlink (tmpfile);
data/cgilib-0.6/cgi.c:338:11:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
				free (tmpfile);
data/cgilib-0.6/cgi.c:355:13:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
				unlink (tmpfile);
data/cgilib-0.6/cgi.c:356:11:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
				free (tmpfile);
data/cgilib-0.6/cgi.c:429:18:  [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.
		    if ((cp = (char *)realloc (result[index]->value, strlen(result[index]->value)+strlen(line)+2)) != NULL) {
data/cgilib-0.6/cgi.c:444:20:  [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.
		    if ((name = (char *)malloc (strlen(result[index]->value)+strlen(xp)+3)) == NULL) {
data/cgilib-0.6/cgi.c:484: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 tmp[101];
data/cgilib-0.6/cgi.c:508: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).
	    length = atoi(ip);
data/cgilib-0.6/cgi.c:824:27:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
	    if (parms->files[i]->tmpfile) {
data/cgilib-0.6/cgi.c:825:28:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
		unlink (parms->files[i]->tmpfile);
data/cgilib-0.6/cgi.c:826:26:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
		free (parms->files[i]->tmpfile);
data/cgilib-0.6/cgi.h:44:4:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
		*tmpfile;
data/cgilib-0.6/cgitest.c:186:49:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
	      printf ("%s=%s (%s", vars[i], tmp, file->tmpfile);
data/cgilib-0.6/aux.c:50: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).
    if (len == strlen(string))
data/cgilib-0.6/aux.c:134: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(line)+strlen(buf)+1 > size) {
data/cgilib-0.6/aux.c:134: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).
      if (strlen(line)+strlen(buf)+1 > size) {
data/cgilib-0.6/aux.c:142: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).
      if (line[strlen(line)-1] == '\n') {
data/cgilib-0.6/aux.c:143: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).
	line[strlen(line)-1] = '\0';
data/cgilib-0.6/aux.c:144: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 (line[strlen(line)-1] == '\r')
data/cgilib-0.6/aux.c:145:9:  [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).
	  line[strlen(line)-1] = '\0';
data/cgilib-0.6/cgi.c:43: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).
    if (!name || !strlen (name) || !value || !strlen (value))
data/cgilib-0.6/cgi.c:43: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).
    if (!name || !strlen (name) || !value || !strlen (value))
data/cgilib-0.6/cgi.c:50:9:  [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 (cgiHeaderString) + cp-name + vp-value + 5) * sizeof (char);
data/cgilib-0.6/cgi.c:54: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).
	pivot += strlen (cgiHeaderString);
data/cgilib-0.6/cgi.c:61:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
    strncpy (pivot, name, cp-name);
data/cgilib-0.6/cgi.c:62:5:  [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 string.
    strncat (pivot, ": ", 2);
data/cgilib-0.6/cgi.c:63:5:  [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 (pivot, value, vp-value);
data/cgilib-0.6/cgi.c:64:5:  [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 string.
    strncat (pivot, "\r\n", 2);
data/cgilib-0.6/cgi.c:74: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).
    if (!type || !strlen (type))
data/cgilib-0.6/cgi.c:85:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
    strncpy (cgiType, type, cp-type);
data/cgilib-0.6/cgi.c:157: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).
    boundarylen = strlen(boundary)+3;
data/cgilib-0.6/cgi.c:183:6:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	c = fgetc (stream);
data/cgilib-0.6/cgi.c:186:10:  [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 (buf)) {
data/cgilib-0.6/cgi.c:196: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 (buf)) {
data/cgilib-0.6/cgi.c:200: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 (buf) == strlen (crlfboundary))
data/cgilib-0.6/cgi.c:200: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).
		if (strlen (buf) == strlen (crlfboundary))
data/cgilib-0.6/cgi.c:255: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).
	if (!strncmp (line, boundary, strlen(boundary))) {
data/cgilib-0.6/cgi.c:284: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(line)) {
data/cgilib-0.6/cgi.c:301: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).
		    if (!strlen (fname)) {
data/cgilib-0.6/cgi.c:429:56:  [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 ((cp = (char *)realloc (result[index]->value, strlen(result[index]->value)+strlen(line)+2)) != NULL) {
data/cgilib-0.6/cgi.c:429:85:  [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 ((cp = (char *)realloc (result[index]->value, strlen(result[index]->value)+strlen(line)+2)) != NULL) {
data/cgilib-0.6/cgi.c:430:4:  [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.
			strcat(cp, "\n");
data/cgilib-0.6/cgi.c:444: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).
		    if ((name = (char *)malloc (strlen(result[index]->value)+strlen(xp)+3)) == NULL) {
data/cgilib-0.6/cgi.c:444:64:  [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 ((name = (char *)malloc (strlen(result[index]->value)+strlen(xp)+3)) == NULL) {
data/cgilib-0.6/cgi.c:491: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).
	cp = strstr(cp, "boundary=") + strlen ("boundary=") - 2;
data/cgilib-0.6/cgi.c:518:13:  [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 (esp && strlen(esp)) {
data/cgilib-0.6/cgi.c:519: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).
	    if ((line = (char *)malloc (strlen(esp)+2)) == NULL)
data/cgilib-0.6/cgi.c:529:10:  [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)) {
data/cgilib-0.6/cgi.c:530: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 (tmp[strlen(tmp)-1] == '\n')
data/cgilib-0.6/cgi.c:531: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).
		    tmp[strlen(tmp)-1] = '&';
data/cgilib-0.6/cgi.c:533: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).
		    length += strlen(tmp);
data/cgilib-0.6/cgi.c:539: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).
		    length = strlen(tmp);
data/cgilib-0.6/cgi.c:551: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 (line[strlen(line)-1] == '&')
data/cgilib-0.6/cgi.c:552: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).
	    line[strlen(line)-1] = '\0';
data/cgilib-0.6/cgi.c:566:9:  [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(line)) {
data/cgilib-0.6/cgi.c:586: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).
	    ip = cp + strlen(cp);
data/cgilib-0.6/cgi.c:593: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(esp)) {
data/cgilib-0.6/cgi.c:604:6:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	    strncpy(name, cp, esp-cp);
data/cgilib-0.6/cgi.c:614:6:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	    strncpy(value, cp, ip-esp);
data/cgilib-0.6/cgi.c:630:10:  [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(result[k]->value)+strlen(value)+2) * sizeof (char);
data/cgilib-0.6/cgi.c:630: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).
		len = (strlen(result[k]->value)+strlen(value)+2) * sizeof (char);
data/cgilib-0.6/cgi.c:685:10:  [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(parms->vars[i]->value) > 0)
data/cgilib-0.6/cgi.c:708: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 (parms->vars[i]->name) +1;
data/cgilib-0.6/cgi.c:736: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 (parms->files[i]->name) +1;
data/cgilib-0.6/cgi.c:767: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).
    if (url && strlen(url)) {
data/cgilib-0.6/cgi.c:768:67:  [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).
	printf ("Content-type: text/html\r\nContent-length: %d\r\n", 77+(strlen(url)*2));
data/cgilib-0.6/cgitest.c:230:10:  [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 (path_info))
data/cgilib-0.6/cookies.c:82:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy (cp, v0, v1-v0);
data/cgilib-0.6/cookies.c:97:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy (pivot->name, n0, n1-n0);
data/cgilib-0.6/cookies.c:105:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy (pivot->value, v0, v1-v0);
data/cgilib-0.6/cookies.c:155: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).
	    len = strlen (parms->cookies[i]->name) +1;

ANALYSIS SUMMARY:

Hits = 119
Lines analyzed = 1679 in approximately 0.08 seconds (22148 lines/second)
Physical Source Lines of Code (SLOC) = 1201
Hits@level = [0]  80 [1]  58 [2]  29 [3]   7 [4]  25 [5]   0
Hits@level+ = [0+] 199 [1+] 119 [2+]  61 [3+]  32 [4+]  25 [5+]   0
Hits/KSLOC@level+ = [0+] 165.695 [1+] 99.0841 [2+] 50.791 [3+] 26.6445 [4+] 20.816 [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.