https://github.com/maelvls/livebox
🍊 A simple CLI for interacting with a Livebox 4 or 5.
https://github.com/maelvls/livebox
livebox orange
Last synced: 26 days ago
JSON representation
🍊 A simple CLI for interacting with a Livebox 4 or 5.
- Host: GitHub
- URL: https://github.com/maelvls/livebox
- Owner: maelvls
- Created: 2020-12-14T08:35:47.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2025-02-11T15:39:31.000Z (over 1 year ago)
- Last Synced: 2025-02-20T07:53:43.928Z (over 1 year ago)
- Topics: livebox, orange
- Language: Go
- Homepage:
- Size: 83 KB
- Stars: 1
- Watchers: 4
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# livebox CLI for the Livebox 4, 5, 6 and 7
> [!NOTE]
>
> Although I haven't tested with an actual Livebox 6 or 7, you should be able to run the `livebox` CLI with them.
My internet service provider is Orange. When you sign up for a plan with them, they provide a modem/router called the ‘Livebox.’ I’ve used two versions of it: Livebox 4 and Livebox 5. I had the Livebox 4 when I was limited to DSL, but once I became eligible for fiber in 2025, I was upgraded to the Livebox 5.
Livebox 4
Livebox 5
I developed the `livebox` CLI to quickly reboot the Livebox and monitor its bandwidth. The CLI is compatible with both Livebox 4 and Livebox 5 models.
## Getting started
You will need Go version 1.21 or later to build the CLI.
```sh
go install github.com/maelvls/livebox@latest
```
To get started:
```sh
livebox login
```
You can now list the devices on your network to find out their IP and MAC
addresses:
```sh
livebox ls
```
You can reboot the Livebox from the command line:
```sh
livebox reboot
```
You can do raw API calls too:
```sh
livebox api <<<'{"service":"NeMo.Intf.lan","method":"getMIBs","parameters":{"mibs":"base wlanradio"}}'
```
You can display the DSL bandwidth (doesn't work for fiber connections, only DSL):
```sh
livebox speed
```
I had a very poor DSL connection back in the day:

## Wi-fi
You can also configure your Wi-Fi. To configure the SSID and pass code for the
2.4 GHz and 5 GHz bands simultaneously:
```sh
livebox wifi config --ssid "Wifi-Valais" --pass "foobar" --24ghz --5ghz
```
If you omit both `--24ghz` and `--5ghz`, both bands will be configured
simultanously:
```sh
livebox wifi config --ssid "Wifi-Valais" --pass "foobar"
```
If you want to configure different settings for each band:
```sh
livebox wifi config --24ghz --ssid "Wifi-Valais" --pass "foobar"
livebox wifi config --5ghz --ssid "Wifi-Valais_5GHz" --pass "foobar"
```
To turn off both and turn on both bands:
```sh
livebox wifi disable
livebox wifi enable
```
To turn on and off only one band:
```sh
livebox wifi disable --24ghz
livebox wifi enable --5ghz
```
## Firewall
You can configure the firewall using the CLI.
For IPv4 TCP port forwarding:
```sh
livebox port-forward set pi443 --from-port 443 --to-port 443 --to-ip 192.168.1.160 --to-mac E4:5F:01:A6:65:FE
```
You can add the `--udp` flag to forward UDP traffic instead of TCP.
Regarding IPv6 pinholes, you can do that too:
```sh
livebox pinhole set tailscale-pi-ipv6 --to-port 41642 --to-ip 192.168.1.160 --to-mac e4:5f:01:a6:65:fe --udp
```
## DHCP
To configure a static lease:
```sh
livebox static-lease set bc:d0:74:32:e9:1a 192.168.1.155
```
To list the static leases:
```sh
livebox static-lease ls
```
## DMZ
To configure the DMZ:
```sh
livebox dmz set 192.168.1.160
```
Also, you can remove the DMZ and see if one is configured:
```sh
livebox dmz rm
livebox dmz get # Returns the IP of the DMZ'ed device.
```