Practice - 5 Tasks
Answer the questions below
1fill in blank
easyComplete the code to allow access from the IP 192.168.1.10.
Nginx
allow [1]; Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'deny all' instead of an IP address.
Using 'all' which allows everyone.
Using 'localhost' which is not the target IP.
✗ Incorrect
The allow directive followed by the IP address permits access from that IP.
2fill in blank
mediumComplete the code to deny access from the IP 10.0.0.5.
Nginx
deny [1]; Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'all' which blocks everyone.
Using a wrong IP address.
Using 'localhost' which is not the target IP.
✗ Incorrect
The deny directive followed by the IP blocks access from that IP.
3fill in blank
hardFix the error in the code to allow only the IP 172.16.0.2 and deny all others.
Nginx
allow [1];
deny all; Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'allow all;' which allows everyone.
Using an incorrect IP address.
Omitting the 'deny all;' line.
✗ Incorrect
To allow only one IP, use allow with that IP and then deny all; to block others.
4fill in blank
hardFill both blanks to allow 192.168.0.0/24 subnet and deny all others.
Nginx
allow [1]; deny [2];
Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'deny 0.0.0.0/0;' which is invalid in this context.
Using 'allow all;' which allows everyone.
Using 'deny localhost;' which does not block all others.
✗ Incorrect
Use allow 192.168.0.0/24; to allow the subnet and deny all; to block others.
5fill in blank
hardFill all three blanks to allow 10.1.1.0/24 subnet, deny 10.1.1.100, and deny all others.
Nginx
deny [1]; allow [2]; deny [3];
Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Reversing the order of allow and deny directives.
Using 'deny localhost;' which does not block all others.
Omitting the final 'deny all;' line.
✗ Incorrect
First deny the specific IP, then allow the subnet, and finally deny all others.