Step 4. Set a Security Group

Last updated: 2020-05-18 10:39:04

Security group is an instance-level firewall service provided by Tencent Cloud to control inbound and outbound traffic of CVM instances. You can configure a security group to allow only traffic from WAF to access your website, preventing attackers from bypassing WAF and directly attacking your real server.
The following uses allowing the WAF intermediate IP 111.230.27.90 in the security group as an example to describe how to configure the security group.

Note:

You can get the intermediate IP on the Protection Settings page in the WAF Console.

  1. Log in to the CVM Console and click Security Group on the left sidebar.
  2. On the security group page, click Create, enter the information as required, select Custom as the template, enter the security group name (such as my-security-group) and remarks, and click OK.
    1
  3. In the security group list, find the newly created security group and click its ID to enter its details page.
  4. On the inbound rule page, click Add Rule.
    2
  5. In the pop-up window, enter relevant information, select "HTTP (80)" as the type, enter the intermediate IP that needs to be allowed for the source, and enter the port and policy as required. After completing the settings, click OK.
    3
  6. Click the Associate Instance tab and click Add Association on the CVM page.
    4
  7. In the pop-up window, select the CVM instance to be bound to and click OK.

    Alternatively, you can enter the CVM instance list page to view or modify the security group bound to a CVM instance. On the list page, select the ID of the CVM instance whose security group you want to adjust and click More > Security Group > Configure Security Group in the "Operation" column on the right for configuration.