Categories


Tags


apache、iis规则设置防盗链

Linux下规则文件.htaccess(手工创建.htaccess文件到站点根目录)

<IfModule mod_rewrite.c>

RewriteEngine on

RewriteCond %{HTTP_REFERER} !baidu.com [NC]

RewriteCond %{HTTP_REFERER} !google.com [NC]

RewriteCond %{HTTP_REFERER} !xxx.net [NC]

#RewriteCond %{HTTP_REFERER} !^$ [NC]

RewriteRule .*\.(gif|jpg|png|css|js)$ /band.txt [NC,L]

</IfModule>

注:xxx.net是您自己的域名,band.txt是被盗链后的提示内容文件

Windows2008、2012或更高系统下规则文件web.config (手工创建web.config文件到站点根目录)

<?xml version="1.0" ?>

<configuration>

<system.webServer>

<rewrite>

<rules>

<rule name="rule1" stopProcessing="true">

<match url="^.*\.(css|js|gif|png|jpg|jpeg)$" ignoreCase="true" />

<conditions>

<add input="{HTTP_REFERER}" pattern="您的域名.com(不用加www)" negate="true" />

<!--<add input="{HTTP_REFERER}" pattern="^$" negate="true" />-->

</conditions>

<action type="AbortRequest" />

</rule>

</rules>

</rewrite>

</system.webServer>

</configuration>

apache、iis屏蔽限制ip访问(适用虚拟主机)

apache、iis规则屏蔽拦截蜘蛛抓取

来源:西部数码


Public @ 2022-01-19 16:09:16

访问我的网站时杀毒软件报警提示中了病毒怎么办?

如果访问您的网站时杀毒软件报警提示中了病毒,您可以采取以下措施: 1. 立即检查您的网站:使用网站安全扫描工具,如VirusTotal、Quttera等在线工具或专业的网站安全服务,对您的网站进行全面扫描,以确认是否存在病毒或恶意软件。 2. 更新防护措施:确保您的网站和服务器软件都是最新版本,包括操作系统、网站平台和插件/扩展程序。同时,确保您的网站有一个强大的防火墙和安全插件,以增强网站的

Public @ 2023-07-23 11:50:33

apache、iis6、ii7独立ip主机设置防盗链(适用vps云主机服务器)

若是安装了我司助手环境请先按http://www.west.cn/faq/list.asp?unid=650 把伪静态组件开启若是纯净版系统,请按http://www.west.cn/faq/list.asp?unid=639 把伪静态组件开启然后在配置文件中按以下系统规则配置apache和iis6实现防盗链规则相同:进入others/httpd.conf中,保留前两行,复制以下规则保存即可Rew

Public @ 2021-11-09 16:09:15

更多您感兴趣的搜索

0.557062s