- Get the reverse shell in netcat
- check python support in the target system
which python- If your terminal is using zsh, then you need to switch to bash
| #!/bin/bash | |
| # Global variable declarations | |
| format="plain" | |
| directories=() | |
| current_directory=`pwd` | |
| report_directory="${current_directory}/report/" | |
| fresh_report_directory="0" | |
| # usage |
| # Create the container - we run 'echo' in the container, and reuse the same as we will be running later | |
| docker run -d -v /data --name redis.data dockerfile/redis echo Data-only container for Redis | |
| # the data container doesn't show up - nothing is running | |
| docker ps | |
| # will show 'redis.data', but as stopped | |
| docker ps -a | |
| # start redis, attach to 'redis.data' | |
| docker run -d -p 6379:6379 --volumes-from redis.data --name ca.redis.1 dockerfile/redis |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000