MCPcopy
hub / github.com/sshuttle/sshuttle / setup_daemon

Function setup_daemon

tests/client/test_firewall.py:12–26  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

10
11
12def setup_daemon():
13 stdin = io.BytesIO(u"""ROUTES
14{inet},24,0,1.2.3.0,8000,9000
15{inet},32,1,1.2.3.66,8080,8080
16{inet6},64,0,2404:6800:4004:80c::,0,0
17{inet6},128,1,2404:6800:4004:80c::101f,80,80
18NSLIST
19{inet},1.2.3.33
20{inet6},2404:6800:4004:80c::33
21PORTS 1024,1025,1026,1027
22GO 1 - - 0x01 12345
23HOST 1.2.3.3,existing
24""".format(inet=AF_INET, inet6=AF_INET6).encode('ASCII'))
25 stdout = Mock()
26 return stdin, stdout
27
28
29def test_rewrite_etc_hosts(tmpdir):

Callers 2

test_mainFunction · 0.85
mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected