Skip to content

Instantly share code, notes, and snippets.

@alexsoin
Last active February 28, 2018 06:08
Show Gist options
  • Select an option

  • Save alexsoin/afcbb44a49f22c9ca35b43085d7a901d to your computer and use it in GitHub Desktop.

Select an option

Save alexsoin/afcbb44a49f22c9ca35b43085d7a901d to your computer and use it in GitHub Desktop.
Настройка доступа к файлам каталога через авторизацию
AuthName "Need authorization"
AuthType Basic
AuthUserFile /home/www/name/.htpasswd
require valid-user
#AuthUserFile /home/www/name/.htapsswd
#AuthName "Private access"
#AuthType Basic
#<FilesMatch "name.txt">
#Require valid-user
#</FilesMatch>
login:passwd

Настройка доступа к файлам каталога через авторизацию

#AuthUserFile /home/www/name/.htapsswd - путь к файлу с логином и паролем

Сгенерировать пароль для .htpasswd можно по ссылке: http://webdevtools.ru/passwd

Файл .htpasswd необходимо разместить в корне файлового менеджера.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment