
A config for the phone
Make a new key pair on the server and add the phone as another peer with an unused address such as 10.8.0.3/32. Every device gets its own key, do not share.
phone.conf
[Interface]
PrivateKey = PHONE_PRIVATE_KEY
Address = 10.8.0.3/32
DNS = 1.1.1.1
[Peer]
PublicKey = SERVER_PUBLIC_KEY
Endpoint = SERVER_IP:51820
AllowedIPs = 0.0.0.0/0, ::/0
PersistentKeepalive = 25Into a QR code
Shown right in the terminal
sudo apt install qrencode
qrencode -t ansiutf8 < phone.confOn the phone tap +, choose Scan from QR code and name the tunnel.
New tunnel
Namehome
QR coderecognised
CreateCancel
Without a terminal
- OpenWrt: the QR icon in the interface's Peers.
- wg-easy: the QR button next to the device.
It will not scan.
The font is too large and the code is cut. Enlarge the window or shrink the font and show it again.
Must the server restart to know the phone?
No. sudo wg syncconf wg0 <(wg-quick strip wg0) adds the peer without dropping others.
Next letterUse your home network from outside