THE GAME HAS CHANGED

Introducing Infoblox Universal DDI ManagementTM

Watch the launch to discover the new era of management for critical network services. Watch Now

API & Integration, DevOps,NetOps,SecOps

Reply

Reproduce nslookup or dig with API queries

New Member
Posts: 2
5276     0

I would like to create a web based site that will return the same results produced by either nslookup or dig.  You can find many public tools to do this and they all work against public DNS servers.  I would like something similar except that it will query our internal DNS.  We would use the tool when we are connected internally.

 

Can I reproduce the results from nslookup or dig by calling API queries?  Any advice for me? thanks.

Re: Reproduce nslookup or dig with API queries

Moderator
Moderator
Posts: 321
5277     0

Yes!  All API calls will go to the Grid Manager, and the GM will send the query task out to the specified appliance.  Here's a curl example, to send a query to two different appliances simultaneously, to compare the answers.

 

curl -k1 -u admin:infoblox -X POST 'https://192.168.1.2/wapi/v2.12/request' -H "Content-Type: application/json" -d \
'[{
  "method":"POST",
  "object":"grid",
  "args":{"_function":"query_fqdn_on_member"},
  "data":{
    "name_server":"8.8.8.8",
    "fqdn":"infoblox.com",
    "record_type":"A",
    "member":"gm.blox.corp"
  }
},
{
  "method":"POST",
  "object":"grid",
  "args":{"_function":"query_fqdn_on_member"},
  "data":{
    "name_server":"8.8.8.8",
    "fqdn":"infoblox.com",
    "record_type":"A",
    "member":"gmc.blox.corp"
  }
}]'

 

 

Re: Reproduce nslookup or dig with API queries

New Member
Posts: 2
5277     0

Thanks for the feedback, I used the example provided to reply other Record types and it is working as needed. 

Showing results for 
Search instead for 
Did you mean: 

Recommended for You