Remmina - The GTK+ Remote Desktop Client  1.2.0
Remmina is a remote desktop client written in GTK+, aiming to be useful for system administrators and travellers, who need to work with lots of remote computers in front of either large monitors or tiny netbooks. Remmina supports multiple network protocols in an integrated and consistent user interface. Currently RDP, VNC, NX, XDMCP and SSH are supported.
remmina_stats.c File Reference

Remmina usage statistics module. More...

Go to the source code of this file.

Data Structures

struct  ProfilesData
 

Functions

static gchar * remmina_stats_gen_random_uuid_prefix ()
 
JsonNode * remmina_stats_get_uid ()
 
JsonNode * remmina_stats_get_os_info ()
 
JsonNode * remmina_stats_get_version ()
 
JsonNode * remmina_stats_get_gtk_version ()
 
JsonNode * remmina_stats_get_gtk_backend ()
 
JsonNode * remmina_stats_get_wm_name ()
 
JsonNode * remmina_stats_get_indicator ()
 
static void remmina_profiles_get_data (RemminaFile *remminafile, gpointer user_data)
 Given a remmina file, fills a structure containing profiles keys/value tuples. More...
 
JsonNode * remmina_stats_get_profiles ()
 Add a json member profile_count with a child for each protocol used by the user. More...
 
JsonNode * remmina_stats_get_all ()
 Get all statistics in json format to send periodically to the PHP server. More...
 

Variables

struct utsname u
 

Detailed Description

Remmina usage statistics module.

Author
Antenore Gatta and Giovanni Panozzo
Date
12 Feb 2018

