2024-07-30 12:21:29 +08:00
|
|
|
# openwrt屏蔽吸血客户端和 pcdn ip段
|
2024-07-30 10:30:19 +08:00
|
|
|
|
2024-07-30 12:21:29 +08:00
|
|
|
> 为transmisson屏蔽迅雷等吸血客户端
|
2024-07-30 10:30:19 +08:00
|
|
|
|
2024-07-30 12:21:29 +08:00
|
|
|
[教程地址](https://github.com/jqtmviyu/BTN-Collected-Rules)
|
2024-07-30 10:30:19 +08:00
|
|
|
|
2024-07-30 12:21:29 +08:00
|
|
|
|
|
|
|
## 防火墙阻止吸血客户端
|
|
|
|
|
|
|
|
1. 创建脚本
|
|
|
|
|
|
|
|
修改自 [WhymustIhaveaname/Transmission-Block-Xunlei](https://github.com/WhymustIhaveaname/Transmission-Block-Xunlei)
|
|
|
|
|
|
|
|
因为是在openwrt中运行,所以有点不太一样
|
|
|
|
|
2024-07-30 12:53:35 +08:00
|
|
|
下载 `block_xunlei.sh` 并修改
|
2024-07-30 12:21:29 +08:00
|
|
|
|
|
|
|
2. 添加计划任务
|
|
|
|
|
|
|
|
每两分钟运行一次
|
|
|
|
|
|
|
|
```crontab
|
|
|
|
PATH=/usr/sbin:/usr/bin:/sbin:/bin
|
|
|
|
*/2 * * * * /root/block_xunlei.sh 2>> /root/block_xunlei.log
|
|
|
|
```
|
|
|
|
|
|
|
|
## 添加屏蔽url
|
|
|
|
|
|
|
|
修改自 [PBH-BTN/BTN-Collected-Rules](https://github.com/PBH-BTN/BTN-Collected-Rules) 的all.txt
|
|
|
|
|
|
|
|
github action 每天自动更新
|
|
|
|
|
|
|
|
`transmission_blacklist.gz` 体积更小, 下载更快.
|
|
|
|
|
2024-07-30 12:53:35 +08:00
|
|
|
需要复制的是raw, 并且不能被墙.
|
|
|
|
|
2024-07-30 12:21:29 +08:00
|
|
|
### 定时更新
|
|
|
|
|
2024-07-30 12:53:35 +08:00
|
|
|
下载并修改`update_transmission_blacklist.sh`
|
2024-07-30 12:21:29 +08:00
|
|
|
|
|
|
|
```crontab
|
|
|
|
0 5 * * * /root/update_transmission_blacklist.sh 2>> /root/block_xunlei.log
|
|
|
|
```
|