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/eztrace-1.1-10/example/libexample_eztrace/example.c Examining data/eztrace-1.1-10/example/libexample_eztrace/example_ev_codes.h Examining data/eztrace-1.1-10/example/libexample_eztrace/eztrace_convert_example.c Examining data/eztrace-1.1-10/example/libexample_orig/example.c Examining data/eztrace-1.1-10/example/libexample_orig/example.h Examining data/eztrace-1.1-10/example/libexample_orig/main.c Examining data/eztrace-1.1-10/example/libexample_orig/static_example.c Examining data/eztrace-1.1-10/src/core/ev_codes.h Examining data/eztrace-1.1-10/src/core/ezt_demangle.c Examining data/eztrace-1.1-10/src/core/ezt_demangle.h Examining data/eztrace-1.1-10/src/core/eztrace.h Examining data/eztrace-1.1-10/src/core/eztrace_array.c Examining data/eztrace-1.1-10/src/core/eztrace_array.h Examining data/eztrace-1.1-10/src/core/eztrace_avail.c Examining data/eztrace-1.1-10/src/core/eztrace_convert.c Examining data/eztrace-1.1-10/src/core/eztrace_convert.h Examining data/eztrace-1.1-10/src/core/eztrace_convert_core.c Examining data/eztrace-1.1-10/src/core/eztrace_convert_core.h Examining data/eztrace-1.1-10/src/core/eztrace_convert_macros.h Examining data/eztrace-1.1-10/src/core/eztrace_convert_types.h Examining data/eztrace-1.1-10/src/core/eztrace_core.c Examining data/eztrace-1.1-10/src/core/eztrace_hierarchical_array.c Examining data/eztrace-1.1-10/src/core/eztrace_hierarchical_array.h Examining data/eztrace-1.1-10/src/core/eztrace_hook.h Examining data/eztrace-1.1-10/src/core/eztrace_list.h Examining data/eztrace-1.1-10/src/core/eztrace_litl.h Examining data/eztrace-1.1-10/src/core/eztrace_litl_packed.h Examining data/eztrace-1.1-10/src/core/eztrace_loaded.c Examining data/eztrace-1.1-10/src/core/eztrace_sampling.c Examining data/eztrace-1.1-10/src/core/eztrace_sampling.h Examining data/eztrace-1.1-10/src/core/eztrace_stack.h Examining data/eztrace-1.1-10/src/core/eztrace_stats.c Examining data/eztrace-1.1-10/src/core/eztrace_stats_core.c Examining data/eztrace-1.1-10/src/core/eztrace_stats_core.h Examining data/eztrace-1.1-10/src/core/eztrace_types.h Examining data/eztrace-1.1-10/src/core/pthread_core.c Examining data/eztrace-1.1-10/src/core/submodules/ezt_getcpu.c Examining data/eztrace-1.1-10/src/core/submodules/ezt_getcpu.h Examining data/eztrace-1.1-10/src/core/submodules/ezt_getcpu_convert.c Examining data/eztrace-1.1-10/src/core/submodules/ezt_submodule.c Examining data/eztrace-1.1-10/src/core/submodules/ezt_submodule.h Examining data/eztrace-1.1-10/src/core/submodules/ezt_submodule_convert.c Examining data/eztrace-1.1-10/src/modules/cuda/cuda_ev_codes.h Examining data/eztrace-1.1-10/src/modules/cuda/ezt_cuda.h Examining data/eztrace-1.1-10/src/modules/cuda/eztrace_convert_cuda.c Examining data/eztrace-1.1-10/src/modules/memory/eztrace_convert_memory.c Examining data/eztrace-1.1-10/src/modules/memory/memory.c Examining data/eztrace-1.1-10/src/modules/memory/memory_ev_codes.h Examining data/eztrace-1.1-10/src/modules/mpi/eztrace_convert_mpi.c Examining data/eztrace-1.1-10/src/modules/mpi/eztrace_convert_mpi.h Examining data/eztrace-1.1-10/src/modules/mpi/eztrace_convert_mpi_coll.c Examining data/eztrace-1.1-10/src/modules/mpi/eztrace_convert_mpi_coll.h Examining data/eztrace-1.1-10/src/modules/mpi/eztrace_convert_mpi_p2p.c Examining data/eztrace-1.1-10/src/modules/mpi/eztrace_convert_mpi_p2p.h Examining data/eztrace-1.1-10/src/modules/mpi/eztrace_convert_mpi_pers.c Examining data/eztrace-1.1-10/src/modules/mpi/eztrace_convert_mpi_pers.h Examining data/eztrace-1.1-10/src/modules/mpi/eztrace_stats_mpi.c Examining data/eztrace-1.1-10/src/modules/mpi/eztrace_stats_mpi.h Examining data/eztrace-1.1-10/src/modules/mpi/mpi.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_ev_codes.h Examining data/eztrace-1.1-10/src/modules/mpi/mpi_eztrace.h Examining data/eztrace-1.1-10/src/modules/mpi/mpi_fortran.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_allgather.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_allgatherv.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_allreduce.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_alltoall.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_alltoallv.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_barrier.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_bcast.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_bsend.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_bsend_init.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_cancel.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_gather.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_gatherv.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_get.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_iallgather.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_iallgatherv.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_iallreduce.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_ialltoall.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_ialltoallv.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_ibarrier.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_ibcast.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_ibsend.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_igather.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_igatherv.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_iprobe.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_irecv.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_ireduce.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_ireduce_scatter.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_irsend.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_iscan.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_iscatter.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_iscatterv.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_isend.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_issend.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_probe.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_put.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_recv.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_recv_init.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_reduce.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_reduce_scatter.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_rsend.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_rsend_init.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_scan.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_scatter.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_scatterv.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_send.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_send_init.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_sendrecv.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_sendrecv_replace.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_ssend.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_ssend_init.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_start.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_startall.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_test.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_testall.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_testany.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_testsome.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_wait.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_waitall.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_waitany.c Examining data/eztrace-1.1-10/src/modules/mpi/mpi_funcs/mpi_waitsome.c Examining data/eztrace-1.1-10/src/modules/omp/gomp_ev_codes.h Examining data/eztrace-1.1-10/src/modules/omp/eztrace_convert_gomp.c Examining data/eztrace-1.1-10/src/modules/omp/gomp.c Examining data/eztrace-1.1-10/src/modules/papi/eztrace_convert_papi.c Examining data/eztrace-1.1-10/src/modules/papi/papi.c Examining data/eztrace-1.1-10/src/modules/papi/papi_ev_codes.h Examining data/eztrace-1.1-10/src/modules/pthread/eztrace_convert_pthread.c Examining data/eztrace-1.1-10/src/modules/pthread/eztrace_convert_pthread.h Examining data/eztrace-1.1-10/src/modules/pthread/pthread.c Examining data/eztrace-1.1-10/src/modules/pthread/pthread_ev_codes.h Examining data/eztrace-1.1-10/src/modules/starpu/eztrace_convert_starpu.c Examining data/eztrace-1.1-10/src/modules/starpu/eztrace_convert_starpu.h Examining data/eztrace-1.1-10/src/modules/starpu/starpu_ev_codes.h Examining data/eztrace-1.1-10/src/modules/starpu/starpu.c Examining data/eztrace-1.1-10/src/modules/stdio/eztrace_convert_stdio.c Examining data/eztrace-1.1-10/src/modules/stdio/stdio.c Examining data/eztrace-1.1-10/src/modules/stdio/stdio_ev_codes.h Examining data/eztrace-1.1-10/src/pptrace/arch/armv7/opcode.c Examining data/eztrace-1.1-10/src/pptrace/arch/armv7/trace.c Examining data/eztrace-1.1-10/src/pptrace/arch/bfd.c Examining data/eztrace-1.1-10/src/pptrace/arch/elf.c Examining data/eztrace-1.1-10/src/pptrace/arch/x86_64/hijack.c Examining data/eztrace-1.1-10/src/pptrace/arch/x86_64/opcode.c Examining data/eztrace-1.1-10/src/pptrace/arch/x86_64/trace.c Examining data/eztrace-1.1-10/src/pptrace/binary.c Examining data/eztrace-1.1-10/src/pptrace/binary.h Examining data/eztrace-1.1-10/src/pptrace/cpu/arm.c Examining data/eztrace-1.1-10/src/pptrace/cpu/intel.c Examining data/eztrace-1.1-10/src/pptrace/errors.c Examining data/eztrace-1.1-10/src/pptrace/errors.h Examining data/eztrace-1.1-10/src/pptrace/hijack.c Examining data/eztrace-1.1-10/src/pptrace/hijack.h Examining data/eztrace-1.1-10/src/pptrace/isize.c Examining data/eztrace-1.1-10/src/pptrace/isize.h Examining data/eztrace-1.1-10/src/pptrace/memory.c Examining data/eztrace-1.1-10/src/pptrace/memory.h Examining data/eztrace-1.1-10/src/pptrace/opcodes.c Examining data/eztrace-1.1-10/src/pptrace/opcodes.h Examining data/eztrace-1.1-10/src/pptrace/os/linux/linux.c Examining data/eztrace-1.1-10/src/pptrace/os/linux/linux.h Examining data/eztrace-1.1-10/src/pptrace/pptrace.c Examining data/eztrace-1.1-10/src/pptrace/pptrace.h Examining data/eztrace-1.1-10/src/pptrace/tracing.c Examining data/eztrace-1.1-10/src/pptrace/tracing.h Examining data/eztrace-1.1-10/src/pptrace/types.h Examining data/eztrace-1.1-10/test/automake/testmemory.c Examining data/eztrace-1.1-10/test/automake/testmpiring.c Examining data/eztrace-1.1-10/test/automake/testopenmplock.c Examining data/eztrace-1.1-10/test/automake/testopenmpnestlock.c Examining data/eztrace-1.1-10/test/automake/testopenmpsimple.c Examining data/eztrace-1.1-10/test/automake/testpthreadcond.c Examining data/eztrace-1.1-10/test/automake/testpthreaddummy_thread.c Examining data/eztrace-1.1-10/test/automake/testpthreadrace_cond.c Examining data/eztrace-1.1-10/test/automake/testpthreadtest.c Examining data/eztrace-1.1-10/test/automake/teststatic.c Examining data/eztrace-1.1-10/test/automake/teststdio.c Examining data/eztrace-1.1-10/test/memory/memory.c Examining data/eztrace-1.1-10/test/memory/tests/vector.cxx Examining data/eztrace-1.1-10/test/module_generator/example_application/example.c Examining data/eztrace-1.1-10/test/module_generator/example_application/example.h Examining data/eztrace-1.1-10/test/module_generator/example_application/main.c Examining data/eztrace-1.1-10/test/module_generator/test_pptrace_application/main.c Examining data/eztrace-1.1-10/test/module_generator/test_pptrace_application/test_pptrace.c Examining data/eztrace-1.1-10/test/module_generator/test_pptrace_application/test_pptrace.h Examining data/eztrace-1.1-10/test/mpi/allgather.c Examining data/eztrace-1.1-10/test/mpi/mpi_communicators/comm_p2p.c Examining data/eztrace-1.1-10/test/mpi/mpi_eztrace_start.c Examining data/eztrace-1.1-10/test/mpi/mpi_multiring.c Examining data/eztrace-1.1-10/test/mpi/mpi_openmp.c Examining data/eztrace-1.1-10/test/mpi/mpi_ping.c Examining data/eztrace-1.1-10/test/mpi/mpi_ring.c Examining data/eztrace-1.1-10/test/mpi/mpi_spawn.c Examining data/eztrace-1.1-10/test/mpi/persistent.c Examining data/eztrace-1.1-10/test/mpi/test_mpi.c Examining data/eztrace-1.1-10/test/mpi/waitall.c Examining data/eztrace-1.1-10/test/mpi/waitany.c Examining data/eztrace-1.1-10/test/openmp/openmp_nowait_c.c Examining data/eztrace-1.1-10/test/openmp/openmp_simple.c Examining data/eztrace-1.1-10/test/openmp/parallel.c Examining data/eztrace-1.1-10/test/openmp/test_lock.c Examining data/eztrace-1.1-10/test/openmp/test_nest_lock.c Examining data/eztrace-1.1-10/test/openmp/test_task.c Examining data/eztrace-1.1-10/test/performance/example_application/example.c Examining data/eztrace-1.1-10/test/performance/example_application/example.h Examining data/eztrace-1.1-10/test/performance/example_application/main.c Examining data/eztrace-1.1-10/test/performance/example_application/plugin_main/eztrace_convert_main.c Examining data/eztrace-1.1-10/test/performance/example_application/plugin_main/main.c Examining data/eztrace-1.1-10/test/performance/example_application/plugin_main/main_ev_codes.h Examining data/eztrace-1.1-10/test/pptrace/automatic/binary.c Examining data/eztrace-1.1-10/test/pptrace/automatic/common.h Examining data/eztrace-1.1-10/test/pptrace/automatic/errors.c Examining data/eztrace-1.1-10/test/pptrace/automatic/hijack.c Examining data/eztrace-1.1-10/test/pptrace/automatic/opcodes.c Examining data/eztrace-1.1-10/test/pptrace/automatic/testcase/titi.c Examining data/eztrace-1.1-10/test/pptrace/automatic/tracing.c Examining data/eztrace-1.1-10/test/pptrace/automatic/wait_open.c Examining data/eztrace-1.1-10/test/pptrace/comparison/instrument/dyninst/my_dyninst.cpp Examining data/eztrace-1.1-10/test/pptrace/comparison/instrument/libinstrument-dummy/instrument.c Examining data/eztrace-1.1-10/test/pptrace/comparison/instrument/libinstrument-dummy/instrument.h Examining data/eztrace-1.1-10/test/pptrace/comparison/instrument/libinstrument-real/instrument.c Examining data/eztrace-1.1-10/test/pptrace/comparison/instrument/libinstrument-real/instrument.h Examining data/eztrace-1.1-10/test/pptrace/comparison/instrument/pin/my_pin.cpp Examining data/eztrace-1.1-10/test/pptrace/comparison/instrument/pptrace/instrument_pptrace.c Examining data/eztrace-1.1-10/test/pptrace/comparison/programs/compute/compute.c Examining data/eztrace-1.1-10/test/pptrace/comparison/programs/md/dyninst/my_dyninst.cpp Examining data/eztrace-1.1-10/test/pptrace/comparison/programs/md/eztrace_plugin/instrument_pptrace.c Examining data/eztrace-1.1-10/test/pptrace/comparison/programs/md/pin/my_pin.cpp Examining data/eztrace-1.1-10/test/pptrace/comparison/programs/simple/foo.c Examining data/eztrace-1.1-10/test/pptrace/comparison/programs/simple/simple.c Examining data/eztrace-1.1-10/test/pptrace/perf/instrumentation/dummy_dyninst.cc Examining data/eztrace-1.1-10/test/pptrace/perf/instrumentation/dyninst.cc Examining data/eztrace-1.1-10/test/pptrace/perf/instrumentation/dyninst_common.h Examining data/eztrace-1.1-10/test/pptrace/perf/instrumentation/pin_dummy.cc Examining data/eztrace-1.1-10/test/pptrace/perf/instrumentation/pin_fast.cc Examining data/eztrace-1.1-10/test/pptrace/perf/instrumentation/pin_probed.cc Examining data/eztrace-1.1-10/test/pptrace/perf/instrumentation/pptrace.c Examining data/eztrace-1.1-10/test/pptrace/perf/tests/alacon.h Examining data/eztrace-1.1-10/test/pptrace/perf/tests/hijacks.h Examining data/eztrace-1.1-10/test/pptrace/perf/tests/libalacon.c Examining data/eztrace-1.1-10/test/pptrace/perf/tests/libdyninst.c Examining data/eztrace-1.1-10/test/pptrace/perf/tests/libmatrix.c Examining data/eztrace-1.1-10/test/pptrace/perf/tests/libpptrace.c Examining data/eztrace-1.1-10/test/pptrace/perf/tests/libpreload.c Examining data/eztrace-1.1-10/test/pptrace/perf/tests/prog.c Examining data/eztrace-1.1-10/test/pthread/cond.c Examining data/eztrace-1.1-10/test/pthread/dummy_thread.c Examining data/eztrace-1.1-10/test/pthread/race_cond.c Examining data/eztrace-1.1-10/test/pthread/test_pthread.c Examining data/eztrace-1.1-10/test/pthread/test_sigsegv.c Examining data/eztrace-1.1-10/test/static/eztrace_convert_staticlib.c Examining data/eztrace-1.1-10/test/static/static.c Examining data/eztrace-1.1-10/test/static/staticlib.c Examining data/eztrace-1.1-10/test/static/staticlib_ev_codes.h Examining data/eztrace-1.1-10/test/stdio/stdio.c FINAL RESULTS: data/eztrace-1.1-10/src/core/eztrace.h:125:7: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. fprintf(stderr, ##args); \ data/eztrace-1.1-10/src/core/eztrace_convert_core.c:139:7: [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(__VA_ARGS__); \ data/eztrace-1.1-10/src/core/eztrace_convert_macros.h:36:7: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. fprintf(stderr, ##args); \ data/eztrace-1.1-10/src/core/eztrace_core.c:75:3: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf(__ezt_trace.filename, "%s/%s_%s", __eztrace_get_filedir(), getenv("USER"), data/eztrace-1.1-10/src/modules/cuda/eztrace_convert_cuda.c:759:3: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf(p_kernel->state_desc, "kernel %s", p_kernel->name); data/eztrace-1.1-10/src/modules/omp/eztrace_convert_gomp.c:27:21: [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. # define OMP_PRINTF printf x data/eztrace-1.1-10/src/pptrace/errors.c:45:3: [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. vsnprintf(errmsg, sizeof(errmsg), fmt, va); data/eztrace-1.1-10/src/pptrace/errors.c:53:3: [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, fmt, va); data/eztrace-1.1-10/src/pptrace/errors.c:69:3: [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, fmt, va); data/eztrace-1.1-10/src/pptrace/errors.c:79: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(stderr, fmt, va); data/eztrace-1.1-10/src/pptrace/pptrace.c:458:3: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy(result, ldpreload); data/eztrace-1.1-10/src/pptrace/pptrace.c:464: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(result + nsize, first->library); data/eztrace-1.1-10/src/pptrace/pptrace.c:476: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(result + nsize, envpreload); data/eztrace-1.1-10/src/pptrace/pptrace.c:577:12: [4] (shell) popen: This causes a new program to execute and is difficult to use safely (CWE-78). try using a library call that implements the same functionality if available. FILE*f = popen(cmd, "r"); data/eztrace-1.1-10/test/memory/memory.c:52: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(stderr, fmt, va); data/eztrace-1.1-10/test/mpi/mpi_eztrace_start.c:37: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, fmt, va); data/eztrace-1.1-10/test/mpi/mpi_ring.c:27: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, fmt, va); data/eztrace-1.1-10/test/openmp/openmp_nowait_c.c:27: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, fmt, va); data/eztrace-1.1-10/test/openmp/openmp_simple.c:27: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, fmt, va); data/eztrace-1.1-10/test/openmp/parallel.c:27: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, fmt, va); data/eztrace-1.1-10/test/openmp/test_lock.c:27: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, fmt, va); data/eztrace-1.1-10/test/openmp/test_nest_lock.c:28: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, fmt, va); data/eztrace-1.1-10/test/openmp/test_task.c:27: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, fmt, va); data/eztrace-1.1-10/test/pptrace/automatic/binary.c:72:5: [4] (shell) execlp: 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. execlp("nm", "nm", path, NULL); data/eztrace-1.1-10/test/pptrace/automatic/wait_open.c:120: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(lib, argv[i]); data/eztrace-1.1-10/test/pptrace/comparison/instrument/libinstrument-real/instrument.c:73:3: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf(PROF_FILE_USER, "/var/tmp/%s_trace", getenv("USER")); data/eztrace-1.1-10/test/pthread/cond.c:26: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, fmt, va); data/eztrace-1.1-10/test/pthread/dummy_thread.c:30: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, fmt, va); data/eztrace-1.1-10/test/pthread/race_cond.c:28: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, fmt, va); data/eztrace-1.1-10/test/pthread/test_pthread.c:30: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, fmt, va); data/eztrace-1.1-10/test/pthread/test_sigsegv.c:30: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, fmt, va); data/eztrace-1.1-10/test/static/static.c:27: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, fmt, va); data/eztrace-1.1-10/test/stdio/stdio.c:34: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(stderr, fmt, va); data/eztrace-1.1-10/test/stdio/stdio.c:37: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(f, fmt, va); data/eztrace-1.1-10/src/core/eztrace.h:212:32: [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. #define ezt_is_in_launcher() ((getenv("TESTLAUNCHER") != NULL) && (strcmp(getenv("TESTLAUNCHER"), "1") == 0)) data/eztrace-1.1-10/src/core/eztrace.h:212:75: [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. #define ezt_is_in_launcher() ((getenv("TESTLAUNCHER") != NULL) && (strcmp(getenv("TESTLAUNCHER"), "1") == 0)) data/eztrace-1.1-10/src/core/eztrace_convert_core.c:88:19: [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* ezt_debug=getenv("EZTRACE_DEBUG"); data/eztrace-1.1-10/src/core/eztrace_convert_core.c:895:14: [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. lib_path = getenv("EZTRACE_LIBRARY_PATH"); data/eztrace-1.1-10/src/core/eztrace_convert_core.c:921: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. char* module_list = getenv("EZTRACE_TRACE"); data/eztrace-1.1-10/src/core/eztrace_core.c:52:15: [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* res = getenv("EZTRACE_BUFFER_SIZE"); data/eztrace-1.1-10/src/core/eztrace_core.c:59:15: [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* res = getenv("EZTRACE_TRACE_DIR"); data/eztrace-1.1-10/src/core/eztrace_core.c:67:24: [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. total_size += strlen(getenv("USER")); data/eztrace-1.1-10/src/core/eztrace_core.c:75:70: [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. sprintf(__ezt_trace.filename, "%s/%s_%s", __eztrace_get_filedir(), getenv("USER"), data/eztrace-1.1-10/src/core/eztrace_core.c:235:15: [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* res = getenv("EZTRACE_NO_SIGNAL_HANDLER"); data/eztrace-1.1-10/src/core/eztrace_core.c:246:9: [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. res = getenv("EZTRACE_SIGALARM"); data/eztrace-1.1-10/src/core/eztrace_core.c:271: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* debug_mode = getenv("EZTRACE_DEBUG"); data/eztrace-1.1-10/src/core/eztrace_core.c:286: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. char* allow_flush = getenv("EZTRACE_FLUSH"); data/eztrace-1.1-10/src/core/eztrace_stats.c:106: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. asprintf(&output_path, "./eztrace_stats_%s", getenv("USER")); data/eztrace-1.1-10/src/core/eztrace_stats.c:115:50: [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. asprintf(&output_path, "./eztrace_stats_%s", getenv("USER")); data/eztrace-1.1-10/src/core/submodules/ezt_getcpu.c:43:15: [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* str = getenv("EZTRACE_USE_GETCPU"); data/eztrace-1.1-10/src/core/submodules/ezt_getcpu.c:46:20: [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* str2 = getenv("EZTRACE_GETCPU_INTERVAL"); data/eztrace-1.1-10/src/modules/mpi/eztrace_stats_mpi.c:696:19: [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_str = getenv("EZTRACE_MPI_DUMP_MESSAGES"); data/eztrace-1.1-10/src/modules/mpi/eztrace_stats_mpi.c:702: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. eztrace_stats_get_output_dir(), getenv("USER")); data/eztrace-1.1-10/src/modules/mpi/mpi.c:365: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* ld_preload = getenv(LD_PRELOAD_NAME); data/eztrace-1.1-10/src/modules/omp/gomp.c:781:15: [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* str = getenv("OMP_RECORD_CALLSITE"); data/eztrace-1.1-10/src/modules/papi/papi.c:236: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. char* env1 = getenv("EZTRACE_PAPI_COUNTERS"); data/eztrace-1.1-10/src/modules/papi/papi.c:305:15: [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=getenv("EZTRACE_PAPI_SAMPLE_INTERVAL"); data/eztrace-1.1-10/src/pptrace/pptrace.c:77:16: [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 = getenv("PATH"); data/eztrace-1.1-10/src/pptrace/pptrace.c:84:15: [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 *ifs = getenv("IFS"); data/eztrace-1.1-10/src/pptrace/pptrace.c:470: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 *envpreload = getenv("LD_PRELOAD"); data/eztrace-1.1-10/test/memory/memory.c:43: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 *buf = getenv("DEBUG_LEVEL"); data/eztrace-1.1-10/test/mpi/mpi_eztrace_start.c:28: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 *buf = getenv("EZTRACE_DEBUG"); data/eztrace-1.1-10/test/mpi/mpi_ring.c:18: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 *buf = getenv("EZTRACE_DEBUG"); data/eztrace-1.1-10/test/openmp/openmp_nowait_c.c:18: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 *buf = getenv("EZTRACE_DEBUG"); data/eztrace-1.1-10/test/openmp/openmp_simple.c:18: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 *buf = getenv("EZTRACE_DEBUG"); data/eztrace-1.1-10/test/openmp/parallel.c:18: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 *buf = getenv("EZTRACE_DEBUG"); data/eztrace-1.1-10/test/openmp/test_lock.c:18: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 *buf = getenv("EZTRACE_DEBUG"); data/eztrace-1.1-10/test/openmp/test_nest_lock.c:19: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 *buf = getenv("EZTRACE_DEBUG"); data/eztrace-1.1-10/test/openmp/test_task.c:18: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 *buf = getenv("EZTRACE_DEBUG"); data/eztrace-1.1-10/test/pptrace/comparison/instrument/libinstrument-real/instrument.c:73: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. sprintf(PROF_FILE_USER, "/var/tmp/%s_trace", getenv("USER")); data/eztrace-1.1-10/test/pthread/cond.c:17: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 *buf = getenv("EZTRACE_DEBUG"); data/eztrace-1.1-10/test/pthread/dummy_thread.c:21: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 *buf = getenv("EZTRACE_DEBUG"); data/eztrace-1.1-10/test/pthread/race_cond.c:19: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 *buf = getenv("EZTRACE_DEBUG"); data/eztrace-1.1-10/test/pthread/test_pthread.c:21: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 *buf = getenv("EZTRACE_DEBUG"); data/eztrace-1.1-10/test/pthread/test_sigsegv.c:21: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 *buf = getenv("EZTRACE_DEBUG"); data/eztrace-1.1-10/test/pthread/test_sigsegv.c:131:3: [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(time(NULL)); data/eztrace-1.1-10/test/static/static.c:18: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 *buf = getenv("EZTRACE_DEBUG"); data/eztrace-1.1-10/test/stdio/stdio.c:25: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 *buf = getenv("EZTRACE_DEBUG"); data/eztrace-1.1-10/src/core/eztrace.h:229: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 __buff[1024]; \ data/eztrace-1.1-10/src/core/eztrace_convert_core.c:90:25: [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). __ezt_debug_level = atoi(ezt_debug); data/eztrace-1.1-10/src/core/eztrace_convert_core.c:187: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(&p_trace->ev, p_ev, sizeof(litl_read_event_t)); data/eztrace-1.1-10/src/core/eztrace_convert_core.c:207:4: [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(&p_trace->ev, p_ev, sizeof(litl_read_event_t)); data/eztrace-1.1-10/src/core/eztrace_core.c:54:31: [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). __ezt_trace.buffer_size = atoi(res); data/eztrace-1.1-10/src/core/eztrace_core.c:250:28: [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). __ezt_alarm_interval = atoi(res)*1000000; data/eztrace-1.1-10/src/core/eztrace_core.c:251:56: [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). printf("[EZTrace] Setting an alarm every %d ms\n", atoi(res)); data/eztrace-1.1-10/src/core/eztrace_core.c:273:33: [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). __ezt_trace.debug_level = atoi(debug_mode); data/eztrace-1.1-10/src/core/eztrace_core.c:515:10: [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. __thread char current_frame[1024]; data/eztrace-1.1-10/src/core/eztrace_core.c:594: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 buffer[1024]; data/eztrace-1.1-10/src/core/eztrace_litl.h:20: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(ptr, LITL_READ_RAW(p_ev)->data, LITL_READ_RAW(p_ev)->size); \ data/eztrace-1.1-10/src/core/submodules/ezt_getcpu.c:50: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). interval = atoi(str2); data/eztrace-1.1-10/src/modules/cuda/eztrace_convert_cuda.c:64:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char state_id[80]; data/eztrace-1.1-10/src/modules/cuda/eztrace_convert_cuda.c:65:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char state_desc[80]; data/eztrace-1.1-10/src/modules/cuda/eztrace_convert_cuda.c:66:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char name[80]; data/eztrace-1.1-10/src/modules/cuda/eztrace_convert_cuda.c:87:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char link_str[80]; data/eztrace-1.1-10/src/modules/cuda/eztrace_convert_cuda.c:99:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char link_str[80]; data/eztrace-1.1-10/src/modules/cuda/eztrace_convert_cuda.c:758:3: [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(p_kernel->state_id, "cuda_kernel_%x", p_kernel->id); data/eztrace-1.1-10/src/modules/memory/memory.c:119:10: [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. static char mem[POOL_SIZE] = {'\0'}; data/eztrace-1.1-10/src/modules/mpi/eztrace_convert_mpi_coll.c:70:17: [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 *f = fopen(path, "w"); data/eztrace-1.1-10/src/modules/mpi/eztrace_stats_mpi.c:342:17: [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 *out = fopen(path, "w+"); data/eztrace-1.1-10/src/modules/mpi/eztrace_stats_mpi.c:366:17: [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 *out = fopen(path, "w+"); data/eztrace-1.1-10/src/modules/mpi/eztrace_stats_mpi.c:393:17: [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 *out = fopen(path, "w+"); data/eztrace-1.1-10/src/modules/mpi/eztrace_stats_mpi.c:421:17: [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 *out = fopen(path, "w+"); data/eztrace-1.1-10/src/modules/mpi/eztrace_stats_mpi.c:448:17: [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 *out = fopen(path, "w+"); data/eztrace-1.1-10/src/modules/mpi/eztrace_stats_mpi.c:477:17: [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 *out = fopen(path, "w+"); data/eztrace-1.1-10/src/modules/mpi/eztrace_stats_mpi.c:504:17: [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 *out = fopen(path, "w+"); data/eztrace-1.1-10/src/modules/mpi/eztrace_stats_mpi.c:703:15: [2] (misc) fopen: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). FILE *f = fopen(path, "w"); data/eztrace-1.1-10/src/modules/mpi/eztrace_stats_mpi.c:726:15: [2] (misc) fopen: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). FILE *out = fopen(data_path, "w+"); data/eztrace-1.1-10/src/modules/mpi/eztrace_stats_mpi.c:739:9: [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). out = fopen(gp_path, "w+"); data/eztrace-1.1-10/src/modules/omp/gomp.c:444: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 buffer[1024]; data/eztrace-1.1-10/src/modules/papi/papi.c:308:25: [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). sample_interval = atoi(env); data/eztrace-1.1-10/src/modules/pthread/eztrace_convert_pthread.c:617:7: [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 lock_type[80]; data/eztrace-1.1-10/src/modules/pthread/eztrace_convert_pthread.c:669:4: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char lock_type[80]; data/eztrace-1.1-10/src/modules/pthread/eztrace_convert_pthread.c:676:4: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char lock_type[80]; data/eztrace-1.1-10/src/modules/pthread/eztrace_convert_pthread.c:689:2: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char lock_type[80]; data/eztrace-1.1-10/src/modules/pthread/eztrace_convert_pthread.c:694:2: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char lock_type[80]; data/eztrace-1.1-10/src/modules/pthread/eztrace_convert_pthread.h:62: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(str, "mutex"); data/eztrace-1.1-10/src/modules/pthread/eztrace_convert_pthread.h:65: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(str, "spinlock"); data/eztrace-1.1-10/src/modules/pthread/eztrace_convert_pthread.h:68: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(str, "rwlock"); data/eztrace-1.1-10/src/modules/pthread/eztrace_convert_pthread.h:71: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(str, "semaphore"); data/eztrace-1.1-10/src/modules/pthread/eztrace_convert_pthread.h:74: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(str, "barrier"); data/eztrace-1.1-10/src/modules/pthread/eztrace_convert_pthread.h:77: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(str, "condition"); data/eztrace-1.1-10/src/modules/pthread/eztrace_convert_pthread.h:80: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(str, "<<unknown>>"); data/eztrace-1.1-10/src/modules/pthread/eztrace_convert_pthread.h:94:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char lock_type_str [80]; data/eztrace-1.1-10/src/modules/starpu/eztrace_convert_starpu.c:979: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(proc, "CT_SP#%i", CUR_RANK); data/eztrace-1.1-10/src/modules/starpu/eztrace_convert_starpu.c:1019: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(procCpt,"CT_SP#%i", CUR_RANK); data/eztrace-1.1-10/src/modules/starpu/eztrace_convert_starpu.c:1020: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(proc,"P#%i", CUR_RANK); data/eztrace-1.1-10/src/modules/starpu/eztrace_convert_starpu.c:1690: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(proc, "CT_SP#%i", CUR_RANK); data/eztrace-1.1-10/src/pptrace/arch/elf.c:108:8: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). fd = open(path, O_RDONLY, 0); data/eztrace-1.1-10/src/pptrace/arch/elf.c:234: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(buffer, ((uint8_t*) data->d_buf) + off, result); data/eztrace-1.1-10/src/pptrace/binary.c:29:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char buf2[4096]; data/eztrace-1.1-10/src/pptrace/cpu/intel.c:162: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((void*) (buf + 1), (void*) (&off), sizeof(uint32_t)); data/eztrace-1.1-10/src/pptrace/cpu/intel.c:170: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((void*) (buf + 1), (void*) (&addr), sizeof(uint32_t)); data/eztrace-1.1-10/src/pptrace/cpu/intel.c:180: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((void*) (buf + 2), (void*) (&reloc_addr), sizeof(word_uint)); data/eztrace-1.1-10/src/pptrace/errors.c:21:1: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char errmsg[1024]; data/eztrace-1.1-10/src/pptrace/os/linux/linux.c:194: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(buffer + curAddr, (void*) (&data), data/eztrace-1.1-10/src/pptrace/os/linux/linux.c:264: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((void*) (&data), (void*) (buffer + curAddr), sizeof(word_uint)); data/eztrace-1.1-10/src/pptrace/os/linux/linux.c:271: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((void*) (&data), (void*) (buffer + curAddr), extraBytes); data/eztrace-1.1-10/src/pptrace/pptrace.c:90:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char rpath[1024]; data/eztrace-1.1-10/src/pptrace/pptrace.c:320:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char module_name[1024]; data/eztrace-1.1-10/src/pptrace/pptrace.c:323:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char hijack_symbol[1024]; data/eztrace-1.1-10/src/pptrace/pptrace.c:575:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char cmd[4096]; data/eztrace-1.1-10/src/pptrace/pptrace.c:596:17: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). TRACE_SYSCALL(open)); data/eztrace-1.1-10/src/pptrace/pptrace.c:608:56: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). int r = trace_wait_syscall(child, &fd, TRACE_SYSCALL(open), data/eztrace-1.1-10/src/pptrace/pptrace.c:764: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 pid[10]; data/eztrace-1.1-10/test/memory/memory.c:47:16: [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). _debug = atoi(buf); data/eztrace-1.1-10/test/mpi/mpi_eztrace_start.c:32:16: [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). _debug = atoi(buf); data/eztrace-1.1-10/test/mpi/mpi_eztrace_start.c:48:8: [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. static char host_name[1024] = ""; data/eztrace-1.1-10/test/mpi/mpi_multiring.c:18:8: [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. static char host_name[1024] = ""; data/eztrace-1.1-10/test/mpi/mpi_openmp.c:18:8: [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. static char host_name[1024] = ""; data/eztrace-1.1-10/test/mpi/mpi_ping.c:44:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char host_name[1024] = ""; data/eztrace-1.1-10/test/mpi/mpi_ring.c:22:16: [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). _debug = atoi(buf); data/eztrace-1.1-10/test/mpi/mpi_ring.c:38:8: [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. static char host_name[1024] = ""; data/eztrace-1.1-10/test/mpi/test_mpi.c:17:8: [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. static char host_name[1024] = ""; data/eztrace-1.1-10/test/openmp/openmp_nowait_c.c:22:16: [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). _debug = atoi(buf); data/eztrace-1.1-10/test/openmp/openmp_simple.c:22:16: [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). _debug = atoi(buf); data/eztrace-1.1-10/test/openmp/parallel.c:22:16: [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). _debug = atoi(buf); data/eztrace-1.1-10/test/openmp/test_lock.c:22:16: [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). _debug = atoi(buf); data/eztrace-1.1-10/test/openmp/test_nest_lock.c:23:16: [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). _debug = atoi(buf); data/eztrace-1.1-10/test/openmp/test_task.c:22:16: [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). _debug = atoi(buf); data/eztrace-1.1-10/test/pptrace/automatic/binary.c:134:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char buf[1024]; data/eztrace-1.1-10/test/pptrace/automatic/binary.c:135:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char buf2[1024]; data/eztrace-1.1-10/test/pptrace/automatic/binary.c:215:10: [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). return atoi(path + i + 1); data/eztrace-1.1-10/test/pptrace/automatic/tracing.c:161:10: [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. static char buffer[10]; data/eztrace-1.1-10/test/pptrace/automatic/wait_open.c:60:52: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). if (trace_wait_syscall(child, &fd, TRACE_SYSCALL(open), data/eztrace-1.1-10/test/pptrace/automatic/wait_open.c:119:7: [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 lib[1024]; data/eztrace-1.1-10/test/pptrace/automatic/wait_open.c:121:7: [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(lib, ".so"); data/eztrace-1.1-10/test/pptrace/comparison/instrument/dyninst/my_dyninst.cpp:106: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 mod_name[80]; data/eztrace-1.1-10/test/pptrace/comparison/instrument/dyninst/my_dyninst.cpp:129: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 mod_name[80]; data/eztrace-1.1-10/test/pptrace/comparison/instrument/libinstrument-real/instrument.c:64:8: [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. static char PROF_FILE_USER[1024]; data/eztrace-1.1-10/test/pptrace/comparison/programs/md/dyninst/my_dyninst.cpp:104: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 mod_name[80]; data/eztrace-1.1-10/test/pptrace/comparison/programs/md/dyninst/my_dyninst.cpp:127: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 mod_name[80]; data/eztrace-1.1-10/test/pptrace/perf/tests/prog.c:30:7: [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). l = atoi(argv[1]); data/eztrace-1.1-10/test/pptrace/perf/tests/prog.c:31:7: [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). s = atoi(argv[2]); data/eztrace-1.1-10/test/pthread/cond.c:21:16: [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). _debug = atoi(buf); data/eztrace-1.1-10/test/pthread/dummy_thread.c:25:16: [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). _debug = atoi(buf); data/eztrace-1.1-10/test/pthread/race_cond.c:23:16: [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). _debug = atoi(buf); data/eztrace-1.1-10/test/pthread/test_pthread.c:25:16: [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). _debug = atoi(buf); data/eztrace-1.1-10/test/pthread/test_sigsegv.c:25:16: [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). _debug = atoi(buf); data/eztrace-1.1-10/test/static/static.c:22:16: [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). _debug = atoi(buf); data/eztrace-1.1-10/test/stdio/stdio.c:29:16: [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). _debug = atoi(buf); data/eztrace-1.1-10/test/stdio/stdio.c:36:15: [2] (misc) fopen: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). FILE *f = fopen("/dev/null", "a"); data/eztrace-1.1-10/src/core/ezt_demangle.c:14: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(mangled_str) + 1; data/eztrace-1.1-10/src/core/ezt_demangle.c:16:5: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy(res_str, mangled_str, len); data/eztrace-1.1-10/src/core/ezt_demangle.c:25: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). int len = strlen(mangled_str) + 1; data/eztrace-1.1-10/src/core/ezt_demangle.c:27:3: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy(res_str, mangled_str, len); data/eztrace-1.1-10/src/core/eztrace.h:232:7: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy(__buff, PPTRACE_SYMBOL_LIST(module_name)[__i], 1024); \ data/eztrace-1.1-10/src/core/eztrace_convert_core.c:796:48: [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(filename, "libeztrace-convert-", strlen("libeztrace-convert-"))) data/eztrace-1.1-10/src/core/eztrace_convert_core.c:803: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). filename += strlen("libeztrace-convert-"); data/eztrace-1.1-10/src/core/eztrace_convert_core.c:805: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). if (strncmp(filename, cur_module_name, strlen(cur_module_name))) data/eztrace-1.1-10/src/core/eztrace_convert_core.c:808: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). filename += strlen(cur_module_name); data/eztrace-1.1-10/src/core/eztrace_convert_core.c:810: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). filename = entry->d_name + strlen(entry->d_name) - strlen(SO_STRING); data/eztrace-1.1-10/src/core/eztrace_convert_core.c:810: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). filename = entry->d_name + strlen(entry->d_name) - strlen(SO_STRING); data/eztrace-1.1-10/src/core/eztrace_convert_core.c:812: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). if (strncmp(filename, SO_STRING, strlen(SO_STRING))) data/eztrace-1.1-10/src/core/eztrace_convert_core.c:817: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). filename += strlen(SO_STRING); data/eztrace-1.1-10/src/core/eztrace_core.c:66: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 total_size = strlen(__eztrace_get_filedir()); data/eztrace-1.1-10/src/core/eztrace_core.c:67: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). total_size += strlen(getenv("USER")); data/eztrace-1.1-10/src/core/eztrace_core.c:68: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). total_size += strlen(name); data/eztrace-1.1-10/src/core/eztrace_core.c:113: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). int len = strlen(symbol); data/eztrace-1.1-10/src/core/eztrace_core.c:360:5: [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(name) + 1, data/eztrace-1.1-10/src/core/eztrace_core.c:366:5: [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(name) + 1, data/eztrace-1.1-10/src/core/eztrace_core.c:372:5: [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(name) + 1, data/eztrace-1.1-10/src/core/eztrace_core.c:378:5: [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(name) + 1, data/eztrace-1.1-10/src/core/eztrace_core.c:384:5: [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(name) + 1, data/eztrace-1.1-10/src/core/eztrace_core.c:508:3: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy(output_str, ptr, strlen(ptr)+1); data/eztrace-1.1-10/src/core/eztrace_core.c:508:28: [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). strncpy(output_str, ptr, strlen(ptr)+1); data/eztrace-1.1-10/src/core/eztrace_core.c:551:3: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy(output_str, current_frame, strlen(current_frame)+1); data/eztrace-1.1-10/src/core/eztrace_core.c:551:38: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). strncpy(output_str, current_frame, strlen(current_frame)+1); data/eztrace-1.1-10/src/core/eztrace_core.c:596:76: [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). litl_write_probe_raw(__ezt_trace.litl_trace, EZTRACE_CALLING_FUNCTION, strlen(buffer), buffer); data/eztrace-1.1-10/src/core/eztrace_litl.h:38: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). EZTRACE_EVENT_RAW_DATA(code, strlen(arg1) + 1, arg1) data/eztrace-1.1-10/src/modules/cuda/eztrace_convert_cuda.c:756:3: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy(p_kernel->name, demangled_name, 80); data/eztrace-1.1-10/src/modules/mpi/mpi.c:393: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 proc_id_len = strlen(mpi_infos.proc_id) + 1; data/eztrace-1.1-10/src/modules/omp/gomp.c:447:76: [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). litl_write_probe_raw(__ezt_trace.litl_trace, EZTRACE_CALLING_FUNCTION, strlen(buffer)+1, buffer); data/eztrace-1.1-10/src/modules/papi/papi.c:328: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). strlen(Event_names[i]), data/eztrace-1.1-10/src/modules/papi/papi.c:332: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). strlen(units_names[i]), data/eztrace-1.1-10/src/modules/stdio/eztrace_convert_stdio.c:31:18: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). GENERATE_HANDLER(read) data/eztrace-1.1-10/src/modules/stdio/stdio.c:27:9: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). ssize_t read(int fd, void *buf, size_t count) { data/eztrace-1.1-10/src/pptrace/os/linux/linux.c:730:5: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). read(fds[0], &plop, sizeof(char)); data/eztrace-1.1-10/src/pptrace/pptrace.c:93: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 (p[strlen(p) - 1] != '/') data/eztrace-1.1-10/src/pptrace/pptrace.c:305: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). res = &res[strlen(LIBEZTRACE_PREFIX)]; data/eztrace-1.1-10/src/pptrace/pptrace.c:311:7: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy(module_name, res, suffix-res); data/eztrace-1.1-10/src/pptrace/pptrace.c:457: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). unsigned int nsize = strlen(ldpreload); data/eztrace-1.1-10/src/pptrace/pptrace.c:460: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). while (size - nsize < strlen(first->library) + 2) { data/eztrace-1.1-10/src/pptrace/pptrace.c:465: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). nsize += strlen(first->library); data/eztrace-1.1-10/src/pptrace/pptrace.c:466:5: [1] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant character. strcpy(result + nsize, ":"); data/eztrace-1.1-10/src/pptrace/pptrace.c:472: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). while (size - nsize < strlen(envpreload) + 1) { data/eztrace-1.1-10/src/pptrace/pptrace.c:543: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 libnamelen = strlen(libname); data/eztrace-1.1-10/src/pptrace/pptrace.c:545:28: [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 = libnamelen - strlen(result->library); data/eztrace-1.1-10/test/pptrace/automatic/binary.c:29:20: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). while (0 <= (r = read(fd, &buf, 1))) { data/eztrace-1.1-10/test/pptrace/automatic/binary.c:49: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(symbol) + 1 >= strlen(line)) data/eztrace-1.1-10/test/pptrace/automatic/binary.c:49:29: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (strlen(symbol) + 1 >= strlen(line)) data/eztrace-1.1-10/test/pptrace/automatic/binary.c:51: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). int i = strlen(line) - strlen(symbol) - 1; data/eztrace-1.1-10/test/pptrace/automatic/binary.c:51:26: [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 i = strlen(line) - strlen(symbol) - 1; data/eztrace-1.1-10/test/pptrace/automatic/binary.c:209: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). int i = strlen(path); data/eztrace-1.1-10/test/pptrace/automatic/binary.c:210:31: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (i > 3 && strncmp(path + strlen(path) - 3, ".so", 3) == 0) { data/eztrace-1.1-10/test/pptrace/automatic/binary.c:221: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). int i = strlen(bnam); data/eztrace-1.1-10/test/pptrace/automatic/binary.c:222:31: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (i > 3 && strncmp(bnam + strlen(bnam) - 3, ".so", 3) == 0) { data/eztrace-1.1-10/test/pptrace/automatic/hijack.c:60:34: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). #define READ_WORD(w) TEST1(-1 != read(fds[0], &w, sizeof(w)), read, "read failed with error %s!", strerror(errno)) data/eztrace-1.1-10/test/pptrace/automatic/hijack.c:60:63: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). #define READ_WORD(w) TEST1(-1 != read(fds[0], &w, sizeof(w)), read, "read failed with error %s!", strerror(errno)) data/eztrace-1.1-10/test/pptrace/automatic/opcodes.c:38: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). offset = insert_opcodes((uint8_t*)str, strlen(str), buf, size, offset); \ data/eztrace-1.1-10/test/pptrace/automatic/opcodes.c:40: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). TEST2(offset == MIN(prev + strlen(str), size), return, "returned "WORD_DEC_FORMAT" while awaiting "WORD_DEC_FORMAT"!", offset, MIN(prev + strlen(str), size)); \ data/eztrace-1.1-10/test/pptrace/automatic/opcodes.c:40:141: [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). TEST2(offset == MIN(prev + strlen(str), size), return, "returned "WORD_DEC_FORMAT" while awaiting "WORD_DEC_FORMAT"!", offset, MIN(prev + strlen(str), size)); \ data/eztrace-1.1-10/test/pptrace/automatic/testcase/titi.c:71:5: [1] (buffer) getchar: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). getchar(); data/eztrace-1.1-10/test/pptrace/automatic/tracing.c:75:22: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). #define READ_WORD(w) read(fds[0], &w, sizeof(w)) data/eztrace-1.1-10/test/pptrace/automatic/tracing.c:166: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). strlen(tocopy) + 1); data/eztrace-1.1-10/test/pptrace/automatic/tracing.c:229: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). trace_copy(child, (word_uint) buf1, mmap, strlen(buf1) + 1); data/eztrace-1.1-10/test/pptrace/automatic/wait_open.c:28: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). env[0] = (char*) malloc(15 + strlen(ldpreload)); data/eztrace-1.1-10/test/pptrace/automatic/wait_open.c:29: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). snprintf(env[0], 15 + strlen(ldpreload), "LD_PRELOAD=%s", ldpreload); data/eztrace-1.1-10/test/stdio/stdio.c:98:5: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). read(fd[my_id][0], &buf, sizeof(int)); ANALYSIS SUMMARY: Hits = 248 Lines analyzed = 41497 in approximately 1.13 seconds (36831 lines/second) Physical Source Lines of Code (SLOC) = 31339 Hits@level = [0] 668 [1] 67 [2] 103 [3] 44 [4] 34 [5] 0 Hits@level+ = [0+] 916 [1+] 248 [2+] 181 [3+] 78 [4+] 34 [5+] 0 Hits/KSLOC@level+ = [0+] 29.2288 [1+] 7.91346 [2+] 5.77555 [3+] 2.48891 [4+] 1.08491 [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.