gnome-user-share random port blocked by firewall

Hi

I am trying to use the gnome-user-share service to transfer some files over my network. There are two issues I have encountered, well three actually but I solved one.

First of all the service needs the apache server which is not installed by default on 11.3 even though gnome user share is, and gnome user share advertises itself in nautilus as a quick way to share files. This is easily solved by obtaining the appache server package from zypper/yast.

Secondly gnome-user-share creates an httpd service which listens in at some random high port. e.g. running lsof -i yields

COMMAND  PID USER   FD   TYPE DEVICE SIZE/OFF NODE NAME
httpd2  5108   ac    4u  IPv6  21752      0t0  TCP *:49638 (LISTEN)
httpd2  5109   ac    4u  IPv6  21752      0t0  TCP *:49638 (LISTEN)
httpd2  5110   ac    4u  IPv6  21752      0t0  TCP *:49638 (LISTEN)

Since the port is random , I can’t think of a way to open it in the firewall without opening the entire high range of ports which to me seems like a bad idea for security reasons. When I allow this port through the filesharing works as it should.

Thirdly when the system reboots, I need to enable “personal file sharing” again for the service to relaunch.

I want some advice on solving problem two in this thread. Namely whats the best way to tell the firewall to open up whichever port gnome-user-share has taken over, without telling it to allow in the entire (large, in the number of thousands I believe) range of ports it can assign itself to?