Create IP sets, Web ACLS

Create IP sets

  1. Search WAF & Shield , select IP sets
  2. Click the Create IP sets button IPSET
  3. In IP set details section:
  • IP set name: enter MYIpSet
  • Description: enter IP set to block my public IP
  • Region: Select Singapore
  • In the IP addresses section, we need to visit https://www.whatismyip.com/ and copy the ipv4 address and add /32 (eg 1.2.3.4/32) IPSET
  1. Click the Create IP set button

Create Web ACLs

  1. Click the Create web ACL button
  2. In the Web ACL details section:
  • Resource type : Select Regional resources
  • Region: Select Singapore
  • Name : MyWebACL
  • Description: You can not fill it out WACL
  1. In the Associated AWS resources section:
  • Select the Add AWS resources button
  • In the Resource type section, select Application Load Balancer and select ALB1 below -> Click Add WACL
  • Then click Next
  1. In the Rules section, select Add rules and select Add my own rules and rule groups

  2. Select Rule type as IP set , name Rule

  3. In the Ip set section, select the MyIpSet just created earlier WACL

  4. Leave all the rest as default and create Web ACL then

  5. Wait a few minutes and F5 the browser again with the url as DNS of the Load Balancer we opened earlier, you can see we have blocked our own IP and it worked, you can install a few extensions to change IP and test again

LB