Merge branch 'dev' into gateway

# Conflicts:
#	scripts/start.sh
This commit is contained in:
juewuy
2025-12-19 19:11:10 +08:00
14 changed files with 187 additions and 84 deletions

Binary file not shown.

Binary file not shown.

View File

@@ -1,4 +1,4 @@
meta_v=v1.19.17 meta_v=v1.19.17
singboxr_v=1.13.0-alpha.27 singboxr_v=1.13.0-alpha.27
versionsh=1.9.3beta9 versionsh=1.9.3pre1
GeoIP_v=20251205 GeoIP_v=20251205

102
docker/README.md Normal file
View File

@@ -0,0 +1,102 @@
# ShellCrash (Official Docker Image)
**ShellCrash 官方 Docker 镜像**,用于在容器环境中运行 ShellCrash支持 **HTTP / SOCKS 代理****旁路由透明代理** 两种部署模式。
该镜像由 **ShellCrash 官方维护**,基于原项目脚本构建,并通过 Docker 多架构机制发布。
------
## Quick Start最小化运行
仅启用 HTTP(S) / SOCKS5 代理功能适用于基础代理需求Mix代理端口7890面板管理端口9999。
```shell
docker run -d \
--name shellcrash \
-p 7890:7890 \
-p 9999:9999 \
shellcrash:latest
```
### 容器管理
首次部署完成后请务必使用以下命令进入容器完成设置导入配置文件允许开机启动及启动内核服务之后也可用此命令进入容器sh环境进行管理
```shell
docker exec -it shellcrash sh -l
```
------
## Advanced Usage旁路由 / 透明代理)
适用于旁路由、软路由或需要透明代理的部署场景需提前创建macvlan这里不推荐使用容器的host模式。
### 1. 创建 macvlan 网络
> 此处请根据实际网络环境调整参数,如之前已创建可忽略。
```shell
docker network create \
--driver macvlan \
--subnet 192.168.31.0/24 \
--gateway 192.168.31.1 \
-o parent=eth0 \
macvlan_lan
```
------
### 2. 启动容器(旁路由模式)
```shell
docker run -d \
--name shellcrash \
--network macvlan_lan \
--ip 192.168.31.222 \
--cap-add NET_ADMIN \
--cap-add NET_RAW \
--cap-add SYS_ADMIN \
--device /dev/net/tun:/dev/net/tun \
--restart unless-stopped \
shellcrash:latest
```
------
### 3.配置需要路由的设备
将需要路由的设备IPV4网关与DNS均指向启动容器时指定的IP地址如192.168.31.222
注意旁路由模式必须禁用子设备的IPV6地址或主路由的IPV6功能否则流量可能会经由IPV6直连而不会进入旁路由转发
------
## Persistent Configuration持久化配置,可选)
推荐使用 volume 挂载以持久化 ShellCrash 配置。
### 创建宿主机目录
```shell
mkdir -p /root/ShellCrash
```
### 启用持久化
将命令粘贴到你的实际容器启动命令中间,例如:
```shell
docker run -d \
………………
-v /root/ShellCrash:/etc/ShellCrash \
………………
```
------
## Notes
- 旁路由模式需要宿主机支持 `TUN`
- macvlan 网络下宿主机默认无法直接访问容器 IP
- 透明代理场景可能需要额外的网络规划

View File

