/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include #include namespace Aws { namespace Route53Resolver { namespace Model { /** */ class UpdateFirewallRuleRequest : public Route53ResolverRequest { public: AWS_ROUTE53RESOLVER_API UpdateFirewallRuleRequest(); // Service request name is the Operation name which will send this request out, // each operation should has unique request name, so that we can get operation's name from this request. // Note: this is not true for response, multiple operations may have the same response name, // so we can not get operation's name from response. inline virtual const char* GetServiceRequestName() const override { return "UpdateFirewallRule"; } AWS_ROUTE53RESOLVER_API Aws::String SerializePayload() const override; AWS_ROUTE53RESOLVER_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override; /** *

The unique identifier of the firewall rule group for the rule.

*/ inline const Aws::String& GetFirewallRuleGroupId() const{ return m_firewallRuleGroupId; } /** *

The unique identifier of the firewall rule group for the rule.

*/ inline bool FirewallRuleGroupIdHasBeenSet() const { return m_firewallRuleGroupIdHasBeenSet; } /** *

The unique identifier of the firewall rule group for the rule.

*/ inline void SetFirewallRuleGroupId(const Aws::String& value) { m_firewallRuleGroupIdHasBeenSet = true; m_firewallRuleGroupId = value; } /** *

The unique identifier of the firewall rule group for the rule.

*/ inline void SetFirewallRuleGroupId(Aws::String&& value) { m_firewallRuleGroupIdHasBeenSet = true; m_firewallRuleGroupId = std::move(value); } /** *

The unique identifier of the firewall rule group for the rule.

*/ inline void SetFirewallRuleGroupId(const char* value) { m_firewallRuleGroupIdHasBeenSet = true; m_firewallRuleGroupId.assign(value); } /** *

The unique identifier of the firewall rule group for the rule.

*/ inline UpdateFirewallRuleRequest& WithFirewallRuleGroupId(const Aws::String& value) { SetFirewallRuleGroupId(value); return *this;} /** *

The unique identifier of the firewall rule group for the rule.

*/ inline UpdateFirewallRuleRequest& WithFirewallRuleGroupId(Aws::String&& value) { SetFirewallRuleGroupId(std::move(value)); return *this;} /** *

The unique identifier of the firewall rule group for the rule.

*/ inline UpdateFirewallRuleRequest& WithFirewallRuleGroupId(const char* value) { SetFirewallRuleGroupId(value); return *this;} /** *

The ID of the domain list to use in the rule.

*/ inline const Aws::String& GetFirewallDomainListId() const{ return m_firewallDomainListId; } /** *

The ID of the domain list to use in the rule.

*/ inline bool FirewallDomainListIdHasBeenSet() const { return m_firewallDomainListIdHasBeenSet; } /** *

The ID of the domain list to use in the rule.

*/ inline void SetFirewallDomainListId(const Aws::String& value) { m_firewallDomainListIdHasBeenSet = true; m_firewallDomainListId = value; } /** *

The ID of the domain list to use in the rule.

*/ inline void SetFirewallDomainListId(Aws::String&& value) { m_firewallDomainListIdHasBeenSet = true; m_firewallDomainListId = std::move(value); } /** *

The ID of the domain list to use in the rule.

*/ inline void SetFirewallDomainListId(const char* value) { m_firewallDomainListIdHasBeenSet = true; m_firewallDomainListId.assign(value); } /** *

The ID of the domain list to use in the rule.

*/ inline UpdateFirewallRuleRequest& WithFirewallDomainListId(const Aws::String& value) { SetFirewallDomainListId(value); return *this;} /** *

The ID of the domain list to use in the rule.

*/ inline UpdateFirewallRuleRequest& WithFirewallDomainListId(Aws::String&& value) { SetFirewallDomainListId(std::move(value)); return *this;} /** *

The ID of the domain list to use in the rule.

*/ inline UpdateFirewallRuleRequest& WithFirewallDomainListId(const char* value) { SetFirewallDomainListId(value); return *this;} /** *

The setting that determines the processing order of the rule in the rule * group. DNS Firewall processes the rules in a rule group by order of priority, * starting from the lowest setting.

You must specify a unique priority for * each rule in a rule group. To make it easier to insert rules later, leave space * between the numbers, for example, use 100, 200, and so on. You can change the * priority setting for the rules in a rule group at any time.

*/ inline int GetPriority() const{ return m_priority; } /** *

The setting that determines the processing order of the rule in the rule * group. DNS Firewall processes the rules in a rule group by order of priority, * starting from the lowest setting.

You must specify a unique priority for * each rule in a rule group. To make it easier to insert rules later, leave space * between the numbers, for example, use 100, 200, and so on. You can change the * priority setting for the rules in a rule group at any time.

*/ inline bool PriorityHasBeenSet() const { return m_priorityHasBeenSet; } /** *

The setting that determines the processing order of the rule in the rule * group. DNS Firewall processes the rules in a rule group by order of priority, * starting from the lowest setting.

You must specify a unique priority for * each rule in a rule group. To make it easier to insert rules later, leave space * between the numbers, for example, use 100, 200, and so on. You can change the * priority setting for the rules in a rule group at any time.

*/ inline void SetPriority(int value) { m_priorityHasBeenSet = true; m_priority = value; } /** *

The setting that determines the processing order of the rule in the rule * group. DNS Firewall processes the rules in a rule group by order of priority, * starting from the lowest setting.

You must specify a unique priority for * each rule in a rule group. To make it easier to insert rules later, leave space * between the numbers, for example, use 100, 200, and so on. You can change the * priority setting for the rules in a rule group at any time.

*/ inline UpdateFirewallRuleRequest& WithPriority(int value) { SetPriority(value); return *this;} /** *

The action that DNS Firewall should take on a DNS query when it matches one * of the domains in the rule's domain list:

  • ALLOW - * Permit the request to go through.

  • ALERT - Permit * the request to go through but send an alert to the logs.

  • * BLOCK - Disallow the request. This option requires additional * details in the rule's BlockResponse.

*/ inline const Action& GetAction() const{ return m_action; } /** *

The action that DNS Firewall should take on a DNS query when it matches one * of the domains in the rule's domain list:

  • ALLOW - * Permit the request to go through.

  • ALERT - Permit * the request to go through but send an alert to the logs.

  • * BLOCK - Disallow the request. This option requires additional * details in the rule's BlockResponse.

*/ inline bool ActionHasBeenSet() const { return m_actionHasBeenSet; } /** *

The action that DNS Firewall should take on a DNS query when it matches one * of the domains in the rule's domain list:

  • ALLOW - * Permit the request to go through.

  • ALERT - Permit * the request to go through but send an alert to the logs.

  • * BLOCK - Disallow the request. This option requires additional * details in the rule's BlockResponse.

*/ inline void SetAction(const Action& value) { m_actionHasBeenSet = true; m_action = value; } /** *

The action that DNS Firewall should take on a DNS query when it matches one * of the domains in the rule's domain list:

  • ALLOW - * Permit the request to go through.

  • ALERT - Permit * the request to go through but send an alert to the logs.

  • * BLOCK - Disallow the request. This option requires additional * details in the rule's BlockResponse.

*/ inline void SetAction(Action&& value) { m_actionHasBeenSet = true; m_action = std::move(value); } /** *

The action that DNS Firewall should take on a DNS query when it matches one * of the domains in the rule's domain list:

  • ALLOW - * Permit the request to go through.

  • ALERT - Permit * the request to go through but send an alert to the logs.

  • * BLOCK - Disallow the request. This option requires additional * details in the rule's BlockResponse.

*/ inline UpdateFirewallRuleRequest& WithAction(const Action& value) { SetAction(value); return *this;} /** *

The action that DNS Firewall should take on a DNS query when it matches one * of the domains in the rule's domain list:

  • ALLOW - * Permit the request to go through.

  • ALERT - Permit * the request to go through but send an alert to the logs.

  • * BLOCK - Disallow the request. This option requires additional * details in the rule's BlockResponse.

*/ inline UpdateFirewallRuleRequest& WithAction(Action&& value) { SetAction(std::move(value)); return *this;} /** *

The way that you want DNS Firewall to block the request. Used for the rule * action setting BLOCK.

  • NODATA - * Respond indicating that the query was successful, but no response is available * for it.

  • NXDOMAIN - Respond indicating that the * domain name that's in the query doesn't exist.

  • * OVERRIDE - Provide a custom override in the response. This option * requires custom handling details in the rule's BlockOverride* * settings.

*/ inline const BlockResponse& GetBlockResponse() const{ return m_blockResponse; } /** *

The way that you want DNS Firewall to block the request. Used for the rule * action setting BLOCK.

  • NODATA - * Respond indicating that the query was successful, but no response is available * for it.

  • NXDOMAIN - Respond indicating that the * domain name that's in the query doesn't exist.

  • * OVERRIDE - Provide a custom override in the response. This option * requires custom handling details in the rule's BlockOverride* * settings.

*/ inline bool BlockResponseHasBeenSet() const { return m_blockResponseHasBeenSet; } /** *

The way that you want DNS Firewall to block the request. Used for the rule * action setting BLOCK.

  • NODATA - * Respond indicating that the query was successful, but no response is available * for it.

  • NXDOMAIN - Respond indicating that the * domain name that's in the query doesn't exist.

  • * OVERRIDE - Provide a custom override in the response. This option * requires custom handling details in the rule's BlockOverride* * settings.

*/ inline void SetBlockResponse(const BlockResponse& value) { m_blockResponseHasBeenSet = true; m_blockResponse = value; } /** *

The way that you want DNS Firewall to block the request. Used for the rule * action setting BLOCK.

  • NODATA - * Respond indicating that the query was successful, but no response is available * for it.

  • NXDOMAIN - Respond indicating that the * domain name that's in the query doesn't exist.

  • * OVERRIDE - Provide a custom override in the response. This option * requires custom handling details in the rule's BlockOverride* * settings.

*/ inline void SetBlockResponse(BlockResponse&& value) { m_blockResponseHasBeenSet = true; m_blockResponse = std::move(value); } /** *

The way that you want DNS Firewall to block the request. Used for the rule * action setting BLOCK.

  • NODATA - * Respond indicating that the query was successful, but no response is available * for it.

  • NXDOMAIN - Respond indicating that the * domain name that's in the query doesn't exist.

  • * OVERRIDE - Provide a custom override in the response. This option * requires custom handling details in the rule's BlockOverride* * settings.

*/ inline UpdateFirewallRuleRequest& WithBlockResponse(const BlockResponse& value) { SetBlockResponse(value); return *this;} /** *

The way that you want DNS Firewall to block the request. Used for the rule * action setting BLOCK.

  • NODATA - * Respond indicating that the query was successful, but no response is available * for it.

  • NXDOMAIN - Respond indicating that the * domain name that's in the query doesn't exist.

  • * OVERRIDE - Provide a custom override in the response. This option * requires custom handling details in the rule's BlockOverride* * settings.

*/ inline UpdateFirewallRuleRequest& WithBlockResponse(BlockResponse&& value) { SetBlockResponse(std::move(value)); return *this;} /** *

The custom DNS record to send back in response to the query. Used for the * rule action BLOCK with a BlockResponse setting of * OVERRIDE.

*/ inline const Aws::String& GetBlockOverrideDomain() const{ return m_blockOverrideDomain; } /** *

The custom DNS record to send back in response to the query. Used for the * rule action BLOCK with a BlockResponse setting of * OVERRIDE.

*/ inline bool BlockOverrideDomainHasBeenSet() const { return m_blockOverrideDomainHasBeenSet; } /** *

The custom DNS record to send back in response to the query. Used for the * rule action BLOCK with a BlockResponse setting of * OVERRIDE.

*/ inline void SetBlockOverrideDomain(const Aws::String& value) { m_blockOverrideDomainHasBeenSet = true; m_blockOverrideDomain = value; } /** *

The custom DNS record to send back in response to the query. Used for the * rule action BLOCK with a BlockResponse setting of * OVERRIDE.

*/ inline void SetBlockOverrideDomain(Aws::String&& value) { m_blockOverrideDomainHasBeenSet = true; m_blockOverrideDomain = std::move(value); } /** *

The custom DNS record to send back in response to the query. Used for the * rule action BLOCK with a BlockResponse setting of * OVERRIDE.

*/ inline void SetBlockOverrideDomain(const char* value) { m_blockOverrideDomainHasBeenSet = true; m_blockOverrideDomain.assign(value); } /** *

The custom DNS record to send back in response to the query. Used for the * rule action BLOCK with a BlockResponse setting of * OVERRIDE.

*/ inline UpdateFirewallRuleRequest& WithBlockOverrideDomain(const Aws::String& value) { SetBlockOverrideDomain(value); return *this;} /** *

The custom DNS record to send back in response to the query. Used for the * rule action BLOCK with a BlockResponse setting of * OVERRIDE.

*/ inline UpdateFirewallRuleRequest& WithBlockOverrideDomain(Aws::String&& value) { SetBlockOverrideDomain(std::move(value)); return *this;} /** *

The custom DNS record to send back in response to the query. Used for the * rule action BLOCK with a BlockResponse setting of * OVERRIDE.

*/ inline UpdateFirewallRuleRequest& WithBlockOverrideDomain(const char* value) { SetBlockOverrideDomain(value); return *this;} /** *

The DNS record's type. This determines the format of the record value that * you provided in BlockOverrideDomain. Used for the rule action * BLOCK with a BlockResponse setting of * OVERRIDE.

*/ inline const BlockOverrideDnsType& GetBlockOverrideDnsType() const{ return m_blockOverrideDnsType; } /** *

The DNS record's type. This determines the format of the record value that * you provided in BlockOverrideDomain. Used for the rule action * BLOCK with a BlockResponse setting of * OVERRIDE.

*/ inline bool BlockOverrideDnsTypeHasBeenSet() const { return m_blockOverrideDnsTypeHasBeenSet; } /** *

The DNS record's type. This determines the format of the record value that * you provided in BlockOverrideDomain. Used for the rule action * BLOCK with a BlockResponse setting of * OVERRIDE.

*/ inline void SetBlockOverrideDnsType(const BlockOverrideDnsType& value) { m_blockOverrideDnsTypeHasBeenSet = true; m_blockOverrideDnsType = value; } /** *

The DNS record's type. This determines the format of the record value that * you provided in BlockOverrideDomain. Used for the rule action * BLOCK with a BlockResponse setting of * OVERRIDE.

*/ inline void SetBlockOverrideDnsType(BlockOverrideDnsType&& value) { m_blockOverrideDnsTypeHasBeenSet = true; m_blockOverrideDnsType = std::move(value); } /** *

The DNS record's type. This determines the format of the record value that * you provided in BlockOverrideDomain. Used for the rule action * BLOCK with a BlockResponse setting of * OVERRIDE.

*/ inline UpdateFirewallRuleRequest& WithBlockOverrideDnsType(const BlockOverrideDnsType& value) { SetBlockOverrideDnsType(value); return *this;} /** *

The DNS record's type. This determines the format of the record value that * you provided in BlockOverrideDomain. Used for the rule action * BLOCK with a BlockResponse setting of * OVERRIDE.

*/ inline UpdateFirewallRuleRequest& WithBlockOverrideDnsType(BlockOverrideDnsType&& value) { SetBlockOverrideDnsType(std::move(value)); return *this;} /** *

The recommended amount of time, in seconds, for the DNS resolver or web * browser to cache the provided override record. Used for the rule action * BLOCK with a BlockResponse setting of * OVERRIDE.

*/ inline int GetBlockOverrideTtl() const{ return m_blockOverrideTtl; } /** *

The recommended amount of time, in seconds, for the DNS resolver or web * browser to cache the provided override record. Used for the rule action * BLOCK with a BlockResponse setting of * OVERRIDE.

*/ inline bool BlockOverrideTtlHasBeenSet() const { return m_blockOverrideTtlHasBeenSet; } /** *

The recommended amount of time, in seconds, for the DNS resolver or web * browser to cache the provided override record. Used for the rule action * BLOCK with a BlockResponse setting of * OVERRIDE.

*/ inline void SetBlockOverrideTtl(int value) { m_blockOverrideTtlHasBeenSet = true; m_blockOverrideTtl = value; } /** *

The recommended amount of time, in seconds, for the DNS resolver or web * browser to cache the provided override record. Used for the rule action * BLOCK with a BlockResponse setting of * OVERRIDE.

*/ inline UpdateFirewallRuleRequest& WithBlockOverrideTtl(int value) { SetBlockOverrideTtl(value); return *this;} /** *

The name of the rule.

*/ inline const Aws::String& GetName() const{ return m_name; } /** *

The name of the rule.

*/ inline bool NameHasBeenSet() const { return m_nameHasBeenSet; } /** *

The name of the rule.

*/ inline void SetName(const Aws::String& value) { m_nameHasBeenSet = true; m_name = value; } /** *

The name of the rule.

*/ inline void SetName(Aws::String&& value) { m_nameHasBeenSet = true; m_name = std::move(value); } /** *

The name of the rule.

*/ inline void SetName(const char* value) { m_nameHasBeenSet = true; m_name.assign(value); } /** *

The name of the rule.

*/ inline UpdateFirewallRuleRequest& WithName(const Aws::String& value) { SetName(value); return *this;} /** *

The name of the rule.

*/ inline UpdateFirewallRuleRequest& WithName(Aws::String&& value) { SetName(std::move(value)); return *this;} /** *

The name of the rule.

*/ inline UpdateFirewallRuleRequest& WithName(const char* value) { SetName(value); return *this;} private: Aws::String m_firewallRuleGroupId; bool m_firewallRuleGroupIdHasBeenSet = false; Aws::String m_firewallDomainListId; bool m_firewallDomainListIdHasBeenSet = false; int m_priority; bool m_priorityHasBeenSet = false; Action m_action; bool m_actionHasBeenSet = false; BlockResponse m_blockResponse; bool m_blockResponseHasBeenSet = false; Aws::String m_blockOverrideDomain; bool m_blockOverrideDomainHasBeenSet = false; BlockOverrideDnsType m_blockOverrideDnsType; bool m_blockOverrideDnsTypeHasBeenSet = false; int m_blockOverrideTtl; bool m_blockOverrideTtlHasBeenSet = false; Aws::String m_name; bool m_nameHasBeenSet = false; }; } // namespace Model } // namespace Route53Resolver } // namespace Aws