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/globus-io-12.2/globus_io_error_hierarchy.c
Examining data/globus-io-12.2/globus_io.h
Examining data/globus-io-12.2/globus_io_xio_compat.c
Examining data/globus-io-12.2/test/globus_io_tcp_test_client.c
Examining data/globus-io-12.2/test/globus_io_file_test.c
Examining data/globus-io-12.2/test/globus_io_tcp_test.c
Examining data/globus-io-12.2/test/globus_io_tcp_test_server.c
Examining data/globus-io-12.2/test/globus_io_authorization_test.c
Examining data/globus-io-12.2/globus_io_error_hierarchy.h

FINAL RESULTS:

data/globus-io-12.2/globus_io_error_hierarchy.c:41:13:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            sprintf(tmp, string, function);
data/globus-io-12.2/globus_io_error_hierarchy.c:57:13:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            sprintf(tmp, string, handle);
data/globus-io-12.2/globus_io_error_hierarchy.c:73:13:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            sprintf(tmp, string, handle);
data/globus-io-12.2/globus_io_error_hierarchy.c:89:13:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            sprintf(tmp, string, handle);
data/globus-io-12.2/globus_io_error_hierarchy.c:105:13:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            sprintf(tmp, string, handle);
data/globus-io-12.2/globus_io_error_hierarchy.c:121:13:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            sprintf(tmp, string, handle);
data/globus-io-12.2/globus_io_error_hierarchy.c:139:13:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            sprintf(tmp, string, position, func);
data/globus-io-12.2/globus_io_error_hierarchy.c:157:13:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            sprintf(tmp, string, position, func);
data/globus-io-12.2/globus_io_error_hierarchy.c:174:13:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            sprintf(tmp, string, attribute);
data/globus-io-12.2/globus_io_error_hierarchy.c:197:13:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            sprintf(tmp, string, position, func, type_name);
data/globus-io-12.2/globus_io_error_hierarchy.c:216:13:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            sprintf(tmp, string, attr1, attr2);
data/globus-io-12.2/globus_io_error_hierarchy.c:235:13:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            sprintf(tmp, string, name);
data/globus-io-12.2/globus_io_error_hierarchy.c:253:13:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            sprintf(tmp, string, name);
data/globus-io-12.2/globus_io_error_hierarchy.c:284:13:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            sprintf(tmp, string, position, func);
data/globus-io-12.2/globus_io_error_hierarchy.c:302:13:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            sprintf(tmp, string, position, func);
data/globus-io-12.2/globus_io_error_hierarchy.c:323:13:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            sprintf(tmp, string, globus_libc_system_error_string(save_errno));
data/globus-io-12.2/globus_io_xio_compat.c:1403:25:  [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.
    iattr->allow_ipv6 = getenv("GLOBUS_IO_IPV6") ? GLOBUS_TRUE : GLOBUS_FALSE;
data/globus-io-12.2/test/globus_io_file_test.c:44:48:  [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.
    const char *                        path = getenv("DATA_FILE");
data/globus-io-12.2/test/globus_io_tcp_test_client.c:167:18:  [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.
    while (( c = getopt(argc, argv, "abrHi:vgsch:p:I:dDz:P:")) != EOF)
data/globus-io-12.2/test/globus_io_tcp_test_server.c:180:18:  [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.
    while (( c = getopt(argc, argv, "brgscvz:i:I:P:")) != EOF)
data/globus-io-12.2/globus_io_xio_compat.c:2062: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[256];
data/globus-io-12.2/globus_io_xio_compat.c:2430:17:  [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).
        *port = atoi(s + 1);
data/globus-io-12.2/globus_io_xio_compat.c:4935: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.
        memcpy(*identity, name_buffer.value, name_buffer.length);
data/globus-io-12.2/test/globus_io_authorization_test.c:69:14:  [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.
    unsigned char                       reply_buffer[256];
data/globus-io-12.2/test/globus_io_tcp_test.c:106:11:  [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).
    test4(atoi(argv[1]));		/* connect to secure server*/
data/globus-io-12.2/test/globus_io_tcp_test.c:306:5:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
    sprintf((char *) test_buffer, "quit\n");
data/globus-io-12.2/test/globus_io_tcp_test.c:446: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[6];
data/globus-io-12.2/test/globus_io_tcp_test_client.c:254:13:  [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).
	    port = atoi(optarg);
data/globus-io-12.2/globus_io_error_hierarchy.c:39: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).
            tmp = globus_malloc(strlen(string) + strlen(function)+1);
data/globus-io-12.2/globus_io_error_hierarchy.c:39: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).
            tmp = globus_malloc(strlen(string) + strlen(function)+1);
data/globus-io-12.2/globus_io_error_hierarchy.c:56: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).
            tmp = globus_malloc(strlen(string) + 64 + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:72: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).
            tmp = globus_malloc(strlen(string) + 64 + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:88: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).
            tmp = globus_malloc(strlen(string) + 64 + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:104: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).
            tmp = globus_malloc(strlen(string) + 64 + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:120: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).
            tmp = globus_malloc(strlen(string) + 64 + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:138: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).
            tmp = globus_malloc(strlen(string) + strlen(func) + 64 + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:138: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).
            tmp = globus_malloc(strlen(string) + strlen(func) + 64 + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:156: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).
            tmp = globus_malloc(strlen(string) + strlen(func) + 64 + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:156: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).
            tmp = globus_malloc(strlen(string) + strlen(func) + 64 + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:172: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).
            tmp = globus_malloc(strlen(string) + strlen(attribute) + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:172: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).
            tmp = globus_malloc(strlen(string) + strlen(attribute) + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:195: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).
            tmp = globus_malloc(strlen(string) + strlen(func) + strlen(type_name)+ 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:195: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).
            tmp = globus_malloc(strlen(string) + strlen(func) + strlen(type_name)+ 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:195:65:  [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 = globus_malloc(strlen(string) + strlen(func) + strlen(type_name)+ 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:215: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).
            tmp = globus_malloc(strlen(string) + strlen(attr1) + strlen(attr2) + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:215: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).
            tmp = globus_malloc(strlen(string) + strlen(attr1) + strlen(attr2) + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:215:66:  [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 = globus_malloc(strlen(string) + strlen(attr1) + strlen(attr2) + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:233: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).
            tmp = globus_malloc(strlen(string) + strlen(name) + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:233: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).
            tmp = globus_malloc(strlen(string) + strlen(name) + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:251: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).
            tmp = globus_malloc(strlen(string) + strlen(name) + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:251: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).
            tmp = globus_malloc(strlen(string) + strlen(name) + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:283: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).
            tmp = globus_malloc(strlen(string) + strlen(func) + 64 + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:283: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).
            tmp = globus_malloc(strlen(string) + strlen(func) + 64 + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:301: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).
            tmp = globus_malloc(strlen(string) + strlen(func) + 64 + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:301: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).
            tmp = globus_malloc(strlen(string) + strlen(func) + 64 + 1);
data/globus-io-12.2/globus_io_error_hierarchy.c:320: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).
                strlen(string) 
data/globus-io-12.2/globus_io_error_hierarchy.c:321: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).
                + strlen(globus_libc_system_error_string(save_errno))
data/globus-io-12.2/globus_io_xio_compat.c:4860: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).
        name_buffer.length = strlen(identity);
data/globus-io-12.2/test/globus_io_tcp_test.c:310: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).
				     strlen((char *) test_buffer),

ANALYSIS SUMMARY:

Hits = 59
Lines analyzed = 12966 in approximately 0.20 seconds (64290 lines/second)
Physical Source Lines of Code (SLOC) = 10478
Hits@level = [0]  97 [1]  31 [2]   8 [3]   4 [4]  16 [5]   0
Hits@level+ = [0+] 156 [1+]  59 [2+]  28 [3+]  20 [4+]  16 [5+]   0
Hits/KSLOC@level+ = [0+] 14.8883 [1+] 5.63085 [2+] 2.67227 [3+] 1.90876 [4+] 1.52701 [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.