Skip to content

Commit

Permalink
Fixed all of the Firefox issues, require root privs to run update.
Browse files Browse the repository at this point in the history
  • Loading branch information
leebaird committed Aug 22, 2021
1 parent 59d6eb7 commit 5261255
Show file tree
Hide file tree
Showing 20 changed files with 55 additions and 115 deletions.
4 changes: 1 addition & 3 deletions active.sh
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,5 @@ echo "***Scan complete.***"
echo
echo
echo -e "The supporting data folder is located at ${YELLOW}$home/data/$domain/${NC}\n"
XAUTHORITY=/root/.Xauthority firefox $home/data/$domain/index.htm &
echo
echo
firefox-esr $home/data/$domain/index.htm &

6 changes: 0 additions & 6 deletions config/zshrc
Original file line number Diff line number Diff line change
Expand Up @@ -30,17 +30,11 @@ alias update='/opt/discover/update.sh'
#-----------------------------------------------------------------------------------------------

alias bh='neo4j console & ; sleep 6 ; cd /opt/BloodHound-v4/BloodHound-linux-x64/ ; ./BloodHound --no-sandbox'
alias cov='cd /opt/Covenant/Covenant/ ; dotnet run'

alias cs='
# Remove old data
# rm /opt/cobaltstrike/data/*.bin 2>/dev/null ;
# Start the teamserver
cd /opt/cobaltstrike/ ; ./teamserver $ip password &
# Split Terminal horizontally
xdotool key Ctrl+D
sleep 5
# Login to the teamserver
cd /opt/cobaltstrike/ ; ./cobaltstrike'

alias m='service postgresql start ; msfdb init ; msfconsole'
Expand Down
3 changes: 0 additions & 3 deletions directObjectRef.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,3 @@ echo "***Scan complete.***"
echo
echo
echo -e "The new report is located at ${YELLOW}$home/data/DirectObjectRef.txt${NC}\n"
echo
echo

3 changes: 0 additions & 3 deletions domain.sh
Original file line number Diff line number Diff line change
Expand Up @@ -63,13 +63,10 @@ case $recon in
echo $medium
echo
echo -e "The new files are located at ${YELLOW}$home/data/$workspace/${NC}\n"
echo
echo
exit
;;

4) f_main;;

*) f_error;;
esac

1 change: 0 additions & 1 deletion generateTargets.sh
Original file line number Diff line number Diff line change
Expand Up @@ -184,4 +184,3 @@ exit
###############################################################################################################################

while true; do f_sub; done

4 changes: 0 additions & 4 deletions listener.sh
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,3 @@ if [[ -z $x ]]; then
fi

msfconsole -r /tmp/listener.rc

echo
echo

1 change: 0 additions & 1 deletion msf-aux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -511,4 +511,3 @@ else
rm $name/master.rc
rm tmpmsf
fi

13 changes: 5 additions & 8 deletions multiTabs.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
#!/bin/bash

cp /home/kali/.Xauthority /root/.Xauthority

f_runlocally
clear
f_banner
Expand All @@ -20,17 +18,17 @@ case $choice in
echo -n "Use an https prefix? (y/N) "
read prefix

XAUTHORITY=/root/.Xauthority sudo firefox &
firefox-esr &
sleep 2

if [ -z $prefix ]; then
for i in $(cat $location); do
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab $i &
firefox-esr -new-tab $i &
sleep 1
done
elif [ "$prefix" == "y" ]; then
for i in $(cat $location); do
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://$i &
firefox-esr -new-tab https://$i &
sleep 1
done
else
Expand Down Expand Up @@ -68,11 +66,11 @@ case $choice in

grep 'Disallow' robots.txt | awk '{print $2}' > tmp

XAUTHORITY=/root/.Xauthority sudo firefox &
firefox-esr &
sleep 2

for i in $(cat tmp); do
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab http://$domain$i &
firefox-esr -new-tab http://$domain$i &
sleep 1
done

Expand All @@ -94,4 +92,3 @@ case $choice in
*) f_error;;
esac
}

3 changes: 0 additions & 3 deletions newModules.sh
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,3 @@ echo
echo $medium
echo
echo -e "The new report is located at ${YELLOW}$home/data/new-modules.txt${NC}\n"
echo
echo

