shadowsocks(服务器端)开启udp 包括shadowsocks manyuser

Home Forums Share your experiences / 经验分享 shadowsocks(服务器端)开启udp 包括shadowsocks manyuser

This topic contains 0 replies, has 1 voice, and was last updated by Super admin Super admin 2 years, 8 months ago.

  • Author
    Posts
  • Super admin
    Keymaster
    #1 Super admin #6075

    某些版本的Shadowsocks python默认在代理码禁用了UDP转发.  需要启用UDP的话需改动一下代码启用之.

    shadowsocks(服务器端)开启udp 包括shadowsocks manyuser

     

    shadowsocks开启UDP方法:修改server_pool.py

    把51行,110行-112行的注释去掉

    self.udp_servers_pool = {}

    udp_server = udprelay.UDPRelay(a_config, self.dns_resolver, False)

    udp_server.add_to_loop(self.loop)

    self.udp_servers_pool.update({port: udp_server})

     

    示例是启用UDP IPV4, 差不多这些代码行的地方还有IPV6的UDP转发代码也被注释了, 如果需要启用的话,也将注释去掉就可以了.

You must be logged in to reply to this topic.

Fonts by Google Fonts. 33 Queries in 0.175 seconds.