Announcement

Collapse
No announcement yet.

Ban everyone from china IP

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

  • #16
    I found this example but has anyone tried the allow to a few and deny to all?

    http://home.golden.net/htaccess.html

    Restricting by IP Address

    This only requires the .htaccess file. There are two approaches to restricting by IP address:
    a) deny everyone access, then allow certain hosts/IP addresses
    AuthName "Lee's Secret Area"
    AuthType Basic
    <Limit GET POST>
    order deny,allow
    deny from all
    allow from 199.166.210.
    allow from .golden.net
    allow from proxy.aol.com
    allow from fish.wiretap.net
    </Limit>

    b) allow everyone except for certain hosts/IP addresses
    AuthName "Lee's Secret Area"
    AuthType Basic
    <Limit GET POST>
    order allow,deny
    allow from all
    deny from .microsoft.com
    deny from .evil-hackers.org
    deny from 24.112.106.235
    deny from morphine.wiretap.net
    </Limit>

    Comment

    widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
    Working...
    X