SukkaW/Koolshare-Clash

Do you want to work on this issue?

You can request for a bounty in order to promote it!

KoolClash Feature 征集 #71

SukkaW posted onGitHub

KoolClash 即将开始进行重构。如果你有什么在 UI 或功能、特性上的需求,可以在这里提出来供我参考。

目前计划中的功能有:

  • _config.yaml 代码编辑器。计划使用轻量级的 CodeMirror:

image

  • 为现有的「自定义 DNS」启用 CodeMirror 代码编辑器
  • 新增「自定义 Hosts」功能,行为同「自定义 DNS」,对应 Clash 配置文件的 hosts 字段
  • 定向劫持 DNS:对于如 Google HomoHome 这类不能修改 DNS 的设备,定向劫持发往某些 IP(如 8.8.8.8)的 DNS 查询请求到 KoolClash 的 Fake DNS、实现 Clash 接管 DNS。

KoolClash 不会提供全局 DNS 劫持功能,以回避 DNS 回环解析

  • 使用由我和 DlerCloud 维护的 geolite.clash.dev GeoLite 镜像
  • KoolClash 白名单 IP 列表支持全部自定义

目前 暂不 考虑 的功能:

  • 适配 Clash 的 Proxy Provider:文档尚不清晰、目前也没有太多商业性质的代理服务提供商提供相关格式的配置。
  • Clash TUN 和 UDP 支持:等 OpenClash 的 iptables 脚本写好了我去拿来用。

1, 定时自动更新ss订阅链接(如96小时,24小时等),并自动重启Clash

posted by ChengduKarthago over 5 years ago

2,选择特定白名单设备,或黑名单设备,这样可以让部分设备翻,部分设备不翻

posted by ChengduKarthago about 5 years ago

希望加入 GFWlist 规则支持

posted by tony27786 about 5 years ago

@tony27786 KoolClash 永远 不会加入 GFWlist 规则支持。建议自行将 GFWList 转换为 Clash 配置文件。

posted by SukkaW about 5 years ago

建议放一份标准的yml文件标准在说明里。想找个rixCloud 和 DlerCloud clash订阅例子参考下,找了N久找不到。你写那么多字,不如直接放个例程,标注下vmess节点需要改成自己的,供使用者参考。

posted by ntgeralt about 5 years ago

订阅使用api热重载配置 启动时保持上一次的节点选择的功能

``` reload_yml () { [ "$app_120" == "2" ] && return [ -z "pidof clash" ] && return

if [ "$1" == "check" ] ; then curltest=which curl if [ -z "$curltest" ] || [ ! -s "which curl" ] ; then logger -t "【clash】" "找不到 curl ,需要手动安装 opt 后输入[opkg update; opkg install curl]安装" eturn 1 fi if [[ "$(jq -h 2>&1 | wc -l)" -lt 2 ]] ; then jq_check if [[ "$(jq -h 2>&1 | wc -l)" -lt 2 ]] ; then logger -t "【clash】" "错误!找不到 jq 程序" return 1 fi fi mkdir -p /etc/storage/clash secret="$(yq r /opt/app/clash/config/config.yaml secret)" #secret="$clash_secret" fi if [ "$1" == "save" ] ; then logger -t "【clash】" "保存web节点选择" curl -H "Authorization: Bearer $secret" 'http://127.0.0.1:9090/proxies' | jq --raw-output '(.proxies[]|select(.type=="Selector")).name' > /tmp/Selector_name.txt [ -s /tmp/Selector_name.txt ] && cp -f /tmp/Selector_name.txt /etc/storage/clash/Selector_name.txt curl -H "Authorization: Bearer $secret" 'http://127.0.0.1:9090/proxies' | jq --raw-output '(.proxies[]|select(.type=="Selector")).now' > /tmp/Selector_now.txt [ -s /tmp/Selector_now.txt ] && cp -f /tmp/Selector_now.txt /etc/storage/clash/Selector_now.txt rm -f /tmp/Selector_name.txt /tmp/Selector_now.txt fi if [ "$1" == "set" ] ; then logger -t "【clash】" "恢复web节点选择" [ -s /etc/storage/clash/Selector_name.txt ] && [ -s /etc/storage/clash/Selector_now.txt ] && eval "$(awk 'NR==FNR{a[NR]=$0}NR>FNR{print "curl -X PUT -w "%{http_code}" -H "Authorization: Bearer '$secret'" -H "Content-Type: application/json" -d \047{"name": ""$0""}\047 \047http://127.0.0.1:9090/proxies/"a[FNR]"\047"}' /etc/storage/clash/Selector_name.txt /etc/storage/clash/Selector_now.txt)" fi if [ "$1" == "reload" ] ; then logger -t "【clash】" "api热重载配置" curl -X PUT -w "%{http_code}" -H "Authorization: Bearer $secret" -H "Content-Type: application/json" -d '{"path": "/opt/app/clash/config/config.yaml"}' 'http://127.0.0.1:9090/configs?force=true' fi

}

posted by hiboyhiboy about 5 years ago

@hiboyhiboy

启动时保持上一次的节点选择的功能

这个 Feature 也有很多人给 Clash 提过了,我也和 Dreamacro 交流过,目前情况是要等 Clash 内部的 Event 管理做出来,Clash 的计划是在 config 目录下写一个状态保存文件。

这个功能还是让 Clash 上游去实现比较合适,这样本地不需要轮询,也可以适配现有所有的 Clash Web 面板。面板如果有现成的了就没必要再去造轮子了。

订阅使用 api 热重载配置

这一块逻辑我还在想怎么做,打算参考 Clash for Windows,毕竟未来有计划做多配置文件,肯定是要用 API 重载的。

posted by SukkaW about 5 years ago
posted by caesarjing about 5 years ago

Dashboard 换成 http://yacd.haishan.me/#/, https://github.com/haishanh/yacd

移动端适配不佳、非 Dreamacro 维护,不予内置,建议自行 Host。

posted by SukkaW about 5 years ago

有规范性_config.yaml文件参考嘛我编写的外部控制部分链接不上

posted by z44499783 about 5 years ago

我希望能把Trojan集成进去,虽然Clash不支持trojan,但可以用Socks方式兼容进去

posted by chacha20 about 5 years ago

我希望能把Trojan集成进去,虽然Clash不支持trojan,但可以用Socks方式兼容进去

已经兼容了 @chacha20

posted by caesarjing about 5 years ago

Clash 0.19 已经提供了对 UDP TPROXY 的支持,所以可以没有必要等 TUN 了、可以直接做 UDP 转发支持。

posted by SukkaW about 5 years ago

支持配置和上传 external-ui:

posted by Rapiz1 almost 5 years ago

@Rapiz1

可以考虑和 OpenClash 一样内置多个版本的面板,不过不一定提供上传。

posted by SukkaW almost 5 years ago

https://github.com/SukkaW/Koolshare-Clash/issues/70 提供用户自定义api token的接口来解决这个问题 希望集成 https://dev.maxmind.com/geoip/geoipupdate/ maxmind的自动化更新工具

posted by Rapiz1 almost 5 years ago

我希望能把Trojan集成进去,虽然Clash不支持trojan,但可以用Socks方式兼容进去

我也希望把trojan的支持加进去,trojan对UDP支持好

posted by soulstage almost 4 years ago

Fund this Issue

$0.00
Funded
Only logged in users can fund an issue

Pull requests