ip filtering

NGINX – Restrict access to Geographical Locations using GeoIP module

Reading Time: 2 minutes In this post I’ll try to explain how NGINX GeoIP module can be used to restrict access to your web-portal/website only to a specific geographical region. Begin by verifying NGINX GeoIP module is installed on the server which can be done via nginx -V if you can see –with-http_geoip_module in the output you are ready to use the GeoIP database with NGINX but if not you Continue Reading

NGINX – Disable direct access (via http and https) to a website using IP address

Reading Time: < 1 minute For the requirements wherein direct access to a website using IP address has to be disabled/blocked, following steps can be followed To disable/block direct access to IP for port 80 create a new or add to an existing (as required) server configurations as follows server { listen 80 default_server; server_name _; return 404; } where _ catches all the domain names pointing to your server’s Continue Reading