Announcement

Collapse
No announcement yet.

Protect .htaccess from visitors.

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Protect .htaccess from visitors.

    The .htaccess file is containing rule which must be safe and secure from visitors to avoid hack or injections. We can secure .htaccess file by using following rule in .htaccess file to disable .htaccess file access for visitors.

    <Files .htaccess>
    order allow,deny
    deny from all
    </Files>
    Regards,
    George S

  • #2
    Thanks for posting this information George
    Kind regards,
    Jack Daniel.

    Cloud Hosting || Managed Dedicated Server || Webhosting UK Knowledgebase

    Comment


    • #3
      Thanks George

      Although with Apache, this rule is applied in the default httpd.conf file for your convenience.
      Webhosting.UK.com || cPanel VPS Hosting || Reseller Hosting

      Sales: 0808-262-0855
      Support: 0800-612-8725
      International: +44 191 303 8191

      Comment


      • #4
        We are facing an issue with the .htaccess. Same thing happened for ErrorDocument blabla. If .htaccess contains it, error occurs. It is fine if the .htaccess only contains AuthName Member's Area Name, AuthUserFile mypath/.htpasswd, AuthType Basic and whenever i use to put this line require valid-user into my .htaccess, the webpages in the folder .htaccess intends to protect gives Server Error upon access.

        Comment

        Working...
        X