You need PC or server with Linux and public IPv4 address. You may have to redirect port 22 from your router to your PC if you use the router and NAT.
Installation of proxy on your own Linux PC
- Python 2.7 or Python 3.4 and higher
- cachetools Python library (python-cachetools or python3-cachetools)
- Twisted Python library (python-twisted or python3-twisted)
- Requests Python library (python-requests or python3-requests)
- sshpass (sshpass)
Installation from PyPI
sudo pip install haas-proxy sudo apt-get install sshpass
Installation from Python package
tar -xzf haas-proxy-1.0.tar.gz sudo python haas-proxy-1.0/setup.py install sudo apt-get install sshpass
Installation on Linux with deb packages
sudo dpkg -i python-haas-proxy_1.0_all.deb sudo apt-get install -f
Installation on Linux with rpm packages
sudo dnf install python-haas-proxy-1.0-1.noarch.rpm
Run the proxy
python -m haas_proxy --pidfile /var/run/haas.pid haas_proxy -l /var/log/haas.log --log-level warning --device-token XXX
Generally it is Twisted app so there are options for Twisted and also for our HaaS. Passing
--help on place of twisted options returns help for the
twistd command, on place of HaaS options it returns help for the HaaS.
python -m haas_proxy [TWISTED OPTIONS] haas_proxy [HAAS OPTIONS]
Configuring the router and the PC behind NAT
You need to run proxy on your PC and you must redirect port 22 to your PC on the router. Proxy by default runs on port 2222. Usually you will redirect 22 from the router to 2222 on your PC (to the proxy) and some other public port to 22 on your PC.
Installation on Turris and Turris Omnia
If you want to use HaaS with your Turris, just enable SSH honeypot in the Package management tab in the web interface called reForis. Then fill the token in Honeypot as a Service tab.