Newly introduced findings

List of Findings

Error: GCC_ANALYZER_WARNING (CWE-401): [#def1]
elfutils-0.194/libdwfl_stacktrace/dwflst_sample_frame.c:239:12: warning[-Wanalyzer-malloc-leak]: leak of ‘sample_arg’
elfutils-0.194/libdwfl_stacktrace/dwflst_sample_frame.c:214:6: branch_false: following ‘false’ branch...
elfutils-0.194/libdwfl_stacktrace/dwflst_sample_frame.c:221:20: branch_false: ...to here
elfutils-0.194/libdwfl_stacktrace/dwflst_sample_frame.c:221:20: acquire_memory: allocated here
elfutils-0.194/libdwfl_stacktrace/dwflst_sample_frame.c:222:10: branch_false: following ‘false’ branch (when ‘sample_arg’ is non-NULL)...
elfutils-0.194/libdwfl_stacktrace/dwflst_sample_frame.c:229:3: branch_false: ...to here
elfutils-0.194/libdwfl_stacktrace/dwflst_sample_frame.c:238:6: branch_false: following ‘false’ branch (when ‘attached == 0’)...
elfutils-0.194/libdwfl_stacktrace/dwflst_sample_frame.c:239:12: branch_false: ...to here
elfutils-0.194/libdwfl_stacktrace/dwflst_sample_frame.c:239:12: throw: if ‘dwfl_attach_state’ throws an exception...
elfutils-0.194/libdwfl_stacktrace/dwflst_sample_frame.c:239:12: danger: ‘sample_arg’ leaks here; was allocated at [(3)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/2)
#  237|   
#  238|     if (! attached
#  239|->       && ! INTUSE(dwfl_attach_state) (dwfl, elf, pid,
#  240|   				      &sample_thread_callbacks, sample_arg))
#  241|       return -1;

Error: GCC_ANALYZER_WARNING (CWE-401): [#def2]
elfutils-0.194/src/elfclassify.c:74:5: warning[-Wanalyzer-malloc-leak]: leak of ‘full_path’
elfutils-0.194/src/elfclassify.c:827:1: enter_function: entry to ‘check_ar_members’
elfutils-0.194/src/elfclassify.c:836:21: acquire_memory: allocated here
elfutils-0.194/src/elfclassify.c:837:6: branch_false: following ‘false’ branch (when ‘full_path’ is non-NULL)...
elfutils-0.194/src/elfclassify.c:837:6: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:846:10: branch_true: following ‘true’ branch...
elfutils-0.194/src/elfclassify.c:848:26: branch_true: ...to here
elfutils-0.194/src/elfclassify.c:849:10: branch_false: following ‘false’ branch...
elfutils-0.194/src/elfclassify.c:857:23: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:857:23: branch_true: following ‘true’ branch...
elfutils-0.194/src/elfclassify.c:858:23: branch_true: ...to here
elfutils-0.194/src/elfclassify.c:858:10: branch_true: following ‘true’ branch...
elfutils-0.194/src/elfclassify.c:860:11: branch_true: ...to here
elfutils-0.194/src/elfclassify.c:862:14: branch_false: following ‘false’ branch (when ‘new_path’ is non-NULL)...
elfutils-0.194/src/elfclassify.c:872:11: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:872:10: branch_false: following ‘false’ branch...
elfutils-0.194/src/elfclassify.c:882:7: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:883:11: call_function: calling ‘run_classify’ from ‘check_ar_members’
#   72|   {
#   73|     if (verbose >= 0)
#   74|->     error (0, 0, "%s: %s: '%s'", msg, elf_errmsg (-1), current_path);
#   75|     issue_found = true;
#   76|   }

Error: GCC_ANALYZER_WARNING (CWE-401): [#def3]
elfutils-0.194/src/elfclassify.c:243:21: warning[-Wanalyzer-malloc-leak]: leak of ‘full_path’
elfutils-0.194/src/elfclassify.c:827:1: enter_function: entry to ‘check_ar_members’
elfutils-0.194/src/elfclassify.c:836:21: acquire_memory: allocated here
elfutils-0.194/src/elfclassify.c:837:6: branch_false: following ‘false’ branch (when ‘full_path’ is non-NULL)...
elfutils-0.194/src/elfclassify.c:837:6: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:846:10: branch_true: following ‘true’ branch...
elfutils-0.194/src/elfclassify.c:848:26: branch_true: ...to here
elfutils-0.194/src/elfclassify.c:849:10: branch_false: following ‘false’ branch...
elfutils-0.194/src/elfclassify.c:857:23: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:857:23: branch_true: following ‘true’ branch...
elfutils-0.194/src/elfclassify.c:858:23: branch_true: ...to here
elfutils-0.194/src/elfclassify.c:858:10: branch_true: following ‘true’ branch...
elfutils-0.194/src/elfclassify.c:860:11: branch_true: ...to here
elfutils-0.194/src/elfclassify.c:862:14: branch_false: following ‘false’ branch (when ‘new_path’ is non-NULL)...
elfutils-0.194/src/elfclassify.c:872:11: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:872:10: branch_false: following ‘false’ branch...
elfutils-0.194/src/elfclassify.c:882:7: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:883:11: call_function: calling ‘run_classify’ from ‘check_ar_members’
#  241|   
#  242|     GElf_Ehdr ehdr_storage;
#  243|->   GElf_Ehdr *ehdr = gelf_getehdr (elf, &ehdr_storage);
#  244|     if (ehdr == NULL)
#  245|       {

Error: GCC_ANALYZER_WARNING (CWE-401): [#def4]
elfutils-0.194/src/elfclassify.c:255:9: warning[-Wanalyzer-malloc-leak]: leak of ‘full_path’
elfutils-0.194/src/elfclassify.c:827:1: enter_function: entry to ‘check_ar_members’
elfutils-0.194/src/elfclassify.c:836:21: acquire_memory: allocated here
elfutils-0.194/src/elfclassify.c:837:6: branch_false: following ‘false’ branch (when ‘full_path’ is non-NULL)...
elfutils-0.194/src/elfclassify.c:837:6: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:846:10: branch_true: following ‘true’ branch...
elfutils-0.194/src/elfclassify.c:848:26: branch_true: ...to here
elfutils-0.194/src/elfclassify.c:849:10: branch_false: following ‘false’ branch...
elfutils-0.194/src/elfclassify.c:857:23: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:857:23: branch_true: following ‘true’ branch...
elfutils-0.194/src/elfclassify.c:858:23: branch_true: ...to here
elfutils-0.194/src/elfclassify.c:858:10: branch_true: following ‘true’ branch...
elfutils-0.194/src/elfclassify.c:860:11: branch_true: ...to here
elfutils-0.194/src/elfclassify.c:862:14: branch_false: following ‘false’ branch (when ‘new_path’ is non-NULL)...
elfutils-0.194/src/elfclassify.c:872:11: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:872:10: branch_false: following ‘false’ branch...
elfutils-0.194/src/elfclassify.c:882:7: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:883:11: call_function: calling ‘run_classify’ from ‘check_ar_members’
#  253|     {
#  254|       size_t nphdrs;
#  255|->     if (elf_getphdrnum (elf, &nphdrs) != 0)
#  256|         {
#  257|   	elf_issue (N_("program headers"));

Error: GCC_ANALYZER_WARNING (CWE-401): [#def5]
elfutils-0.194/src/elfclassify.c:263:27: warning[-Wanalyzer-malloc-leak]: leak of ‘full_path’
elfutils-0.194/src/elfclassify.c:827:1: enter_function: entry to ‘check_ar_members’
elfutils-0.194/src/elfclassify.c:836:21: acquire_memory: allocated here
elfutils-0.194/src/elfclassify.c:837:6: branch_false: following ‘false’ branch (when ‘full_path’ is non-NULL)...
elfutils-0.194/src/elfclassify.c:837:6: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:846:10: branch_true: following ‘true’ branch...
elfutils-0.194/src/elfclassify.c:848:26: branch_true: ...to here
elfutils-0.194/src/elfclassify.c:849:10: branch_false: following ‘false’ branch...
elfutils-0.194/src/elfclassify.c:857:23: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:857:23: branch_true: following ‘true’ branch...
elfutils-0.194/src/elfclassify.c:858:23: branch_true: ...to here
elfutils-0.194/src/elfclassify.c:858:10: branch_true: following ‘true’ branch...
elfutils-0.194/src/elfclassify.c:860:11: branch_true: ...to here
elfutils-0.194/src/elfclassify.c:862:14: branch_false: following ‘false’ branch (when ‘new_path’ is non-NULL)...
elfutils-0.194/src/elfclassify.c:872:11: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:872:10: branch_false: following ‘false’ branch...
elfutils-0.194/src/elfclassify.c:882:7: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:883:11: call_function: calling ‘run_classify’ from ‘check_ar_members’
#  261|         {
#  262|   	GElf_Phdr phdr_storage;
#  263|-> 	GElf_Phdr *phdr = gelf_getphdr (elf, phdr_idx, &phdr_storage);
#  264|   	if (phdr == NULL)
#  265|   	  {

Error: GCC_ANALYZER_WARNING (CWE-401): [#def6]
elfutils-0.194/src/elfclassify.c:284:9: warning[-Wanalyzer-malloc-leak]: leak of ‘full_path’
elfutils-0.194/src/elfclassify.c:827:1: enter_function: entry to ‘check_ar_members’
elfutils-0.194/src/elfclassify.c:836:21: acquire_memory: allocated here
elfutils-0.194/src/elfclassify.c:837:6: branch_false: following ‘false’ branch (when ‘full_path’ is non-NULL)...
elfutils-0.194/src/elfclassify.c:837:6: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:846:10: branch_true: following ‘true’ branch...
elfutils-0.194/src/elfclassify.c:848:26: branch_true: ...to here
elfutils-0.194/src/elfclassify.c:849:10: branch_false: following ‘false’ branch...
elfutils-0.194/src/elfclassify.c:857:23: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:857:23: branch_true: following ‘true’ branch...
elfutils-0.194/src/elfclassify.c:858:23: branch_true: ...to here
elfutils-0.194/src/elfclassify.c:858:10: branch_true: following ‘true’ branch...
elfutils-0.194/src/elfclassify.c:860:11: branch_true: ...to here
elfutils-0.194/src/elfclassify.c:862:14: branch_false: following ‘false’ branch (when ‘new_path’ is non-NULL)...
elfutils-0.194/src/elfclassify.c:872:11: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:872:10: branch_false: following ‘false’ branch...
elfutils-0.194/src/elfclassify.c:882:7: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:883:11: call_function: calling ‘run_classify’ from ‘check_ar_members’
#  282|     {
#  283|       size_t nshdrs;
#  284|->     if (elf_getshdrnum (elf, &nshdrs) != 0)
#  285|         {
#  286|   	elf_issue (N_("section headers"));

Error: GCC_ANALYZER_WARNING (CWE-401): [#def7]
elfutils-0.194/src/elfclassify.c:846:17: warning[-Wanalyzer-malloc-leak]: leak of ‘full_path’
elfutils-0.194/src/elfclassify.c:836:21: acquire_memory: allocated here
elfutils-0.194/src/elfclassify.c:837:6: branch_false: following ‘false’ branch (when ‘full_path’ is non-NULL)...
elfutils-0.194/src/elfclassify.c:837:6: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:846:17: throw: if ‘elf_begin’ throws an exception...
elfutils-0.194/src/elfclassify.c:846:17: danger: ‘full_path’ leaks here; was allocated at [(1)](sarif:/runs/0/results/5/codeFlows/0/threadFlows/0/locations/0)
#  844|     int cmd = ELF_C_READ;
#  845|     bool bad_ar = false;
#  846|->   while ((elf = elf_begin (file_fd, cmd, ar_elf)) != NULL)
#  847|       {
#  848|         Elf_Arhdr *arhdr = elf_getarhdr (elf);

Error: GCC_ANALYZER_WARNING (CWE-401): [#def8]
elfutils-0.194/src/elfclassify.c:848:26: warning[-Wanalyzer-malloc-leak]: leak of ‘full_path’
elfutils-0.194/src/elfclassify.c:836:21: acquire_memory: allocated here
elfutils-0.194/src/elfclassify.c:837:6: branch_false: following ‘false’ branch (when ‘full_path’ is non-NULL)...
elfutils-0.194/src/elfclassify.c:837:6: branch_false: ...to here
elfutils-0.194/src/elfclassify.c:846:10: branch_true: following ‘true’ branch...
elfutils-0.194/src/elfclassify.c:848:26: branch_true: ...to here
elfutils-0.194/src/elfclassify.c:848:26: throw: if ‘elf_getarhdr’ throws an exception...
elfutils-0.194/src/elfclassify.c:848:26: danger: ‘full_path’ leaks here; was allocated at [(1)](sarif:/runs/0/results/6/codeFlows/0/threadFlows/0/locations/0)
#  846|     while ((elf = elf_begin (file_fd, cmd, ar_elf)) != NULL)
#  847|       {
#  848|->       Elf_Arhdr *arhdr = elf_getarhdr (elf);
#  849|         if (arhdr == NULL)
#  850|   	{

Scan Properties

analyzer-version-clippy1.92.0
analyzer-version-cppcheck2.19.1
analyzer-version-gcc16.0.0
analyzer-version-gcc-analyzer16.0.0
analyzer-version-shellcheck0.11.0
analyzer-version-unicontrol0.0.2
diffbase-analyzer-version-clippy1.92.0
diffbase-analyzer-version-cppcheck2.19.1
diffbase-analyzer-version-gcc16.0.0
diffbase-analyzer-version-gcc-analyzer16.0.0
diffbase-analyzer-version-shellcheck0.11.0
diffbase-analyzer-version-unicontrol0.0.2
diffbase-enabled-pluginsclippy, cppcheck, gcc, shellcheck, unicontrol
diffbase-exit-code0
diffbase-hostip-172-16-1-98.us-west-2.compute.internal
diffbase-known-false-positives/usr/share/csmock/known-false-positives.js
diffbase-known-false-positives-rpmknown-false-positives-0.0.0.20250521.132812.g8eff701.main-1.el9.noarch
diffbase-mock-configfedora-rawhide-x86_64
diffbase-project-nameelfutils-0.193-3.fc43
diffbase-store-results-to/tmp/tmp_jsrpp18/elfutils-0.193-3.fc43.tar.xz
diffbase-time-created2026-01-08 15:55:28
diffbase-time-finished2026-01-08 16:00:12
diffbase-toolcsmock
diffbase-tool-args'/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'gcc,cppcheck,clippy,shellcheck,unicontrol' '-o' '/tmp/tmp_jsrpp18/elfutils-0.193-3.fc43.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '--gcc-analyzer-bin=/usr/bin/gcc' '/tmp/tmp_jsrpp18/elfutils-0.193-3.fc43.src.rpm'
diffbase-tool-versioncsmock-3.8.3.20251215.161544.g62de9a5-1.el9
enabled-pluginsclippy, cppcheck, gcc, shellcheck, unicontrol
exit-code0
hostip-172-16-1-98.us-west-2.compute.internal
known-false-positives/usr/share/csmock/known-false-positives.js
known-false-positives-rpmknown-false-positives-0.0.0.20250521.132812.g8eff701.main-1.el9.noarch
mock-configfedora-rawhide-x86_64
project-nameelfutils-0.194-2.fc44
store-results-to/tmp/tmpuuwbx_ns/elfutils-0.194-2.fc44.tar.xz
time-created2026-01-08 16:00:37
time-finished2026-01-08 16:04:56
titleNewly introduced findings
toolcsmock
tool-args'/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'gcc,cppcheck,clippy,shellcheck,unicontrol' '-o' '/tmp/tmpuuwbx_ns/elfutils-0.194-2.fc44.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '--gcc-analyzer-bin=/usr/bin/gcc' '/tmp/tmpuuwbx_ns/elfutils-0.194-2.fc44.src.rpm'
tool-versioncsmock-3.8.3.20251215.161544.g62de9a5-1.el9