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/cubew-4.5/test/test3/cube_self_test_mem_tracking.c
Examining data/cubew-4.5/test/test3/cube_self_test3_6.c
Examining data/cubew-4.5/test/test3/cube_self_test3_5.c
Examining data/cubew-4.5/test/test3/cube_self_test3_3.c
Examining data/cubew-4.5/test/test3/cube_self_test3_2.c
Examining data/cubew-4.5/test/test3/cube_self_test3_1.c
Examining data/cubew-4.5/test/test3/cube_self_test3.c
Examining data/cubew-4.5/examples/cubew/cubew_example_old_complex.c
Examining data/cubew-4.5/examples/cubew/cubew_system_tree_memory_footprint_optimized.c
Examining data/cubew-4.5/examples/cubew/cubew_system_tree_memory_footprint_standard.c
Examining data/cubew-4.5/examples/cubew/cubew_example_derived.c
Examining data/cubew-4.5/examples/cubew/cubew_example_simple.c
Examining data/cubew-4.5/examples/cubew/cubew_example_complex.c
Examining data/cubew-4.5/examples/cubew/backend/cubew_example_complex.mpi.c
Examining data/cubew-4.5/examples/cubew/backend/cubew_example_simple.mpi.c
Examining data/cubew-4.5/src/tools/include/cubew_tools.hpp
Examining data/cubew-4.5/src/tools/cubew_config/cubew_config_helper.cpp
Examining data/cubew-4.5/src/tools/cubew_config/cubew_config_data.hpp
Examining data/cubew-4.5/src/tools/cubew_config/cubew_config_data.cpp
Examining data/cubew-4.5/src/tools/cubew_config/cubew_config.hpp
Examining data/cubew-4.5/src/tools/cubew_config/cubew_config.cpp
Examining data/cubew-4.5/src/cubew/cubew_tar_writing.c
Examining data/cubew-4.5/src/cubew/cubew_system_tree_writer.c
Examining data/cubew-4.5/src/cubew/cubew_system_tree_node_plain.c
Examining data/cubew-4.5/src/cubew/cubew_system_tree_node.c
Examining data/cubew-4.5/src/cubew/cubew_services.c
Examining data/cubew-4.5/src/cubew/cubew_region.c
Examining data/cubew-4.5/src/cubew/cubew_metric.c
Examining data/cubew-4.5/src/cubew/cubew_memory.c
Examining data/cubew-4.5/src/cubew/cubew_location_plain.c
Examining data/cubew-4.5/src/cubew/cubew_location_group_plain.c
Examining data/cubew-4.5/src/cubew/cubew_location_group.c
Examining data/cubew-4.5/src/cubew/cubew_location.c
Examining data/cubew-4.5/src/cubew/cubew_file_layout_embedded.c
Examining data/cubew-4.5/src/cubew/cubew_cube.c
Examining data/cubew-4.5/src/cubew/cubew_compat_platform.c
Examining data/cubew-4.5/src/cubew/cubew_cnode.c
Examining data/cubew-4.5/src/cubew/cubew_cartesian.c
Examining data/cubew-4.5/src/cubew/cubew_allocs.c
Examining data/cubew-4.5/src/cubew/cubew_vector.h
Examining data/cubew-4.5/src/cubew/cubew_types.h
Examining data/cubew-4.5/src/cubew/cubew_tar_writing.h
Examining data/cubew-4.5/src/cubew/cubew_system_tree_writer.h
Examining data/cubew-4.5/src/cubew/cubew_system_tree_node_plain.h
Examining data/cubew-4.5/src/cubew/cubew_system_tree_node.h
Examining data/cubew-4.5/src/cubew/cubew_services.h
Examining data/cubew-4.5/src/cubew/cubew_report_layouts_types.h
Examining data/cubew-4.5/src/cubew/cubew_report_layouts.h
Examining data/cubew-4.5/src/cubew/cubew_region.h
Examining data/cubew-4.5/src/cubew/cubew_metric.h
Examining data/cubew-4.5/src/cubew/cubew_meta_data_writer.h
Examining data/cubew-4.5/src/cubew/cubew_memory.h
Examining data/cubew-4.5/src/cubew/cubew_location_plain.h
Examining data/cubew-4.5/src/cubew/cubew_location_group_plain.h
Examining data/cubew-4.5/src/cubew/cubew_location_group.h
Examining data/cubew-4.5/src/cubew/cubew_location.h
Examining data/cubew-4.5/src/cubew/cubew_file_layout_embedded.h
Examining data/cubew-4.5/src/cubew/cubew_cube.h
Examining data/cubew-4.5/src/cubew/cubew_compat_platform.h
Examining data/cubew-4.5/src/cubew/cubew_cnode.h
Examining data/cubew-4.5/src/cubew/cubew_cartesian.h
Examining data/cubew-4.5/src/cubew/cubew_allocs.h
Examining data/cubew-4.5/src/cubew/cubew_meta_data_writer.c
Examining data/cubew-4.5/common/utils/include/utils_package.h
Examining data/cubew-4.5/common/utils/include/UTILS_IO.h
Examining data/cubew-4.5/common/utils/include/UTILS_Portability.h
Examining data/cubew-4.5/common/utils/include/UTILS_Error.h
Examining data/cubew-4.5/common/utils/include/UTILS_DebugStream.hpp
Examining data/cubew-4.5/common/utils/include/UTILS_Debug.h
Examining data/cubew-4.5/common/utils/include/UTILS_CStr.h
Examining data/cubew-4.5/common/utils/test/cutest/CuTest.h
Examining data/cubew-4.5/common/utils/test/cutest/CuTest.c
Examining data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c
Examining data/cubew-4.5/common/utils/src/io/UTILS_IO_GetExe.c
Examining data/cubew-4.5/common/utils/src/cstr/UTILS_CStr.c
Examining data/cubew-4.5/common/utils/src/exception/normalize_file.h
Examining data/cubew-4.5/common/utils/src/exception/UTILS_Error.c
Examining data/cubew-4.5/common/utils/src/exception/UTILS_Debug.c
Examining data/cubew-4.5/common/utils/src/exception/ErrorCodes.tmpl.h
Examining data/cubew-4.5/build-config/common/generate-library-dependencies-la-object.hpp
Examining data/cubew-4.5/build-config/common/config-common.h

