'Return all active ports associated with the allowed_addr_pair ip.'

def _get_ports_for_allowed_address_pair_ip(self, context, network_id, fixed_ip):

    query = context.session.query(models_v2.Port).filter((models_v2.Port.id == aap_models.AllowedAddressPair.port_id), (aap_models.AllowedAddressPair.ip_address == fixed_ip), (models_v2.Port.network_id == network_id), (models_v2.Port.admin_state_up == True))
    return query.all()
