全球主机交流论坛

 找回密码
 注册

QQ登录

只需一步,快速开始

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

v2配置咋样改让v4直接走本地的s5

[复制链接]
发表于 2022-5-25 15:50:30 | 显示全部楼层 |阅读模式
hk区想用warp就官方的能开出s5 用的x-ui v4是全球广播的 v6是原生的 用的是x-ui 咋样配能让v4走s5 v6直连 MJJ指点下
发表于 2022-5-25 17:13:22 | 显示全部楼层
东云研究所 发表于 2022-5-25 16:20
我太菜了 这样写全部都走s5 我想访问v4地址就走s5  v6就直连不走 求大佬指点 ...

https://xtls.github.io/Xray-docs-next/config/outbounds/freedom.html#outboundconfigurationobject   
  
  
domainStrategy: "AsIs" | "UseIP" | "UseIPv4" | "UseIPv6"

在目标地址为域名时, 配置相应的值, Freedom 的行为模式如下:

"AsIs": Freedom 通过系统 DNS 服务器解析获取 IP, 向此域名发出连接.
"UseIP"、"UseIPv4" 和 "UseIPv6": Xray 使用 内置 DNS 服务器 解析获取 IP, 向此域名发出连接. 默认值为 "AsIs"。
TIP 1

当使用 "UseIP" 模式,并且 出站连接配置 中指定了 sendThrough 时,Freedom 会根据 sendThrough 的值自动判断所需的 IP 类型,IPv4 或 IPv6。

TIP 2

当使用 "UseIPv4" 或 "UseIPv6" 模式时,Freedom 会只使用对应的 IPv4 或 IPv6 地址。当 sendThrough 指定了不匹配的本地地址时,将导致连接失败。

点评

牛蛙  发表于 2022-5-25 18:17
发表于 2022-5-25 16:09:57 来自手机 | 显示全部楼层
先开个socks的outbound出站,然后路由里面出站写成socks,自己重写下配置完事
 楼主| 发表于 2022-5-25 16:20:32 | 显示全部楼层
厂弟 发表于 2022-5-25 16:09
先开个socks的outbound出站,然后路由里面出站写成socks,自己重写下配置完事

我太菜了 这样写全部都走s5 我想访问v4地址就走s5  v6就直连不走 求大佬指点
  1. {
  2.   "api": {
  3.     "services": [
  4.       "HandlerService",
  5.       "LoggerService",
  6.       "StatsService"
  7.     ],
  8.     "tag": "api"
  9.   },
  10.   "inbounds": [
  11.     {
  12.       "listen": "127.0.0.1",
  13.       "port": 62789,
  14.       "protocol": "dokodemo-door",
  15.       "settings": {
  16.         "address": "127.0.0.1"
  17.       },
  18.       "tag": "proxy-in"
  19.     }
  20.   ],
  21.   "outbounds": [
  22.     {
  23.         "protocol": "socks",
  24.         "tag": "proxy-out",
  25.         "settings": {
  26.           "servers": [{
  27.             "address": "127.0.0.1",
  28.             "port": 40000,
  29.             "users": []
  30.           }]
  31.         }
  32.     },
  33.     {
  34.       "protocol": "freedom",
  35.       "settings": {}
  36.     },
  37.     {
  38.       "protocol": "blackhole",
  39.       "settings": {},
  40.       "tag": "blocked"
  41.     }
  42.   ],
  43.   "policy": {
  44.     "system": {
  45.       "statsInboundDownlink": true,
  46.       "statsInboundUplink": true
  47.     }
  48.   },
  49.   "routing": {
  50.     "rules": [
  51.         {
  52.             "type": "field",
  53.             "inboundTag": [
  54.               "proxy-in"
  55.             ],
  56.             "outboundTag": "proxy-out"
  57.           },
  58.       {
  59.         "inboundTag": [
  60.           "api"
  61.         ],
  62.         "outboundTag": "api",
  63.         "type": "field"
  64.       },
  65.       {
  66.         "ip": [
  67.           "geoip:private"
  68.         ],
  69.         "outboundTag": "blocked",
  70.         "type": "field"
  71.       },
  72.       {
  73.         "outboundTag": "blocked",
  74.         "protocol": [
  75.           "bittorrent"
  76.         ],
  77.         "type": "field"
  78.       }
  79.     ]
  80.   },
  81.   "stats": {}
  82. }
复制代码
发表于 2022-5-25 17:03:47 | 显示全部楼层
m247 机房吗?

点评

yes  发表于 2022-5-25 18:15
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2024-4-30 10:27 , Processed in 0.108039 second(s), 11 queries , Gzip On, MemCache On.

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

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