Protect directory (htaccess) don't work properly

speckados

Well-Known Member
Hi

My customer protect directory with cpanel.

Cpanel create usually .htaccess

Code:
AuthType Basic
AuthName "PROFESIONAL"
AuthUserFile "/home2/XXXXXX/.htpasswds/public_html/pdf/pros/passwd"
require valid-user
And /home2/XXXXXX/.htpasswds/public_html/pdf/pros/passwd

PROBLEM:

on browser

domain/pdf/pros/ --->> Protected with user & password
domain/pdf/pros/anyfile.html --> NO PROTECTED (Browser don't ask for user & password)

Also try with

Code:
<FilesMatch "\.(htm|html|pdf)$">
AuthType Basic
AuthName "PROFESIONAL"
AuthUserFile "/home2/XXXXX/.htpasswds/public_html/pdf/pros/passwd"
require valid-user
</FilesMatch>
Dont' work...
 
Last edited: