Connecting a Non-website Service to AAD
Scenarios
Non-website services include Apps and PC client services. For such services, you can configure CNAME records in DNS or directly configure high-defense IP addresses on clients to use AAD.
Prerequisites
- You have obtained an account and its password to log in to the management console.
- You have purchased an AAD instance.
Procedure
Figure 1 shows the procedure for accessing non-website services.
- Log in to the management console.
- (Optional) Configure domain name access. Perform this step if intelligent resolution lines will be provided for domain names.
- Log in to the management console.
- Follow the procedure in the following figure to enter the Domain Name Access page. Figure 2 Domain Name Access page
- On the displayed page, click Add Domain Name.
- Complete the necessary domain name information and click Next. Figure 3 Entering domain name information for a non-website service
If you log in to the management console using an enterprise project account, you can choose Enterprise > Project Management in the upper right corner. On the displayed page, choose Project Management in the navigation pane on the left, and select the target project.
Table 1 Parameter description Parameter
Description
Protected Domain Name
Enter the domain name of the service to protect.
- Single domain name: Enter a single domain name, for example, www.example.com.
- Wildcard domain
- If the server IP address of each subdomain name is the same, enter a wildcard domain name to be protected. For example, if the subdomain names a.example.com, b.example.com, and c.example.com have the same server IP address, you can add the wildcard domain name *.example.com to AAD to protect all three.
- If the server IP addresses of subdomain names are different, add subdomain names one by one.
Service Type
Select Non-website.
- Select required AAD instances and lines and click Submit and Continue.
You can select multiple lines (with high-defense IP addresses) for a domain name. However, the IP addresses must have the same number of forwarding rules, the same forwarding protocols, ports, and the same service type.
HUAWEI CLOUD provides multiple carrier lines for each instance to avoid cross-carrier access from your users. You are advised to select a complete set of lines, which includes all carriers, when selecting lines for your instance.
Figure 4 Selecting an instance and a line
- Copy the displayed CNAME record of the domain name and click Next. Figure 5 Modifying DNS
- Whitelist the back-to-origin IP addresses.
- If no firewall has been configured for the origin server, click Finish.
- If a firewall has been configured for the origin server, add the back-to-origin IP address range to the whitelist of the firewall. Then click Finish.
The Domain Name Access page is displayed. The newly added domain name is displayed in the list.
- (Optional) Enable CNAME-based auto scheduling if you need to access the service using a domain name. CNAME-based auto schedule distributes incoming traffic based on its originating carrier. It can divert traffic to other lines if a line is blocked by a black hole. Figure 6 Enabling CNAME-based automatic scheduling
- Add a forwarding rule.
For details, see Configuring a Forwarding Rule.
- Whitelist the back-to-origin IP addresses.
- Reason for whitelisting the IP addresses: AAD executes Full Network Address Translation (Full-NAT) and diverts access traffic to the back-to-origin IP addresses.
- If AAD is not used, access traffic is sent directly from the source IP addresses of clients towards origin servers. From the view of origin servers, the requests originate from scattered clients and each source IP address sends only a few access requests.
- After AAD is enabled, access traffic will be forwarded to the back-to-origin IP addresses. From the view of origin servers, the requests originate from these back-to-origin IP addresses. These IP addresses are fixed and limited in quantity, and each carries more requests than the source IP address. Therefore, they may be mistakenly regarded as the sources that launch attacks. In this case, other anti-DDoS security policies working on the origin servers may block or limit the requests from the back-to-origin IP addresses. For example, error 502 is reported if the access request is blocked by mistake.
- Procedure:
- View the back-to-origin IP address range. For details, see Viewing a Back-to-Origin IP Address Range.
- Whitelist the back-to-origin IP address range on the firewall, ACL, or any other security software on your origin servers to prevent the access traffic from being blocked or limited by the security policies.
- Reason for whitelisting the IP addresses:
- Verify the configuration.
After the configuration takes effect, AAD is expected to forward the packets sent to the high-defense IP address or AAD CNAME to the origin servers. To ensure service stability, you can use the following steps to verify the configuration:
- Assumed parameter values:
- Lines: CTCC, CUCC, and CMCC
- CTCC IP address: 1.1.1.1
- CUCC IP address: 2.2.2.2
- CMCC IP address: 3.3.3.3
- CNAME: 5dc728e1769ad666.huaweisafedns.com
- Forwarding port: 1234
- Protected domain name: www.test.com
- Origin server IP address: 4.4.4.4
- Origin server port: 1234
- Lines: CTCC, CUCC, and CMCC
- Procedure:
- Use Telnet www.huaweicloud.com 80 to verify the network connectivity.
- If the connection setup is successful, you can Telnet to the public IP address from your local network environment.
- If the connection setup fails, change your test network environment and try again. Some enterprises may have internal network constraints and fail the verification. For example, you can connect to the personal hotspot of your phone to verify the connectivity.
- After verifying the network connectivity, you can Telnet to the high-defense IP address of each carrier line and the AAD CNAME over port 1234.
- If the Telnet command is executed successfully, the configuration has taken effect.
- If the command execution fails, check whether the required steps have been completed.
- If the fault persists, contact HUAWEI CLOUD technical support.
- Use Telnet www.huaweicloud.com 80 to verify the network connectivity.
- Assumed parameter values:
- (Optional) Modify DNS.
Perform this step if you need to access the service using a domain name.
- If you have configured domain name access and obtained the CNAME, perform Adding a CNAME Record.
- If you added a forwarding rule without configuring domain name access, perform Adding an A Record.
The DNS configuration takes effect after a period of time. In this period, you can test the domain name resolution using some online test tools such as 17ce and China Webmaster.
Follow-up Procedure
- If you do not want a domain name to be resolved to a high-defense IP address, locate the row containing the domain name on the Domain Name Access page and click View details in the Instance and Line column. On the page that is displayed, click
for the target high-defense IP address to set DNS Resolution to
. - If you do not want to protect a domain name, locate the row containing the domain name on the Domain Name Access page and click Delete in the Operation column.
Last Article: Connecting a Website Service to AAD
Next Article: Configuring a Forwarding Rule

Did this article solve your problem?
Thank you for your score!Your feedback would help us improve the website.