Anti-Bot Service (Anti-Bot) can be deployed with CDN (such as Wangsu, Jiasule, Qiniu, Youpai, and Alibaba Cloud CDN) to protect CDN-enabled content against malicious bot traffic. You can deploy both Anti-Bot and CDN for your origin server in this schema: CDN (ingress to content acceleration) > Anti-Bot (intermediate layer for application-layer protection) > origin server.

Use Alibaba Cloud CDN

Here, Alibaba Cloud CDN is used as an example. Perform the following steps to deploy both Anti-Bot and CDN for your website:
  1. Configure CDN for the (accelerating) domain name to be protected based on CDN quick start.
  2. Create website configuration in the Anti-Bot console.
    • Domain: Enter the domain name that you want to protect.
    • Server Address: Enter the public IP address of an SLB instance, the public IP address of an ECS instance, or the IP address of a server in an IDC.
    • Layer-7 gateways are in use, such as Alibaba Cloud Anti-DDoS Pro or CDN: Select Yes.
    For more information, see Add domain name configuration.
  3. After the website configuration is created, Anti-Bot generates a dedicated CNAME address for the domain name.
    Note For how to check the CNAME address generated by Anti-Bot, see Check the CNAME address allocated by Anti-Bot.
  4. Perform the following step to change the origin server address in CDN configuration to the CNAME address allocated by Anti-Bot:
    1. Log on to the Alibaba Cloud CDN console.
    2. On the Domain Configuration page, select the target domain name and click Configure.
    3. Click Edit Origin IP under Origin Edit.
    4. Modify the origin server information.
      • Type: Select Origin Site Domain.
      • Origin Site Domain: Enter the CNAME address generated by Anti-Bot.
      • Use the same protocol as the back-to-origin protocol: Enable this option.

    5. Confirm that Back-to-Origin Host is disabled under Back-to-Origin Configuration.

After the preceding configuration, traffic passes through CDN, and dynamic content is detected and protected by Anti-Bot.