pwnagotchi/builder/data/usr/bin/bettercap-launcher

16 lines
499 B
Plaintext
Raw Normal View History

#!/usr/bin/env bash
# start mon0
/usr/bin/monstart
# if usb0 or eth0 are up
if [[ $(ifconfig | grep usb0 | grep RUNNING) ]] || [[ !$(grep '1' /sys/class/net/eth0/carrier) ]]; then
# if override file exists, go into auto mode
if [ -f /root/.pwnagotchi-auto ]; then
/usr/bin/bettercap -no-colors -caplet pwnagotchi-auto -iface mon0
else
/usr/bin/bettercap -no-colors -caplet pwnagotchi-manual -iface mon0
fi
else
/usr/bin/bettercap -no-colors -caplet pwnagotchi-auto -iface mon0
fi