code: def _unassigned_ports():
      
      free_ports = ranges_to_set(_parse_ranges(_iana_unassigned_port_ranges()))
      known_ports = ranges_to_set(_wikipedia_known_port_ranges())
      return free_ports.difference(known_ports)
docs: Returns a set of all unassigned ports (according to IANA and Wikipedia)