BasicAuth

BasicAuthentication with Nginx

NOT YET WORKING … Install NGINX pkg_add -v nginx rcctl enable nginx rcctl restart nginx Enable BasicAuth server { ... auth_basic "Administrator’s Area"; auth_basic_user_file conf/htpasswd; location /public/ { auth_basic off; } } Create File and User htpasswd -c /etc/apache2/.htpasswd user1 Restart Service rcctl restart nginx Source https://docs.nginx.com/nginx/admin-guide/security-controls/configuring-http-basic-authentication/ sha256: a030f2314ac07debef7ffdbc0f71930fd0f1ee51289dd43dd3dc33d26674e3be

BasicAuthentication with httpd

Enable Auth server "default" { listen on * port 80 authenticate "secure area" with "/htpasswd.conf" } create htpasswd file htpasswd /var/www/htpasswd.conf user-x Password: Retype Password: chown www /var/www/htpasswd.conf chmod 600 /var/www/htpasswd.conf Restart Service rcctl restart httpd sha256: 152bd33928dbafc599f85b89c0f832fae8c0ac8a3ee957c8694817c4d566f9c9