Test cases for Socks end 2 end.

This commit is contained in:
V2Ray
2015-11-06 13:08:20 +01:00
parent fdc72ed8c9
commit e60fcba4b3
3 changed files with 240 additions and 0 deletions
+2
View File
@@ -145,6 +145,8 @@ func (server *SocksServer) handleSocks5(reader *v2net.TimeOutReader, writer io.W
if request.Command == protocol.CmdBind || request.Command == protocol.CmdUdpAssociate {
response := protocol.NewSocks5Response()
response.Error = protocol.ErrorCommandNotSupported
response.Port = uint16(0)
response.SetIPv4([]byte{0, 0, 0, 0})
responseBuffer := alloc.NewSmallBuffer().Clear()
response.Write(responseBuffer)