月光博客 » 网站建设 » 过滤和禁止中国IP地址访问的方法

过滤和禁止中国IP地址访问的方法

  做英文共享软件的作者,为了防止软件被破解,经常需要设置禁用中国地区的IP地址,但很多人不知道怎么进行设置。

  如何在apache主机上设置禁用中国的IP地址访问,其实很简单,修改apache的.htaccess文件,在文件中加入下面的语句,即可阻止大部分中国用户的访问。当然,这份IP过滤表有些旧,某些新的IP会漏网,可以适当进行一些修改。

  当然,英文网站大多不需要中文用户,如果想阻止中国的搜索引擎对其网站进行索引,也可以利用下面的语句。

deny from 61.52
deny from 61.53
deny from 61.54
deny from 61.131
deny from 61.132
deny from 61.133
deny from 61.134
deny from 61.135
deny from 61.136
deny from 61.137
deny from 61.138
deny from 61.139
deny from 61.140
deny from 61.141
deny from 61.142
deny from 61.143
deny from 61.144
deny from 61.145
deny from 61.146
deny from 61.147
deny from 61.148
deny from 61.149
deny from 61.150
deny from 61.151
deny from 61.152
deny from 61.153
deny from 61.154
deny from 61.155
deny from 61.156
deny from 61.157
deny from 61.158
deny from 61.159
deny from 61.160
deny from 61.161
deny from 61.172
deny from 61.173
deny from 61.174
deny from 61.175
deny from 61.176
deny from 202.4.252
deny from 202.4.253
deny from 202.4.254
deny from 202.4.255
deny from 202.97
deny from 202.98
deny from 202.99
deny from 202.100
deny from 202.101
deny from 202.102
deny from 202.103
deny from 202.104
deny from 202.105
deny from 202.106
deny from 202.107
deny from 202.108
deny from 202.109
deny from 202.110
deny from 202.111
deny from 202.112
deny from 202.113
deny from 202.114
deny from 202.115
deny from 202.130.224
deny from 202.130.225
deny from 202.130.226
deny from 202.130.227
deny from 202.130.228
deny from 202.130.229
deny from 202.130.245
deny from 211.81
deny from 211.82
deny from 211.90
deny from 211.91
deny from 211.102
deny from 211.149
deny from 211.150
deny from 211.151
deny from 211.152
deny from 211.153
deny from 211.154
deny from 211.155
deny from 211.156
deny from 211.157
deny from 211.158
deny from 211.159
deny from 211.160
deny from 211.161
deny from 211.162
deny from 211.163
deny from 218.5
deny from 218.21
deny from 218.28
deny from 218.29
deny from 218.71
deny from 218.72
deny from 218.73
deny from 218.74
deny from 218.75
deny from 218.76
deny from 218.77
deny from 218.78
deny from 218.79
deny from 218.80
deny from 218.81
deny from 218.82
deny from 218.83
deny from 218.84
deny from 218.242

过滤和禁止中国IP地址访问的方法

顶一下 ▲()   踩一下 ▼()

相关文章

  1. 1
    浏览器   说道:
    4楼的和6楼的,人不能无耻到这个地步!!!你不能无视中国很多人肆意破解外国软件的做法
    支持(17反对(6回复
  1. 2
    路飞   说道:
    有两点:

    我觉得楼主应该没恶意,仅仅是出于技术方面的交流而已,是有心人想多了。


    告诉那些所谓的“台湾人”,你们的根还是在这里,只不过幸运的是你们的岛上人少所以见过的恶人少些罢了。大陆和台湾是同祖同宗,你们这样说不是在自打耳光么?再者,人民是被执政者玩弄于股掌之间的“玩物”,无论是满清、民国还是别的,不要把所有的罪都加到可怜的弱势者头上。
    支持(14反对(7回复
  1. 23和26的两位 还不知道吧
    我们大陆这边决定2008年强行收复台湾
    时间就在奥运会之前或是之后
    等收了你们的时候 你门是不是也是属于你们口中劣等民族和最最最下贱的种族了畜牲等等?
    支持(13反对(8回复
  1. 4
    eko   说道:
    好像crack组织还是国外做的大一些吧,中国什么时候排上号了?
    支持(13反对(9回复
  1. 5
    Zx.MYS   说道:
    月光,这方法有点傻
    源代码里加几个隐藏的XXX关键字,搞定。
    支持(12反对(8回复

发表留言


点击更换验证码