Introducing SOC Insights for BloxOne Threat Defense: Boost your SOC efficiency with AI-driven insights to eliminate manual work and accelerate investigation and response times. Read the blog announcement here.

API Examples

Reply

Correct usage / syntax on "allow_update" field

New Member
Posts: 1
2436     0

Hi Infoblox Experts!

 

I'm adding authoritative reverse zones using Powershell, using the below:

$data = '{"fqdn": "'+$Name+'","zone_format": "IPV4","view":"Internal","ns_group":"Internal","use_allow_update":true}'

Invoke-RestMethod -Uri $URL -Method Post -Credential $Creds -Body $data -ContentType "application/json"

 

The above works fine, however, when I want to use the "allow_update": field to appoint a named ACL, I can't find the right syntax to do that, always get 400 error.

 

Few examples I've tried but all fail e.g.:

1.

$data = '{"fqdn": "'+$Name+'","zone_format":

"IPV4","view":"Internal","ns_group":"Internal","use_allow_update":true,"allow_update":[{"namedacl":"TEST DDNS Updaters"}/"Allow"]}'

 

2.

$data = '{"fqdn": "'+$Name+'","zone_format": "IPV4","view":"Internal","ns_group":"Internal","use_allow_update":true,"allow_update":[{"namedacl":"TEST DDNS Updaters"}]}'

 

3.

$data = '{"fqdn": "'+$Name+'","zone_format": "IPV4","view":"Internal","ns_group":"Internal","use_allow_update":true,"allow_update":[{"namedacl":"TEST DDNS Updaters/Allow"}]}'

 

4.

$data = '{"fqdn": "'+$Name+'","zone_format": "IPV4","view":"Internal","ns_group":"Internal","use_allow_update":true,"allow_update":"TEST DDNS Updaters"}'

 

Could you give an example of how the "allow_update" should look like, preferably even a PS example please?

 

Thank you!

Re: Correct usage / syntax on "allow_update" field

Superuser
Posts: 17
2436     0

You need to supply a reference to the Named ACL, which means you need to run a GET first. For my example, the object reference for the Named ACL is 

namedacl/b25lLmRlZmluZWRfYWNsJDAuSW50ZXJuYWwgSG9zdHM:Internal%20Hosts

 

 POST /wapi/v2.10/zone_auth
 Content-Type: application/json

    {
      "fqdn":"test.org",
      "allow_update":[
          {
             "_ref":"namedacl/b25lLmRlZmluZWRfYWNsJDAuSW50ZXJuYWwgSG9zdHM:Internal%20Hosts"
          }
      ]
    }
Showing results for 
Search instead for 
Did you mean: 

Recommended for You