rs-loves-bugs / xsshunter

MIT License
158 stars 42 forks source link

A working and easy to install fork of XSSHunter

Fork features

It works and it's simple to setup: the current as of March 1, 2023 XSSHunter repository is not in a deploy-able state. This fork fixes that.

Single user support and multi user support: you can setup XSSHunter in either single user mode with only your account or in multi user mode using either the env file or with Google OAuth(allowing only the Gmail accounts you want to login). Compared, the original XSSHunter version only allows Google OAuth login and does not restrict the Gmail accounts allowed(all Gmail accounts can create an user and login).

Full Trufflehog support: Detect secrets on the page your payload fired. The original version implemented simple regex checks for AWS, GCP and Slack keys. This fork supports all the current ~750 detectors from Trufflehog.

No blurred screenshots

Local Storage: Read all data stored in Local Storage for the page the payload fired on

Slack, Discord, Telegram and custom notifications: this fork will send notifications to Slack, Discord and to your custom HTTP hook when a XSS triggers. Compared, the original XSSHunter version only sends email notifications.

Twitter  Mastodon


Requirements


Setup

Login as root on your server and run these commands:

# clone the repository
git clone https://github.com/rs-loves-bugs/xsshunter
# enter the directory
cd xsshunter
# enabled the environment variables file
cp env.example .env

Edit the following variables in the .env file:

Run this command to setup XSSHunter:

# build and start the containers
docker compose up -d

When this finishes you can login on https://admin.example.com with the panel username and password. Go ahead and setup notifications and other settings in Settings.

Have fun!


Upgrading

Upgrading should be as simple as running these 4 commands:

# change directory to xsshunter
cd xsshunter
# stop the containers
docker compose down
# pull the update from Github
git pull
# build and start the containers
docker compose up -d --build

Optional Setup

Everytime you edit the .env you will need to restart the containers:

# edit the .env file in your favorite editor
nano .env 
# stop the containers
docker compose down
# start the containers
docker compose up -d

If you want email notifications(Discord/Slack notifications are better, Sendgrid is not really worth the trouble):

Run this command to setup XSSHunter:

# build and start the containers
docker compose up -d xsshunterexpress-db xsshunterexpress-service xsshunterexpress-trufflehog

You can use apache.conf or nginx.conf config files from this repository as guides to setup vhosts on your web server.


Credits