gustavo-iniguez-goya/opensnitch

running GUI from source requires "sudo make install"

themighty1 opened this issue · 5 comments

Hi I've built from the master today and I cant connect the gui. The daemon shows:

[2020-10-26 16:09:32] IMP Starting opensnitch-daemon v1.0.1
[2020-10-26 16:09:32] INF Loading rules from /etc/opensnitchd/rules ...
WARNING: nfq_get_uid not available
[2020-10-26 16:09:32] INF Process monitor method /proc
[2020-10-26 16:09:32] INF Running on netfilter queue #0 ...
[2020-10-26 16:09:45] INF Connected to the UI service on /tmp/osui.sock
[2020-10-26 16:09:45] ERR Subscribing to GUI%!(EXTRA *status.statusError=rpc error: code = Internal desc = Exception deserializing request!)
[2020-10-26 16:09:45] WAR Error while pinging UI service: rpc error: code = Internal desc = Exception deserializing request!

the last line keep repeating every second.

nvm for now, I managed to get it working by starting from a clean rules folder. Will let you know when I have more info.

looking at -debug, the daemon is working and is loading my old rules fine. It is the frontend that has trouble connecting. So, maybe some recent change in ui code is at fault.

ok, thank you @themighty1 ! I built it on a clean VM and it worked fine, but I'll take a look at it soon. Some more changes are coming.

I've reproduced it in this way:

  • install version 1.0.1 (daemon and gui) and launch it
  • create some permanent rules
  • install latest daemon compiled from sources and launch it.

In this case, the daemon and GUI has different protocol specification, so the daemon complains on the data received.

Copy also the UI files under opensnitch/ui/opensnitch/* to /usr/lib/python3/dist-packages/opensnitch/ if you didn't it already, and see if the error appears again.

Thank you so much, after your post I realized that maybe I need to run
sudo make install
(even though I don't intend to invoke the installed binaries but will use the binaries from the source folders.)
It worked! So, Ill just change the ticket name and close it.
Thanks.