3 changes: 0 additions & 3 deletions nikto.sh
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,3 @@ echo "***Scan complete.***"
echo
echo
echo -e "The new report is located at ${YELLOW}$home/data/nikto/${NC}\n"
echo
echo

4 changes: 3 additions & 1 deletion notes/bash.txt
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,9 @@ fi

# Check for root
if [[ $EUID -ne 0 ]]; then
echo "This script must be ran as root."
echo
echo "[!] This script must be ran as root."
exit
fi

# Check for no answer
Expand Down
36 changes: 7 additions & 29 deletions notes/linux.txt
Original file line number Diff line number Diff line change
Expand Up @@ -340,10 +340,6 @@ git config --global http.proxy http://proxy:port
Add to bottom of /root/.bashrc
export http_proxy=http://username:password@proxy:port
export https_proxy=https://username:password@proxy:port

- Proxychains
ssh -f -N -D 9050 user@host
proxychains nmap <options>
------------------------------------------------------------------------------------------------------------------------------------------------------

# Redirecting
Expand Down Expand Up @@ -461,6 +457,7 @@ smbpasswd -a lee Add a user and set the password
# SSH

ssh-keygen Create new keys
ssh-copy-id -i ~/.ssh/id_rsa.pub user@host Copy new key to server

- Configure a non-standard port
vi /etc/ssh/sshd_config
Expand Down Expand Up @@ -494,9 +491,9 @@ ssh user@host -R 2222:localhost:22 -f -N
-N Do not execute a remote command

- Dynamic port forwarding
ssh -D <local proxy port> <target IP>
ssh user@host -D 1080
-D Create a SOCKS tunnel on the default port
ssh user@host -f -N -D 1080
-D Create a SOCKS tunnel
proxychains nmap <options>

Firefox Preferences > Advanced > Network > Settings > Manual proxy configuration
Remove everything for HTTP, SSL and FTP proxies and ports
Expand All @@ -512,28 +509,10 @@ X11Forwarding yes
systemctl restart sshd Restart the SSH service on the server
exit

ssh -X user@<target IP> -o "XAuthLocation=/opt/X11/bin/xauth"
ssh -X user@host -o "XAuthLocation=/opt/X11/bin/xauth"
firefox Start a GUI app

Note: if using macOS as the client, install XQuartz.

- Generate a new key pair for AWS
Login to https://aws.amazon.com/console/
EC2 > Network & Security > Key Pairs
Create key pair > aws2 > pem > Create key pair
The private key will auto d/l in your browser
Move the key to ~/.ssh/
chmod 600 aws2.pem
ssh-keygen -y -f aws2.pem Show the public key, copy
ssh to your Kali on AWS
cd .ssh
Add your new public key to authorized_keys <new key> aws2
sudo -i
cd .ssh
Add your new public key to authorized_keys <rules> <new key> aws2
exit
exit
ssh in with your new key
------------------------------------------------------------------------------------------------------------------------------------------------------

# Startup Services
Expand Down Expand Up @@ -610,7 +589,7 @@ tcpdump -w out.pcap -s 65535 'udp port 53'

# Tunneling VNC over SSH

OS X (awsv) ssh -L 5901:localhost:5901 -i ~/.ssh/aws.pem ec2-user@<atter IP>
OS X (awsv) ssh -L 5901:localhost:5901 -i ~/.ssh/aws.pem ec2-user@host

Remote Kali sudo -i
vncserver -geometry 2560x1600
Expand All @@ -632,8 +611,7 @@ Perl perl —e 'exec "/bin/bash";'
Perl exec "/bin/sh";
Python python -c 'import pty; pty.spawn("/bin/bash")'
Ruby exec "/bin/sh"
sh echo os.system('/bin/bash')
sh /bin/sh
sh /bin/bash
Within IRB exec "/bin/sh"
Within vi :!bash
Within vi :set shell=/bin/bash:shell
Expand Down
1 change: 0 additions & 1 deletion nse.sh
Original file line number Diff line number Diff line change
Expand Up @@ -775,4 +775,3 @@ if [[ -e $name/161.txt ]] || [[ -e $name/445.txt ]] || [[ -e $name/500.txt ]]; t

rm tmp 2>/dev/null
fi

