Read the content of
/etc/services. There are a few comments that will shed some light on this.
# Network services, Internet style
# Note that it is presently the policy of IANA to assign a single well-known
# port number for both TCP and UDP; hence, officially ports have two entries
# even if the protocol doesn't support UDP operations.
# Updated from https://www.iana.org/assignments/service-names-port-numbers/service-names-port-numbers.xhtml .
# New ports will be added on request if they have been officially assigned
# by IANA and used in the real-world or are needed by a debian package.
# If you need a huge list of used numbers please install the nmap package.
# The remaining port numbers are not as allocated by IANA.
# Services added for the Debian GNU/Linux distribution
# Local services
These are not the only comments in the file.
From this I see a section of ports assigned by IANA. A section that are documented by IANA (but not assigned by), a section assigned by Debian (I am running Debian Gnu/Linux), and a section for me to add locally used ports.
See these pages for more information
The second link above has information on how to register a port. You can also register just a name (ports can be looked up for a particular end-point using DNS).
How would you go about getting a port registered for your software
Get popular: You won't convince anyone until your software is popular.
What to do now.
Choose a port that is not in use. Chose a default, but make it configurable.
Low numbered ports (reserved for root, or capability CAP_NET_BIND_SERVICE)
You can use these if you have control over the machine. The advantage on a multi user machine, is other users can not use the port: steal the port (DOS), use the port (fake site), etc.