From 7f2b157956ab1f11137b960ea5aae541d79028dc Mon Sep 17 00:00:00 2001 From: v2ray Date: Sun, 28 Feb 2016 21:11:50 +0100 Subject: [PATCH] Fix OTA in Shadowsocks TCP --- proxy/shadowsocks/shadowsocks.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/proxy/shadowsocks/shadowsocks.go b/proxy/shadowsocks/shadowsocks.go index be91b9bb..59c7968b 100644 --- a/proxy/shadowsocks/shadowsocks.go +++ b/proxy/shadowsocks/shadowsocks.go @@ -184,7 +184,7 @@ func (this *Shadowsocks) handleConnection(conn *hub.TCPConn) { reader := crypto.NewCryptionReader(stream, timedReader) - request, err := ReadRequest(reader, NewAuthenticator(HeaderKeyGenerator(iv, key)), false) + request, err := ReadRequest(reader, NewAuthenticator(HeaderKeyGenerator(key, iv)), false) if err != nil { log.Access(conn.RemoteAddr(), serial.StringLiteral(""), log.AccessRejected, serial.StringLiteral(err.Error())) log.Warning("Shadowsocks: Invalid request from ", conn.RemoteAddr(), ": ", err)