1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Protecting admin.php and the install directory using .htaccess

Stop those annoying skiddies.

Tags:
  1. Brogan

    Brogan XenForo Moderator Staff Member

    Brogan submitted a new resource:

    Protecting admin.php and the install directory using .htaccess (version 1.0) - Stop those annoying skiddies.

    Read more about this resource...
     
  2. Cool

    Cool Active Member

    just for all wich donĀ“t know exatctly how to ip-protect:
    Code:
    <Files admin.php>
    Order Deny,Allow
    Deny from all
    Allow from 127.0.0.1
    Allow from ???.???.???.??? # set your ip here
    </Files>
    
     
    turbos likes this.
  3. Ryan Kent

    Ryan Kent Well-Known Member

    I have a dynamic IP but it normally varies only slightly. Is there a wildcard char that can be used? Would something like 159.254.???.??? work? I know it is not 100% secure but it should be solid enough for my purposes.
     
  4. Brogan

    Brogan XenForo Moderator Staff Member

    You can just add the first 2 blocks like so: Allow from 127.0
     
    Oracle likes this.
  5. Ryan Kent

    Ryan Kent Well-Known Member

    appreciate the reply and you taking the time to make this thread
     
  6. WoodiE

    WoodiE Well-Known Member

    Good advice, I've been using htaccess to control my wordpress, vbulletin, and XF access based on IP, works great!
     
  7. Martyn

    Martyn Active Member

    Not bad but i recommend using this one! ( works good )
    Code:
    <Files admin.php>
    RewriteEngine On
    RewriteBase /
    RewriteCond %{REMOTE_HOST} !^120\.0\.0\.1
    RewriteCond %{REMOTE_HOST} !^123\.45\.56\.789
    RewriteCond %{REQUEST_URI} !/index\.php$
    RewriteRule .* /index.php [R=302,L]
    </Files>
    that way rather then giving the person and error, it just redirects them back to the home page.... :)

    please "Like" if you use! :)
     
  8. Floris

    Floris Guest

  9. xTOPSECRETx

    xTOPSECRETx Member

    what if you dont have cpanel? i used shared hosting with godaddy
     
  10. Brogan

    Brogan XenForo Moderator Staff Member

    In that case speak to your host.

    I don't know what services and features are available with godaddy.
     
  11. a legacy reborn

    a legacy reborn Well-Known Member

    Nice tut Brogan, I am sure alot of people will find it useful :). (I however still believe your a bot)
     
    Fuhrmann likes this.
  12. Digital Doctor

    Digital Doctor Well-Known Member

  13. a legacy reborn

    a legacy reborn Well-Known Member

  14. Digital Doctor

    Digital Doctor Well-Known Member

  15. xTOPSECRETx

    xTOPSECRETx Member

    hey guys, it doesnt work for me, i tried all of them...

    Not Found

    The requested URL /cpanel was not found on this server.
    Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
     
  16. a legacy reborn

    a legacy reborn Well-Known Member

    try :2082 it is the most common.
     
  17. Digital Doctor

    Digital Doctor Well-Known Member

    Hmmm ...
    I tried my other godaddy account and it didnt work either.
    It looks like cpanel is an OPTION in godaddy.
    The shared hosting account doesnt seem to have cpanel, whereas the virtual dedicated account does have cpanel.
    Godaddy has their own cpanel ... just log into godaddy.com to access it.
    IMO, cpanel is better than what godaddy provides.
     
  18. a legacy reborn

    a legacy reborn Well-Known Member

    Agreed...but I think anything is better than godaddy in general...
     
  19. xTOPSECRETx

    xTOPSECRETx Member

    yeah its not working, i used their vps years ago and that had cpanel.... thanks everyone for the support.
     
  20. Disrelation

    Disrelation Active Member

    Is it possible that when they go to the install dictionary for instance, make them see a 404 Not Found error?
     

Share This Page