Browse Source

add ipv6 config

dev
BreakWa11 9 years ago
parent
commit
c0d1d666a4
  1. 1
      config.json
  2. 3
      shadowsocks/local.py
  3. 3
      shadowsocks/server.py

1
config.json

@ -9,6 +9,7 @@
"method": "aes-256-cfb", "method": "aes-256-cfb",
"obfs": "http_simple_compatible", "obfs": "http_simple_compatible",
"obfs_param": "", "obfs_param": "",
"ipv6": false,
"fast_open": false, "fast_open": false,
"workers": 1 "workers": 1
} }

3
shadowsocks/local.py

@ -43,6 +43,9 @@ def main():
config = shell.get_config(True) config = shell.get_config(True)
if not config.get('ipv6', False):
asyncdns.IPV6_CONNECTION_SUPPORT = False
daemon.daemon_exec(config) daemon.daemon_exec(config)
try: try:

3
shadowsocks/server.py

@ -54,6 +54,9 @@ def main():
else: else:
config['port_password'][str(server_port)] = config['password'] config['port_password'][str(server_port)] = config['password']
if not config.get('ipv6', False):
asyncdns.IPV6_CONNECTION_SUPPORT = False
if config.get('manager_address', 0): if config.get('manager_address', 0):
logging.info('entering manager mode') logging.info('entering manager mode')
manager.run(config) manager.run(config)

Loading…
Cancel
Save