Reply
Highlighted

Host by network

Posts: 1
1989     0

Hi,

 

I was trying to get all DNS hosts from a specific range (for instance 150.100.23.0/23) but I can't get it. Is there any way to achieve this?

 

I'm using WAPI through URL, not using Curl or Perl or Python.

 

Thanks and best regards

Re: Host by network

GHorne Community Manager
Community Manager
Posts: 254
1990     0

you can query the /ipv4address and /ipv6address objects by either a range or a network.

 

e.g:

 

/ipv4address?network=150.100.23.0/23

/ipv4address?ip_address>150.100.23.0&ip_address<150.100.23.255

 

For each address returned in the query, you will get a list of REFs to any DNS objects that are using that address:

 

    {
        "_ref": "ipv4address/Li5pcHY0X2FkZHJlc3MkMS4wLjAuMS8w:1.0.0.1", 
        "ip_address": "1.0.0.1", 
        "is_conflict": false, 
        "mac_address": "", 
        "names": [
            "dnsteamtest.org.com"
        ], 
        "network": "1.0.0.0/24", 
        "network_view": "default", 
        "objects": [
            "record:host/ZG5zLmhvc3QkLl9kZWZhdWx0LmNvbS5zc21iLm55LmRuc3RlYW10ZXN0:dnsteamtest.org.com/default"
        ], 
        "status": "USED", 
        "types": [
            "HOST"
        ], 
        "usage": [
            "DNS"
        ]
    }, 

 

Showing results for 
Search instead for 
Do you mean 

Recommended for You