Commit graph

404 commits

Author SHA1 Message Date
Gustavo Iñiguez Goia
94fa3c8093 ui, stats: better window restoration on KDE
Latest approach seems to not always work (latest KDE on kubuntu 20 and
manjaro as of today).

This seems to work better:
https://doc.qt.io/qt-5/qwidget.html#setWindowState
2021-08-13 18:03:10 +02:00
Gustavo Iñiguez Goia
2b8c931762 ui, events: translate columns headers
Related: #465
2021-08-12 15:12:11 +02:00
Gustavo Iñiguez Goia
38d4fb9ae5 Bump versions to v1.4.0rc4 2021-08-11 17:16:56 +02:00
Gustavo Iñiguez Goia
6ce099ffd5 ui, events: fixed restoring state when minimized
On KDE the events window was not restored to previous state when the
window was minimized to the taskbar.

This was fixed by @themighty1 in this PR #315, but there was an
unexpected behaviour on others DE.

As I haven't seen this error in others DE, we apply the original
fix, but only when the DE in use is KDE.
2021-08-09 15:28:15 +02:00
Gustavo Iñiguez Goia
0910249fb2 ui: fixed typos, improvements.
- Fixed typos in the preferences dialog (#465).
- Fixed hiding/showing rules combobox.
- Keep opensnitchd/default-config.json format when saving node's
  configuration from the GUI.
2021-08-09 13:30:56 +02:00
Gustavo Iñiguez Goia
db18b0cc63
Merge pull request #470 from ovari/master
Update opensnitch-hu_HU.ts
2021-08-08 12:51:34 +02:00
Gustavo Iñiguez Goia
bca5ffa9b5 ui,rules: update rules last_seen field on new stats
Update the last_seen field every time a new connection is established.
2021-08-08 12:29:37 +02:00
ovari
dd94c3fe1a
Update opensnitch-hu_HU.ts 2021-08-06 18:28:24 +10:00
Gustavo Iñiguez Goia
388c98e559 ui,preferences dialog: fixed crash
qcombobox placeHolderText preference was set as translatable, and it
caused a crash.
2021-08-03 01:11:12 +02:00
Gustavo Iñiguez Goia
f96e44dc93 ui: improved UI internationalization, columns fix
- Now the columns names of the details views can be translated (#465).
- Fixed columns size restoring when clicking on the Events tab to view
  the details of an item (process, rule or node).
2021-08-02 17:16:10 +02:00
Gustavo Iñiguez Goia
de3c4be5d5 ui: allow personalize columns size
Now if you resize any columns, it'll be remembered the next time you
open that view.
2021-07-31 18:57:17 +02:00
Gustavo Iñiguez Goia
2b3fdfc948 ui,db: display an error if the db file is corrupted
Display an alert if the db loaded from disk is corrupted.

closes #460
2021-07-31 01:35:28 +02:00
Gustavo Iñiguez Goia
83ab1f9f5e ui, prompt: fixed increasing height when prompting
There was an annoying bug that increased the pop-up height a little bit
everytime a new pop-up was displayed.

Hopefully this time it's fixed, while maintaining compatiblitiy on the
mobile (i.e.: displaying the buttons at the bottom and the connection
information at the top of the pop-up).
2021-07-29 19:22:15 +02:00
Gustavo Iñiguez Goia
b644853d63 ui: allow to configure events columns, misc
* Preferences:
  - Allow to configure the columns of the Events tab.
  - Fixed displaying labels on small screens.

* Rules:
  - Added combo to select the type of rules to list (all, permanent,
    temporary) when the left panel is hidden.

* Main window:
  - Improved tabs widgets positioning.

* Misc:
  - Improved code to avoid typos.
2021-07-26 19:00:22 +02:00
Gustavo Iñiguez Goia
a3a171d2a2 ui: allow to ignore temporary rules, fixes, impovements
- Added option to ignore temporary rules. All or only of duration
  "once".
  You can still use them when answering a pop-up, but if you check the
  option, the rules won't be added to the rules list.

- Fixed wrong behaviour when adding rules to the db/gui.
  When changing a rule duration (always->30s, 30s->always), if there
  were connections matching that rule, the rule was re-added to the
  db/rules list with the old duration, ending up with 2 rules in the
  list.
  This was caused by how stats are sent to the GUI. When populating the
  db with the stats, we were also adding the rules.

  Now we don't add the rules when adding the stats. Rules are added to
  the db everytime a node connects to the GUI, when answering a pop-up
  or whenever the user performs an operation on them.

  Performance has increased a little bit due to this.

- Fixed applying configuration to all nodes at once.
- Added help menu to the preferences dialog.
- Removed lists grid.
- A little bit of code reorganization.
2021-07-24 23:53:42 +02:00
Gustavo Iñiguez Goia
544887adeb ui, pkgs: added packaging step to fix pb2 files.
Some checks failed
Build status / Build (push) Has been cancelled
2021-07-17 11:13:34 +02:00
Gustavo Iñiguez Goia
708a7e6333 Bump versions to v1.4.0rc3 2021-07-16 23:41:02 +02:00
Gustavo Iñiguez Goia
5e56e9033f ui, process monitor dialog: fixed exception
Fixed exception when stopping the monitor fails and an error is
returned.
2021-06-19 01:00:33 +02:00
Steven Hollingsworth
de559dccf8
Changed import ui_pb2 from global to relative 2021-06-18 12:54:17 -07:00
Steven Hollingsworth
3d9b44cb50
fixes #439 - module namespace conflict 2021-06-17 16:39:35 -07:00
gnuhead-chieb
a006f25fb3
Add files via upload 2021-06-16 11:39:42 +00:00
Gustavo Iñiguez Goia
eaa015870b ui,rules: fixed refreshing list after delete,
- Fixed refreshing rules list after delete a rule(s).
  (There was an annoying delay).
- Added button to delete connections associated with a rule, from the
  details view of a rule. (related: #334).
2021-06-09 00:25:24 +02:00
ovari
5f73dc1069
Update opensnitch_ui.desktop 2021-06-03 06:44:21 +10:00
Gustavo Iñiguez Goia
95a30c4959 ui, rules editor: fixed editing/adding rules
There was a race condition that caused several problems when editing or
adding rules.

for rules of type "list", the operand must be "list" as well.

related: #429 #425
2021-05-31 20:22:44 +02:00
Gustavo Iñiguez Goia
2c1f8e1d8c ui: added description to the .desktop file
closes #422
2021-05-23 16:14:36 +02:00
ovari
cbabc84076
Update opensnitch-hu_HU.ts 2021-05-21 06:57:25 +10:00
ovari
5ae629bde4
Update opensnitch-hu_HU.ts 2021-05-20 19:49:23 +10:00
Gustavo Iñiguez Goia
050292601e translations: deleted hu_HU file from wrong directory 2021-05-14 01:57:18 +02:00
ovari
5be9911f00
Add translation template for hu_HU and sort TRANSLATORS alphabetically (#411)
* Update opensnitch_i18n.pro

List `TRANSLATIONS` alphabetically

* Create opensnitch-hu_HU.ts
2021-05-13 23:34:56 +02:00
Gustavo Iñiguez Goia
03f378687b updated translation files, added ro_RO and hu_HU
New translation files not yet translated.
2021-05-12 21:06:20 +02:00
Gustavo Iñiguez Goia
1be19788ed ui: updated spanish translation 2021-05-10 21:37:21 +02:00
Flávio Costa
49cd9052eb
Update Brazilian Portuguese translation (#409)
* Update Brazilian Portuguese translation

* Update Brazilian Portuguese translation
2021-05-10 21:31:57 +02:00
Gustavo Iñiguez Goia
f0b4d7ab68 ui, systray menu: fixed translations
translations must occur inside __init__():
2021-05-09 23:03:17 +02:00
Gustavo Iñiguez Goia
0e6489bab7
Update i18n instructions 2021-05-08 00:06:56 +02:00
Gustavo Iñiguez Goia
2e42e989d4 Bump versions to 1.4.0rc2
As we've added eBPF interception method, we need go iovisor ebpf package,
which is not packaged for Debian yet, so the way I was compiling it
differs a little bit (instead of using gbp buildpackage,
dpkg-buildpackage is used).

Aside from that, there'll be a new eBPF module (.o ELF), which must be
packaged with the packages. Will be compiled on the fly, but maybe it
could be hosted in the repo, because it won't change that much.
2021-05-07 21:24:42 +02:00
Gustavo Iñiguez Goia
042b04e3fb ui: main window improvements
- disable clicks when the user enters into the details of an item
  (process, host, user, etc).
- fixed displaying the button to inspect a process.
- improved listing connections of a process.
2021-05-01 01:29:30 +02:00
Gustavo Iñiguez Goia
dc56be495c ui: display 50 events by default, fixed pop-up crash
- By default there was no limit of events to display. If the user had
  the GUI opened for a long period of time, that could lead to an
  excessive CPU usage and thus a bad user experience. So by default
  set it to 50.
- pop-ups: Fixed crash when getting malformed icons from .desktop
  files.
2021-04-27 01:29:05 +02:00
Arnout Engelen
517ecd7e13
Allow using newer grpcio-tools
My OS comes with grpcio-tools 1.36.1, which seems to work fine, so it
would be nice to allow the ui to use that instead of building 1.10.1
specifically for opensnitch.
2021-04-24 21:05:02 +02:00
Gustavo Iñiguez Goia
82ca19a190 ui: configure more options from the preferences
- pop-ups: allow to configure if the "advanced view" is displayed
  by default or not.
- pop-ups: allow to configure 3 more fields to filter connections by.
- services.py: fixed typo that caused an error when displaying a
  message.

closes #399.
2021-04-23 22:25:51 +02:00
Gustavo Iñiguez Goia
80c9519d08 ui: make UI updates on the main thread
- Updates of the GUI must occur on the main thread of the app. AskRule,
  Ping, Subscribe and Notifications runs on a different thread.
- Fixed paused state when the daemon is running (and paused) and the GUI
  is launched.
- Moved functionality to its own file/class.
2021-04-18 17:01:53 +02:00
Gustavo Iñiguez Goia
966342cbbc ui: allow to stop/start interception from systray
- removed unused import time.
- allow to pause/start interception from tray contextual menu.
- improved case when the daemon is in paused state, and the GUI is
  launched.

There's more work yet to do to improve the states when there're several
nodes connected.

closes #398
2021-04-17 22:09:16 +02:00
Gustavo Iñiguez Goia
23b61f5341 ui, pop-ups: allow to choose the position of popups
This feature was disabled on the preferences dialog, it just needed to
be removed or implmented.
2021-04-17 13:07:38 +02:00
Gustavo Iñiguez Goia
49d12612db ui: updated help url, fixed a typo
point help links to evilsocket's repo.
fixed error launching the GUI when there's no systray available.
2021-04-13 00:10:56 +02:00
Gustavo Iñiguez Goia
f288078c0b ui, db: fixed loading db type from saved configuration
If a db from disk was being used, and the user changed it to in-memory,
we were still loading the file from disk.
2021-04-12 17:59:14 +02:00
Gustavo Iñiguez Goia
03e97903d6 ui, prefs/pop-ups: improved layout
specially for non-desktop displays (mobiles), like librem5.
2021-04-12 17:52:27 +02:00
Gustavo Iñiguez Goia
4332469fc2 improved nodes connectivity handling
problem:
 - after losing network connectivity node<->server, the node didn't restore
   the connection. In reality, the connection with the server was not
   closed, but the notifications channel was closed due to inactivity
   after 20s.

set inactivity timeouts to 20s on both node and server. Previous
timeouts were 2h for the main connection and 20s for the streaming
channels (notifications).

- get rid of the logic to determine if the server is alive or not based
  on sending pings.
  Instead, use the connection events when a node connects/disconnects
  (Subscribe).
  The Ping call is still used to send the statistics.

other:
- fixed exception when updating the status of a node.
2021-04-11 20:55:14 +02:00
Gustavo Iñiguez Goia
356e3dc54e ui: fixed notifications and rules editing
- fixed remote nodes rules editing.
- improved notifications when a node is not connected and an action is
  performed on it (edit a rule, disable/enable a rule, etc).
2021-04-08 00:49:49 +02:00
Gustavo Iñiguez Goia
2c1c3b0251 ui,stats: added more options to handle rules in batch
- allow to change duration and action to multiple rules at once.
closes #393
- fixed updating a rule on the db (per node).
- fixed typo.

 #334
2021-04-07 23:14:26 +02:00
Gustavo Iñiguez Goia
c7411a4770 ui, pop-up: improved layout
better layout when there's or there isn't app description.
2021-04-07 19:03:50 +02:00
Gustavo Iñiguez Goia
dbe7861bcb ui: allow to select eBPF method from the GUI
+ fixed getting PID column in order to monitor processes' details.
2021-04-05 13:28:16 +02:00