设为首页收藏本站

简体中文 繁體中文 English 日本語 Deutsch 한국 사람 بالعربية TÜRKÇE português คนไทย Français

 找回密码
 立即注册
搜索
热搜: 活动 交友 discuz
查看: 51|回复: 8

v2ray 中转求助

[复制链接]

3

主题

19

回帖

55

积分

注册会员

积分
55
发表于 2019-12-9 11:10:53 | 显示全部楼层 |阅读模式
本帖最后由 MurrddoL 于 2019-12-9 11:26 编辑

查找过之前中转的贴子netflix流量中转到另一个
@ymcoming 的回贴如下


如果你落地鸡是SS,也可以不变,唯一变的是中转鸡的V2服务器端的"outboundDetour":
---------------------------------------------------------
[
        {
            "tag": "netflix",
        "protocol": "shadowsocks",
            "settings": {
                "servers": [
                    {
                        "address": "xxx.com",
                        "port": xxx,
                        "method": "aes-256-gcm",
                        "password": "xxxx",
                        "ota": false,
                        "level": 1
                    }
                ]
            }
----------------------------------------------------
我目前用的是v2ray搭建的ss+v2ray-plugin和ss+ws(供quantumult x /kitsunebi使用).
v2ray服务端
[ol]
  • {
  •   "log": {
  •     "access": "/var/log/v2ray/access.log",
  •     "error": "/var/log/v2ray/error.log",
  •     "loglevel": "info"
  •   },
  •   "inbounds": [
  •     { // 第一个进站配置,用于普通的 v2ray-plugin
  •       "port": 10100,
  •       "protocol": "dokodemo-door",
  •       "tag": "wsdoko",
  •       "settings": {
  •         "address": "v1.mux.cool",
  •         "followRedirect": false,
  •         "network": "tcp"
  •       },
  •       "streamSettings": {
  •         "network": "ws",
  •         "wsSettings": {
  •           "path": "/s"
  •         }
  •       }
  •     },
  •     { // 配合上面的进站配置的 SS 协议配置
  •       "port": 8389, // 此处的端口实际用不到但必须设置
  •       "protocol": "shadowsocks",
  •       "settings": {
  •         "method": "aes-128-gcm",
  •         "ota": false,
  •         "password": "Fuck高墙",
  •         "network": "tcp,udp"
  •       },
  •       "streamSettings": {
  •         "network": "domainsocket"
  •       }
  •     },
  •     {  // 第三个进站配置,用于 Quantumult X 的 v2ray-plugin
  •       "port": 10200,
  •       "protocol": "shadowsocks",
  •       "settings": {
  •         "method": "aes-128-gcm",
  •         "ota": false,
  •         "password": "Fuck高墙",
  •         "network": "tcp,udp"
  •       },
  •       "streamSettings": {
  •         "network": "ws",
  •         "wsSettings": {
  •           "path": "/x"
  •         }
  •       }
  •     }
  •   ],
  •   "outbounds": [
  •     {
  •       "protocol": "freedom",
  •       "settings": {},
  •       "tag": "direct"
  •     },
  •     {
  •       "protocol": "blackhole",
  •       "settings": {},
  •       "tag": "blocked"
  •     },
  •     { // 用于普通 v2ray-plugin
  •       "protocol": "freedom",
  •       "tag": "ssmux",
  •       "streamSettings": {
  •         "network": "domainsocket"
  •       }
  •     }
  •   ], // 用于普通 v2ray-plugin
  •   "transport": {
  •     "dsSettings": {
  •       "path": "/var/run/ss-loop.sock"
  •     }
  •   },
  •   "routing": {
  •     "rules": [
  •       { // 用于普通 v2ray-plugin
  •         "type": "field",
  •         "inboundTag": [
  •           "wsdoko"
  •         ],
  •         "outboundTag": "ssmux"
  •       },
  •       {
  •         "type": "field",
  •         "ip": [
  •           "geoip:private"
  •         ],
  •         "outboundTag": "blocked"
  •       }
  •     ]
  •   }
  • }[/ol]复制代码

    caddy 配置
    [ol]
  • server {
  •         listen 80;
  •         server_name banana-zone.me;##你的域名
  •         #rewrite ^(.*)$  https://$host$1 permanent; ##这句是强制HTTP跳转HTTPS
  •         #rewrite ^/(.*) https://www.microsoft.com permanent;
  • }
  • #上面这个我是让http直接跳转到/www.microsoft.com permanent,会导致shadowrocket连不了
  • server
  •     {
  •         listen 443;
  •         ssl on;
  •         server_name banana-zone.me;##你的域名
  •         ssl_certificate  /root/ssl/banana-zone.me.fullchain.cer;  ##证书位置
  •         ssl_certificate_key /root/ssl/banana-zone.me.key;         ##证书位置
  •         ssl_session_timeout 5m;
  •         ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
  •         ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:HIGH:!aNULL:!MD5:!RC4:!DHE;
  •         ssl_prefer_server_ciphers on;
  •         index index.html index.htm index.php;
  • #上面是Nginx的https配置
  •         location / {
  •         proxy_pass  https://www.microsoft.com;
  •     }
  • #这个是反向代理,即浏览banana-zone.me时会跳转到www.microsoft.com
  •         location /s { # path
  •         proxy_redirect off;
  •         proxy_pass http://127.0.0.1:10100; # Shadowsocks 或 VMess 配置里的端口
  •         proxy_http_version 1.1;
  •         proxy_set_header Upgrade $http_upgrade;
  •         proxy_set_header Connection "upgrade";
  •         proxy_set_header Host $http_host;
  •     }
  • #上面是适用于shadowrocket的配置
  •         location /x { # path
  •         proxy_redirect off;
  •         proxy_pass http://127.0.0.1:10200; # Shadowsocks 或 VMess 配置里的端口
  •         proxy_http_version 1.1;
  •         proxy_set_header Upgrade $http_upgrade;
  •         proxy_set_header Connection "upgrade";
  •         proxy_set_header Host $http_host;
  •     }
  • }
  • #上面是适用于Quantumult X的配置
  • #看个人需求,需要哪个要哪个或者两个一起
  • [/ol]复制代码
    或者caddy
    [ol]
  • example.com { # 你的域名
  •     tls [email protected] # 你的邮箱用于申请 SSL 证书
  •     gzip
  •     # root /var/www/example.com
  •     proxy / www.microsoft.com # 需要反向代理网站的网址
  •     proxy /s localhost:10100 { # 用于 v2ray-plugin 的 path
  •         websocket
  •         header_upstream -Origin
  •     }
  •     proxy /x localhost:10200 { # 可以多加一个给 Quantumult X
  •         websocket
  •         header_upstream -Origin
  •     }
  • }
  • [/ol]复制代码


    问题来了,中转鸡的V2服务器端怎么添加ss+v2ray-plugin
  • 回复

    使用道具 举报

    1

    主题

    109

    回帖

    241

    积分

    中级会员

    积分
    241
    发表于 2019-12-9 11:13:36 | 显示全部楼层
    好奇一下,lz v2+ws+tls能成功中转么
    回复

    使用道具 举报

    5

    主题

    60

    回帖

    141

    积分

    注册会员

    积分
    141
    发表于 2019-12-9 11:20:59 | 显示全部楼层
    没意义啊,你直接中转v2+ws+tls就可以了啊,在落地服务器上再加个inbound,你中转机的inbound支持ss+v2-plugin不就可以了
    回复

    使用道具 举报

    114

    主题

    1732

    回帖

    3896

    积分

    论坛元老

    积分
    3896
    发表于 2019-12-9 11:24:12 | 显示全部楼层
    你本地怎么链接服务端的配置outbounds复制到中转去添加个tag,然后中转的路由设置下geosite:netflix使用这个tag就行了吧。没测试过。我是本地用wss然后中转机把netflix再转出去一次,其它直接freedom
    回复

    使用道具 举报

    3

    主题

    19

    回帖

    55

    积分

    注册会员

    积分
    55
     楼主| 发表于 2019-12-9 11:27:07 | 显示全部楼层

    勇气不足 发表于 2019-12-9 11:13

    好奇一下,lz v2+ws+tls能成功中转么

    之前的贴子有
    https://www.52.ht/thread-551706-1-1.html
    回复

    使用道具 举报

    3

    主题

    19

    回帖

    55

    积分

    注册会员

    积分
    55
     楼主| 发表于 2019-12-9 11:13:00 | 显示全部楼层

    cznet 发表于 2019-12-9 11:20

    没意义啊,你直接中转v2+ws+tls就可以了啊,在落地服务器上再加个inbound,你中转机的inbound支持ss+v2-plu ...

    我落地服务器也配置的ss+v2ray 和 ss ws,技术讨论
    回复

    使用道具 举报

    3

    主题

    19

    回帖

    55

    积分

    注册会员

    积分
    55
     楼主| 发表于 2019-12-9 11:28:29 | 显示全部楼层

    zdszf 发表于 2019-12-9 11:24

    你本地怎么链接服务端的配置outbounds复制到中转去添加个tag,然后中转的路由设置下geosite:netflix使用这 ...

    问题是 我现在客户端用的是shadowsocks.exe + v2ray.exe插件 ss +ws 是手机走的shadowsocks配置
    回复

    使用道具 举报

    5

    主题

    60

    回帖

    141

    积分

    注册会员

    积分
    141
    发表于 2019-12-9 11:20:00 | 显示全部楼层
    中转机和落地机用什么协议通讯可以改啊,中转机当然也可以支持你现在的客户端设置啊
    回复

    使用道具 举报

    3

    主题

    19

    回帖

    55

    积分

    注册会员

    积分
    55
     楼主| 发表于 2019-12-9 11:30:20 | 显示全部楼层
    "

    这个知道,没什么办法的话,落地机到时单独配置一个简单的SS解决
    回复

    使用道具 举报

    您需要登录后才可以回帖 登录 | 立即注册

    本版积分规则

    Archiver|手机版|小黑屋|Discuz! X

    GMT+8, 2025-12-20 16:34 , Processed in 0.016806 second(s), 4 queries , Gzip On, Redis On.

    Powered by Discuz! X3.5

    © 2001-2025 Discuz! Team.

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