-
V2Ray的版本?服务端:4.38.3 你看到的异常现象是什么?浏览器直接访问8080端口、v2rayNG/v2rayN内测试均提示400 bad request 你期待看到的正常表现是怎样的?正常使用 请附上你的配置服务端配置: // 在这里附上服务器端配置文件
//备注此配置仅为测试用,本人知晓非加密连接可能带来的安全性问题
{
"log": {
"access": "/var/log/v2ray/access.log",
"error": "/var/log/v2ray/error.log",
"loglevel": "warning"
},
"inbounds": [{
"listen": "0.0.0.0",
"port": "8080",
"protocol": "vmess",
"settings": {
"clients": [{
"id": "(id_1)",
"alterId": 64
},
{
"id": "(id_2)",
"alterId": 16
}
]
},
"streamSettings": {
"network": "ws",
"wsSettings": {
"acceptProxyProtocol": true,
"path": "/ray_v1"
}
}
}
],
"outbounds": [{
"protocol": "freedom",
"settings": {}
},
{
"protocol": "blackhole",
"settings": {},
"tag": "blocked"
}
],
"routing": {
"domainStrategy": "IPIfNonMatch",
"domainMatcher": "mph",
"rules": [{
"type": "field",
"ip": [
"0.0.0.0/8",
"10.0.0.0/8",
"100.64.0.0/10",
"127.0.0.0/8",
"169.254.0.0/16",
"172.16.0.0/12",
"192.0.0.0/24",
"192.0.2.0/24",
"192.168.0.0/16",
"198.18.0.0/15",
"198.51.100.0/24",
"203.0.113.0/24",
"::1/128",
"fc00::/7",
"fe80::/10"
],
"outboundTag": "blocked"
},
{
"type": "field",
"outboundTag": "blocked",
"protocol": [
"bittorrent"
]
},
{
"type": "field",
"domain": ["geosite:category-ads"],
"outboundTag": "blocked"
}
]
}
}
客户端配置: // 在这里附上客户端配置
{
"log": {
"access": "",
"error": "",
"loglevel": "warning"
},
"inbounds": [
{
"tag": "socks",
"port": 10808,
"listen": "127.0.0.1",
"protocol": "socks",
"sniffing": {
"enabled": true,
"destOverride": [
"http",
"tls"
]
},
"settings": {
"auth": "noauth",
"udp": true,
"allowTransparent": false
}
},
{
"tag": "http",
"port": 10809,
"listen": "127.0.0.1",
"protocol": "http",
"sniffing": {
"enabled": true,
"destOverride": [
"http",
"tls"
]
},
"settings": {
"udp": false,
"allowTransparent": false
}
}
],
"outbounds": [
{
"tag": "proxy",
"protocol": "vmess",
"settings": {
"vnext": [
{
"address": "example.com",
"port": 8080,
"users": [
{
"id": "id_1",
"alterId": 64,
"email": "[email protected]",
"security": "auto"
}
]
}
]
},
"streamSettings": {
"network": "ws",
"wsSettings": {
"path": "/ray",
"headers": {
"Host": "example.com"
}
}
},
"mux": {
"enabled": false,
"concurrency": -1
}
},
{
"tag": "direct",
"protocol": "freedom",
"settings": {}
},
{
"tag": "block",
"protocol": "blackhole",
"settings": {
"response": {
"type": "http"
}
}
}
],
"routing": {
"domainStrategy": "IPIfNonMatch",
"rules": [
{
"type": "field",
"inboundTag": [
"api"
],
"outboundTag": "api"
},
{
"type": "field",
"outboundTag": "proxy",
"domain": [
"geosite:google"
]
},
{
"type": "field",
"outboundTag": "direct",
"domain": [
"domain:example-example.com",
"domain:example-example2.com"
]
},
{
"type": "field",
"outboundTag": "block",
"domain": [
"geosite:category-ads-all"
]
}
]
}
}
请附上出错时软件输出的错误日志服务器端错误日志: // 在这里附上服务器端日志
2021/05/01 22:02:48 [Warning] V2Ray 4.38.3 started 客户端错误日志: // 在这里附上客户端日志
V2Ray 4.38.3 (V2Fly, a community-driven edition of V2Ray.) Custom (go1.16.3 windows/amd64)
A unified platform for anti-censorship.
2021/05/02 10:07:45 [Info] main/jsonem: Reading config: stdin:
2021/05/02 10:07:45 [Warning] V2Ray 4.38.3 started
2021/05/02 10:07:46 127.0.0.1:55687 accepted http://cachefly.cachefly.net/10mb.test [proxy10911]
2021/05/02 10:07:51 [Warning] [2977398629] app/proxyman/outbound: failed to process outbound traffic > proxy/vmess/outbound: failed to find an available destination > common/retry: [transport/internet/websocket: failed to dial WebSocket > transport/internet/websocket: failed to dial to (wss://example.com/ray): 400 Bad Request > websocket: bad handshake] > common/retry: all retry attempts failed
2021/05/02 10:07:51 [Warning] [2977398629] proxy/http: failed to read response from cachefly.cachefly.net > io: read/write on closed pipe 请附上访问日志// 在这里附上服务器端日志
(空白) |
Beta Was this translation helpful? Give feedback.
Answered by
wl223600
May 23, 2021
Replies: 2 comments 1 reply
-
客户端 "path": "/ray", |
Beta Was this translation helpful? Give feedback.
1 reply
-
破案了,v2ray写了"acceptProxyProtocol": true,但nginx没写proxy_protocol,此贴完结。 |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
wl223600
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
破案了,v2ray写了"acceptProxyProtocol": true,但nginx没写proxy_protocol,此贴完结。