riobard / go-shadowsocks2

Experimental Shadowsocks in Go. Stable fork at https://github.com/shadowsocks/go-shadowsocks2
Apache License 2.0
719 stars 1.67k forks source link

Error: "too many colons in address" in windows 10 #28

Closed bjzhang closed 4 years ago

bjzhang commented 6 years ago

First of all, thanks for your work. I try this in Linux. It works in both client and server. But when I try to run the client in windows10. It says "too many colons in address". The command is as follows:

shadowsocks2-win64.exe -c 'ss://AEAD_CHACHA20_POLY1305:bar@1.1.1.1:8488' -verbose -socks :1080 -u -udptun :8053=8.8.8.8:53,:8054=8.8.4.4:53 -tcptun :8053=8.8.8.8:53,:8054=8.8.4.4:53 2018/09/02 09:30:07 udp.go:81: UDP server address error: address 'ss://AEAD_CHACHA20_POLY1305:bar@1.1.1.1:8488': too many colons in address 2018/09/02 09:30:07 udp.go:27: UDP server address error: address 'ss://AEAD_CHACHA20_POLY1305:bar@1.1.1.1:8488': too many colons in address 2018/09/02 09:30:07 tcp.go:24: TCP tunnel :8054 <-> 'ss://AEAD_CHACHA20_POLY1305:bar@1.1.1.1:8488' <-> 8.8.4.4:53 2018/09/02 09:30:07 tcp.go:13: SOCKS proxy :1080 <-> 'ss://AEAD_CHACHA20_POLY1305:bar@1.1.1.1:8488' 2018/09/02 09:30:07 udp.go:27: UDP server address error: address 'ss://AEAD_CHACHA20_POLY1305:bar@1.1.1.1:8488': too many colons in address 2018/09/02 09:30:07 tcp.go:24: TCP tunnel :8053 <-> 'ss://AEAD_CHACHA20_POLY1305:bar@1.1.1.1:8488' <-> 8.8.8.8:53

If I change ss://AEAD_CHACHA20_POLY1305:bar@1.1.1.1:8488 to ss://AEAD_CHACHA20_POLY1305, there is no above error. So, I suppose there are some escape issues. But I am not familar with the escape characters in windows10. I am confusing after I read the the following link. And there is similar issue in docker in 2016. It still opens.

Thanks.

riobard commented 6 years ago

Seems like a Go problem, not specific to go-ss2. I don't use Windows so if anyone knows how to fix it, please send a pull request.

bjzhang commented 6 years ago

I avoid it by using Linux(ubuntu) on windows. Still hope someone could fix it.

silverzhaojr commented 6 years ago

Try double quote instead of single quote.

riobard commented 4 years ago

Try replace single quotes with double quotes.