monkey/monkey_island
Itay Mizeretz bebe1dab4d Update island readme 2017-09-12 14:25:47 +03:00
..
cc sambacry works 2017-08-31 18:40:42 +03:00
deb-package Fix deb package requirement 2017-08-13 17:13:39 +03:00
linux Merge branch 'master' of https://github.com/guardicore/monkey 2016-08-03 09:24:55 +03:00
windows Add batch to execute entire server 2017-09-10 13:17:47 +03:00
readme.txt Update island readme 2017-09-12 14:25:47 +03:00
requirements.txt Fix deb package requirement 2017-08-13 17:13:39 +03:00

readme.txt

How to set C&C server:

---------------- On Windows ----------------:
1. Create bin folder
	1.1. create folder "bin" under monkey_island
2. Place portable version of Python 2.7
	2.1. Download and install from: https://www.python.org/download/releases/2.7/
	2.2. Download & Run get-pip.py from: https://bootstrap.pypa.io/get-pip.py
	2.3. Install required python libraries using "python -m pip install -r monkey_island\requirements.txt"
	2.4. Copy Contents from Installation path (Usually C:\Python27) to monkey_island\bin\Python27
	2.5. Copy Python27.dll from System32 folder (Usually C:\Windows\System32) to monkey_island\bin\Python27
	2.6. (Optional) You may uninstall Python27 if you like.
3. Place portable version of mongodb
	3.1. Download from: http://downloads.mongodb.org/win32/mongodb-win32-x86_64-2008plus-ssl-latest.zip
	3.2. Extract contents from bin folder to monkey_island\bin\mongodb.
4. Place portable version of OpenSSL
	4.1. Download from: http://downloads.sourceforge.net/gnuwin32/openssl-0.9.8h-1-bin.zip
	4.2. Extract content from bin folder to monkey_island\bin\openssl
5. Download and install Microsoft Visual C++ Redisutable for Visual Studio 2017
	5.1. Download and install from: https://go.microsoft.com/fwlink/?LinkId=746572
6. Generate SSL Certificate
	6.1. run create_certificate.bat when your current working directory is monkey_island
7. Put chaos monkey binaries in monkey_island\cc\binaries (create folder if it doesn't exist):
	monkey-linux-64 - monkey binary for linux 64bit
	monkey-linux-32 - monkey binary for linux 32bit
	monkey-windows-32.exe - monkey binary for windows 32bit
	monkey-windows-64.exe - monkey binary for windows 64bit

How to run:
1. start monkey_island\windows\run_server.bat (when your current working directory is monkey_island)
2. to clear db, run clear_db.bat

---------------- On Linux ----------------:
1. Create the following directories:
    sudo mkdir /var/monkey_island
    sudo chmod 777 /var/monkey_island
    mkdir -p /var/monkey_island/bin/mongodb
    mkdir -p /var/monkey_island/db
    mkdir -p /var/monkey_island/cc/binaries

2. Install the following packages:
	sudo pip install flask
	sudo pip install Flask-Pymongo
	sudo pip install Flask-Restful
	sudo pip install python-dateutil
	
3. put monkey binaries in /var/monkey_island/cc/binaries
    monkey-linux-64 - monkey binary for linux 64bit
	monkey-linux-32 - monkey binary for linux 32bit
	monkey-windows-32.exe - monkey binary for windows 32bit
	monkey-windows-64.exe - monkey binary for windows 64bi

4. Download MongoDB and extract it to /var/monkey_island/bin/mongodb
    for debian64 - https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-debian71-3.0.7.tgz
    for ubuntu64 14.10 - https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-ubuntu1410-clang-3.0.7.tgz
    find more at - https://www.mongodb.org/downloads#production
	untar.gz with: tar -zxvf filename.tar.gz -C /var/monkey_island/bin/mongodb
	(make sure the content of the mongo folder is in this directory, meaning this path exists:
		/var/monkey_island/bin/mongodb/bin)

5. install OpenSSL
    sudo apt-get install openssl

6. Generate SSL Certificate, Run create_certificate.sh (located under /linux)

7. Copy monkey island server to /var/monkey_island:
    cp -r [monkey_island_source]/cc /var/monkey_island/

How to run:
1. run run.sh
2. to clear db, run clear.db.sh