@@ -36,7 +36,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/private.mrs path: ./ruleset/private.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/private.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/private.mrs"
interval: 86400 interval: 86400
ads: ads:
@@ -44,7 +44,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/ads.mrs path: ./ruleset/ads.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/ads.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/ads.mrs"
interval: 86400 interval: 86400
trackerslist: trackerslist:
@@ -52,7 +52,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/trackerslist.mrs path: ./ruleset/trackerslist.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/trackerslist.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/trackerslist.mrs"
interval: 86400 interval: 86400
microsoft-cn: microsoft-cn:
@@ -60,7 +60,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/microsoft-cn.mrs path: ./ruleset/microsoft-cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/microsoft-cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/microsoft-cn.mrs"
interval: 86400 interval: 86400
apple-cn: apple-cn:
@@ -68,7 +68,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/apple-cn.mrs path: ./ruleset/apple-cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/apple-cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/apple-cn.mrs"
interval: 86400 interval: 86400
google-cn: google-cn:
@@ -76,7 +76,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/google-cn.mrs path: ./ruleset/google-cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/google-cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/google-cn.mrs"
interval: 86400 interval: 86400
games-cn: games-cn:
@@ -84,7 +84,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/games-cn.mrs path: ./ruleset/games-cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/games-cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/games-cn.mrs"
interval: 86400 interval: 86400
media: media:
@@ -92,7 +92,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/media.mrs path: ./ruleset/media.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/media.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/media.mrs"
interval: 86400 interval: 86400
games: games:
@@ -100,7 +100,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/games.mrs path: ./ruleset/games.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/games.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/games.mrs"
interval: 86400 interval: 86400
ai: ai:
@@ -108,7 +108,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/ai.mrs path: ./ruleset/ai.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/ai.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/ai.mrs"
interval: 86400 interval: 86400
networktest: networktest:
@@ -116,7 +116,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/networktest.mrs path: ./ruleset/networktest.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/networktest.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/networktest.mrs"
interval: 86400 interval: 86400
proxy: proxy:
@@ -124,7 +124,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/proxy.mrs path: ./ruleset/proxy.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/proxy.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/proxy.mrs"
interval: 86400 interval: 86400
cn: cn:
@@ -132,7 +132,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/cn.mrs path: ./ruleset/cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/cn.mrs"
interval: 86400 interval: 86400
privateip: privateip:
@@ -140,7 +140,7 @@ rule-providers:
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/privateip.mrs path: ./ruleset/privateip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/privateip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/privateip.mrs"
interval: 86400 interval: 86400
cnip: cnip:
@@ -148,7 +148,7 @@ rule-providers:
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/cnip.mrs path: ./ruleset/cnip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/cnip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/cnip.mrs"
interval: 86400 interval: 86400
mediaip: mediaip:
@@ -156,7 +156,7 @@ rule-providers:
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/mediaip.mrs path: ./ruleset/mediaip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/mediaip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/mediaip.mrs"
interval: 86400 interval: 86400
gamesip: gamesip:
@@ -164,7 +164,7 @@ rule-providers:
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/gamesip.mrs path: ./ruleset/gamesip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/gamesip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/gamesip.mrs"
interval: 86400 interval: 86400
telegramip: telegramip:
@@ -172,7 +172,7 @@ rule-providers:
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/telegramip.mrs path: ./ruleset/telegramip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/telegramip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/telegramip.mrs"
interval: 86400 interval: 86400
rules: rules:

View File

@@ -33,7 +33,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/private.mrs path: ./ruleset/private.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/private.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/private.mrs"
interval: 86400 interval: 86400
trackerslist: trackerslist:
@@ -41,7 +41,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/trackerslist.mrs path: ./ruleset/trackerslist.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/trackerslist.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/trackerslist.mrs"
interval: 86400 interval: 86400
microsoft-cn: microsoft-cn:
@@ -49,7 +49,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/microsoft-cn.mrs path: ./ruleset/microsoft-cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/microsoft-cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/microsoft-cn.mrs"
interval: 86400 interval: 86400
apple-cn: apple-cn:
@@ -57,7 +57,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/apple-cn.mrs path: ./ruleset/apple-cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/apple-cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/apple-cn.mrs"
interval: 86400 interval: 86400
google-cn: google-cn:
@@ -65,7 +65,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/google-cn.mrs path: ./ruleset/google-cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/google-cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/google-cn.mrs"
interval: 86400 interval: 86400
games-cn: games-cn:
@@ -73,7 +73,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/games-cn.mrs path: ./ruleset/games-cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/games-cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/games-cn.mrs"
interval: 86400 interval: 86400
media: media:
@@ -81,7 +81,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/media.mrs path: ./ruleset/media.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/media.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/media.mrs"
interval: 86400 interval: 86400
games: games:
@@ -89,7 +89,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/games.mrs path: ./ruleset/games.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/games.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/games.mrs"
interval: 86400 interval: 86400
ai: ai:
@@ -97,7 +97,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/ai.mrs path: ./ruleset/ai.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/ai.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/ai.mrs"
interval: 86400 interval: 86400
networktest: networktest:
@@ -105,7 +105,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/networktest.mrs path: ./ruleset/networktest.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/networktest.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/networktest.mrs"
interval: 86400 interval: 86400
proxy: proxy:
@@ -113,7 +113,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/proxy.mrs path: ./ruleset/proxy.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/proxy.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/proxy.mrs"
interval: 86400 interval: 86400
cn: cn:
@@ -121,7 +121,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/cn.mrs path: ./ruleset/cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/cn.mrs"
interval: 86400 interval: 86400
privateip: privateip:
@@ -129,7 +129,7 @@ rule-providers:
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/privateip.mrs path: ./ruleset/privateip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/privateip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/privateip.mrs"
interval: 86400 interval: 86400
cnip: cnip:
@@ -137,7 +137,7 @@ rule-providers:
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/cnip.mrs path: ./ruleset/cnip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/cnip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/cnip.mrs"
interval: 86400 interval: 86400
mediaip: mediaip:
@@ -145,7 +145,7 @@ rule-providers:
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/mediaip.mrs path: ./ruleset/mediaip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/mediaip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/mediaip.mrs"
interval: 86400 interval: 86400
gamesip: gamesip:
@@ -153,7 +153,7 @@ rule-providers:
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/gamesip.mrs path: ./ruleset/gamesip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/gamesip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/gamesip.mrs"
interval: 86400 interval: 86400
telegramip: telegramip:
@@ -161,7 +161,7 @@ rule-providers:
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/telegramip.mrs path: ./ruleset/telegramip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/telegramip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/telegramip.mrs"
interval: 86400 interval: 86400
rules: rules:

View File

@@ -21,7 +21,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/cn.mrs path: ./ruleset/cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/cn.mrs"
interval: 86400 interval: 86400
private: private:
@@ -29,7 +29,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/private.mrs path: ./ruleset/private.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/private.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/private.mrs"
interval: 86400 interval: 86400
tld-proxy: tld-proxy:
@@ -37,7 +37,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/tld-proxy.mrs path: ./ruleset/tld-proxy.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/tld-proxy.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/tld-proxy.mrs"
interval: 86400 interval: 86400
proxy: proxy:
@@ -45,7 +45,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/proxy.mrs path: ./ruleset/proxy.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/proxy.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/proxy.mrs"
interval: 86400 interval: 86400
privateip: privateip:
@@ -53,7 +53,7 @@ rule-providers:
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/privateip.mrs path: ./ruleset/privateip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/privateip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/privateip.mrs"
interval: 86400 interval: 86400
cnip: cnip:
@@ -61,7 +61,7 @@ rule-providers:
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/cnip.mrs path: ./ruleset/cnip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/cnip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/cnip.mrs"
interval: 86400 interval: 86400
telegramip: telegramip:
@@ -69,7 +69,7 @@ rule-providers:
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/telegramip.mrs path: ./ruleset/telegramip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/telegramip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/telegramip.mrs"
interval: 86400 interval: 86400
rules: rules:

View File

@@ -34,7 +34,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/private.mrs path: ./ruleset/private.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/private.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/private.mrs"
interval: 86400 interval: 86400
ads: ads:
@@ -42,7 +42,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/ads.mrs path: ./ruleset/ads.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/ads.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/ads.mrs"
interval: 86400 interval: 86400
trackerslist: trackerslist:
@@ -50,7 +50,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/trackerslist.mrs path: ./ruleset/trackerslist.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/trackerslist.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/trackerslist.mrs"
interval: 86400 interval: 86400
microsoft-cn: microsoft-cn:
@@ -58,7 +58,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/microsoft-cn.mrs path: ./ruleset/microsoft-cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/microsoft-cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/microsoft-cn.mrs"
interval: 86400 interval: 86400
apple-cn: apple-cn:
@@ -66,7 +66,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/apple-cn.mrs path: ./ruleset/apple-cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/apple-cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/apple-cn.mrs"
interval: 86400 interval: 86400
google-cn: google-cn:
@@ -74,7 +74,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/google-cn.mrs path: ./ruleset/google-cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/google-cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/google-cn.mrs"
interval: 86400 interval: 86400
games-cn: games-cn:
@@ -82,7 +82,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/games-cn.mrs path: ./ruleset/games-cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/games-cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/games-cn.mrs"
interval: 86400 interval: 86400
ai: ai:
@@ -90,7 +90,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/ai.mrs path: ./ruleset/ai.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/ai.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/ai.mrs"
interval: 86400 interval: 86400
networktest: networktest:
@@ -98,7 +98,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/networktest.mrs path: ./ruleset/networktest.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/networktest.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/networktest.mrs"
interval: 86400 interval: 86400
proxy: proxy:
@@ -106,7 +106,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/proxy.mrs path: ./ruleset/proxy.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/proxy.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/proxy.mrs"
interval: 86400 interval: 86400
cn: cn:
@@ -114,7 +114,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/cn.mrs path: ./ruleset/cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/cn.mrs"
interval: 86400 interval: 86400
privateip: privateip:
@@ -122,7 +122,7 @@ rule-providers:
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/privateip.mrs path: ./ruleset/privateip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/privateip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/privateip.mrs"
interval: 86400 interval: 86400
cnip: cnip:
@@ -130,7 +130,7 @@ rule-providers:
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/cnip.mrs path: ./ruleset/cnip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/cnip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/cnip.mrs"
interval: 86400 interval: 86400
telegramip: telegramip:
@@ -138,7 +138,7 @@ rule-providers:
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/telegramip.mrs path: ./ruleset/telegramip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/telegramip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/telegramip.mrs"
interval: 86400 interval: 86400
rules: rules:

View File

@@ -31,7 +31,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/private.mrs path: ./ruleset/private.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/private.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/private.mrs"
interval: 86400 interval: 86400
trackerslist: trackerslist:
@@ -39,7 +39,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/trackerslist.mrs path: ./ruleset/trackerslist.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/trackerslist.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/trackerslist.mrs"
interval: 86400 interval: 86400
microsoft-cn: microsoft-cn:
@@ -47,7 +47,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/microsoft-cn.mrs path: ./ruleset/microsoft-cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/microsoft-cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/microsoft-cn.mrs"
interval: 86400 interval: 86400
apple-cn: apple-cn:
@@ -55,7 +55,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/apple-cn.mrs path: ./ruleset/apple-cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/apple-cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/apple-cn.mrs"
interval: 86400 interval: 86400
google-cn: google-cn:
@@ -63,7 +63,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/google-cn.mrs path: ./ruleset/google-cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/google-cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/google-cn.mrs"
interval: 86400 interval: 86400
games-cn: games-cn:
@@ -71,7 +71,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/games-cn.mrs path: ./ruleset/games-cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/games-cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/games-cn.mrs"
interval: 86400 interval: 86400
ai: ai:
@@ -79,7 +79,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/ai.mrs path: ./ruleset/ai.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/ai.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/ai.mrs"
interval: 86400 interval: 86400
networktest: networktest:
@@ -87,7 +87,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/networktest.mrs path: ./ruleset/networktest.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/networktest.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/networktest.mrs"
interval: 86400 interval: 86400
proxy: proxy:
@@ -95,7 +95,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/proxy.mrs path: ./ruleset/proxy.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/proxy.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/proxy.mrs"
interval: 86400 interval: 86400
cn: cn:
@@ -103,7 +103,7 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/cn.mrs path: ./ruleset/cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/cn-lite.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/cn-lite.mrs"
interval: 86400 interval: 86400
privateip: privateip:
@@ -111,7 +111,7 @@ rule-providers:
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/privateip.mrs path: ./ruleset/privateip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/privateip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/privateip.mrs"
interval: 86400 interval: 86400
cnip: cnip:
@@ -119,7 +119,7 @@ rule-providers:
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/cnip.mrs path: ./ruleset/cnip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/cnip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/cnip.mrs"
interval: 86400 interval: 86400
telegramip: telegramip:
@@ -127,7 +127,7 @@ rule-providers:
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/telegramip.mrs path: ./ruleset/telegramip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/telegramip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/telegramip.mrs"
interval: 86400 interval: 86400
rules: rules:

View File

@@ -8,21 +8,21 @@ rule-providers:
behavior: domain behavior: domain
format: mrs format: mrs
path: ./ruleset/cn.mrs path: ./ruleset/cn.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/cn.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/cn.mrs"
interval: 86400 interval: 86400
privateip: privateip:
type: http type: http
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/privateip.mrs path: ./ruleset/privateip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/privateip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/privateip.mrs"
interval: 86400 interval: 86400
cnip: cnip:
type: http type: http
behavior: ipcidr behavior: ipcidr
format: mrs format: mrs
path: ./ruleset/cnip.mrs path: ./ruleset/cnip.mrs
url: "https://github.com/DustinWin/ruleset_geodata/releases/download/mihomo-ruleset/cnip.mrs" url: "https://testingcf.jsdelivr.net/gh//DustinWin/ruleset_geodata@refs/heads/mihomo-ruleset/cnip.mrs"
interval: 86400 interval: 86400
rules: rules:
- RULE-SET,privateip,🎯 全球直连,no-resolve - RULE-SET,privateip,🎯 全球直连,no-resolve

View File

@@ -1,7 +1,7 @@
#!/bin/sh #!/bin/sh
# Copyright (C) Juewuy # Copyright (C) Juewuy
version=1.9.3beta9 version=1.9.3pre1
setdir() { setdir() {
dir_avail() { dir_avail() {

View File

@@ -295,7 +295,7 @@ urlencode() {
| hexdump -v -e '/1 "%02X\n"' \ | hexdump -v -e '/1 "%02X\n"' \
| while read -r hex; do | while read -r hex; do
case "$hex" in case "$hex" in
2D|2E|5F|7E|3[0-9]|4[1-9A-F]|5[A-F]|6[1-9A-F]|7[0-9A-E]) 2D|2E|5F|7E|3[0-9]|4[1-9A-F]|5[0-9A]|6[1-9A-F]|7[0-9A-E])
printf "\\$(printf '%03o' "0x$hex")" printf "\\$(printf '%03o' "0x$hex")"
;; ;;
*) *)
@@ -558,7 +558,7 @@ EOF
fi fi
fi fi
#分割配置文件 #分割配置文件
yaml_char='proxies proxy-groups proxy-providers rules rule-providers' yaml_char='proxies proxy-groups proxy-providers rules rule-providers sub-rules listeners'
for char in $yaml_char; do for char in $yaml_char; do
sed -n "/^$char:/,/^[a-z]/ { /^[a-z]/d; p; }" $core_config >"$TMPDIR"/${char}.yaml sed -n "/^$char:/,/^[a-z]/ { /^[a-z]/d; p; }" $core_config >"$TMPDIR"/${char}.yaml
done done
@@ -836,11 +836,9 @@ EOF
"default_domain_resolver": "dns_resolver", "default_domain_resolver": "dns_resolver",
"default_mark": $routing_mark, "default_mark": $routing_mark,
"rules": [ "rules": [
{ "inbound": [ "dns-in" ], "action": "sniff", "timeout": "500ms" }, { "inbound": [ "dns-in" ], "action": "hijack-dns" },
$tailscale_set $tailscale_set
$sniffer_set $sniffer_set
{ "protocol": "dns", "action": "hijack-dns" },
{ "inbound": [ "dns-in" ], "action": "reject" },
{ "clash_mode": "Direct" , "outbound": "DIRECT" }, { "clash_mode": "Direct" , "outbound": "DIRECT" },
{ "clash_mode": "Global" , "outbound": "GLOBAL" } { "clash_mode": "Global" , "outbound": "GLOBAL" }
] ]
@@ -2073,7 +2071,10 @@ start)
systemctl start shellcrash.service || start_error systemctl start shellcrash.service || start_error
} }
elif grep -q 's6' /proc/1/comm; then elif grep -q 's6' /proc/1/comm; then
bfstart && /command/s6-svc -u /run/service/shellcrash && afstart & bfstart && /command/s6-svc -u /run/service/shellcrash && {
[ ! -f "$CRASHDIR"/.dis_startup ] && touch /etc/s6-overlay/s6-rc.d/user/contents.d/afstart
afstart &
}
elif rc-status -r >/dev/null 2>&1; then elif rc-status -r >/dev/null 2>&1; then
rc-service shellcrash stop >/dev/null 2>&1 rc-service shellcrash stop >/dev/null 2>&1
rc-service shellcrash start rc-service shellcrash start
@@ -2177,7 +2178,7 @@ webget)
#参数【$4】代表输出显示【$5】不启用重定向 #参数【$4】代表输出显示【$5】不启用重定向
#参数【$6】代表验证证书【$7】使用自定义UA #参数【$6】代表验证证书【$7】使用自定义UA
[ -n "$7" ] && agent="--user-agent \"$7\"" [ -n "$7" ] && agent="--user-agent \"$7\""
if wget --version >/dev/null 2>&1; then if wget --help 2>&1 | grep -q 'show-progress' >/dev/null 2>&1; then
[ "$4" = "echooff" ] && progress='-q' || progress='-q --show-progress' [ "$4" = "echooff" ] && progress='-q' || progress='-q --show-progress'
[ "$5" = "rediroff" ] && redirect='--max-redirect=0' || redirect='' [ "$5" = "rediroff" ] && redirect='--max-redirect=0' || redirect=''
[ "$6" = "skipceroff" ] && certificate='' || certificate='--no-check-certificate' [ "$6" = "skipceroff" ] && certificate='' || certificate='--no-check-certificate'

