Untitled

mail@pastecode.io avatar
unknown
json
a month ago
16 kB
4
Indexable
Never
	{
    "log": {
       "disabled": false,
       "level": "info",
       "output": "usr/local/etc/sing-box/sing-box.log",
       "timestamp": true
    },
    "dns": {
       "servers": [
      {
        "tag": "mosdns",
        "address": "udp://10.0.0.215:53",   
        "strategy": "ipv4_only",
        "detour": "direct"
      },
      {
        "tag": "success",
        "address": "rcode://success"
      },
	  {
        "tag": "block",
        "address": "rcode://refused"
      }
    ],
      "rules": [
      {
        "clash_mode": "Global",
        "server": "mosdns"
      },
      {
        "clash_mode": "Direct",
        "server": "mosdns"
      },
       {
        "query_type": [
          "AAAA",
          "HTTPS"
        ],
        "server": "block" ,
        "disable_cache": true
      },	  
      {
        "rule_set": "geosite-category-ads-all",
        "server": "block",
        "disable_cache": true
      }
    ],
        "strategy": "ipv4_only",
        "disable_cache": false,
        "disable_expire": false
    },
    "inbounds": [
      {
        "type": "mixed",
        "listen": "::",
        "listen_port": 10000
      },
        {
        "type": "direct",
        "tag": "dns-in",
        "network": "udp",
        "listen": "::",
        "listen_port": 53
        },
        {
        "type": "tproxy",
        "tag": "tproxy-in",
        "listen": "::",
        "listen_port": 7896,
        "tcp_fast_open": true,
        "sniff": true,
        "sniff_override_destination": false,
        "sniff_timeout": "100ms",
        "udp_timeout": 300
       }
    ],
    "outbounds": [
        {
            "tag":"proxy",
            "type":"selector",
            "outbounds":[
              "*******"    # 节点TAG , 可以多行, 最后一行 没有英文逗号  
        ]
        },
       {
            "type": "vless",   # 这是个vless brutal 的例子, tag 的名字要和上面selector ( 如82 行) 名字一样
            "tag": "*****",
            "uuid": "**********",
            "packet_encoding": "xudp",
            "server": "*******",
            "server_port": ************,
            "flow": "",
            "tls": {
            "enabled": true,
            "server_name": "*********",
            "utls": {
            "enabled": true,
            "fingerprint": "chrome"
           },
           "reality": {
           "enabled": true,
           "public_key": "*********",
           "short_id": "**************"
            }
        },
           "multiplex": {
           "enabled": true,
           "protocol": "h2mux",
           "max_connections": 1,
           "min_streams": 2,
           "padding": true,
           "brutal": {
             "enabled": true,
             "up_mbps": 50,
             "down_mbps": 500
              }
           }
        },
        {
          "type": "direct",
          "tag": "direct"
        },
        {
            "type": "block",
            "tag": "block"
        },
        {
            "type": "dns",
            "tag": "mosdns"
        }
    ],
    "route": {
        "rules": [
        {
        "inbound": "dns-in",
        "outbound": "mosdns"
        },
        {
        "protocol": "dns",
        "outbound": "mosdns"
        },
		{
        "clash_mode": "direct",
        "outbound": "direct"
        },
        {
        "clash_mode": "global",
        "outbound": "proxy"
        },
        {
        "network": "udp",
        "port": 443,
        "outbound": "block"
        },
	    {
        "rule_set": "geosite-category-ads-all",
        "outbound": "block"
        },
       	{
	    "domain_suffix": [ 
	        ".cn"
        ],
        "outbound": "direct"
        },
        {
	    "domain_suffix": [ 
	        "office365.com"
        ],
        "outbound": "direct"
        },
        {
        "domain_regex": "^-cn-ssl.ls.apple.com",
        "domain_suffix": [
          "push.apple.com",
          "iphone-ld.apple.com",
          "lcdn-locator.apple.com",
          "lcdn-registration.apple.com"
        ],
        "outbound": "direct"
        },
        {
	    "domain_suffix": [ 
	        "microsoft.com"
        ],
        "outbound": "proxy"
        },
        {
        "rule_set": "geosite-cn",
        "outbound": "direct"
        },
	    {
        "rule_set": "geosite-category-games-cn",
        "outbound": "direct"
        },
	    {
        "rule_set": [
		   "geosite-category-scholar-!cn",
		   "geosite-category-scholar-cn"
	   ],   
        "outbound": "direct"
        },
	    {
        "rule_set": "geoip-cn",
        "outbound": "direct"
        },
        {
        "domain_suffix": [
          "googleapis.com",
          "googleapis.cn",
          "gstatic.com"
        ],
        "outbound": "proxy"
        },
		{
        "rule_set": "geosite-geolocation-!cn",
        "outbound": "proxy"
        },
		{
        "rule_set": [
		  "geoip-telegram",
		  "geosite-telegram"
		],  
        "outbound": "proxy"
        },
		{
        "rule_set": [
		   "geoip-google",
		   "geosite-google"
		],   
        "outbound": "proxy"
        },
		{
        "rule_set": "geoip-cn",
		"invert": true,
        "outbound": "proxy"
        },
        {
        "ip_is_private": true,
        "outbound": "direct"
        }
      ],
    "rule_set": [
      {
        "tag": "geoip-google",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geoip/google.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geoip-telegram",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geoip/telegram.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geoip-twitter",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geoip/twitter.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geoip-facebook",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geoip/facebook.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geoip-netflix",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geoip/netflix.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geoip-cn",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geoip/cn.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
	  {
        "tag": "geoip-hk",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geoip/hk.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
	  {
        "tag": "geoip-mo",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geoip/mo.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-openai",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/openai.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-youtube",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/youtube.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-google",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/google.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-github",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/github.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-telegram",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/telegram.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-twitter",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/twitter.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-facebook",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/facebook.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-instagram",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/instagram.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-amazon",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/amazon.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-apple",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/apple.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
	  {
        "tag": "geosite-apple-cn",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/apple@cn.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-microsoft",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/microsoft.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
	  {
        "tag": "geosite-microsoft-cn",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/microsoft@cn.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-category-games",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/category-games.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
	  {
        "tag": "geosite-category-games-cn",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/category-games@cn.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-bilibili",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/bilibili.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-tiktok",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/tiktok.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-netflix",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/netflix.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-hbo",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/hbo.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-disney",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/disney.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-primevideo",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/primevideo.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-cn",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/cn.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-geolocation-!cn",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/geolocation-!cn.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
      {
        "tag": "geosite-category-ads-all",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/category-ads-all.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
	  {
        "tag": "geosite-category-scholar-!cn",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/category-scholar-!cn.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      },
	  {
        "tag": "geosite-category-scholar-cn",
        "type": "remote",
        "format": "binary",
        "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/category-scholar-cn.srs",
        "download_detour": "direct",
		"update_interval": "7d"
      }
    ],
        "final": "proxy",
        "auto_detect_interface": true,
        "default_mark": 1
    },
    "experimental": {
    "clash_api": {
    "external_controller": "0.0.0.0:9090"
    },
	  "cache_file": {
      "enabled": true,
      "path": "/root/cache.db",
      "cache_id": "my_profile1",
      "store_fakeip": true
    }
  }
}	
Leave a Comment