Skip to navigation
DNS Firewall ProfileCreate a DNS firewall profile

Create a DNS firewall profile

Required permissions Learn more

DnsFirewallProfile + Create

Roles: Administrator

Creates a new DNS firewall profile.

The provided profile content is validated before creation. Rules use a line-oriented text format: <ACTION> <NAME> [# COMMENT]. Supported actions are ALLOW and DENY. Wildcards are supported only as a leading *.. Internationalised (non-ASCII) names are accepted and normalized to Punycode before validation. Rule order does not matter: when multiple rules match a domain, the most specific matching rule takes precedence (an exact name beats a wildcard, and a more specific wildcard beats a broader one).

If no rule matches, the effective default behavior is controlled by the service profile’s DNS firewall mode: allowlist denies unmatched queries, blocklist allows them.

Use the dry_run query parameter to validate the profile without persisting it.

Authentication

AuthorizationBearer

An auth_token should be provided to authenticate a session.

To obtain an auth_token, see the /api/v1/authenticate POST request.

Query parameters

dry_runbooleanOptionalDefaults to false

When set to true, validates the profile rules without creating the profile. Returns validation results only.

Request

This endpoint expects an object.
namestringRequired
Name of the DNS firewall profile.
profilestringRequired

DNS firewall rules in line-oriented text format, one rule per line. Each rule follows the syntax: <ACTION> <NAME> [# COMMENT].

profile_file_namestringRequired

Original file name of the uploaded profile. Must end with .txt.

descriptionstringOptional
Description of the DNS firewall profile.

Response

Dry-run validation only (dry_run=true and validation succeeded)

validation_issuesobjectOptional

Errors

400
Bad Request Error
401
Unauthorized Error
403
Forbidden Error
409
Conflict Error
422
Unprocessable Entity Error