Repository navigation
Expand file tree
/
Copy pathsetup.sh
More file actions
executable file
·53 lines (41 loc) · 1.6 KB
/
Copy pathsetup.sh
File metadata and controls
executable file
·53 lines (41 loc) · 1.6 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
#!/usr/bin/env bash
# Wardriver setup — creates a venv and installs the 'wd' launcher.
# Works from wherever you cloned the repo; nothing is hardcoded.
set -euo pipefail
REPO_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
echo "==> Installing into: $REPO_DIR"
if ! command -v python3 >/dev/null; then
echo "python3 is required" >&2
exit 1
fi
echo "==> Creating virtualenv"
python3 -m venv "$REPO_DIR/venv"
"$REPO_DIR/venv/bin/pip" install --quiet --upgrade pip
"$REPO_DIR/venv/bin/pip" install --quiet -r "$REPO_DIR/requirements.txt"
echo "==> Checking system dependencies"
for tool in iw nmcli hciconfig openssl; do
command -v "$tool" >/dev/null \
&& echo " ok $tool" \
|| echo " MISSING $tool (Debian/Kali: sudo apt install iw network-manager bluez openssl)"
done
echo "==> Installing the 'wd' launcher to /usr/local/bin"
sudo tee /usr/local/bin/wd >/dev/null <<EOF
#!/usr/bin/env bash
# Wardriver launcher (generated by setup.sh)
exec "$REPO_DIR/venv/bin/python3" "$REPO_DIR/wardriver_tui.py" "\$@"
EOF
sudo chmod +x /usr/local/bin/wd
cat <<EOF
Done.
sudo wd launch the dashboard
Scanning needs root: 'iw scan' requires CAP_NET_ADMIN, and bringing a
Bluetooth adapter up requires privileges.
First run:
1. Press WIGLE and enter your own WiGLE API Name + Token
(wigle.net -> Account -> Show My Token). Nothing is bundled.
2. Press QR and scan it with your phone to share GPS, or press GPS
to type coordinates manually.
3. Press START.
Your credentials, TLS keypair and captures live in ~/.wardriver/ and are
git-ignored. Never commit that directory.
EOF