Changing default screen sharing port

Recently I've installed Zorin OS 16 Pro and unlike previous versions of Zorin, 16 appears to not be using vino for the remote desktop sharing. This is perfectly fine and in my opinion a good change due to the somewhat broken encryption it had. It appears to me that 16 is using Gnome's built in desktop sharing package "gnome-remote-desktop" Can anyone help me to confirm this and possible help with a solution to changing the default port? Due to online sniffers who look for open vnc and rdp ports, I like to change my port often and don't like to use the default of 5900. I've already tried using dconf-editor, however the remote desktop entries don't appear to be present under /desktop/gnome/remote-desktop. I might be on the wrong track with believing Zorin 16 is using gnome-remote-desktop, however the package was installed by default and vino was not. In addition when running "netstat -a | grep 5900" it shows that the default port of 5900 indeed opens up when enabling desktop sharing from settings. Any help would be greatly appreciated. Thanks in advance.

A few things, Yes Zorin 16 uses gnome-remote-desktop for vnc and rdp which can be activated from the sharing tab in settings. The bad news is that this is not as far as I can tell easily changeable without recompiling from source of the package having made the change of port within the /src/grd-settings.c file. This approach does however 100% work and I was able to change my remote desktop port and confirm that gnome is now using my specified port rather than the default of 5900. This could be my ignorance and lack of knowledge with C, however there is a commit on the master branch of this project which says added ability to override port. When I was looking I didn't see a way to do this due to my inexperience with the code base and C, plus my method worked anyways so I didn't dig too deep. In addition this override would likely be through command line. Countless google searches gave no results as to how to achieve this override with most resources referring to Ubuntu and vino (which I've already stated are not applicable). Either way figured I'd give an update to anyone looking to solve this issue in the future as I've done the heavy lifting and could save you some time. Be advised however, the build process is not documented and it will require both ninja and meson to build along with a large list of deficiencies which will become apparent when using meson. Thanks to anybody who may have been looking into this yet unable to provide a solution, I thank you nonetheless.

1 Like

Dude, you're the ninja. Nice persistence and thanks for posting your findings.

1 Like

Thanks lol, I still have a lot to learn. I've been using Linux and Zorin OS namely since Zorin OS 9 (Zorin has been my main OS since) so I have a lot of experience with Ubuntu. However things like this always challenge me and show how much that I really don't know and this was a fun learning experience which I hope can help some others.

1 Like

I posted the same question not too long ago. I think I will just install xRDP. I'm not having luck with the build-in gnome-remote-desktop. For one, I run dual monitors and for some reason, I either get a black screen when connecting remotely or I'm only able to see my primary screen. This poses a problem when application windows are opened on the secondary screen.

1 Like

xrdp seem to have the same issue as VNC, except some even worse. More research I do, turns out these remote desktop issues are localized to GNOME and gdm3. I've settled on NoMachine. It gets me what I need. I have full desktop with dual monitors (both monitors) accessible.

Why not use LightDM or SDDM and a Different Desktop like XFCE?