1 change: 0 additions & 1 deletion parse.sh
Original file line number Diff line number Diff line change
Expand Up @@ -107,4 +107,3 @@ case $choice in
6) f_main;;
*) f_error;;
esac

47 changes: 22 additions & 25 deletions passive.sh
Original file line number Diff line number Diff line change
Expand Up @@ -770,48 +770,45 @@ echo -e "The supporting data folder is located at ${YELLOW}$home/data/$domain/${

f_runlocally

XAUTHORITY=/root/.Xauthority sudo firefox &
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://www.google.com/search?q=$companyurl+logo &
firefox-esr &
firefox-esr -new-tab https://www.google.com/search?q=$companyurl+logo &
sleep 4
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://$companyurl.s3.amazonaws.com &
firefox-esr -new-tab https://$companyurl.s3.amazonaws.com &
sleep 4
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://www.google.com/search?q=site:$domain+%22internal+use+only%22 &
firefox-esr -new-tab https://www.google.com/search?q=site:$domain+%22internal+use+only%22 &
sleep 4
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://www.google.com/search?q=site:$domain+%22index+of/%22+%22parent+directory%22 &
firefox-esr -new-tab https://www.google.com/search?q=site:$domain+%22index+of/%22+%22parent+directory%22 &
sleep 4
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://dockets.justia.com/search?parties=%22$companyurl%22&cases=mostrecent &
firefox-esr -new-tab https://dockets.justia.com/search?parties=%22$companyurl%22&cases=mostrecent &
sleep 4
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://www.google.com/search?q=site:$domain+inurl:login &
firefox-esr -new-tab https://www.google.com/search?q=site:$domain+inurl:login &
sleep 4
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab http://www.reuters.com/finance/stocks/lookup?searchType=any\&search=$companyurl &
firefox-esr -new-tab http://www.reuters.com/finance/stocks/lookup?searchType=any\&search=$companyurl &
sleep 4
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://www.google.com/search?q=site:$domain+intext:username+intext:password+inurl:ftp &
firefox-esr -new-tab https://www.google.com/search?q=site:$domain+intext:username+intext:password+inurl:ftp &
sleep 4
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://secsearch.sec.gov/search/docs?affiliate=secsearch&query=$companyurl &
firefox-esr -new-tab https://secsearch.sec.gov/search/docs?affiliate=secsearch&query=$companyurl &
sleep 4
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://www.google.com/search?q=site:$domain+intext:username+intext:password+-inurl:careers &
firefox-esr -new-tab https://www.google.com/search?q=site:$domain+intext:username+intext:password+-inurl:careers &
sleep 4
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://networksdb.io/search/org/$companyurl &
firefox-esr -new-tab https://networksdb.io/search/org/$companyurl &
sleep 4
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://www.google.com/search?q=site:$domain+intext:Atlassian+intext:jira+-inurl:careers &
firefox-esr -new-tab https://www.google.com/search?q=site:$domain+intext:Atlassian+intext:jira+-inurl:careers &
sleep 6
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://www.google.com/search?q=site:pastebin.com+intext:$domain &
firefox-esr -new-tab https://www.google.com/search?q=site:pastebin.com+intext:$domain &
sleep 4
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://www.facebook.com &
firefox-esr -new-tab https://www.facebook.com &
sleep 4
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://www.instagram.com &
firefox-esr -new-tab https://www.instagram.com &
sleep 4
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://www.linkedin.com &
firefox-esr -new-tab https://www.linkedin.com &
sleep 4
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://www.pinterest.com &
firefox-esr -new-tab https://www.pinterest.com &
sleep 4
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://twitter.com &
firefox-esr -new-tab https://twitter.com &
sleep 4
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://www.youtube.com &
firefox-esr -new-tab https://www.youtube.com &
sleep 4
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab https://$domain &
firefox-esr -new-tab https://$domain &
sleep 4
XAUTHORITY=/root/.Xauthority sudo firefox -new-tab $home/data/$domain/index.htm &

echo
echo
firefox-esr -new-tab $home/data/$domain/index.htm &
2 changes: 0 additions & 2 deletions payload.sh
Original file line number Diff line number Diff line change
Expand Up @@ -174,5 +174,3 @@ if [ "$answer" == "y" ]; then
else
msfvenom -p $payload LHOST=$lhost LPORT=$lport -f $format -a $arch --platform $platform -e x64/xor_dynamic -i $iterations -o $home/data/$x-$lport-$iterations$extention
fi

echo
18 changes: 9 additions & 9 deletions person.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,21 +22,21 @@ if [[ -z $lastName ]]; then
f_error
fi

XAUTHORITY=/root/.Xauthority firefox &
firefox-esr &
sleep 2
XAUTHORITY=/root/.Xauthority firefox -new-tab https://www.411.com/name/$firstName-$lastName/ &
firefox-esr -new-tab https://www.411.com/name/$firstName-$lastName/ &
sleep 2
uripath="https://www.advancedbackgroundchecks.com/search/results.aspx?type=&fn=${firstName}&mi=&ln=${lastName}&age=&city=&state="
XAUTHORITY=/root/.Xauthority firefox -new-tab $uripath &
firefox-esr -new-tab $uripath &
sleep 2
XAUTHORITY=/root/.Xauthority firefox -new-tab https://www.linkedin.com/pub/dir/?first=$firstName\&last=$lastName\&search=Search &
firefox-esr -new-tab https://www.linkedin.com/pub/dir/?first=$firstName\&last=$lastName\&search=Search &
sleep 2
XAUTHORITY=/root/.Xauthority firefox -new-tab https://www.peekyou.com/$firstName%5f$lastName &
firefox-esr -new-tab https://www.peekyou.com/$firstName%5f$lastName &
sleep 2
XAUTHORITY=/root/.Xauthority firefox -new-tab https://www.addresses.com/people/$firstName+$lastName &
firefox-esr -new-tab https://www.addresses.com/people/$firstName+$lastName &
sleep 2
XAUTHORITY=/root/.Xauthority firefox -new-tab https://www.spokeo.com/$firstName-$lastName &
firefox-esr -new-tab https://www.spokeo.com/$firstName-$lastName &
sleep 2
XAUTHORITY=/root/.Xauthority firefox -new-tab https://twitter.com/search?q=%22$firstName%20$lastName%22&src=typd &
firefox-esr -new-tab https://twitter.com/search?q=%22$firstName%20$lastName%22&src=typd &
sleep 2
XAUTHORITY=/root/.Xauthority firefox -new-tab https://www.youtube.com/results?search_query=$firstName+$lastName &
firefox-esr -new-tab https://www.youtube.com/results?search_query=$firstName+$lastName &
3 changes: 0 additions & 3 deletions report.sh
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,3 @@ echo "***Scan complete.***"
echo
echo
echo -e "The new report is located at ${YELLOW}$home/data/$name/report.txt${NC}\n"
echo
echo

3 changes: 0 additions & 3 deletions ssl.sh
Original file line number Diff line number Diff line change
Expand Up @@ -228,6 +228,3 @@ echo "***Scan complete.***"
echo
echo
echo -e "The new reports are located at ${YELLOW}$home/data/sslscan.txt, sslyze.txt, ${NC}and ${YELLOW}nmap-ssl.txt ${NC}"
echo
echo

14 changes: 8 additions & 6 deletions update.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,17 @@ BLUE='\033[1;34m'
YELLOW='\033[1;33m'
NC='\033[0m'

# Check for root
if [[ $EUID -ne 0 ]]; then
echo
echo "[!] This script must be ran as root."
exit
fi

###############################################################################################################################

# Clean up

if [ -f /opt/cobaltstrike/malleable-c2-profiles/packages-microsoft-prod.deb ]; then
rm -rf /opt/cobaltstrike/malleable-c2-profiles/
fi

###############################################################################################################################

clear
Expand All @@ -28,8 +31,8 @@ fi

echo -e "${BLUE}Updating Kali.${NC}"
apt update ; apt -y upgrade ; apt -y dist-upgrade ; apt -y autoremove ; apt -y autoclean ; updatedb
echo

exit
if [ ! -e /usr/bin/amass ]; then
echo -e "${YELLOW}Installing Amass.${NC}"
apt install -y amass
Expand Down Expand Up @@ -477,4 +480,3 @@ echo -e "${BLUE}Updating locate database.${NC}"
updatedb

exit

0 comments on commit 5261255

Please sign in to comment.