#include <AppsPage.hpp>
Classes | |
| struct | Columns |
Public Member Functions | |
| AppsPage () | |
| void | noteConnection (const ConnectionInfo &info, const std::string &verdict) |
| void | clear () |
Private Member Functions | |
| void | buildUI () |
Static Private Member Functions | |
| static std::string | currentTimeString () |
| static std::string | displayNameFor (const ConnectionInfo &info) |
Private Attributes | |
| Columns | m_columns |
| Glib::RefPtr< Gtk::ListStore > | m_store |
| Gtk::TreeView | m_treeView |
| Gtk::ScrolledWindow | m_scroll |
| Gtk::Label | m_headerLabel |
| Gtk::Button | m_clearBtn |
| std::unordered_map< std::string, Gtk::TreeModel::iterator > | m_appRows |
Pagina che elenca tutte le applicazioni che hanno aperto connessioni nella sessione corrente, con conteggio + ultimo host contattato + timestamp.
Identita' applicazione: nome reale del processo dal kernel (/proc/<pid>/comm). Nessuna scansione dei file .desktop.
Aggregazione per process_path (binario unico). Aggiornata a O(1) tramite mappa path -> iterator nel ListStore.
Definition at line 25 of file AppsPage.hpp.
| AppsPage::AppsPage | ( | ) |
Definition at line 16 of file AppsPage.cpp.
References buildUI().
|
private |
Definition at line 27 of file AppsPage.cpp.
References _, clear(), AppsPage::Columns::col_count, AppsPage::Columns::col_last_host, AppsPage::Columns::col_last_time, AppsPage::Columns::col_last_verdict, AppsPage::Columns::col_name, AppsPage::Columns::col_path, m_clearBtn, m_columns, m_headerLabel, m_scroll, m_store, and m_treeView.
Referenced by AppsPage().
| void AppsPage::clear | ( | ) |
Azzera la lista.
Definition at line 150 of file AppsPage.cpp.
References m_appRows, and m_store.
Referenced by buildUI().
|
staticprivate |
Definition at line 93 of file AppsPage.cpp.
Referenced by noteConnection().
|
staticprivate |
Definition at line 103 of file AppsPage.cpp.
References ConnectionInfo::app_args, ConnectionInfo::app_comm, ConnectionInfo::app_path, bsc::ui_util::best_connection_display_name(), ConnectionInfo::dest_ip, and ConnectionInfo::src_ip.
Referenced by noteConnection().
| void AppsPage::noteConnection | ( | const ConnectionInfo & | info, |
| const std::string & | verdict ) |
Registra una connessione nella vista per-app.
Definition at line 109 of file AppsPage.cpp.
References ConnectionInfo::app_comm, ConnectionInfo::app_path, AppsPage::Columns::col_count, AppsPage::Columns::col_last_host, AppsPage::Columns::col_last_time, AppsPage::Columns::col_last_verdict, AppsPage::Columns::col_name, AppsPage::Columns::col_path, currentTimeString(), ConnectionInfo::dest_host, ConnectionInfo::dest_ip, ConnectionInfo::dest_port, displayNameFor(), bsc::ui_util::is_safe_local_connection(), m_appRows, m_columns, m_store, and ConnectionInfo::src_ip.
Referenced by MainWindow::onDaemonAlert(), MainWindow::onNewConnection(), and MainWindow::onVerdict().
|
private |
Definition at line 62 of file AppsPage.hpp.
Referenced by clear(), and noteConnection().
|
private |
Definition at line 59 of file AppsPage.hpp.
Referenced by buildUI().
|
private |
Definition at line 54 of file AppsPage.hpp.
Referenced by buildUI(), and noteConnection().
|
private |
Definition at line 58 of file AppsPage.hpp.
Referenced by buildUI().
|
private |
Definition at line 57 of file AppsPage.hpp.
Referenced by buildUI().
|
private |
Definition at line 55 of file AppsPage.hpp.
Referenced by buildUI(), clear(), and noteConnection().
|
private |
Definition at line 56 of file AppsPage.hpp.
Referenced by buildUI().