Skip to content

Commit 482d395

Browse files
committed
creating a way to quickly search multiple queries using a bash script
1 parent aea40a7 commit 482d395

File tree

4 files changed

+43
-3
lines changed

4 files changed

+43
-3
lines changed

dryrun_autosploit.sh renamed to drysploit.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,13 @@
11
#!/usr/bin/env bash
22

3+
#
4+
# this script dryruns autosploit. That's it, nothing special just a dry run
5+
#
6+
37

48
if [[ $# -lt 1 ]]; then
59
echo "Syntax:"
6-
echo -e "\t./dryrun_autosploit.sh <search_query> [whitelist]"
10+
echo -e "\t./drysploit.sh <search_query> [whitelist]"
711
exit 1
812
fi
913

lib/cmdline/cmd.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ def optparser():
7979
misc.add_argument("--ethics", action="store_true", dest="displayEthics",
8080
help=argparse.SUPPRESS) # easter egg!
8181
misc.add_argument("--whitelist", metavar="PATH", dest="whitelist",
82-
help="only exploit hosts listed in the whitelist file")
82+
help="only exploit hosts listed in the whitelist file")
8383
misc.add_argument("-D", "--download", nargs="+", metavar="SEARCH1 SEARCH2 ...", dest="downloadModules",
8484
help="download new exploit modules with a provided search flag")
8585
opts = parser.parse_args()

quicksploit.sh

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
#!/bin/bash
2+
3+
#
4+
# this script quickly runs a query list of search keywords provided from a file on ALL of the
5+
# available APIs. (Censys, Zoomeye, and Shodan) from there it will save all of them to the hosts.txt
6+
# file and you can do as you will with that
7+
#
8+
9+
function doQuick() {
10+
for item in $(cat $1); do python autosploit.py -A -a -f etc/json/default_modules.json -q $item; done
11+
}
12+
13+
function helpPage() {
14+
echo "./quicksploit.sh FILENAME";
15+
exit 1;
16+
}
17+
18+
function main() {
19+
if [[ $EUID -ne 0 ]]; then
20+
echo "[!] must run script as root!";
21+
exit 1;
22+
elif [[ ! -f $1 ]]; then
23+
helpPage;
24+
else
25+
echo "[+] starting quicksploit searching!";
26+
doQuick $1;
27+
fi
28+
}
29+
30+
main $@;

run_autosploit.sh renamed to runsploit.sh

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,15 @@
11
#!/bin/bash
22

3+
#
4+
# this script runs autosploit with default configs and default modules
5+
# protip be on a VPS when you run this because it's gonna start an attack
6+
# right away
7+
#
8+
39

410
if [[ $# -lt 1 ]]; then
511
echo "Syntax:"
6-
echo -e "\t./run_autosploit.sh PORT [WHITELIST]"
12+
echo -e "\t./runsploit.sh PORT [WHITELIST]"
713
exit 1
814
fi
915

0 commit comments

Comments
 (0)