httpd access control

Insert into section of an Apache configuration file or into .htaccess file or in a virtual host configuration section:

# AuthType Basic
# AuthUserFile /srv/auth/.htpasswd
# AuthName “Sign In Here To Gain Access To the Site”
# Require valid-user

Generating HTTP AUTH Passwords:
# yum install apache2-utils
# htpasswd -mcb /srv/auth/.htpasswd username password
c – create file, m – crypt with md5, b – insert the password in same line, -n – add new user

Access Control Lists with Groups
Insert into section of an Apache configuration file or into .htaccess file or in a virtual host configuration section:
# AuthType Basic
# AuthUserFile /srv/auth/.htpasswd
# AuthGroupFile /srv/auth/.htpgroup
# Require group Authorized

https://www.linode.com/docs/websites/authbased-access-control-with-apache