apache 아파치 인증
페이지 정보
본문
1. httpd.conf
################################################
<Directory /home/httpd/html/인증디렉토리 >
Options FollowSymlinks
AllowOverride AuthConfig
ErrorDocument 401 "죄송합니다. 관리자만 들어올수 있습니다."
</Directory>
## AccessFileName .htaccess //디폴트 파일명,숨김으로 변경 요망
################################################
2. 인증디렉토리에 파일만듬
################################################
[root@ADNEC public_html]# vi /home/httpd/html/인증디렉토리/.htaccess
AuthName "관리자"
AuthType Basic
AuthUserFile /home/httpd/html/인증디렉토리/.htpasswd
AuthGroupFile /dev/null
<Limit GET POST>
require valid-user
</Limit>
################################################
3. 패스워드입력
################################################
/usr/local/apache/bin/htpasswd -c /home/httpd/html/인증디렉토리/.htpasswd 사용자
################################################
################################################
<Directory /home/httpd/html/인증디렉토리 >
Options FollowSymlinks
AllowOverride AuthConfig
ErrorDocument 401 "죄송합니다. 관리자만 들어올수 있습니다."
</Directory>
## AccessFileName .htaccess //디폴트 파일명,숨김으로 변경 요망
################################################
2. 인증디렉토리에 파일만듬
################################################
[root@ADNEC public_html]# vi /home/httpd/html/인증디렉토리/.htaccess
AuthName "관리자"
AuthType Basic
AuthUserFile /home/httpd/html/인증디렉토리/.htpasswd
AuthGroupFile /dev/null
<Limit GET POST>
require valid-user
</Limit>
################################################
3. 패스워드입력
################################################
/usr/local/apache/bin/htpasswd -c /home/httpd/html/인증디렉토리/.htpasswd 사용자
################################################
- 이전글일정기간이 지난 파일 삭제 (cron 에서) 21.02.10
- 다음글vi 편집기 21.02.10
댓글목록
등록된 댓글이 없습니다.