zeenix / gps-share

Utility to share your GPS device on local network
GNU General Public License v2.0
67 stars 9 forks source link

Use the standard 10110/TCP port instead of a dynamically selected port #9

Closed da2x closed 6 years ago

da2x commented 6 years ago

TCP port 10110 is the standard port for nmea-0183 services. The port has been claimed and registered with IANA, making it an established industry standard.

Use of this port with GeoClue specifically has prescience in the GeoClueShare app for Android.

Using this port instead of a dynamically selected port will ease service discovery and uncomplicate packaging and firewall configuration.

If you agree to the change @zeenix, I’ll add generic firewall service definitions upstream so people will be able to just enable the nmea-0183 service in their firewall to allow remote connections to gps-share.

hadess commented 6 years ago

firewalld's Fedora Workstation configuration already has all user-accessible ports opened, fwiw.

zeenix commented 6 years ago

oh cool, I didn't know of this. I do agree but i didn't understand what you mean by "upstream" here. There are no changes needed geoclue as it gets the port from avahi. We need changes to gps-share (and geoclue-share android app if I understood you correctly?) but we should still allow user to specify a different port.

da2x commented 6 years ago

geoclue-share already uses this port by default. No change needed there.

gps-share needs to be changed to use this port by default instead of a random port (unless overwritten with --port ####).

“upstream” here refers to the firewall projects firewalld, ufw, and others. I’ll submit a generic nmea-0183 service that allows connections on port 10110. As it’s an IANA registered port, upstream should be willing to accept the new service definition (a named preset). The end goal is to allow users to easily configure their firewalls with something like firewall-cmd --zone=local --add-service=nmea-0183 to allow remote connections to gps-share from the local network.

zeenix commented 6 years ago

@da2x alright, awesome stuff. :) I guess my GSoC student (who wrote gps-share) was smarter than me. :) I'm hoping you'll be providing a patch for gps-share too? ;)

da2x commented 6 years ago

Resolved by #10.