demonic

Like demo, but more demonic!

This is an xterm.js-powered web app that runs a shell I wrote called devilish in a sandboxed environment. It’s purpose is to show off some of the features of devilish without requiring users to download, compile, and run it on their own machine. I originally wrote demo to do the same thing, but ran into difficulty with ASCII escape sequences and other terminal-specific features. xterm.js takes care of that, and allows anyone to explore in a safe, non-persistent sandbox. Networking is explicitly disabled, but Bash, tmux, and vim (among others) are installed and ready to use.

Give it a Spin!

Try it out here.




Installation

0. Prerequisites

python 3 :: for running the server.

npm :: for installing the dependencies.

firejail :: for running programs in a sandboxed chroot environment.

git :: for a quick git clone.

If you are running Windows, the above utilities will be packaged in any of the following: babun, cmder, or Linux Subsystem for Windows. Take your pick! : )

The above utilities should be installed (or readily available) if you are running a Unix derivative (such as Linux, macOS, or any of the BSD’s).

1. Quickstart

# clone the git repo
git clone https://github.com/lbeckman314/demonic

# enter directory
cd demonic

# install node.js dependencies
npm install xterm

# create virtual environment
python3 -m venv virtual

# activate virtual environment
source virtual/bin/activate

# install python dependencies
pip install terminado

# run server
python app.py

# then you can connect to the server from a client at HOST_ADDRESS:8282 (e.g. https://localhost:8282).


Uninstallation

0. Delete the directory/folder.

# remove this directory
rm -rfI demonic