Giter Site home page Giter Site logo

kohyzsc123 / clash-config Goto Github PK

View Code? Open in Web Editor NEW

This project forked from haman23333/proxy-config

0.0 0.0 0.0 54 KB

包含 mixin 和 parsers 配置,实现了 Clash 的 dns 抗污染、tun 全局代理、parsers 自定义分流,解决机场自带垃圾配置的糟心问题

clash-config's Introduction

Clash

已包含 mixin 和 parsers 配置,可以直接使用

已经配置好了 dns 和 tun 参数,分别实现减少dns污染和全局代理,不要用 redir-host 了,未来版本不会支持了

原文:

since redir-host brings a lot of misunderstandings and problems (some of which are even hard to find). I decided to remove it. It is only used in the fake-ip-filter for a few domain name mappings. I know that it can be bypassed and "recovered" in fake-ip mode. If fake-ip-filter finds that it has been abused, I will delete the domain mapping mode completely.

关于为什么不在 dns 中添加 fallback 详见 https://github.com/Dreamacro/clash/issues/642#issuecomment-816448986

关于 fake-ip 导致一些即时通信无法正常使用的解决方式为 fake-ip-filter 里添加白名单 https://github.com/Dreamacro/clash/issues/1644#issuecomment-927270223

预处理机场的配置文件,因为机场的配置太垃圾无法忍受所以按照别人的模板写了配置 https://github.com/Fndroid/clash_for_windows_pkg/issues/2193#issue-987352146

实现了以下分流规则:

  • Apple系
  • Microsoft系
  • Google系
  • 巴哈姆特
  • 常用境外游戏平台
  • 下载(包含了种子的规则,谨慎使用 BitTorrent 防止侵权问题导致代理服务器被 ban)
  • Telegram
  • 境内网站

自行修改

为避免一大坨规则扔进去导致性能浪费,用了 rule-provider,跟据 Stash 手册得知,只要正确配置,即使超过几十万条规则依然不会产生大的开销,还方便维护

rule-providers:
  proxy-domain:
    behavior: domain # 使用 domain 类规则集,可以使匹配更高效
    url: https://cdn.jsdelivr.net/gh/Loyalsoldier/clash-rules@release/proxy.txt
    interval: 86400
 
  cn-cidr:
    behavior: ipcidr # 使用 ipcidr 类规则集,可以使匹配更高效
    url: https://cdn.jsdelivr.net/gh/Loyalsoldier/clash-rules@release/cncidr.txt
    interval: 86400
 
rules:
  - RULE-SET,proxy-domain,Proxy
  - RULE-SET,cn-cidr,DIRECT

domain 和 ipcidr 两种类型的规则集合专门针对大量数据进行了优化,在规则条目较多时建议优先选择。

不建议使用内含大量规则的 classical 规则集合,会显著提高 Stash 内存占用。

Quanmtumult X 和 Shadowrocket (实验性)

直接导入配置即可

其他

国内相关规则已自带 GEOIP 相关参数,可以不用调用 GEOIP 了

clash-config's People

Contributors

haman23333 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.