conmon-2.1.12-3.fc42
List of Findings
Error: GCC_ANALYZER_WARNING (CWE-775): [#def1]
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c: scope_hint: In function ‘process_cgroup_subsystem_path’
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c:57:37: warning[-Wanalyzer-file-leak]: leak of FILE ‘fopen(g_strdup_printf("/proc/%d/cgroup", pid), "re")’
Error: GCC_ANALYZER_WARNING (CWE-401): [#def2]
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c:57:37: warning[-Wanalyzer-malloc-leak]: leak of ‘fopen(g_strdup_printf("/proc/%d/cgroup", pid), "re")’
Error: GCC_ANALYZER_WARNING (CWE-775): [#def3]
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c: scope_hint: In function ‘setup_oom_handling_cgroup_v1’
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c:147:35: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open(g_build_filename(process_cgroup_subsystem_path(pid, 0, "memory"), "cgroup.event_control", 0), 524289)’
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c: scope_hint: In function ‘setup_oom_handling_cgroup_v1’
Error: GCC_ANALYZER_WARNING (CWE-775): [#def4]
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c:156:25: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open(g_build_filename(process_cgroup_subsystem_path(pid, 0, "memory"), "memory.oom_control", 0), 524288)’
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c: scope_hint: In function ‘setup_oom_handling_cgroup_v1’
Error: GCC_ANALYZER_WARNING (CWE-775): [#def5]
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c: scope_hint: In function ‘check_cgroup2_oom’
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c:278:37: warning[-Wanalyzer-file-leak]: leak of FILE ‘fopen(g_build_filename(cgroup2_path, "memory.events", 0), "re")’
Error: GCC_ANALYZER_WARNING (CWE-401): [#def6]
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c:278:37: warning[-Wanalyzer-malloc-leak]: leak of ‘fopen(g_build_filename(cgroup2_path, "memory.events", 0), "re")’
Error: GCC_ANALYZER_WARNING (CWE-775): [#def7]
conmon-2.1.12-build/conmon-2.1.12/src/conmon.c: scope_hint: In function ‘disconnect_std_streams’
conmon-2.1.12-build/conmon-2.1.12/src/conmon.c:29:12: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘dup2(dev_null_r, 0)’
Error: GCC_ANALYZER_WARNING (CWE-775): [#def8]
conmon-2.1.12-build/conmon-2.1.12/src/conmon.c:31:12: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘dup2(dev_null_w, 1)’
Error: GCC_ANALYZER_WARNING (CWE-775): [#def9]
conmon-2.1.12-build/conmon-2.1.12/src/conmon.c:33:12: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘dup2(dev_null_w, 2)’
Error: GCC_ANALYZER_WARNING (CWE-775): [#def10]
conmon-2.1.12-build/conmon-2.1.12/src/conmon.c: scope_hint: In function ‘main’
conmon-2.1.12-build/conmon-2.1.12/src/conmon.c:79:43: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open("/dev/null", 524288)’
Error: GCC_ANALYZER_WARNING (CWE-775): [#def11]
conmon-2.1.12-build/conmon-2.1.12/src/conmon.c:83:43: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open("/dev/null", 524289)’
Error: GCC_ANALYZER_WARNING (CWE-775): [#def12]
conmon-2.1.12-build/conmon-2.1.12/src/conmon.c:244:28: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘dup2(workerfd_stdin, 0)’
Error: GCC_ANALYZER_WARNING (CWE-775): [#def13]
conmon-2.1.12-build/conmon-2.1.12/src/conmon.c:251:28: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘dup2(workerfd_stdout, 1)’
Error: GCC_ANALYZER_WARNING (CWE-775): [#def14]
conmon-2.1.12-build/conmon-2.1.12/src/conmon.c:258:28: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘dup2(workerfd_stderr, 2)’
Error: GCC_ANALYZER_WARNING (CWE-910): [#def15]
conmon-2.1.12-build/conmon-2.1.12/src/conmon.c:287:44: warning[-Wanalyzer-fd-use-after-close]: ‘read’ on closed file descriptor ‘get_pipe_fd_from_env("_OCI_STARTPIPE")’
conmon-2.1.12-build/conmon-2.1.12/src/conmon.c:8: included_from: Included from here.
conmon-2.1.12-build/conmon-2.1.12/src/conmon.c:286:33: note: in expansion of macro ‘ndebug’
Error: GCC_ANALYZER_WARNING (CWE-1341): [#def16]
conmon-2.1.12-build/conmon-2.1.12/src/conmon.c:292:33: warning[-Wanalyzer-fd-double-close]: double ‘close’ of file descriptor ‘get_pipe_fd_from_env("_OCI_STARTPIPE")’
conmon-2.1.12-build/conmon-2.1.12/src/conmon.c:286:33: note: in expansion of macro ‘ndebug’
Error: GCC_ANALYZER_WARNING (CWE-775): [#def17]
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.c:213:12: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘*fd’
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.c: scope_hint: In function ‘setup_socket’
Error: GCC_ANALYZER_WARNING (CWE-775): [#def18]
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.c:274:45: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open(socket_parent_dir(use_full_attach_path, 108), 2621440)’
Error: GCC_ANALYZER_WARNING (CWE-688): [#def19]
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.c: scope_hint: In function ‘bind_unix_socket’
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.c:274:45: warning[-Wanalyzer-possible-null-argument]: use of possibly-NULL ‘socket_parent_dir(use_full_attach_path, 108)’ where non-null expected
/usr/include/glib-2.0/glib-unix.h:34: included_from: Included from here.
conmon-2.1.12-build/conmon-2.1.12/src/utils.h:10: included_from: Included from here.
/usr/include/fcntl.h:209:12: note: argument 1 of ‘open’ must be non-null
Error: GCC_ANALYZER_WARNING (CWE-401): [#def20]
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.c:317:24: warning[-Wanalyzer-malloc-leak]: leak of ‘socket_parent_dir(use_full_attach_path, 108)’
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.c:276:17: note: in expansion of macro ‘pexitf’
Error: GCC_ANALYZER_WARNING (CWE-775): [#def21]
conmon-2.1.12-build/conmon-2.1.12/src/ctrl.c: scope_hint: In function ‘setup_fifo’
conmon-2.1.12-build/conmon-2.1.12/src/ctrl.c:273:24: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open(g_build_filename(opt_bundle_path, filename, 0), 526336)’
Error: GCC_ANALYZER_WARNING (CWE-775): [#def22]
conmon-2.1.12-build/conmon-2.1.12/src/ctrl.c:276:24: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open(g_build_filename(opt_bundle_path, filename, 0), 524289)’
Error: GCC_ANALYZER_WARNING (CWE-401): [#def23]
conmon-2.1.12-build/conmon-2.1.12/src/seccomp_notify.c: scope_hint: In function ‘seccomp_notify_plugins_load’
conmon-2.1.12-build/conmon-2.1.12/src/seccomp_notify.c:295:16: warning[-Wanalyzer-malloc-leak]: leak of ‘xmalloc0((long unsigned int)*(struct seccomp_notify_context_s *)<unknown>.sizes.seccomp_notif)’
Error: GCC_ANALYZER_WARNING (CWE-401): [#def24]
conmon-2.1.12-build/conmon-2.1.12/src/seccomp_notify.c:295:16: warning[-Wanalyzer-malloc-leak]: leak of ‘xmalloc0((long unsigned int)*(struct seccomp_notify_context_s *)<unknown>.sizes.seccomp_notif_resp)’
Error: GCC_ANALYZER_WARNING (CWE-401): [#def25]
conmon-2.1.12-build/conmon-2.1.12/src/seccomp_notify.c:295:16: warning[-Wanalyzer-malloc-leak]: leak of ‘xmalloc0(48)’
Error: GCC_ANALYZER_WARNING (CWE-775): [#def26]
conmon-2.1.12-build/conmon-2.1.12/src/utils.h:57:21: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open(g_build_filename(process_cgroup_subsystem_path(pid, 0, "memory"), "cgroup.event_control", 0), 524289)’
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c:161:17: note: in expansion of macro ‘pexit’
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c: scope_hint: In function ‘setup_oom_handling_cgroup_v1’
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c:161:17: note: in expansion of macro ‘pexit’
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c:161:17: note: in expansion of macro ‘pexit’
Error: GCC_ANALYZER_WARNING (CWE-401): [#def27]
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.c:6: included_from: Included from here.
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.c: scope_hint: In function ‘setup_socket’
conmon-2.1.12-build/conmon-2.1.12/src/utils.h:57:21: warning[-Wanalyzer-malloc-leak]: leak of ‘strdup(path)’
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.c:175:25: note: in expansion of macro ‘pexit’
/usr/include/glib-2.0/glib/gtestutils.h:32: included_from: Included from here.
/usr/include/glib-2.0/glib.h:89: included_from: Included from here.
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.h:4: included_from: Included from here.
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.c:3: included_from: Included from here.
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.c:175:25: note: in expansion of macro ‘pexit’
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.c:175:25: note: in expansion of macro ‘pexit’
Error: GCC_ANALYZER_WARNING (CWE-775): [#def28]
conmon-2.1.12-build/conmon-2.1.12/src/utils.h:64:17: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open(g_build_filename(process_cgroup_subsystem_path(pid, 0, "memory"), "cgroup.event_control", 0), 524289)’
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c:158:17: note: in expansion of macro ‘pexitf’
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c: scope_hint: In function ‘setup_oom_handling_cgroup_v1’
/usr/include/glib-2.0/glib/gtestutils.h:32: included_from: Included from here.
/usr/include/glib-2.0/glib.h:89: included_from: Included from here.
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.h:4: included_from: Included from here.
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c:3: included_from: Included from here.
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c:158:17: note: in expansion of macro ‘pexitf’
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c:158:17: note: in expansion of macro ‘pexitf’
Error: GCC_ANALYZER_WARNING (CWE-775): [#def29]
conmon-2.1.12-build/conmon-2.1.12/src/utils.h:65:21: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open(socket_parent_dir(use_full_attach_path, 108), 2621440)’
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.c:291:17: note: in expansion of macro ‘pexitf’
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.c:291:17: note: in expansion of macro ‘pexitf’
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.c:291:17: note: in expansion of macro ‘pexitf’
Error: GCC_ANALYZER_WARNING (CWE-401): [#def30]
conmon-2.1.12-build/conmon-2.1.12/src/utils.h:65:21: warning[-Wanalyzer-malloc-leak]: leak of ‘strdup(path)’
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.c:180:25: note: in expansion of macro ‘pexitf’
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.c:180:25: note: in expansion of macro ‘pexitf’
conmon-2.1.12-build/conmon-2.1.12/src/conn_sock.c:180:25: note: in expansion of macro ‘pexitf’
Error: GCC_ANALYZER_WARNING (CWE-775): [#def31]
conmon-2.1.12-build/conmon-2.1.12/src/utils.h:179:12: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open(g_build_filename(process_cgroup_subsystem_path(pid, 0, "memory"), "cgroup.event_control", 0), 524289)’
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c: scope_hint: In function ‘setup_oom_handling_cgroup_v1’
conmon-2.1.12-build/conmon-2.1.12/src/cgroup.c: scope_hint: In function ‘setup_oom_handling_cgroup_v1’
Scan Properties
analyzer-version-clippy | 1.82.0 |
analyzer-version-cppcheck | 2.16.0 |
analyzer-version-gcc | 14.2.1 |
analyzer-version-gcc-analyzer | 15.0.0 |
analyzer-version-shellcheck | 0.10.0 |
analyzer-version-unicontrol | 0.0.2 |
enabled-plugins | clippy, cppcheck, gcc, shellcheck, unicontrol |
exit-code | 0 |
host | ip-172-16-1-229.us-west-2.compute.internal |
mock-config | fedora-rawhide-gcc-latest-x86_64 |
project-name | conmon-2.1.12-3.fc42 |
store-results-to | /tmp/tmpbng0_5sq/conmon-2.1.12-3.fc42.tar.xz |
time-created | 2024-11-12 23:21:41 |
time-finished | 2024-11-12 23:22:58 |
tool | csmock |
tool-args | '/usr/bin/csmock' '-r' 'fedora-rawhide-gcc-latest-x86_64' '-t' 'clippy,cppcheck,gcc,unicontrol,shellcheck' '-o' '/tmp/tmpbng0_5sq/conmon-2.1.12-3.fc42.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install=gcc-latest' '--gcc-analyzer-bin=/opt/gcc-latest/bin/gcc' '/tmp/tmpbng0_5sq/conmon-2.1.12-3.fc42.src.rpm' |
tool-version | csmock-3.7.1.20241107.094801.gb3f0f26.pr_192-1.el9 |