def _parse_ports(ports_text):
    """
    Handle the case where the entry represents a range of ports.
    
    Parameters
    ----------
    ports_text: str
        The text of the given port table entry.
        
    Returns
    -------
    tuple
        A tuple of all ports the text represents.
    """
    ports = ports_text.split('-')
    try:
        if len(ports) == 2:
            ports = tuple(range(int(ports[0]), int(ports[1]) + 1))
        else:
            ports = (int(ports[0]),)
    except ValueError:
        return ()
    
    return ports