全球主机交流论坛

 找回密码
 注册

QQ登录

只需一步,快速开始

CeraNetworks网络延迟测速工具IP归属甄别会员请立即修改密码
查看: 433|回复: 4

给mjj分享个sing-box1.12版的客户端配置

[复制链接]
发表于 2025-6-18 15:14:18 | 显示全部楼层 |阅读模式

  1. {
  2.   "log": {
  3.     "disabled": false,
  4.     "level": "warn",
  5.     "timestamp": true
  6.   },
  7.   "experimental": {
  8.     "cache_file": {
  9.       "enabled": true,
  10.       "path": "cache.db",
  11.       "store_fakeip": true,
  12.       "store_rdrc": true
  13.     }
  14.   },
  15.   "dns": {
  16.     "servers": [
  17.       {
  18.         "tag": "dns_proxy",
  19.         "type": "https",
  20.         "server": "1.1.1.1",
  21.         "detour": "Proxy"
  22.       },
  23.       {
  24.         "tag": "dns_direct",
  25.         "type": "https",
  26.         "server": "223.5.5.5"
  27.       },
  28.       {
  29.         "tag": "dns_fakeip",
  30.         "type": "fakeip",
  31.         "inet4_range": "198.18.0.0/15",
  32.         "inet6_range": "fc00::/18"
  33.       }
  34.     ],
  35.     "rules": [
  36.       {
  37.         "clash_mode": "Direct",
  38.         "server": "dns_direct"
  39.       },
  40.       {
  41.         "clash_mode": "Global",
  42.         "server": "dns_proxy"
  43.       },
  44.       {
  45.         "rule_set": "geosite-category-ads-all",
  46.         "action": "predefined",
  47.         "rcode": "NOERROR",
  48.         "answer": [
  49.           "localhost. 60 IN A 0.0.0.0"
  50.         ]
  51.       },
  52.       {
  53.         "rule_set": "geosite-geolocation-cn",
  54.         "server": "dns_direct"
  55.       },
  56.       {
  57.         "rule_set": "geosite-geolocation-!cn",
  58.         "query_type": [
  59.           "A",
  60.           "AAAA"
  61.         ],
  62.         "server": "dns_fakeip"
  63.       }
  64.     ],
  65.     "final": "dns_proxy",
  66.     "strategy": "ipv4_only",
  67.     "independent_cache": true
  68.   },
  69.   "inbounds": [
  70.     {
  71.       "type": "tun",
  72.       "tag": "tun-in",
  73.       "address": [
  74.         "172.18.0.1/30",
  75.         "fdfe:dcba:9876::1/126"
  76.       ],
  77.       "mtu": 1400,
  78.       "auto_route": true,
  79.       "strict_route": true,
  80.       "stack": "gvisor"
  81.     }
  82.   ],
  83.   "outbounds": [
  84.     {
  85.       "type": "selector",
  86.       "tag": "Proxy",
  87.       "outbounds": [
  88.         "direct-out",
  89.         "auto"
  90.       ],
  91.       "default": "direct-out",
  92.       "interrupt_exist_connections": false
  93.     },
  94.     {
  95.       "type": "urltest",
  96.       "tag": "auto",
  97.       "outbounds": [
  98.         "direct-out"
  99.       ],
  100.       "url": "https://www.gstatic.com/generate_204",
  101.       "interval": "10m",
  102.       "tolerance": 50,
  103.       "interrupt_exist_connections": false
  104.     },
  105.     {
  106.       "type": "direct",
  107.       "tag": "direct-out"
  108.     }
  109.   ],
  110.   "route": {
  111.     "default_domain_resolver": {
  112.       "server": "dns_direct"
  113.     },
  114.     "rules": [
  115.       {
  116.         "inbound": "tun-in",
  117.         "action": "sniff"
  118.       },
  119.       {
  120.         "type": "logical",
  121.         "mode": "or",
  122.         "rules": [
  123.           {
  124.             "port": 53
  125.           },
  126.           {
  127.             "protocol": "dns"
  128.           }
  129.         ],
  130.         "action": "hijack-dns"
  131.       },
  132.       {
  133.         "clash_mode": "Direct",
  134.         "outbound": "direct-out"
  135.       },
  136.       {
  137.         "clash_mode": "Global",
  138.         "outbound": "Proxy"
  139.       },
  140.       {
  141.         "type": "logical",
  142.         "mode": "and",
  143.         "rules": [
  144.           {
  145.             "type": "logical",
  146.             "mode": "or",
  147.             "rules": [
  148.               {
  149.                 "domain": [
  150.                   "*.l.google.com"
  151.                 ]
  152.               },
  153.               {
  154.                 "domain_keyword": [
  155.                   "voice"
  156.                 ]
  157.               },
  158.               {
  159.                 "domain_suffix": [
  160.                   "gstatic.com",
  161.                   "googleapis.com"
  162.                 ]
  163.               },
  164.               {
  165.                 "ip_cidr": [
  166.                   "74.125.39.0/24",
  167.                   "74.125.250.129/32",
  168.                   "2001:4860:4864:2::/64"
  169.                 ]
  170.               }
  171.             ]
  172.           },
  173.           {
  174.             "type": "logical",
  175.             "mode": "or",
  176.             "rules": [
  177.               {
  178.                 "network": "udp"
  179.               },
  180.               {
  181.                 "protocol": "stun"
  182.               }
  183.             ]
  184.           }
  185.         ],
  186.         "outbound": "Proxy"
  187.       },
  188.       {
  189.         "type": "logical",
  190.         "mode": "or",
  191.         "rules": [
  192.           {
  193.             "port": 853
  194.           },
  195.           {
  196.             "network": "udp",
  197.             "port": 443
  198.           },
  199.           {
  200.             "protocol": "stun"
  201.           }
  202.         ],
  203.         "action": "reject",
  204.         "method": "drop"
  205.       },
  206.       {
  207.         "type": "logical",
  208.         "mode": "or",
  209.         "rules": [
  210.           {
  211.             "ip_is_private": true
  212.           },
  213.           {
  214.             "rule_set": "geosite-geolocation-cn"
  215.           },
  216.           {
  217.             "rule_set": "geoip-cn"
  218.           }
  219.         ],
  220.         "outbound": "direct-out"
  221.       }
  222.     ],
  223.     "final": "Proxy",
  224.     "auto_detect_interface": true,
  225.     "rule_set": [
  226.       {
  227.         "type": "remote",
  228.         "tag": "geosite-category-ads-all",
  229.         "format": "binary",
  230.         "url": "https://raw.githubusercontent.com/SagerNet/sing-geosite/rule-set/geosite-category-ads-all.srs",
  231.         "download_detour": "Proxy"
  232.       },
  233.       {
  234.         "type": "remote",
  235.         "tag": "geosite-geolocation-cn",
  236.         "format": "binary",
  237.         "url": "https://raw.githubusercontent.com/SagerNet/sing-geosite/rule-set/geosite-geolocation-cn.srs",
  238.         "download_detour": "Proxy"
  239.       },
  240.       {
  241.         "type": "remote",
  242.         "tag": "geosite-geolocation-!cn",
  243.         "format": "binary",
  244.         "url": "https://raw.githubusercontent.com/SagerNet/sing-geosite/rule-set/geosite-geolocation-!cn.srs",
  245.         "download_detour": "Proxy"
  246.       },
  247.       {
  248.         "type": "remote",
  249.         "tag": "geoip-cn",
  250.         "format": "binary",
  251.         "url": "https://raw.githubusercontent.com/SagerNet/sing-geoip/rule-set/geoip-cn.srs",
  252.         "download_detour": "Proxy"
  253.       }
  254.     ]
  255.   }
  256. }
复制代码

喜欢的拿去,欢迎进我的脚本群: https://t.me/Devmiston
发表于 2025-6-18 18:14:54 | 显示全部楼层
辣鸡软件,早点抛弃它吧。没见过升级后旧的配置就不能用的,而且还不止一次
发表于 2025-6-18 15:27:48 | 显示全部楼层
没有ipv6差评
 楼主| 发表于 2025-6-18 18:11:33 | 显示全部楼层

mjj就是不一样,这也能差评
您需要登录后才可以回帖 登录 | 注册

本版积分规则

Archiver|手机版|小黑屋|全球主机交流论坛

GMT+8, 2025-9-6 02:59 , Processed in 0.063995 second(s), 10 queries , Gzip On, MemCache On.

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表