gnome-remote-desktop-47.1-1.fc42

List of Findings

Error: GCC_ANALYZER_WARNING (CWE-401): [#def1]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-clipboard-rdp.c: scope_hint: In function ‘grd_clipboard_rdp_new’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-clipboard-rdp.c:2426:21: warning[-Wanalyzer-malloc-leak]: leak of ‘cliprdr_server_context_new(vcm)’
# 2424|   
# 2425|     clipboard_rdp = g_object_new (GRD_TYPE_CLIPBOARD_RDP, NULL);
# 2426|->   cliprdr_context = cliprdr_server_context_new (vcm);
# 2427|     if (!cliprdr_context)
# 2428|       {

Error: GCC_ANALYZER_WARNING (CWE-401): [#def2]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-configuration.c: scope_hint: In function ‘on_handle_import_certificate’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-configuration.c:444:21: warning[-Wanalyzer-malloc-leak]: leak of ‘freerdp_certificate_new_from_file(certificate_filename)’
/usr/include/glib-2.0/gobject/gobject.h:26: included_from: Included from here.
/usr/include/glib-2.0/gobject/gbinding.h:31: included_from: Included from here.
/usr/include/glib-2.0/glib-object.h:24: included_from: Included from here.
/usr/include/glib-2.0/gio/gioenums.h:30: included_from: Included from here.
/usr/include/glib-2.0/gio/giotypes.h:30: included_from: Included from here.
/usr/include/glib-2.0/gio/gio.h:28: included_from: Included from here.
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-configuration.c:25: included_from: Included from here.
/usr/include/glib-2.0/gobject/gtype.h:541:66: note: in expansion of macro ‘_G_TYPE_CIT’
/usr/include/glib-2.0/gio/gunixfdlist.h:35:62: note: in expansion of macro ‘G_TYPE_CHECK_INSTANCE_TYPE’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-configuration.c:356:8: note: in expansion of macro ‘G_IS_UNIX_FD_LIST’
/usr/include/glib-2.0/gobject/gtype.h:541:66: note: in expansion of macro ‘_G_TYPE_CIT’
/usr/include/glib-2.0/gio/gunixfdlist.h:35:62: note: in expansion of macro ‘G_TYPE_CHECK_INSTANCE_TYPE’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-configuration.c:356:8: note: in expansion of macro ‘G_IS_UNIX_FD_LIST’
#  442|       }
#  443|   
#  444|->   rdp_certificate = freerdp_certificate_new_from_file (certificate_filename);
#  445|   
#  446|     if (!rdp_certificate)

Error: GCC_ANALYZER_WARNING (CWE-401): [#def3]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-configuration.c:464:21: warning[-Wanalyzer-malloc-leak]: leak of ‘freerdp_key_new_from_file(key_filename)’
/usr/include/glib-2.0/gobject/gtype.h:541:66: note: in expansion of macro ‘_G_TYPE_CIT’
/usr/include/glib-2.0/gio/gunixfdlist.h:35:62: note: in expansion of macro ‘G_TYPE_CHECK_INSTANCE_TYPE’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-configuration.c:356:8: note: in expansion of macro ‘G_IS_UNIX_FD_LIST’
/usr/include/glib-2.0/gobject/gtype.h:541:66: note: in expansion of macro ‘_G_TYPE_CIT’
/usr/include/glib-2.0/gio/gunixfdlist.h:35:62: note: in expansion of macro ‘G_TYPE_CHECK_INSTANCE_TYPE’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-configuration.c:356:8: note: in expansion of macro ‘G_IS_UNIX_FD_LIST’
#  462|       }
#  463|   
#  464|->   rdp_private_key = freerdp_key_new_from_file (key_filename);
#  465|   
#  466|     if (!rdp_private_key)

Error: GCC_ANALYZER_WARNING (CWE-688): [#def4]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-ctl.c: scope_hint: In function ‘vnc_set_credentials’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-ctl.c:470:7: warning[-Wanalyzer-null-argument]: use of NULL ‘password’ where non-null expected
/usr/include/glib-2.0/glib/gstring.h:37: included_from: Included from here.
/usr/include/glib-2.0/glib/giochannel.h:36: included_from: Included from here.
/usr/include/glib-2.0/glib.h:56: included_from: Included from here.
/usr/include/glib-2.0/gobject/gbinding.h:30: included_from: Included from here.
/usr/include/glib-2.0/glib-object.h:24: included_from: Included from here.
/usr/include/glib-2.0/gio/gioenums.h:30: included_from: Included from here.
/usr/include/glib-2.0/gio/giotypes.h:30: included_from: Included from here.
/usr/include/glib-2.0/gio/gio.h:28: included_from: Included from here.
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-ctl.c:24: included_from: Included from here.
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-ctl.c:467:18: note: in expansion of macro ‘g_strdup’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-ctl.c:467:18: note: in expansion of macro ‘g_strdup’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-ctl.c: scope_hint: In function ‘vnc_set_credentials’
<built-in>: note: argument 1 of ‘__builtin_strlen’ must be non-null
#  468|       }
#  469|   
#  470|->   if (strlen (password) > MAX_VNC_PASSWORD_SIZE)
#  471|       {
#  472|         g_set_error (error, G_IO_ERROR, G_IO_ERROR_INVALID_DATA,

Error: CPPCHECK_WARNING (CWE-664): [#def5]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-daemon.c:955: error[va_end_missing]: va_list 'booleans' was opened but not closed by va_end().
#  953|       booleans_count += va_arg (booleans, gboolean) ? 1 : 0;
#  954|   
#  955|->   return booleans_count;
#  956|   }
#  957|   

Error: GCC_ANALYZER_WARNING (CWE-404): [#def6]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-daemon.c: scope_hint: In function ‘count_trues’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-daemon.c:956:1: warning[-Wanalyzer-va-list-leak]: missing call to ‘va_end’
#  954|   
#  955|     return booleans_count;
#  956|-> }
#  957|   
#  958|   int

Error: CPPCHECK_WARNING (CWE-190): [#def7]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-pipewire-utils.c:68: error[integerOverflow]: Signed integer overflow for expression '0-1'.
#   66|     if (pipewire_source->pipewire_loop)
#   67|       {
#   68|->       pw_loop_leave (pipewire_source->pipewire_loop);
#   69|         pw_loop_destroy (pipewire_source->pipewire_loop);
#   70|       }

Error: CPPCHECK_WARNING (CWE-190): [#def8]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-pipewire-utils.c:104: error[integerOverflow]: Signed integer overflow for expression '0-1'.
#  102|   
#  103|     g_source_add_unix_fd (&pipewire_source->base,
#  104|->                         pw_loop_get_fd (pipewire_source->pipewire_loop),
#  105|                           G_IO_IN | G_IO_ERR);
#  106|   

Error: CPPCHECK_WARNING (CWE-190): [#def9]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-pipewire-utils.c:107: error[integerOverflow]: Signed integer overflow for expression '0-1'.
#  105|                           G_IO_IN | G_IO_ERR);
#  106|   
#  107|->   pw_loop_enter (pipewire_source->pipewire_loop);
#  108|     g_source_attach (&pipewire_source->base, NULL);
#  109|   

Error: CPPCHECK_WARNING (CWE-190): [#def10]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-audio-input.c:696: error[integerOverflow]: Signed integer overflow for expression '0-1'.
#  694|       }
#  695|   
#  696|->   pw_core_add_listener (audio_input->pipewire_core,
#  697|                           &audio_input->pipewire_core_listener,
#  698|                           &pipewire_core_events, audio_input);

Error: CPPCHECK_WARNING (CWE-190): [#def11]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-audio-output-stream.c:89: error[integerOverflow]: Signed integer overflow for expression '0-1'.
#   87|             info->params[i].flags & SPA_PARAM_INFO_READ)
#   88|           {
#   89|->           pw_node_enum_params (audio_output_stream->pipewire_node,
#   90|                                  0, SPA_PARAM_Props, 0, -1, NULL);
#   91|           }

Error: CPPCHECK_WARNING (CWE-190): [#def12]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-audio-output-stream.c:330: error[integerOverflow]: Signed integer overflow for expression '0-1'.
#  328|       }
#  329|   
#  330|->   pw_node_add_listener (audio_output_stream->pipewire_node,
#  331|                           &audio_output_stream->pipewire_node_listener,
#  332|                           &pipewire_node_events, audio_output_stream);

Error: GCC_ANALYZER_WARNING (CWE-401): [#def13]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-audio-playback.c: scope_hint: In function ‘grd_rdp_audio_playback_new’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-audio-playback.c:765:20: warning[-Wanalyzer-malloc-leak]: leak of ‘rdpsnd_server_context_new(vcm)’
#  763|   
#  764|     audio_playback = g_object_new (GRD_TYPE_RDP_AUDIO_PLAYBACK, NULL);
#  765|->   rdpsnd_context = rdpsnd_server_context_new (vcm);
#  766|     if (!rdpsnd_context)
#  767|       g_error ("[RDP.AUDIO_PLAYBACK] Failed to create server context");

Error: GCC_ANALYZER_WARNING (CWE-688): [#def14]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-audio-playback.c: scope_hint: In function ‘registry_event_global’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-audio-playback.c:1270:11: warning[-Wanalyzer-null-argument]: use of NULL ‘*item.value’ where non-null expected
/usr/include/spa-0.2/spa/support/plugin.h:13: included_from: Included from here.
/usr/include/pipewire-0.3/pipewire/pipewire.h:12: included_from: Included from here.
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-pipewire-utils.h:24: included_from: Included from here.
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-audio-playback.c:24: included_from: Included from here.
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-audio-playback.c:1262:3: note: in expansion of macro ‘spa_dict_for_each’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-audio-playback.c:1262:3: note: in expansion of macro ‘spa_dict_for_each’
/usr/include/glib-2.0/glib/glist.h:34: included_from: Included from here.
/usr/include/glib-2.0/glib/ghash.h:36: included_from: Included from here.
/usr/include/glib-2.0/glib.h:52: included_from: Included from here.
/usr/include/glib-2.0/gobject/gbinding.h:30: included_from: Included from here.
/usr/include/glib-2.0/glib-object.h:24: included_from: Included from here.
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-audio-playback.h:24: included_from: Included from here.
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-audio-playback.c:22: included_from: Included from here.
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-audio-playback.c:1266:11: note: in expansion of macro ‘g_clear_pointer’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-audio-playback.c:1266:11: note: in expansion of macro ‘g_clear_pointer’
/usr/include/glib-2.0/glib/gstring.h:37: included_from: Included from here.
/usr/include/glib-2.0/glib/giochannel.h:36: included_from: Included from here.
/usr/include/glib-2.0/glib.h:56: included_from: Included from here.
/usr/include/glib-2.0/glib/gstrfuncs.h:324:38: note: in definition of macro ‘g_strdup’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-audio-playback.c:1267:23: note: in expansion of macro ‘g_strdup’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-audio-playback.c: scope_hint: In function ‘registry_event_global’
/usr/include/winpr3/winpr/handle.h:25: included_from: Included from here.
/usr/include/winpr3/winpr/io.h:25: included_from: Included from here.
/usr/include/winpr3/winpr/file.h:28: included_from: Included from here.
/usr/include/winpr3/winpr/wtsapi.h:28: included_from: Included from here.
/usr/include/freerdp3/freerdp/types.h:25: included_from: Included from here.
/usr/include/freerdp3/freerdp/channels/wtsvc.h:35: included_from: Included from here.
/usr/include/freerdp3/freerdp/server/rdpsnd.h:25: included_from: Included from here.
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-audio-playback.h:23: included_from: Included from here.
/usr/include/string.h:156:12: note: argument 1 of ‘strcmp’ must be non-null
# 1268|           }
# 1269|         if (strcmp (item->key, "media.class") == 0 &&
# 1270|->           strcmp (item->value, "Audio/Sink") == 0)
# 1271|           found_audio_sink = TRUE;
# 1272|       }

Error: CPPCHECK_WARNING (CWE-190): [#def15]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-audio-playback.c:1370: error[integerOverflow]: Signed integer overflow for expression '0-1'.
# 1368|       }
# 1369|   
# 1370|->   pw_core_add_listener (audio_playback->pipewire_core,
# 1371|                           &audio_playback->pipewire_core_listener,
# 1372|                           &pipewire_core_events, audio_playback);

Error: CPPCHECK_WARNING (CWE-190): [#def16]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-audio-playback.c:1384: error[integerOverflow]: Signed integer overflow for expression '0-1'.
# 1382|       }
# 1383|   
# 1384|->   pw_registry_add_listener (audio_playback->pipewire_registry,
# 1385|                               &audio_playback->pipewire_registry_listener,
# 1386|                               &registry_events, audio_playback);

Error: CPPCHECK_WARNING (CWE-190): [#def17]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-pipewire-stream.c:1126: error[integerOverflow]: Signed integer overflow for expression '0-1'.
# 1124|       }
# 1125|   
# 1126|->   pw_core_add_listener (stream->pipewire_core,
# 1127|                           &stream->pipewire_core_listener,
# 1128|                           &core_events,

Error: CPPCHECK_WARNING (CWE-190): [#def18]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-pipewire-stream.c:1140: error[integerOverflow]: Signed integer overflow for expression '0-1'.
# 1138|       }
# 1139|   
# 1140|->   pw_registry_add_listener (stream->pipewire_registry,
# 1141|                               &stream->pipewire_registry_listener,
# 1142|                               &registry_events, stream);

Error: GCC_ANALYZER_WARNING (CWE-401): [#def19]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-routing-token.c: scope_hint: In function ‘peek_routing_token’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-routing-token.c:197:7: warning[-Wanalyzer-malloc-leak]: leak of ‘Stream_New(0, 4)’
#  195|   
#  196|     /* Peek TPKT Header */
#  197|->   s = Stream_New (NULL, 4);
#  198|     g_assert (s);
#  199|   

Error: GCC_ANALYZER_WARNING (CWE-401): [#def20]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-routing-token.c:222:7: warning[-Wanalyzer-malloc-leak]: leak of ‘Stream_New(0, (long unsigned int)stream_read_u16_be(Stream_New(0, 4), 1))’
/usr/lib64/glib-2.0/include/glibconfig.h:9: included_from: Included from here.
/usr/include/glib-2.0/glib/gtypes.h:34: included_from: Included from here.
/usr/include/glib-2.0/glib/galloca.h:34: included_from: Included from here.
/usr/include/glib-2.0/glib.h:32: included_from: Included from here.
/usr/include/glib-2.0/gobject/gbinding.h:30: included_from: Included from here.
/usr/include/glib-2.0/glib-object.h:24: included_from: Included from here.
/usr/include/glib-2.0/gio/gioenums.h:30: included_from: Included from here.
/usr/include/glib-2.0/gio/giotypes.h:30: included_from: Included from here.
/usr/include/glib-2.0/gio/gio.h:28: included_from: Included from here.
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-routing-token.h:26: included_from: Included from here.
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-routing-token.c:25: included_from: Included from here.
/usr/include/glib-2.0/glib/gmacros.h:1249:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1250:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-routing-token.c:198:3: note: in expansion of macro ‘g_assert’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-routing-token.c: scope_hint: In function ‘peek_routing_token’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-routing-token.c:203:3: note: in expansion of macro ‘Stream_Read_UINT8’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-routing-token.c:203:3: note: in expansion of macro ‘Stream_Read_UINT8’
/usr/include/winpr3/winpr/assert.h:25: included_from: Included from here.
/usr/include/winpr3/winpr/stream.h:30: included_from: Included from here.
/usr/include/winpr3/winpr/stream.h:147:17: note: in expansion of macro ‘WINPR_ASSERT’
/usr/include/winpr3/winpr/stream.h:148:17: note: in expansion of macro ‘WINPR_ASSERT’
/usr/include/winpr3/winpr/stream.h:148:17: note: in expansion of macro ‘WINPR_ASSERT’
/usr/include/winpr3/winpr/stream.h:127:17: note: in expansion of macro ‘WINPR_ASSERT’
/usr/include/winpr3/winpr/stream.h:128:17: note: in expansion of macro ‘WINPR_ASSERT’
/usr/include/winpr3/winpr/stream.h:128:17: note: in expansion of macro ‘WINPR_ASSERT’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-routing-token.c:203:3: note: in expansion of macro ‘Stream_Read_UINT8’
/usr/include/winpr3/winpr/stream.h:127:17: note: in expansion of macro ‘WINPR_ASSERT’
/usr/include/winpr3/winpr/stream.h:128:17: note: in expansion of macro ‘WINPR_ASSERT’
/usr/include/winpr3/winpr/stream.h:128:17: note: in expansion of macro ‘WINPR_ASSERT’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-routing-token.c:205:3: note: in expansion of macro ‘Stream_Read_UINT16_BE’
/usr/include/winpr3/winpr/stream.h:182:17: note: in expansion of macro ‘WINPR_ASSERT’
/usr/include/winpr3/winpr/stream.h:183:17: note: in expansion of macro ‘WINPR_ASSERT’
/usr/include/winpr3/winpr/stream.h:183:17: note: in expansion of macro ‘WINPR_ASSERT’
/usr/include/winpr3/winpr/stream.h:127:17: note: in expansion of macro ‘WINPR_ASSERT’
/usr/include/winpr3/winpr/stream.h:128:17: note: in expansion of macro ‘WINPR_ASSERT’
/usr/include/winpr3/winpr/stream.h:128:17: note: in expansion of macro ‘WINPR_ASSERT’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-rdp-routing-token.c:205:3: note: in expansion of macro ‘Stream_Read_UINT16_BE’
#  220|     /* Peek full PDU */
#  221|     Stream_Free (s, TRUE);
#  222|->   s = Stream_New (NULL, tpkt_length);
#  223|     g_assert (s);
#  224|   

Error: GCC_ANALYZER_WARNING (CWE-401): [#def21]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c: scope_hint: In function ‘get_certificate_container’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c:265:21: warning[-Wanalyzer-malloc-leak]: leak of ‘freerdp_certificate_new_from_pem(certificate)’
#  263|     *size = 0;
#  264|   
#  265|->   rdp_certificate = freerdp_certificate_new_from_pem (certificate);
#  266|     if (!rdp_certificate)
#  267|       return NULL;

Error: GCC_ANALYZER_WARNING (CWE-401): [#def22]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c:269:21: warning[-Wanalyzer-malloc-leak]: leak of ‘freerdp_certificate_get_der(freerdp_certificate_new_from_pem(certificate), &der_certificate_len)’
#  267|       return NULL;
#  268|   
#  269|->   der_certificate = freerdp_certificate_get_der (rdp_certificate,
#  270|                                                    &der_certificate_len);
#  271|     if (!der_certificate)

Error: GCC_ANALYZER_WARNING (CWE-401): [#def23]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c:274:7: warning[-Wanalyzer-malloc-leak]: leak of ‘Stream_New(0, 2048)’
#  272|       return NULL;
#  273|   
#  274|->   s = Stream_New (NULL, 2048);
#  275|     g_assert (s);
#  276|   

Error: GCC_ANALYZER_WARNING (CWE-401): [#def24]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c: scope_hint: In function ‘grd_session_rdp_send_server_redirection’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c:321:17: warning[-Wanalyzer-malloc-leak]: leak of ‘redirection_new()’
/usr/lib64/glib-2.0/include/glibconfig.h:9: included_from: Included from here.
/usr/include/glib-2.0/glib/gtypes.h:34: included_from: Included from here.
/usr/include/glib-2.0/glib/galloca.h:34: included_from: Included from here.
/usr/include/glib-2.0/glib.h:32: included_from: Included from here.
/usr/include/glib-2.0/gobject/gbinding.h:30: included_from: Included from here.
/usr/include/glib-2.0/glib-object.h:24: included_from: Included from here.
/usr/include/glib-2.0/gio/gioenums.h:30: included_from: Included from here.
/usr/include/glib-2.0/gio/giotypes.h:30: included_from: Included from here.
/usr/include/glib-2.0/gio/gio.h:28: included_from: Included from here.
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.h:23: included_from: Included from here.
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c:22: included_from: Included from here.
/usr/include/glib-2.0/glib/gmacros.h:1249:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1250:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c:316:3: note: in expansion of macro ‘g_assert’
/usr/include/glib-2.0/glib/gmacros.h:1249:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1250:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c:317:3: note: in expansion of macro ‘g_assert’
/usr/include/glib-2.0/glib/gmacros.h:1249:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1250:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c:317:3: note: in expansion of macro ‘g_assert’
/usr/include/glib-2.0/glib/gmacros.h:1249:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1250:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c:318:3: note: in expansion of macro ‘g_assert’
/usr/include/glib-2.0/glib/gmacros.h:1249:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1250:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c:318:3: note: in expansion of macro ‘g_assert’
/usr/include/glib-2.0/glib/gmacros.h:1249:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1250:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c:319:3: note: in expansion of macro ‘g_assert’
/usr/include/glib-2.0/glib/gmacros.h:1249:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1250:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c:319:3: note: in expansion of macro ‘g_assert’
#  319|     g_assert (certificate);
#  320|   
#  321|->   redirection = redirection_new ();
#  322|     g_assert (redirection);
#  323|   

Error: GCC_ANALYZER_WARNING (CWE-401): [#def25]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c: scope_hint: In function ‘init_rdp_session’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c:1152:10: warning[-Wanalyzer-malloc-leak]: leak of ‘freerdp_peer_new(g_socket_get_fd(g_socket_connection_get_socket(*session_rdp.connection)))’
# 1150|     g_debug ("Initialize RDP session");
# 1151|   
# 1152|->   peer = freerdp_peer_new (g_socket_get_fd (socket));
# 1153|     if (!peer)
# 1154|       {

Error: GCC_ANALYZER_WARNING (CWE-401): [#def26]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c:1197:21: warning[-Wanalyzer-malloc-leak]: leak of ‘freerdp_certificate_new_from_pem(server_cert)’
# 1195|                   NULL);
# 1196|   
# 1197|->   rdp_certificate = freerdp_certificate_new_from_pem (server_cert);
# 1198|     if (!rdp_certificate)
# 1199|       {

Error: GCC_ANALYZER_WARNING (CWE-401): [#def27]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c:1204:8: warning[-Wanalyzer-malloc-leak]: leak of ‘freerdp_certificate_new_from_pem(server_cert)’
# 1202|         return FALSE;
# 1203|       }
# 1204|->   if (!freerdp_settings_set_pointer_len (rdp_settings,
# 1205|                                            FreeRDP_RdpServerCertificate,
# 1206|                                            rdp_certificate, 1))

Error: GCC_ANALYZER_WARNING (CWE-401): [#def28]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c:1209:21: warning[-Wanalyzer-malloc-leak]: leak of ‘freerdp_key_new_from_pem(server_key)’
# 1207|       g_assert_not_reached ();
# 1208|   
# 1209|->   rdp_private_key = freerdp_key_new_from_pem (server_key);
# 1210|     if (!rdp_private_key)
# 1211|       {

Error: GCC_ANALYZER_WARNING (CWE-401): [#def29]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-session-rdp.c:1216:8: warning[-Wanalyzer-malloc-leak]: leak of ‘freerdp_key_new_from_pem(server_key)’
# 1214|         return FALSE;
# 1215|       }
# 1216|->   if (!freerdp_settings_set_pointer_len (rdp_settings,
# 1217|                                            FreeRDP_RdpServerRsaKey,
# 1218|                                            rdp_private_key, 1))

Error: GCC_ANALYZER_WARNING (CWE-401): [#def30]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-settings.c: scope_hint: In function ‘update_rdp_server_fingerprint’
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-settings.c:451:21: warning[-Wanalyzer-malloc-leak]: leak of ‘freerdp_certificate_new_from_file(*(GrdSettingsPrivate *)<unknown>.rdp.server_cert_path)’
#  449|   
#  450|   #ifdef HAVE_RDP
#  451|->   rdp_certificate = freerdp_certificate_new_from_file (priv->rdp.server_cert_path);
#  452|     if (!rdp_certificate)
#  453|       {

Error: GCC_ANALYZER_WARNING (CWE-401): [#def31]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-settings.c:458:17: warning[-Wanalyzer-malloc-leak]: leak of ‘freerdp_certificate_get_fingerprint(freerdp_certificate_new_from_file(*(GrdSettingsPrivate *)<unknown>.rdp.server_cert_path))’
#  456|       }
#  457|   
#  458|->   fingerprint = freerdp_certificate_get_fingerprint (rdp_certificate);
#  459|     if (!fingerprint)
#  460|       {

Error: CPPCHECK_WARNING (CWE-190): [#def32]
gnome-remote-desktop-47.1-build/gnome-remote-desktop-47.1/src/grd-vnc-pipewire-stream.c:1019: error[integerOverflow]: Signed integer overflow for expression '0-1'.
# 1017|     g_source_unref (source);
# 1018|   
# 1019|->   pw_core_add_listener (stream->pipewire_core,
# 1020|                           &stream->pipewire_core_listener,
# 1021|                           &core_events,

Scan Properties

analyzer-version-clippy1.82.0
analyzer-version-cppcheck2.16.0
analyzer-version-gcc14.2.1
analyzer-version-gcc-analyzer15.0.0
analyzer-version-shellcheck0.10.0
analyzer-version-unicontrol0.0.2
enabled-pluginsclippy, cppcheck, gcc, shellcheck, unicontrol
exit-code0
hostip-172-16-1-201.us-west-2.compute.internal
mock-configfedora-rawhide-gcc-latest-x86_64
project-namegnome-remote-desktop-47.1-1.fc42
store-results-to/tmp/tmpqu160jpy/gnome-remote-desktop-47.1-1.fc42.tar.xz
time-created2024-11-13 00:00:05
time-finished2024-11-13 00:02:49
toolcsmock
tool-args'/usr/bin/csmock' '-r' 'fedora-rawhide-gcc-latest-x86_64' '-t' 'clippy,cppcheck,gcc,unicontrol,shellcheck' '-o' '/tmp/tmpqu160jpy/gnome-remote-desktop-47.1-1.fc42.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install=gcc-latest' '--gcc-analyzer-bin=/opt/gcc-latest/bin/gcc' '/tmp/tmpqu160jpy/gnome-remote-desktop-47.1-1.fc42.src.rpm'
tool-versioncsmock-3.7.1.20241107.094801.gb3f0f26.pr_192-1.el9