AWS EC2 User-Data for basic Cowrie Build
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# based on https://cowrie.readthedocs.io/en/latest/INSTALL.html | |
apt -y update | |
DEBIAN_FRONTEND=noninteractive apt -y upgrade | |
apt -y install git python-virtualenv libssl-dev libffi-dev build-essential libpython3-dev python3-minimal authbind virtualenv | |
adduser --disabled-password --gecos "" cowrie | |
sudo -H -u cowrie /bin/bash -s << EOF >> /home/cowrie/heredoc.out | |
cd /home/cowrie/ | |
git clone http://github.com/cowrie/cowrie | |
cd /home/cowrie/cowrie | |
virtualenv --python=python3 cowrie-env | |
source cowrie-env/bin/activate | |
pip install --upgrade pip | |
pip install --upgrade -r requirements.txt | |
bin/cowrie start | |
EOF | |
# runs with cowrie.cfg.dist - will need tuning to specific usecase |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment