Add GET BB_LABEL function and docs (#569)

* Add GET BUNNY_LABEL to get.sh

Instead of hardcoding "BashBunny" or whatever new name the Bunny has, attackers can use a GET command.

* Add docs for GET HOST_IP & GET BB_LABEL
pull/574/head
rsxchin 2022-12-16 08:58:09 -10:00 committed by GitHub
parent 858bb2df2c
commit d68298eaa3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 1 deletions

View File

@ -6,7 +6,7 @@
Bash Bunny by Hak5 USB Attack/Automation Platform Bash Bunny by Hak5 USB Attack/Automation Platform
-+- QUICK REFERENCE GUIDE v1.4 -+- -+- QUICK REFERENCE GUIDE v1.5 -+-
+-----------------+ +-----------------+
@ -107,6 +107,8 @@
$HOST_IP IP Address of the Bash Bunny $HOST_IP IP Address of the Bash Bunny
(Default: 172.16.64.1) (Default: 172.16.64.1)
$SWITCH_POSITION "switch1", "switch2" or "switch3" $SWITCH_POSITION "switch1", "switch2" or "switch3"
$BB_LABEL Volume name of the BashBunny
when mounted.
@ -153,6 +155,8 @@
GET TARGET_HOSTNAME Returns $TARGET_HOSTNAME GET TARGET_HOSTNAME Returns $TARGET_HOSTNAME
GET HOST_IP Returns $HOST_IP GET HOST_IP Returns $HOST_IP
GET SWITCH_POSITION Returns $SWITCH_POSITION GET SWITCH_POSITION Returns $SWITCH_POSITION
GET TARGET_OS Returns $TARGET_OS
GET BB_LABEL Returns $BB_LABEL

View File

@ -26,6 +26,10 @@ function GET() {
[[ "${ScanForOS,,}" == *"linux"* ]] && export TARGET_OS='LINUX' && return [[ "${ScanForOS,,}" == *"linux"* ]] && export TARGET_OS='LINUX' && return
export TARGET_OS='UNKNOWN' export TARGET_OS='UNKNOWN'
;; ;;
"BB_LABEL")
export BB_LABEL=$(ls -l /dev/disk/by-label/ | awk '/nandf$/ { print $9 }')
;;
esac esac
} }