When Remmina starts asks the user if she/he wants to share some usage statistics with the Remmina developers. As per the opt-in model (https://en.wikipedia.org/wiki/Opt-in_email), without the consent of the user, none of these data will be collected. Additionally a user can asks, at any moment, that any data linked to his/her profiles to be deleted, and he/she can change the Remmina settings to stop collecting and sharing usage statistics.

All the data are encrypted at client side using RSA, through the OpenSSL libraries, and decrypted offline to maximize security.

The following example show which kind of data are collected.

{
"UID": "P0M20TXN03DWF4-9a1e6da2ad"
"REMMINAVERSION": {
"version": "1.2.0-rcgit-26"
"git_revision": "9c5c4805"
"snap_build": 0
}
"SYSTEM": {
"kernel_name": "Linux"
"kernel_release": "4.14.11-200.fc26.x86_64"
"kernel_arch": "x86_64"
"lsb_distributor": "Fedora"
"lsb_distro_description": "Fedora release 26 (Twenty Six)"
"lsb_distro_release": "26"
"lsb_distro_codename": "TwentySix"
"etc_release": "Fedora release 26 (Twenty Six)"
}
"GTKVERSION": {
"major": 3
"minor": 22
"micro": 21
}
"GTKBACKEND": "X11"
"WINDOWMANAGER": {
"window_manager": "GNOME i3-gnome"
}
"APPINDICATOR": {
"appindicator_supported": 0
"icon_is_active": 1
"appindicator_type": "AppIndicator on GtkStatusIcon/xembed"
}
"PROFILES": {
"profile_count": 457
"SSH": 431
"NX": 1
"RDP": 7
"TERMINAL": 2
"X2GO": 5
"SFTP": 4
"PYTHON_SIMPLE": 4
"SPICE": 3
"DATE_SSH": "20180209"
"DATE_NX": ""
"DATE_RDP": "20180208"
"DATE_TERMINAL": ""
"DATE_X2GO": ""
"DATE_SFTP": ""
"DATE_PYTHON_SIMPLE": ""
"DATE_SPICE": ""
}
}

All of these data are solely transmitted to understand:

  • On which type of system Remmina is used
  • Operating System
  • Architecture (32/64bit)
  • Linux distributor or OS vendor
  • Desktop Environment type.
  • Main library versions installed on the system in use by Remmina.
  • Protocols used
  • Last time each protocol has been used (globally).
See also
http://www.remmina.org/wp for more information.

Definition in file remmina_stats.c.

Function Documentation

◆ remmina_profiles_get_data()

static void remmina_profiles_get_data ( RemminaFile remminafile,
gpointer  user_data 
)
static

Given a remmina file, fills a structure containing profiles keys/value tuples.

This is used as a callback function with remmina_file_manager_iterate.

Todo:
Move this in a separate file.

Source date -> from profile

Destination date -> The date in the pdata structure

When both date in the has and in the profile are valid we compare the date

If the date in the hash less than the date in the profile, we take the latter

If the date in the hash is NOT valid and the date in the profile is valid we keep the latter

If both date are NULL, we insert NULL for that protocol

If there is not the protocol in the hash, we add it

If the date in the profile is not NULL we use it

Otherwise we set it to NULL

Definition at line 540 of file remmina_stats.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ remmina_stats_gen_random_uuid_prefix()

static gchar* remmina_stats_gen_random_uuid_prefix ( )
static

Definition at line 161 of file remmina_stats.c.

Here is the caller graph for this function:

◆ remmina_stats_get_all()

JsonNode* remmina_stats_get_all ( void  )

Get all statistics in json format to send periodically to the PHP server.

The caller should free the returned buffer with g_free()

Warning
This function is usually executed on a dedicated thread, not on the main thread.
Returns
a pointer to the JSON string.

Definition at line 727 of file remmina_stats.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ remmina_stats_get_gtk_backend()

JsonNode* remmina_stats_get_gtk_backend ( )
Warning
this function is usually executed on a dedicated thread, not on the main thread

Definition at line 409 of file remmina_stats.c.

Here is the caller graph for this function:

◆ remmina_stats_get_gtk_version()

JsonNode* remmina_stats_get_gtk_version ( )
Warning
this function is usually executed on a dedicated thread, not on the main thread

Definition at line 384 of file remmina_stats.c.

Here is the caller graph for this function:

◆ remmina_stats_get_indicator()

JsonNode* remmina_stats_get_indicator ( )

Support for StatusNotifier or AppIndicator

StatusNotifier/Appindicator supported by desktop

libappindicator is compiled in remmina.

Remmina not compiled with -DWITH_APPINDICATOR=on

StatusNotifier/Appindicator NOT supported by desktop

Remmina icon is active

libappindicator fallback to GtkStatusIcon/xembed");

Remmina fallback to GtkStatusIcon/xembed

Remmina icon is NOT active

Definition at line 485 of file remmina_stats.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ remmina_stats_get_os_info()

JsonNode* remmina_stats_get_os_info ( )
Warning
this function is usually executed on a dedicated thread, not on the main thread
Todo:
Add other means to identify a release name/description to cover as much OS as possible, like /etc/issue

Definition at line 230 of file remmina_stats.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ remmina_stats_get_profiles()

JsonNode* remmina_stats_get_profiles ( )

Add a json member profile_count with a child for each protocol used by the user.

Count how many profiles are in use and for each protocol in use counts of how many profiles that uses such protocol.

The data can be expressed as follows:

PROTO PROF COUNT
RDP 2560
SPICE 334
SSH 1540
VNC 2
PROTO LAST USED
RDP 20180129
SPICE 20171122
SSH 20180111
Warning
this function is usually executed on a dedicated thread, not on the main thread

Definition at line 657 of file remmina_stats.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ remmina_stats_get_uid()

JsonNode* remmina_stats_get_uid ( )
Warning
this function is usually executed on a dedicated thread, not on the main thread

Definition at line 188 of file remmina_stats.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ remmina_stats_get_version()

JsonNode* remmina_stats_get_version ( )
Warning
this function is usually executed on a dedicated thread, not on the main thread

Detect if we are running under Flatpak

Definition at line 342 of file remmina_stats.c.

Here is the caller graph for this function:

◆ remmina_stats_get_wm_name()

JsonNode* remmina_stats_get_wm_name ( )

We try to get the Gnome SHELL version

When everything else fails with set the WM name to NULL

Definition at line 441 of file remmina_stats.c.

Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ u

struct utsname u

Definition at line 150 of file remmina_stats.c.