Commit fcd18dd8 authored by Michal Horejsek's avatar Michal Horejsek

Do not check host key

parent 7601418e
......@@ -3,7 +3,7 @@
# Normally it would be just twistd but it runs always with Python 2 in this moment.
TWISTD_CMD=-c "from twisted.scripts.twistd import run; run()"
TWISTD_RUN_ARGS=-l haas.log --pidfile haas_proxy -p 2220 -d 42
TWISTD_RUN_ARGS=-l haas.log --pidfile haas_proxy -d 42
FPM_CMD=fpm -f -d sshpass -m '' -s python
FPM_CMD_PY2=${FPM_CMD} --python-bin /usr/bin/python2 --python-package-name-prefix python
......@@ -37,10 +37,12 @@ test:
python3 -m pylint --rcfile=pylintrc haas_proxy twisted/plugins/
run-py2: run-kill
sudo python2 ${TWISTD_CMD} ${TWISTD_RUN_ARGS}
run-py3: run-kill
sudo python3 ${TWISTD_CMD} ${TWISTD_RUN_ARGS}
kill `cat` >/dev/null || true
# Debian packages
......@@ -139,6 +139,8 @@ class ProxySSHSession(SSHSessionForUnixConchUser):
'-p', self.mangled_password,
'-o', 'UserKnownHostsFile=/dev/null',
'-o', 'StrictHostKeyChecking=no',
'-p', str(self.cmd_args.honeypot_port),
'{}@{}'.format(force_text(self.avatar.username), self.cmd_args.honeypot_host),
......@@ -52,7 +52,13 @@ def test_force_text(value, expected):
def test_honeypot_ssh_arguments(proxy_ssh_session):
assert proxy_ssh_session.honeypot_ssh_arguments[3:] == ['ssh', '-p', '2222', 'user@localhost']
assert proxy_ssh_session.honeypot_ssh_arguments[3:] == [
'-o', 'UserKnownHostsFile=/dev/null',
'-o', 'StrictHostKeyChecking=no',
'-p', '2222',
def test_mangle_password(proxy_ssh_session):
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment