mirror of
https://github.com/jayofelony/pwnagotchi.git
synced 2025-07-01 18:37:27 -04:00
BIN
builder/data/usr/local/bin/bettercap
Normal file
BIN
builder/data/usr/local/bin/bettercap
Normal file
Binary file not shown.
BIN
builder/data/usr/local/bin/pwngrid
Normal file
BIN
builder/data/usr/local/bin/pwngrid
Normal file
Binary file not shown.
@ -14,72 +14,18 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"provisioners": [
|
"provisioners": [
|
||||||
{
|
|
||||||
"type": "file",
|
|
||||||
"source": "../builder/data/usr/bin/pwnlib",
|
|
||||||
"destination": "/usr/bin/pwnlib"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "file",
|
|
||||||
"source": "../builder/data/usr/bin/bettercap-launcher",
|
|
||||||
"destination": "/usr/bin/bettercap-launcher"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "file",
|
|
||||||
"source": "../builder/data/usr/bin/pwnagotchi-launcher",
|
|
||||||
"destination": "/usr/bin/pwnagotchi-launcher"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "file",
|
|
||||||
"source": "../builder/data/usr/bin/monstop",
|
|
||||||
"destination": "/usr/bin/monstop"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "file",
|
|
||||||
"source": "../builder/data/usr/bin/monstart",
|
|
||||||
"destination": "/usr/bin/monstart"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "file",
|
|
||||||
"source": "../builder/data/usr/bin/hdmion",
|
|
||||||
"destination": "/usr/bin/hdmion"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "file",
|
|
||||||
"source": "../builder/data/usr/bin/hdmioff",
|
|
||||||
"destination": "/usr/bin/hdmioff"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "file",
|
|
||||||
"source": "../builder/data/etc/systemd/system/pwngrid-peer.service",
|
|
||||||
"destination": "/etc/systemd/system/pwngrid-peer.service"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "file",
|
|
||||||
"source": "../builder/data/etc/systemd/system/pwnagotchi.service",
|
|
||||||
"destination": "/etc/systemd/system/pwnagotchi.service"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "file",
|
|
||||||
"source": "../builder/data/etc/systemd/system/bettercap.service",
|
|
||||||
"destination": "/etc/systemd/system/bettercap.service"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"inline": [
|
"inline": [
|
||||||
"chmod +x /usr/bin/*"
|
"mkdir -p /usr/local/src/pwnagotchi"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"source": "../builder/data/etc/update-motd.d/01-motd",
|
"sources": [
|
||||||
"destination": "/etc/update-motd.d/01-motd"
|
"../dist/pwnagotchi-{{user `pwn_version`}}.tar.gz"
|
||||||
},
|
],
|
||||||
{
|
"destination": "/usr/local/src/pwnagotchi/"
|
||||||
"type": "shell",
|
|
||||||
"inline": [
|
|
||||||
"chmod +x /etc/update-motd.d/*"
|
|
||||||
]
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
|
@ -193,7 +193,7 @@
|
|||||||
# Install nexmon to fix wireless scanning (takes 2.5G of space)
|
# Install nexmon to fix wireless scanning (takes 2.5G of space)
|
||||||
- name: clone nexmon repository
|
- name: clone nexmon repository
|
||||||
git:
|
git:
|
||||||
repo: https://github.com/jayofelony/nexmon.git
|
repo: https://github.com/DrSchottky/nexmon.git
|
||||||
dest: /usr/local/src/nexmon
|
dest: /usr/local/src/nexmon
|
||||||
register: nexmongit
|
register: nexmongit
|
||||||
|
|
||||||
@ -260,6 +260,26 @@
|
|||||||
state: absent
|
state: absent
|
||||||
path: /usr/lib/firmware/brcm/brcmfmac43430-sdio.raspberrypi,3-model-b.clm_blob
|
path: /usr/lib/firmware/brcm/brcmfmac43430-sdio.raspberrypi,3-model-b.clm_blob
|
||||||
|
|
||||||
|
- name: Delete the RPi02w firmware blob to avoid it crashing
|
||||||
|
file:
|
||||||
|
state: absent
|
||||||
|
path: /usr/lib/firmware/brcm/brcmfmac43430b0-sdio.raspberrypi,model-zero-2-w.clm_blob
|
||||||
|
|
||||||
|
- name: Delete the RPi02w firmware blob to avoid it crashing
|
||||||
|
file:
|
||||||
|
state: absent
|
||||||
|
path: /usr/lib/firmware/brcm/brcmfmac43436-sdio.clm_blob
|
||||||
|
|
||||||
|
- name: Delete the RPi302w firmware blob to avoid it crashing
|
||||||
|
file:
|
||||||
|
state: absent
|
||||||
|
path: /usr/lib/firmware/brcm/brcmfmac43436-sdio.raspberrypi,model-zero-2-w.clm_blob
|
||||||
|
|
||||||
|
- name: Delete the RPi02w firmware blob to avoid it crashing
|
||||||
|
file:
|
||||||
|
state: absent
|
||||||
|
path: /usr/lib/firmware/brcm/brcmfmac43455-sdio.clm_blob
|
||||||
|
|
||||||
- name: backup original driver
|
- name: backup original driver
|
||||||
command: "mv /usr/lib/modules/{{ kernel.full }}/kernel/drivers/net/wireless/broadcom/brcm80211/brcmfmac/brcmfmac.ko.xz /usr/lib/modules/{{ kernel.full }}/kernel/drivers/net/wireless/broadcom/brcm80211/brcmfmac/brcmfmac.ko.xz.orig"
|
command: "mv /usr/lib/modules/{{ kernel.full }}/kernel/drivers/net/wireless/broadcom/brcm80211/brcmfmac/brcmfmac.ko.xz /usr/lib/modules/{{ kernel.full }}/kernel/drivers/net/wireless/broadcom/brcm80211/brcmfmac/brcmfmac.ko.xz.orig"
|
||||||
|
|
||||||
@ -287,23 +307,10 @@
|
|||||||
path: /etc/pwnagotchi/conf.d/
|
path: /etc/pwnagotchi/conf.d/
|
||||||
state: directory
|
state: directory
|
||||||
|
|
||||||
- name: clone pwnagotchi repository
|
- name: Install pwnagotchi from source archive
|
||||||
git:
|
|
||||||
repo: https://github.com/jayofelony/pwnagotchi.git
|
|
||||||
dest: /usr/local/src/pwnagotchi
|
|
||||||
register: pwnagotchigit
|
|
||||||
|
|
||||||
- name: build pwnagotchi wheel
|
|
||||||
command: "python3 setup.py sdist bdist_wheel"
|
|
||||||
args:
|
|
||||||
chdir: /usr/local/src/pwnagotchi
|
|
||||||
when: (pwnagotchigit.changed) or (pip_packages['pwnagotchi'] is undefined) or (pip_packages['pwnagotchi'] != pwnagotchi_version)
|
|
||||||
|
|
||||||
- name: install pwnagotchi wheel and dependencies
|
|
||||||
pip:
|
pip:
|
||||||
name: "{{ lookup('fileglob', '/usr/local/src/pwnagotchi/dist/pwnagotchi*.whl') }}"
|
name: /usr/local/src/pwnagotchi/pwnagotchi-{{ pwnagotchi.version }}.tar.gz
|
||||||
extra_args: "--no-cache-dir"
|
extra_args: --verbose --prefer-binary --ignore-installed
|
||||||
when: (pwnagotchigit.changed) or (pip_packages['pwnagotchi'] is undefined) or (pip_packages['pwnagotchi'] != pwnagotchi_version)
|
|
||||||
|
|
||||||
- name: remove pwnagotchi folder
|
- name: remove pwnagotchi folder
|
||||||
file:
|
file:
|
||||||
@ -315,57 +322,57 @@
|
|||||||
path: /usr/local/share/pwnagotchi/
|
path: /usr/local/share/pwnagotchi/
|
||||||
state: directory
|
state: directory
|
||||||
|
|
||||||
- name: Install go-1.21
|
#- name: Install go-1.21
|
||||||
unarchive:
|
# unarchive:
|
||||||
src: https://go.dev/dl/go1.21.3.linux-arm64.tar.gz
|
# src: https://go.dev/dl/go1.21.3.linux-arm64.tar.gz
|
||||||
dest: /usr/local
|
# dest: /usr/local
|
||||||
remote_src: yes
|
# remote_src: yes
|
||||||
register: golang
|
# register: golang
|
||||||
|
|
||||||
- name: Update .bashrc for go-1.21
|
#- name: Update .bashrc for go-1.21
|
||||||
blockinfile:
|
# blockinfile:
|
||||||
dest: /home/pi/.bashrc
|
# dest: /home/pi/.bashrc
|
||||||
state: present
|
# state: present
|
||||||
block: |
|
# block: |
|
||||||
export GOPATH=$HOME/go
|
# export GOPATH=$HOME/go
|
||||||
export PATH=/usr/local/go/bin:$PATH:$GOPATH/bin
|
# export PATH=/usr/local/go/bin:$PATH:$GOPATH/bin
|
||||||
when: golang.changed
|
# when: golang.changed
|
||||||
|
|
||||||
- name: download pwngrid 1.10.4
|
#- name: download pwngrid 1.10.4
|
||||||
git:
|
# git:
|
||||||
repo: https://github.com/jayofelony/pwngrid.git
|
# repo: https://github.com/jayofelony/pwngrid.git
|
||||||
dest: /usr/local/src/pwngrid
|
# dest: /usr/local/src/pwngrid
|
||||||
register: pwngrid
|
# register: pwngrid
|
||||||
|
|
||||||
- name: install pwngrid 1.10.4
|
#- name: install pwngrid 1.10.4
|
||||||
shell: "export GOPATH=$HOME/go && export PATH=/usr/local/go/bin:$PATH:$GOPATH/bin && go mod tidy && make && make install"
|
# shell: "export GOPATH=$HOME/go && export PATH=/usr/local/go/bin:$PATH:$GOPATH/bin && go mod tidy && make && make install"
|
||||||
args:
|
# args:
|
||||||
executable: /bin/bash
|
# executable: /bin/bash
|
||||||
chdir: /usr/local/src/pwngrid
|
# chdir: /usr/local/src/pwngrid
|
||||||
when: pwngrid.changed
|
# when: pwngrid.changed
|
||||||
|
|
||||||
- name: remove pwngrid folder
|
#- name: remove pwngrid folder
|
||||||
file:
|
# file:
|
||||||
state: absent
|
# state: absent
|
||||||
path: /usr/local/src/pwngrid
|
# path: /usr/local/src/pwngrid
|
||||||
|
|
||||||
- name: download bettercap v2.32.1
|
#- name: download bettercap v2.32.1
|
||||||
git:
|
# git:
|
||||||
repo: https://github.com/jayofelony/bettercap.git
|
# repo: https://github.com/jayofelony/bettercap.git
|
||||||
dest: /usr/local/src/bettercap
|
# dest: /usr/local/src/bettercap
|
||||||
register: bettercap
|
# register: bettercap
|
||||||
|
|
||||||
- name: Install bettercap v2.32.1
|
#- name: Install bettercap v2.32.1
|
||||||
shell: "export GOPATH=$HOME/go && export PATH=/usr/local/go/bin:$PATH:$GOPATH/bin && go mod tidy && make && make install"
|
# shell: "export GOPATH=$HOME/go && export PATH=/usr/local/go/bin:$PATH:$GOPATH/bin && go mod tidy && make && make install"
|
||||||
args:
|
# args:
|
||||||
executable: /bin/bash
|
# executable: /bin/bash
|
||||||
chdir: /usr/local/src/bettercap
|
# chdir: /usr/local/src/bettercap
|
||||||
when: bettercap.changed
|
# when: bettercap.changed
|
||||||
|
|
||||||
- name: remove bettercap folder
|
#- name: remove bettercap folder
|
||||||
file:
|
# file:
|
||||||
state: absent
|
# state: absent
|
||||||
path: /usr/local/src/bettercap
|
# path: /usr/local/src/bettercap
|
||||||
|
|
||||||
- name: clone bettercap caplets
|
- name: clone bettercap caplets
|
||||||
git:
|
git:
|
||||||
@ -533,16 +540,6 @@
|
|||||||
args:
|
args:
|
||||||
executable: /bin/bash
|
executable: /bin/bash
|
||||||
|
|
||||||
- name: remove /root/go folder
|
|
||||||
file:
|
|
||||||
state: absent
|
|
||||||
path: /root/go
|
|
||||||
|
|
||||||
- name: remove /usr/local/go folder
|
|
||||||
file:
|
|
||||||
state: absent
|
|
||||||
path: /usr/local/go
|
|
||||||
|
|
||||||
- name: remove pip cache
|
- name: remove pip cache
|
||||||
file:
|
file:
|
||||||
state: absent
|
state: absent
|
||||||
@ -553,6 +550,12 @@
|
|||||||
autoremove: yes
|
autoremove: yes
|
||||||
when: removed.changed
|
when: removed.changed
|
||||||
|
|
||||||
|
- name: set permissions
|
||||||
|
command: "chmod +x /usr/bin/*"
|
||||||
|
|
||||||
|
- name: set permissions
|
||||||
|
command: "chmod +x /usr/local/bin/*"
|
||||||
|
|
||||||
handlers:
|
handlers:
|
||||||
- name: reload systemd services
|
- name: reload systemd services
|
||||||
systemd:
|
systemd:
|
||||||
|
Reference in New Issue
Block a user