FINAL RESULTS:

data/cubew-4.5/common/utils/src/cstr/UTILS_CStr.c:48:5:  [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( dup, source );
data/cubew-4.5/common/utils/src/exception/UTILS_Debug.c:385:9:  [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( stdout, msgFormatString, va );
data/cubew-4.5/common/utils/src/exception/UTILS_Debug.c:410:5:  [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( stdout, msgFormatString, va );
data/cubew-4.5/common/utils/src/exception/UTILS_Error.c:138:13:  [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, msgFormatString, va );
data/cubew-4.5/common/utils/src/io/UTILS_IO_GetExe.c:124:13:  [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( full_file_name, current_path );
data/cubew-4.5/common/utils/src/io/UTILS_IO_GetExe.c:126:13:  [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( &full_file_name[ path_len + 1 ], exe );
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:364:9:  [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( result_path + total_length, sep );
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:368:9:  [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( result_path + total_length, path );
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:458:5:  [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( buf, cwd );
data/cubew-4.5/common/utils/test/cutest/CuTest.c:33:5:  [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( newStr, old );
data/cubew-4.5/common/utils/test/cutest/CuTest.c:107:5:  [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( str->buffer, text );
data/cubew-4.5/common/utils/test/cutest/CuTest.c:137:5:  [4] (format) vsprintf:
  Potential format string problem (CWE-134). Make format string constant.
    vsprintf( buf, format, argp );
data/cubew-4.5/common/utils/test/cutest/CuTest.c:232:5:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
    sprintf( buf, "%s:%d: ", file, line );
data/cubew-4.5/common/utils/test/cutest/CuTest.c:456:23:  [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.
              || 0 == system( "test -t 1" ) ) )
data/cubew-4.5/src/cubew/cubew_meta_data_writer.c:79:15:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
        len = vsnprintf( NULL, 0, format, fmtargs );
data/cubew-4.5/src/cubew/cubew_meta_data_writer.c:105:9:  [4] (format) vsprintf:
  Potential format string problem (CWE-134). Make format string constant.
        vsprintf( writer->pointer, format, fmtargs );
data/cubew-4.5/src/cubew/cubew_meta_data_writer.c:110:9:  [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( writer->file, format, fmtargs );
data/cubew-4.5/src/cubew/cubew_meta_data_writer.c:113:5:  [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( writer->file, format, fmtargs );
data/cubew-4.5/src/cubew/cubew_services.c:1393:13:  [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( ":%20g:%" PRIu64, ( *ptr_pattern ).d, ( *ptr_pattern ).ui );
data/cubew-4.5/src/cubew/cubew_services.c:1418:5:  [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( new_str, str );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:58:5:  [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( buff, cubename );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:215:9:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
        sprintf( paxname, "PaxHeader/%s", dataname );
data/cubew-4.5/src/tools/cubew_config/cubew_config.cpp:341:18:  [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.
            if ( system( summary_command.c_str() ) != 0 )
data/cubew-4.5/src/tools/cubew_config/cubew_config.cpp:383:11:  [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.
    exit( system( command.c_str() ) );
data/cubew-4.5/common/utils/src/exception/UTILS_Debug.c:294:42:  [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* debug_level_string = getenv( env_name );
data/cubew-4.5/common/utils/src/io/UTILS_IO_GetExe.c:90:44:  [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* path_list      = UTILS_CStr_dup( getenv( "PATH" ) );
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:403:22:  [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* hostname = getenv( "HOST" );
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:434: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.
    char* cwd = getenv( "PWD" );
data/cubew-4.5/common/utils/test/cutest/CuTest.c:449:23:  [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 ( 0 != strcmp( getenv( "AM_COLOR_TESTS" ) ? getenv( "AM_COLOR_TESTS" ) : "", "no" )
data/cubew-4.5/common/utils/test/cutest/CuTest.c:449:52:  [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 ( 0 != strcmp( getenv( "AM_COLOR_TESTS" ) ? getenv( "AM_COLOR_TESTS" ) : "", "no" )
data/cubew-4.5/common/utils/test/cutest/CuTest.c:450:26:  [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.
         && 0 != strcmp( getenv( "TERM" ) ? getenv( "TERM" ) : "", "dumb" )
data/cubew-4.5/common/utils/test/cutest/CuTest.c:450:45:  [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.
         && 0 != strcmp( getenv( "TERM" ) ? getenv( "TERM" ) : "", "dumb" )
data/cubew-4.5/common/utils/test/cutest/CuTest.c:451: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.
         && ( ( getenv( "AM_COLOR_TESTS" )
data/cubew-4.5/common/utils/test/cutest/CuTest.c:452: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.
                && 0 == strcmp( getenv( "AM_COLOR_TESTS" ), "always" ) )
data/cubew-4.5/examples/cubew/backend/cubew_example_complex.mpi.c:461:5:  [3] (random) srand:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
    srand( 0 );
data/cubew-4.5/examples/cubew/cubew_example_complex.c:446:5:  [3] (random) srand:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
    srand( 0 );
data/cubew-4.5/examples/cubew/cubew_example_old_complex.c:270:9:  [3] (random) srand:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
        srand( 0 );
data/cubew-4.5/src/cubew/cubew_allocs.c:563: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.
    pTracking = getenv( "SCOREP_DEVELOPMENT_MEMORY_STATS" );
data/cubew-4.5/src/cubew/cubew_allocs.c:566:21:  [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.
        pTracking = getenv( "CUBEW_DEVELOPMENT_MEMORY_STATS" );
data/cubew-4.5/src/cubew/cubew_cube.c:70:28:  [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* env_compressed = getenv( "CUBEW_ZLIB_COMPRESSION" );
data/cubew-4.5/src/cubew/cubew_cube.c:79:21:  [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.
    cubew_trace = ( getenv( "CUBEW_TRACE" ) != NULL );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:357:42:  [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.
    tar_writer->username = cubew_strdup( getenv( "USER" ) );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:360:46:  [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.
        tar_writer->username = cubew_strdup( getenv( "LOGNAME" ) );
data/cubew-4.5/src/tools/cubew_config/cubew_config_data.cpp:234:31:  [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* ld_run_path = getenv( "LD_RUN_PATH" );
data/cubew-4.5/test/test3/cube_self_test3.c:551:5:  [3] (random) srand:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
    srand( 0 );
data/cubew-4.5/test/test3/cube_self_test3_1.c:545:5:  [3] (random) srand:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
    srand( 0 );
data/cubew-4.5/test/test3/cube_self_test3_2.c:469:5:  [3] (random) srand:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
    srand( 0 );
data/cubew-4.5/test/test3/cube_self_test3_3.c:566:5:  [3] (random) srand:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
    srand( 0 );
data/cubew-4.5/test/test3/cube_self_test3_5.c:444:5:  [3] (random) srand:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
    srand( 0 );
data/cubew-4.5/test/test3/cube_self_test3_6.c:428:5:  [3] (random) srand:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
    srand( 0 );
data/cubew-4.5/test/test3/cube_self_test_mem_tracking.c:475:5:  [3] (random) srand:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
    srand( 0 );
data/cubew-4.5/common/utils/src/io/UTILS_IO_GetExe.c:40:18:  [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).
    FILE* file = fopen( filename, "rb" );
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:393:5:  [2] (buffer) TCHAR:
  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.
    TCHAR computer_name[ MAX_COMPUTERNAME_LENGTH + 1 ];
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:466: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[ BUFSIZ ];
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:469:20:  [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).
    FILE* source = fopen( sourceFileName, "rb" );
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:470:20:  [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).
    FILE* dest   = fopen( destFileName, "wb" );
data/cubew-4.5/common/utils/test/cutest/CuTest.c:114: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 text[ 2 ];
data/cubew-4.5/common/utils/test/cutest/CuTest.c:136: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[ HUGE_STRING_LEN ];
data/cubew-4.5/common/utils/test/cutest/CuTest.c:157:5:  [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( str->buffer + pos, text, length );
data/cubew-4.5/common/utils/test/cutest/CuTest.c:230: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[ HUGE_STRING_LEN ];
data/cubew-4.5/common/utils/test/cutest/CuTest.c:330: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[ STRING_MAX ];
data/cubew-4.5/common/utils/test/cutest/CuTest.c:346: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( buf, "expected <%d> but was <%d>", expected, actual );
data/cubew-4.5/common/utils/test/cutest/CuTest.c:359: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[ STRING_MAX ];
data/cubew-4.5/common/utils/test/cutest/CuTest.c:375: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( buf, "Not expected <%d> but was <%d>", notExpected, actual );
data/cubew-4.5/common/utils/test/cutest/CuTest.c:388: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[ STRING_MAX ];
data/cubew-4.5/common/utils/test/cutest/CuTest.c:404: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( buf, "expected <%lf> but was <%lf>", expected, actual );
data/cubew-4.5/common/utils/test/cutest/CuTest.c:416: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[ STRING_MAX ];
data/cubew-4.5/common/utils/test/cutest/CuTest.c:432: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( buf, "expected pointer <%p> but was <%p>", expected, actual );
data/cubew-4.5/examples/cubew/backend/cubew_example_complex.mpi.c:476:9:  [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 buffer[ 30 ];
data/cubew-4.5/examples/cubew/backend/cubew_example_complex.mpi.c:477:9:  [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( buffer, "Thread %u", i );
data/cubew-4.5/examples/cubew/backend/cubew_example_simple.mpi.c:59: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 cubefile[ 20 ] = "simple-mpi-cube";
data/cubew-4.5/examples/cubew/backend/cubew_example_simple.mpi.c:134:9:  [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 buffer[ 30 ];
data/cubew-4.5/examples/cubew/backend/cubew_example_simple.mpi.c:135:9:  [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( buffer, "Thread %d", i );
data/cubew-4.5/examples/cubew/cubew_example_derived.c:44: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 cubefile[ 20 ] = "simple-cube-derived";
data/cubew-4.5/examples/cubew/cubew_example_simple.c:44: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 cubefile[ 12 ] = "simple-cube";
data/cubew-4.5/examples/cubew/cubew_system_tree_memory_footprint_optimized.c:140: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 cubefile[ 40 ] = "system_tree_mem_optimized";
data/cubew-4.5/examples/cubew/cubew_system_tree_memory_footprint_standard.c:41: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 cubefile[ 40 ] = "system_tree_mem_standard";
data/cubew-4.5/src/cubew/cubew_allocs.c:530:13:  [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( ( char* )new_ptr + BLOCK_SIZE_SHIFT, ptr, osize );
data/cubew-4.5/src/cubew/cubew_file_layout_embedded.c:55: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[ 50 ];
data/cubew-4.5/src/cubew/cubew_file_layout_embedded.c:59:9:  [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( buf, "%u.data", id );
data/cubew-4.5/src/cubew/cubew_file_layout_embedded.c:63:9:  [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( buf, "ghost_%u.data", id );
data/cubew-4.5/src/cubew/cubew_file_layout_embedded.c:78: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[ 50 ];
data/cubew-4.5/src/cubew/cubew_file_layout_embedded.c:82:9:  [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( buf, "%u.index", id );
data/cubew-4.5/src/cubew/cubew_file_layout_embedded.c:86:9:  [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( buf, "ghost_%u.index", id );
data/cubew-4.5/src/cubew/cubew_metric.c:145:13:  [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( target_row, data_row, metric->nthrd * sizeof( double ) );
data/cubew-4.5/src/cubew/cubew_metric.c:167:13:  [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( target_row, data_row, metric->nthrd * sizeof( uint64_t ) );
data/cubew-4.5/src/cubew/cubew_metric.c:191:13:  [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( target_row, data_row, metric->nthrd * sizeof( uint64_t ) );
data/cubew-4.5/src/cubew/cubew_services.c:286:9:  [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( _string, "HISTOGRAM(%i)", dtype->data[ 0 ] );
data/cubew-4.5/src/cubew/cubew_services.c:293:9:  [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( _string, "NDOUBLES(%i)", dtype->data[ 0 ] );
data/cubew-4.5/src/cubew/cubew_services.c:320:27:  [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).
        uint32_t _value = atoi( token );
data/cubew-4.5/src/cubew/cubew_services.c:345:11:  [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.
    const char bits[ 256 ] = {
data/cubew-4.5/src/cubew/cubew_services.c:568: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 transformed_value[ to_sizeof ];
data/cubew-4.5/src/cubew/cubew_services.c:578:13:  [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( target_row, row, size * to_sizeof );
data/cubew-4.5/src/cubew/cubew_services.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.
        memcpy( ( uint8_t* )target_row + i * to_sizeof, transformed_value, to_sizeof );
data/cubew-4.5/src/cubew/cubew_services.c:975:13:  [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( ( uint8_t* )row + pos, element, elements_size );
data/cubew-4.5/src/cubew/cubew_services.c:1300:21:  [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.
                    strcat( r, "&lt;" );
data/cubew-4.5/src/cubew/cubew_services.c:1303:21:  [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.
                    strcat( r, "&gt;" );
data/cubew-4.5/src/cubew/cubew_services.c:1306:21:  [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.
                    strcat( r, "&amp;" );
data/cubew-4.5/src/cubew/cubew_services.c:1309:21:  [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.
                    strcat( r, "&apos;" );
data/cubew-4.5/src/cubew/cubew_services.c:1312:21:  [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.
                    strcat( r, "&quot;" );
data/cubew-4.5/src/cubew/cubew_services.c:1377:9:  [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     ch[ 8 ];
data/cubew-4.5/src/cubew/cubew_services.c:1433:9:  [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[ foundlen + 1 ];
data/cubew-4.5/src/cubew/cubew_services.c:1435: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( buf, mystr1, foundlen );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:59:5:  [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.
    strcat( buff, ".cubex" );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:71:5:  [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( header->checksum, pre_checksum,  strlen( pre_checksum ) );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:102:5:  [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( tar_header->name, filename,  strlen( filename ) );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:103:5:  [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( tar_header->mode, tar_writer->mode,  strlen( tar_writer->mode ) );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:108:5:  [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( tar_header->typeflag, "0", 1 );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:109:5:  [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( tar_header->uname, tar_writer->username, strlen( tar_writer->username ) );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:110:5:  [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( tar_header->gname, tar_writer->group, strlen( tar_writer->group ) );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:113:5:  [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( tar_header->magic, _magic, strlen( _magic ) );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:115:5:  [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( tar_header->version, _version, strlen( _version ) );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:173:5:  [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( tar4pax->typeflag, "x", 1 );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:368:5:  [2] (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 string.
    strcpy( tar_writer->group, "users" );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:372:35:  [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).
    tar_writer->tar             = fopen( tar_writer->actual_tar_file, "wb" );
data/cubew-4.5/src/cubew/cubew_tar_writing.h:37: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 name[ 100 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:38: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 mode[ 8 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:39: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 uid[ 8 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:40: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 gid[ 8 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:41: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 size[ 12 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:42: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 mtime[ 12 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:43: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 checksum[ 8 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:44: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 typeflag[ 1 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:45: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 linkname[ 100 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:46: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 magic[ 6 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:47: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 version[ 2 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:48: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 uname[ 32 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:49: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 gname[ 32 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:50: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 devmajor[ 8 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:51: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 devminor[ 8 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h: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 atime[ 12 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:53: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 ctime[ 12 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:54: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 offset[ 12 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:55: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 longnames[ 4 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:56: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 unused[ 1 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:59:9:  [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 offset[ 12 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:60:9:  [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 numbytes[ 12 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:62: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 isextended[ 1 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:63: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 realsize[ 12 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:64: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 pad[ 17 ];
data/cubew-4.5/src/cubew/cubew_tar_writing.h:70: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 block[ TAR_BLOCKSIZE ];
data/cubew-4.5/src/cubew/cubew_types.h:718: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 as_array[ 1 ];
data/cubew-4.5/common/utils/src/cstr/UTILS_CStr.c:42: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).
    char* dup = ( char* )malloc( strlen( source ) + 1 );
data/cubew-4.5/common/utils/src/cstr/UTILS_CStr.c:57: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).
    const size_t length = strlen( pattern );
data/cubew-4.5/common/utils/src/exception/UTILS_Debug.c:350:39:  [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( msgFormatString ) : 0;
data/cubew-4.5/common/utils/src/exception/UTILS_Error.c:108: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).
                                          strlen( msgFormatString ) : 0;
data/cubew-4.5/common/utils/src/exception/normalize_file.h:47: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).
    size_t      srcdir_len      = strlen( srcdir );
data/cubew-4.5/common/utils/src/io/UTILS_IO_GetExe.c:115: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).
            path_len       = strlen( current_path );
data/cubew-4.5/common/utils/src/io/UTILS_IO_GetExe.c:116: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).
            full_file_name = ( char* )malloc( path_len + strlen( exe ) + 2 );
data/cubew-4.5/common/utils/src/io/UTILS_IO_GetExe.c:127:44:  [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).
            full_file_name[ path_len + 1 + strlen( exe ) ] = '\0';
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:89: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).
    while ( strlen( *buffer ) == *buffer_size - 1 )
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:118: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).
    return strcspn( path, "/" ) < strlen( path );
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:126: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).
    int len = strlen( path );
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:316: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).
        size_t path_len = strlen( path );
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:331: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).
        total_length += strlen( sep ) + path_len;
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:358: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).
        size_t path_len = strlen( path );
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:365: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).
        total_length += strlen( sep );
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:398:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
    strncpy( name, computer_name, effective_name_len );
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:409: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).
    size_t len = strlen( hostname ) + 1; /* For terminating zero */
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:414:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
    strncpy( name, hostname, len );
data/cubew-4.5/common/utils/src/io/UTILS_IO_Tools.c:451: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).
    size_t len = strlen( cwd );
data/cubew-4.5/common/utils/test/cutest/CuTest.c:31:20:  [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( old );
data/cubew-4.5/common/utils/test/cutest/CuTest.c:101:14:  [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( text );
data/cubew-4.5/common/utils/test/cutest/CuTest.c:146: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 length = strlen( text );
data/cubew-4.5/src/cubew/cubew_services.c:1274:21:  [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( s );
data/cubew-4.5/src/cubew/cubew_services.c:1295:13:  [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( r, p, n );
data/cubew-4.5/src/cubew/cubew_services.c:1417: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).
    char* new_str = CUBEW_CALLOC( strlen( str ) + 1, 1, MEMORY_TRACING_PREFIX "Allocate string for duplication" );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:57:44:  [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).
    char* buff = ( char* )CUBEW_CALLOC( 1, strlen( cubename ) + 7, MEMORY_TRACING_PREFIX "Allocate cubename" );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:71:46:  [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).
    memcpy( header->checksum, pre_checksum,  strlen( pre_checksum ) );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:102: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).
    memcpy( tar_header->name, filename,  strlen( filename ) );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:103: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).
    memcpy( tar_header->mode, tar_writer->mode,  strlen( tar_writer->mode ) );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:109:54:  [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).
    memcpy( tar_header->uname, tar_writer->username, strlen( tar_writer->username ) );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:110:51:  [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).
    memcpy( tar_header->gname, tar_writer->group, strlen( tar_writer->group ) );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:113:40:  [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).
    memcpy( tar_header->magic, _magic, strlen( _magic ) );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:115:44:  [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).
    memcpy( tar_header->version, _version, strlen( _version ) );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:171: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).
    uint8_t len = strlen( ( char* )pax_block );
data/cubew-4.5/src/cubew/cubew_tar_writing.c:214: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).
        char* paxname = calloc( 1, 11 + strlen( dataname ) );
data/cubew-4.5/src/tools/cubew_config/cubew_config_data.cpp:124: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).
                j->replace( index, strlen( "-R" ), "" );
data/cubew-4.5/src/tools/cubew_config/cubew_config_data.cpp:171: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).
        rpath_flag.replace( index, strlen( "$wl" ), wl );
data/cubew-4.5/test/test3/cube_self_test3.c:151: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).
    cube_write_misc_data( cube, "Humpty Dumpty", test1, strlen( test1 ) );
data/cubew-4.5/test/test3/cube_self_test3.c:180:55:  [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).
    cube_write_misc_data( cube, "Jabberwocky", test2, strlen( test2 ) );
data/cubew-4.5/test/test3/cube_self_test3_3.c:155: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).
    cube_write_misc_data( cube, "Humpty Dumpty", test1, strlen( test1 ) );
data/cubew-4.5/test/test3/cube_self_test3_3.c:184:55:  [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).
    cube_write_misc_data( cube, "Jabberwocky", test2, strlen( test2 ) );

ANALYSIS SUMMARY:

Hits = 183
Lines analyzed = 25198 in approximately 0.76 seconds (33017 lines/second)
Physical Source Lines of Code (SLOC) = 17570
Hits@level = [0]  97 [1]  41 [2]  91 [3]  27 [4]  24 [5]   0
Hits@level+ = [0+] 280 [1+] 183 [2+] 142 [3+]  51 [4+]  24 [5+]   0
Hits/KSLOC@level+ = [0+] 15.9363 [1+] 10.4155 [2+] 8.08196 [3+] 2.90268 [4+] 1.36596 [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.