PySocket
PySocket copied to clipboard
关于Limit_Clients udp 在 shadowsocks 下的bug。
安卓端在开启优酷客户端并且开启了udp转发的情况下关闭了ss之后服务端会出现如下错误,但不影响使用。
2017-03-20 02:36:39 DEBUG send udp response to 192.168.*.*:57525
2017-03-20 02:36:40 ERROR [Errno 10054]
Traceback (most recent call last):
File "E:\github\shadowsocks\shadowsocks\../shadowsocks\eventloop.py", line 216
, in run
handler.handle_event(sock, fd, event)
File "E:\github\shadowsocks\shadowsocks\../shadowsocks\udprelay.py", line 333,
in handle_event
self._handle_server()
File "E:\github\shadowsocks\shadowsocks\../shadowsocks\udprelay.py", line 151,
in _handle_server
data, r_addr = server.recvfrom(BUF_SIZE)
File "E:\github\shadowsocks\shadowsocks\../socket.py", line 84, in <lambda>
setattr(self, method_name, types.MethodType(lambda *args, **kwds: new_method
(method, *args, **kwds), self, self))
File "E:\github\shadowsocks\shadowsocks\../socket.py", line 132, in new_recvfr
om
return_value = orgin_method(*args, **kwds)
error: [Errno 10054]
目测是优酷客户端的udp连接跟一般的不一样,估计是实现了一个类似tcp的效果。具体原因有空再找吧。
BUG 2:
火狐浏览器开启了dns转发后会出现连接长时间不会释放的问题,具体原因不详。
可能要放弃利用tcp 的close 方法来清理客户端列表的方式了。。。因为有 UDP associate 的存在。估计这些BUG都是它引起的。
看来是我弄错了,优酷的bug应该是正常现象,只有在开了debug的情况下才会显示报错的信息。至于火狐的,暂时还没弄明白。