def all_subnets_shorter_prefix(ip_net, cidr, include_default=False):
    """
    Function to return every subnet a ip can belong to with a shorter prefix
    Args:
        ip_net: Unicast or Multicast IP address or subnet in the following format 192.168.1.1, 239.1.1.1
        cidr: CIDR value of 0 to 32
        include_default: If you want the list to inlclude the default route set to True

    Returns: returns a list of subnets

    """
    subnets_list = list()
    if include_default:
        while int(cidr) >= 0:
            try:
                subnets_list.append('%s/%s' % (whole_subnet_maker(ip_net, cidr), cidr))
            except Exception as e:
                LOGGER.critical('Function all_subnets_shorter_prefix {item}'.format(item=e))
            cidr = str(int(cidr) - 1)
    else:
        while int(cidr) > 0:
            try:
                subnets_list.append('%s/%s' % (whole_subnet_maker(ip_net, cidr), cidr))
            except Exception as e:
                LOGGER.critical('Function all_subnets_shorter_prefix {item}'.format(item=e))
            cidr = str(int(cidr) - 1)
    return subnets_list
Function to return every subnet a ip can belong to with a shorter prefix
    Args:
        ip_net: Unicast or Multicast IP address or subnet in the following format 192.168.1.1, 239.1.1.1
        cidr: CIDR value of 0 to 32
        include_default: If you want the list to inlclude the default route set to True

    Returns: returns a list of subnets