Aleksandar's Online Notes

Personal ramblings and thoughts on Life, the Universe and Everything — including but not limited to Infosec & Tech

Headless Pwnagotchi Build - A minimal setup

In case you are wondering what a Pwnagotchi is, I recommend reading this excellent article by Evilsocket.

While there are some very comprehensive DIY tutorials for building a Pwnagotchi, I’ve noticed a lack of any minimal setup instructions out there. Considering that I had a Raspberry Pi Zero W laying around, I decided to go ahead and make the minimal build. The build is using only the Pi Zero W. There is no screen attached, no battery soldered to the Pi board, no additional antenna.

The goal of the mini-project is to build a Pwnagotchi and connect to it via Bluetooth from an iPhone. The most common problems I’ve seen out there are exactly Bluetooth related - how to reliably connect to your virtual hacking pet using BT.

Final note before we begin - this blog post will largely overlap with the original Pwnagotchi installation instructions. If you are familiar with the process of getting your Pwnagotchi up and running, but you are having problems with connecting your iPhone, you can skip directly to the Bluetooth setup section.

So here we go.

Build Requirements:

Step 1: Flashing the Pwnagotchi img to the card

The instructions laid out on the official pwnagotchi website are quite easy to follow. I will, however, add my own version here also, since I had used Raspberry Pi Imager instead of balenaEtcher for writing the .img to your microSD.

Step 2: Configuration file

In order to configure your Pwnagotchi, you will be creating a config.toml file in the root of your microSD card. The contents of your configuration file should be based on this example below:

main.name = "NAME OF YOUR PWNAGOTCHI"
main.lang = "en"
main.whitelist = [
  "YOUR HOME NETWORK SSID 1",
  "YOUR HOME NETWORK SSID 2"
]

main.plugins.grid.enabled = false     # see original setup if you want to enable
main.plugins.grid.report = false      # the grid plugin and grid reporting

ui.web.username = "USERNAME FOR THE WEB UI"   # set this to anything you want
ui.web.password = "PASSWORD FOR THE WEB UI"

# This is the bluetooth section
main.plugins.bt-tether.enabled = true
main.plugins.bt-tether.devices.ios-phone.enabled = true
main.plugins.bt-tether.devices.ios-phone.search_order = 1
main.plugins.bt-tether.devices.ios-phone.mac = "YOUR IPHONE BT MAC ADDRESS"
main.plugins.bt-tether.devices.ios-phone.ip = "172.20.10.66"
main.plugins.bt-tether.devices.ios-phone.netmask = 24
main.plugins.bt-tether.devices.ios-phone.interval = 1
main.plugins.bt-tether.devices.ios-phone.scantime = 10
main.plugins.bt-tether.devices.ios-phone.max_tries = 0
main.plugins.bt-tether.devices.ios-phone.share_internet = true
main.plugins.bt-tether.devices.ios-phone.priority = 1

Step 3: First boot of your new pet

Step 4: Bluetooth pairing

Step 5: Connect to your new pet from your iPhone

↑ Archive