import_firewall_domains
async
¶
import_firewall_domains(
firewall_domain_list_id: ResourceId,
operation: FirewallDomainImportOperation,
domain_file_url: DomainListFileUrl,
*,
config_overrides: Optional[AsyncRoute53ResolverClientConfig] = None,
) -> ImportFirewallDomainsResponse
Imports domain names from a file into a domain list, for use in a DNS firewall rule group.
Each domain specification in your domain list must satisfy the following requirements:
-
It can optionally start with
*(asterisk). -
With the exception of the optional starting asterisk, it must only contain the following characters:
A-Z,a-z,0-9,-(hyphen). -
It must be from 1-255 characters in length.
Parameters:
-
firewall_domain_list_id(ResourceId) –The ID of the domain list that you want to modify with the import operation.
-
operation(FirewallDomainImportOperation) –What you want DNS Firewall to do with the domains that are listed in the file. This must be set to
REPLACE, which updates the domain list to exactly match the list in the file. -
domain_file_url(DomainListFileUrl) –The fully qualified URL or URI of the file stored in Amazon Simple Storage Service (Amazon S3) that contains the list of domains to import.
The file must be in an S3 bucket that's in the same Region as your DNS Firewall. The file must be a text file and must contain a single domain per line.
Raises:
-
AccessDeniedException–The current account doesn't have the IAM permissions required to perform the specified Resolver operation.
This error can also be thrown when a customer has reached the 5120 character limit for a resource policy for CloudWatch Logs.
-
ConflictException–The requested state transition isn't valid. For example, you can't delete a firewall domain list if it is in the process of being deleted, or you can't import domains into a domain list that is in the process of being deleted.
-
InternalServiceErrorException–We encountered an unknown error. Try again in a few minutes.
-
LimitExceededException–The request caused one or more limits to be exceeded.
-
ResourceNotFoundException–The specified resource doesn't exist.
-
ThrottlingException–The request was throttled. Try again in a few minutes.
-
ValidationException–You have provided an invalid command. If you ran the
UpdateFirewallDomainsrequest. supported values areADD,REMOVE, orREPLACEa domain. -
UnknownServiceError–The service returned an error code this client does not model.