View File

@@ -523,7 +523,7 @@ EOF
#调用内核测试 #调用内核测试
${CRASHDIR}/start.sh core_check && ${TMPDIR}/CrashCore merge ${TMPDIR}/config.json -C ${TMPDIR}/providers ${CRASHDIR}/start.sh core_check && ${TMPDIR}/CrashCore merge ${TMPDIR}/config.json -C ${TMPDIR}/providers
if [ "$?" = 0 ];then if [ "$?" = 0 ];then
echo -e "\033[32m配置文件生成成功\033[0m" echo -e "\033[32m配置文件生成成功如果启动超时建议更新里手动安装Singbox-srs数据库常用包\033[0m"
mkdir -p ${CRASHDIR}/jsons mkdir -p ${CRASHDIR}/jsons
mv -f ${TMPDIR}/config.json ${CRASHDIR}/jsons/config.json mv -f ${TMPDIR}/config.json ${CRASHDIR}/jsons/config.json
rm -rf ${TMPDIR}/providers rm -rf ${TMPDIR}/providers
@@ -934,7 +934,7 @@ gen_core_config_link(){ #在线生成工具
echo -e " 0 \033[31m撤销输入并返回上级菜单\033[0m" echo -e " 0 \033[31m撤销输入并返回上级菜单\033[0m"
echo "-----------------------------------------------" echo "-----------------------------------------------"
read -p "请直接输入第${i}个链接或对应数字选项 > " link read -p "请直接输入第${i}个链接或对应数字选项 > " link
link=$(echo $link | sed 's/\&/%26/g') #处理分隔符 link=$(echo $link | sed 's/\&/\\&/g') #处理分隔符
test=$(echo $link | grep "://") test=$(echo $link | grep "://")
link=`echo ${link/\#*/''}` #删除链接附带的注释内容 link=`echo ${link/\#*/''}` #删除链接附带的注释内容
link=`echo ${link/\ \(*\)/''}` #删除恶心的超链接内容 link=`echo ${link/\ \(*\)/''}` #删除恶心的超链接内容

View File

@@ -1 +1 @@
1.9.3beta9 1.9.3pre1