IP based restriction using Nginx

You can restrict access to certain parts of your website using Nginx’s inbuilt authentication and authorization mechanism based either on your client’s I.P, by prompting for a login prompt or both. A sample I.P. based authorization configuration would be like:

October 12, 2019 · 1 min · 40 words · Akhil Jalagam

apache2/httpd – IP based restriction to a virtual host

The Require provides a variety of different ways to allow or deny access to resources. In conjunction with the RequireAll, RequireAny, and RequireNone directives, these requirements may be combined in arbitrarily complex ways, to enforce whatever your access policy happens to be. example: <VirtualHost *:80> ServerName example.net Documentroot /var/www/html/ <Location /> Require ip </Location>; </VirtualHost>

September 26, 2019 · 1 min · 57 words · Akhil Jalagam