Compare commits

...

11 Commits

Author SHA1 Message Date
Dane Mealey bacc61d3d8
Merge 8b2affd0ad into dcf527fd86 2024-09-26 07:03:53 +00:00
Peaks dcf527fd86
Merge pull request #65 from BuffBaby253/master
SharkNetSniffer
2024-09-17 18:02:11 -04:00
BuffBaby253 6f8d44d068
Update payload.sh 2024-09-17 12:19:41 -07:00
BuffBaby253 cb64802ff5
Update payload.sh
added variable
2024-09-16 12:25:56 -07:00
BuffBaby253 26040becb0
Create payload.sh 2024-09-15 08:43:02 -07:00
BuffBaby253 4c5fdf62a1
Delete payloads/library/Wireshark PCAP Capture directory 2024-09-15 08:36:23 -07:00
BuffBaby253 4d3431c2e4
Add files via upload 2024-01-11 21:27:04 -08:00
n0m4d1k 8b2affd0ad Auto update broken .conf files 2023-07-27 14:02:15 -04:00
n0m4d1k 17cb024c35 Modified payload to automatically change distfeeds and customfeeds 2023-07-27 13:55:14 -04:00
n0m4d1k ceb3ab6906 Added corrected files and README 2023-07-27 11:13:24 -04:00
n0m4d1k 0c3af2ecae Adding info 2023-07-27 11:11:23 -04:00
5 changed files with 149 additions and 0 deletions

View File

@ -0,0 +1,46 @@
#!/bin/bash
#
# Title: Wireshark PCAP Capture & Examine
# Author: BuffBaby253
# Version: 1.1
#
# Description: uses tcpdump to capture network traffic for 1 minute and saves into pcap
# into loot storage folder for further analysis in Wireshark
#
# Note: If you want to extend the time, change the amount of seconds in line 38
#
# LED SETUP making loot directory and waiting for an ip address from DHCP
# LED ATTACK capturing packets
# LED FINISH the Shark Jack is finished and you can now download saved pcaps to open in Wireshark
LOOT_DIR=/root/loot/pcaps
INTERFACE="eth0"
seconds=60
# preparing for capture
LED SETUP
# setting up loot directory
mkdir -p $LOOT_DIR
COUNT=$(($(ls -l $LOOT_DIR/*.txt | wc -l)+1))
# waiting for ip address
NETMODE DHCP_CLIENT
while [ -z "$IPADDR" ]; do sleep 1 && IPADDR=$(ifconfig eth0 | grep "inet addr"); done
LED ATTACK
# using tcpdump to capture network traffic and save to loot directory
tcpdump -i $INTERFACE -w $LOOT_DIR/net-traffic_$COUNT.txt &
# sleep command will let it run for amount of seconds selected
sleep $seconds
# end capture
killall tcpdump
# the work is done and you can unplug
LED FINISH

View File

@ -0,0 +1,32 @@
# Title: Update enabler
### Author: n0m4d1k
### Version: 2.0
### Description:
This payload sets the shark jack to DHCP_CLIENT mode toallow access to the internet and then enables SSH on the shark jack allowing you to SSH into the device an perform updates or download additional tools. It also automatically updates the distfeeds.conf and customfeeds.conf file to fix update errors.
Note:
As of 07/27/2023 the /etc/opkg/distfeeds.conf file that comes with the stock shark jack is incorrect and will error out. I have also included the corrected files in this directory. To fix this manually remove the original text and add the below.
```
src/gz openwrt_core http://downloads.openwrt.org/releases/18.06.0/targets/ramips/mt76x8/packages
src/gz openwrt_base http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/base
src/gz openwrt_luci http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/luci
src/gz openwrt_packages http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/packages
src/gz openwrt_routing http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/routing
src/gz openwrt_telephony http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/telephony
```
Additionally, there is currently nothing in the Hak5 packages repo so this will also throw and error.
to fix this you can simply comment out the second line in the /etc/opkg/customfeeds.conf
Keep in mind that the shark jack will most likely have a 10.42.0.0/24 IP address and you will need to SSH to that. You can find the new IP using nmap by running the below command.
`nmap -sn 10.42.0.0/24`
#### LED Key:
LED SETUP (Magenta)... Setting NETMODE to DHCP_CLIENT and starting SSH
LED Green... Ready

View File

@ -0,0 +1,2 @@
# Hak5 Packages
# src/gz 1907_shark http://downloads.hak5.org/packages/shark/1907

View File

@ -0,0 +1,6 @@
src/gz openwrt_core http://downloads.openwrt.org/releases/18.06.0/targets/ramips/mt76x8/packages
src/gz openwrt_base http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/base
src/gz openwrt_luci http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/luci
src/gz openwrt_packages http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/packages
src/gz openwrt_routing http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/routing
src/gz openwrt_telephony http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/telephony

View File

@ -0,0 +1,63 @@
#!/bin/bash
#
# Title: Update enabler
# Author: n0m4d1k
# Version: 2.0
#
# Description: This payload sets the shark jack to DHCP_CLIENT mode to
# allow access to the internet and then enables SSH on the
# shark jack allowing you to SSH into the device an perform updates or download additional tools
# It also automatically updates the distfeeds.conf and customfeeds.conf file to fix update errors.
#
# Note: As of 07/27/2023 the /etc/opkg/distfeeds.conf file that comes with the stock shark jack is incorrect and will error out.
# to fix this remove the original text and add the below.
#
# src/gz openwrt_core http://downloads.openwrt.org/releases/18.06.0/targets/ramips/mt76x8/packages
# src/gz openwrt_base http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/base
# src/gz openwrt_luci http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/luci
# src/gz openwrt_packages http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/packages
# src/gz openwrt_routing http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/routing
# src/gz openwrt_telephony http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/telephony
#
# Additionally, there is currently nothing in the Hak5 packages repo so this will also throw and error.
# to fix this you can simply comment out the second line in the /etc/opkg/customfeeds.conf
#
# Keep in mind that the shark jack will most likely have a 10.42.0.0/24 IP address and you will need to SSH to that.
#
# LED SETUP (Magenta)... Setting NETMODE to DHCP_CLIENT and starting SSH
# LED Green... Ready
LED SETUP
# Variables
DISTFEEDS=/etc/opkg/distfeeds.conf
CUSTOMFEEDS=/etc/opkg/customfeeds.conf
# Setup DHCP client, and determine subnet
NETMODE DHCP_CLIENT
# Start SSH server
/etc/init.d/sshd start
sleep 10
# Wait until Shark Jack has an IP address
while [ -z "$IPADDR" ]; do sleep 1 && IPADDR=$(ifconfig eth0 | grep "inet addr"); done
LED ATTACK
# Fixes config files
mv $DISTFEEDS /etc/opkg/distfeeds.conf.og
touch $DISTFEEDS
echo "src/gz openwrt_core http://downloads.openwrt.org/releases/18.06.0/targets/ramips/mt76x8/packages" >> $DISTFEEDS
echo "src/gz openwrt_base http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/base" >> $DISTFEEDS
echo "src/gz openwrt_luci http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/luci" >> $DISTFEEDS
echo "src/gz openwrt_packages http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/packages" >> $DISTFEEDS
echo "src/gz openwrt_routing http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/routing" >> $DISTFEEDS
echo "src/gz openwrt_telephony http://downloads.openwrt.org/releases/18.06.0/packages/mipsel_24kc/telephony" >> $DISTFEEDS
mv $CUSTOMFEEDS /etc/opkg/customfeeds.conf.og
touch $CUSTOMFEEDS
echo "# Hak5 Packages" >> $CUSTOMFEEDS
echo "# src/gz 1907_shark http://downloads.hak5.org/packages/shark/1907" >> $CUSTOMFEEDS
LED FINISH