Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

htaccess does not work for LAN IP (192.168.)

Discussion in 'General Discussion' started by laluvirtual, Oct 18, 2006.

  1. laluvirtual

    laluvirtual Member

    Joined:
    Aug 31, 2006
    Messages:
    24
    Likes Received:
    0
    Trophy Points:
    151
    I want to allow local ip address (192.168.10.*) only and deny all local ip (192.168.*.*) and deny all public ip by this htaccess but why it doesn't work?

    Code:
    order deny,allow
    deny from all
    allow from 192.168.10.
    
    that htaccess code block all local and public ip and not allow 192.168.10.* | Why?


    thanks
    Best Regards
     
    #1 laluvirtual, Oct 18, 2006
    Last edited: Oct 18, 2006
  2. webignition

    webignition Well-Known Member

    Joined:
    Jan 22, 2005
    Messages:
    1,880
    Likes Received:
    0
    Trophy Points:
    166
    Yep, this just seems to be the way Apache works.

    Try Googling some related terms and you'll find you're not the only one to encounter such issues. Doing so should also find you one or more possible solutions.

    You could give the following a go:

    Code:
    order allow,deny
    allow from env=is_internal
    deny from all
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. laluvirtual

    laluvirtual Member

    Joined:
    Aug 31, 2006
    Messages:
    24
    Likes Received:
    0
    Trophy Points:
    151
    i've tried it but it doesn't work???
    any other solutions?
     
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice