Open Kein opened 3 months ago
So yeah, it looks like SOCKS5 protocol is poorly imlplemented.
Disabling
"settings": { "udp": false }
and
"sniffing":
{
"enabled": false,
"destOverride": ["http", "tls"]
},
fixes the issue because it appears to be unable to rely UDP packets as a proper SOCKS proxy (including proxying DNS queries, as per Firefox capability). Even if it did I assume it would not be shaped by vmess
anyway.
Which leaves v2ray
standalone to be typical TCP-only half-working SOCKS5 proxy (essential;ly a HTTP proxy) whcih is real shame, in a year of our lord 2024.
I suppose without Shadowsocks on top of v2ray (as a pluggable transport) it is not very unusable, but then you have to ask yourself why use v2ray with shadowsocks when you have CLOACK
plugin for the latter.
Actually, I've tested this more without UDP mode and can confirm this has nothing to do with UDP - it just fails with Discord uploads at all.
It is almost impossible to use SOCKS5 UDP Associate without transparent proxy method because in the real world almost no software that supports SOCKS5 actually supports SOCKS5 UDP Associate (including but not limiting to Chrome/Firefox). And your log shows nothing about UDP traffic. If you can fix something by turning off sniffing, usually it means that some traffic has mismatched SNI (or HTTP Host, or something recognized as them) and destination.
If you can fix something by turning off sniffing, usually it means that some traffic has mismatched SNI (or HTTP Host, or something recognized as them) and destination.
I actually can't, I was wrong. It was just a coincidence that the bug did not appear after I disabled sniffing and UDP and restarted proxy. Right now I'm running with both of these options enabled and it works, but randomly the bug re-appears. It is not related to any of the settings I've tried, it is a fundamental issue of the v2ray vmess protocol it seems.
The worst part, as you have seen, logs in debug
mode show nothing. The file upload just silently fails. It is definitely v2ray issue, because if I switch to Shadowsocks in the same session it immediately start working without a hitch.
What version of V2Ray are you using?
v5.14.1
What's your scenario of using V2Ray?
Bypass RU/CIS blackbox DPI that throttles any traffic it does not like.
What problems have you encountered?
Unable to upload pictures on some resources, namely Discord
What's your expectation?
it just works, like Shadowsocks.
Please attach your configuration here
CLIENT:
SERVER:
Please attach error logs here
SERVER
error.log
CLIENT
access.log
error.log
Other configurations (such as Nginx) and logs here
N/A
Additional info
V2ray used in standalone in SOCKS5 mode. Firefox 123 in FULL SOCKS5 mode (including UDP proxying of DNS)
ANY attempt tp upload any picture on Discord from local PC fails. Upload works on something like
imgur.com
without issues. Switching toShadowsocks
on the SAME VPS and the same client pc works flawlessly. The issue appears to be with v2ray SOCKS implementation (?, it is lacking?)