-
Notifications
You must be signed in to change notification settings - Fork 53
Installation Guide
- Requirements
- Installation
- First run & configuration
- Updating pwn-machine
- Frequently Asked Questions (FAQ)
To use the PwnMachine, you don't need many prerequisites. You just need to have docker on your machine. We do not provide a tutorial for installing Docker, you can find all the useful information here: https://docs.docker.com/get-started/.
- Clone the repository locally on your machine
git clone https://github.com/yeswehack/pwn-machine.git- Enter in the repository previously cloned
cd pwn-machine/
If you start to build direclty the project, you will be faced with an error:
${LETS_ENCRYPT_EMAIL?Please provide an email for let's encrypt}" # Replace with your email address or create a .env fileWe highly recommend to create a .env file in the PwnMachine directory and to configure an email. It's used for let's encrypt to have a SSL certificate.
LETS_ENCRYPT_EMAIL="your_email@domain.com"- Build the project (using option
-dwill start the project in background, it's optional). Building can take several minutes (depending on your computer and network connection).
docker-compose up --build -d- Once everything is done on docker side, you should be able to access on the PwnMachine at
http://your_address_ip
Starting pm_powerdns-db_1 ... done
Starting pm_redis_1 ... done
Starting pm_powerdns_1 ... done
Starting pm_filebeat_1 ... done
Recreating traefik ... done
Recreating pm_manager_1 ... done
When you start the PwnMachine for the first time, we ask users to set a new password and 2FA authentication. This is mandatory to continue. You can use Google Authenticator, Authy, Keepass... anything you want that allows you to set up 2FA authentication.
After this, you are ready to use the PwnMachine!
First, we need to create a new DNS zone. Go on DNS > ZONES
Name: `domain.com`
Nameserver: `ns.domain.com.`
Postmaster: `noreply.example.com.`
- Click on the button to save the configuration and the this new DNS zone
Zone: example.com.
Name: *.example.com.
Type: A
- Add a new record
your_adress_ip
-
Click on the button +
-
Click on the button to save the configuration
Now you need to update your DNS servers at your ISP with the one that has just been configured.
For this example, we will create a new subdomain like manager.example.com to expose the PwnMachine interface on it and accessible in HTTPS.
- Go on DOCKER > CONTAINERS
- Right click on pm_manager
- Click on Expose via traefik
- A new window should open:
Name: pm_manager-router
Rule: Host(`manager.example.com`) && PathPrefix(`/`)
Entrypoint: https
Select "Middlewares"
Service: pm_manager-service
---- TLS ----
Cert Resolver: Let's Encrypt staging - DNS
Domain: *.example.com
Now, wait the DNS propagation and after some minutes you should be able to connect on manager.example.com.
To update pwn-machine simply run
git pull && docker-compose up --build -d
This will pull the latest version and only restart the relevant containers.