It seems like your browser didn't download the required fonts. Please revise your security settings and try again.
Barracuda Web Application Firewall

Trusted Hosts

  • Last updated on

A trusted host group can be created with a set of trusted hosts, which can be associated with the service to enforce action for the trusted hosts.

For more information on trusted hosts, see How to Configure Trusted Hosts  .

Creating a Trusted Host Group

URL:  /v1/ trusted_host_groups
Method: POST
Description: Creates a trusted host group with the given name.
Parameter NameData TypeMandatoryDescription
Input Parameters:   
nameAlphanumericYesA name for the trusted host group that needs to be created.
Example:

Request:

curl http://192.168.0.1:8000/restapi/v1/trusted_host_groups -u 'eyJldCI6mFkbWluIn0=\n:' -X POST -H Content-Type:application/json -d '{"name":"Group1"}'

Response:

{"id":"Group1","token":"eyJldCWluIn0=\n"}

Deleting a Trusted Host Group

URL:  /v1/ trusted_host_groups/{trusted_host_group_name}
Method: DELETE
Description: Deletes the given service group
Example:

Request:

curl http://192.168.0.1:8000/restapi/v1/trusted_host_groups/Group1 -u 'eyJldkbWluIn0=\n:' -X DELETE

Response:

{"msg":"Successfully deleted","token":"eyJldbWluIn0=\n"}

Adding a Trusted Host Group

URL:  /v1/ trusted_host_groups/{trusted_host_group_name}/trusted_hosts
Method: POST
Description: Creates a trusted host with the given name.
Parameter NameData TypeMandatoryDescription
Input Parameters:   
nameAlphanumericYesName for the trusted host.
address_versionEnumerationYesInternet protocol version for the trusted host.
ip_addressAlphanumericYesIP address of the trusted host.
maskAlphanumericYesAssociated subnet mask.
commentsAlphanumericOptionalDescription about the trusted host.
Example:

Request:

curl http://192.168.0.1:8000/restapi/v1/trusted_host_groups/Group1/trusted_hosts -u 'eyJldCluIn0=\n:' -X POST -H Content-Type:application/json -d '{"name":"Host1", "ip_address":"99.99.124.56", "address_version":"ipv4", "mask":"255.255.255.255", "comments":"raj"}'

Response:

{"id":"Host1","token":"eyJldWluIn0=\n"} 

Updating a Trusted Host

URL:  /v1/ trusted_host_groups/{trusted_host_group_name}/trusted_hosts/(trusted_host_name)
Method: PUT
Description: Updates the values of given parameters.
Parameter NameData TypeMandatoryDescription
Input Parameters:   
ip_addressAlphanumericOptionalIP address of the trusted host.
maskAlphanumericOptionalAssociated subnet mask.
commentsAlphanumericOptionalDescription about the trusted host.
Example:

Request:

curl http://192.168.0.1:8000/restapi/v1/trusted_host_groups/Group1/trusted_hosts/Host1 -u 'eyJldCIn0=\n:' -X PUT -H Content-Type:application/json -d '{"ip_address":"99.99.107.69", "mask":"255.255.0.0"}'

 

Response:

{"id":"Host1","token":"eyJldCWluIn0=\n"}

Deleting a Trusted Host

URL:  /v1/ trusted_host_groups/{trusted_host_group_name}/trusted_hosts/(trusted_host_name)
Method: DELETE
Description: Deletes the given trusted host.
Parameter NameData TypeMandatoryDescription
Input Parameters:   
ip_addressAlphanumericOptionalIP address of the trusted host.
maskAlphanumericOptionalAssociated subnet mask.
commentsAlphanumericOptionalDescription about the trusted host.
Example:

Request:

curl http://192.168.0.1:8000/restapi/v1/trusted_host_groups/group1/trusted_hosts/Host1 -u 'eyJldCI6IjEluIn0=\n:' -X DELETE

 

Response:

{"msg":"Successfully deleted","token":"eyJldCI6IjEIn0=\n"}