mirror of
https://github.com/wrolpi/wrolpi-help.git
synced 2026-12-02 21:00:00 -05:00
Downloading and sharing torrents, the Torrents page, the qBittorrent WebUI, setting up the VPN, port forwarding by provider, fail-closed, and what the VPN does not protect. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
91 lines
5.9 KiB
Markdown
91 lines
5.9 KiB
Markdown
# The VPN for Torrents
|
|
|
|
[Torrents](index.md) only reach the Internet through a VPN. Torrent peers see each other's addresses, so without a VPN
|
|
anyone sharing the same torrent sees your home's address. With the VPN, they see your VPN provider's address instead.
|
|
|
|
The VPN only carries torrents. The rest of WROLPi (downloads, upgrades, the Controller) uses your normal Internet
|
|
connection.
|
|
|
|
## Setting Up the VPN
|
|
|
|
You need an account with a VPN provider, and a WireGuard (`.conf`) or OpenVPN (`.ovpn`) config file from it. Most
|
|
providers offer these on their website, for use on routers or Linux.
|
|
|
|
> To set up the VPN, click **Admin**, then **Control**, and find the **VPN** section. The **VPN settings** link on the
|
|
> Torrents page opens it.
|
|
|
|

|
|
|
|
1. Click **Upload VPN Config**, and choose the file from your VPN provider.
|
|
2. If it is an OpenVPN config which needs a login, enter your provider's VPN username and password, and click
|
|
**Save Login**. (These are usually not your account's login; providers list them with their OpenVPN configs.)
|
|
3. Choose the [Port forwarding](#port-forwarding) your provider offers, and click **Save**.
|
|
4. Check **Turn on the VPN**.
|
|
|
|
The status shows **Connected**, and the address peers see, once the VPN is up. The same settings are on the
|
|
[Controller](../../controller/index.md)'s own page.
|
|
|
|
**Replace VPN Config** uploads a new file in place of the old one (for example, to use another server). **Remove**
|
|
deletes the config and the login, and turns the VPN off.
|
|
|
|
### What Configs Work
|
|
|
|
* **WireGuard**: any config with an `[Interface]` (PrivateKey and Address) and at least one `[Peer]` (PublicKey and
|
|
Endpoint). Commands in the config (`PostUp`, `PreDown`, etc.) are ignored.
|
|
* **OpenVPN**: TUN configs whose certificates and keys are inside the file (`<ca>`, `<cert>`, `<key>` blocks), as
|
|
providers' downloadable configs usually are. Configs which run scripts, use a proxy, or use TAP are refused, and
|
|
WROLPi says why.
|
|
|
|
## Port Forwarding
|
|
|
|
Torrent peers connect to each other. Without port forwarding, your WROLPi can only connect *out* to peers: you can
|
|
download, and upload to peers who accept connections, but peers behind their own firewalls (many home users) cannot
|
|
connect to you. The Torrents page shows this as **Firewalled**.
|
|
|
|
To seed to everyone, your VPN provider must forward a port to your WROLPi. Choose the mode your provider offers:
|
|
|
|
| Mode | When to use it |
|
|
|----------|----------------------------------------------------------------------------------------------------------------------|
|
|
| None | Your provider does not forward ports. Torrents work, but are firewalled. |
|
|
| Fixed | Your provider forwards a port you chose on their website. Enter that port. |
|
|
| NAT-PMP | Your provider gives a port to whoever asks (NAT-PMP). WROLPi asks for one, keeps it, and shows it in the status. |
|
|
|
|
Providers change what they offer; check your provider's website. At the time of writing:
|
|
|
|
| Provider | Port forwarding | How |
|
|
|--------------------|-----------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
|
| Proton VPN | NAT-PMP | Use a P2P server. For WireGuard, turn on NAT-PMP (port forwarding) when making the config. For OpenVPN, add `+pmp` to your OpenVPN username (e.g. `name+pmp`). |
|
|
| AirVPN | Fixed | Choose a port in AirVPN's Client Area, and enter it in WROLPi. |
|
|
| Mullvad, IVPN | None | Both stopped offering port forwarding in 2023. |
|
|
| Others | Varies | A provider which forwards a port through its own app, or changes the port every session, works with **None** only. |
|
|
|
|
## Fail-Closed
|
|
|
|
The VPN is fail-closed: torrents can only reach the Internet through it. If the VPN disconnects, cannot connect, is
|
|
turned off, or its config is removed, torrents stop; they never fall back to your WROLPi's own Internet connection.
|
|
Through the VPN, nothing from the Internet reaches your WROLPi except the forwarded port, and only the torrent client
|
|
listens on it.
|
|
|
|
When you have torrents and the VPN is not connected, a warning icon appears in the navigation bar. It opens the VPN
|
|
settings.
|
|
|
|
WROL Mode turns the VPN off.
|
|
|
|
## What the VPN Does Not Protect
|
|
|
|
The VPN hides your address from torrent peers and trackers. It does not:
|
|
|
|
* Hide what you share. Anyone with a torrent's magnet link can see what it contains, and download it.
|
|
* Make you anonymous to your VPN provider, which can see your traffic's destinations. Choose a provider you trust.
|
|
* Protect the rest of your network. Only torrents use the VPN.
|
|
* Keep a forwarded port private. Anyone on the Internet can connect to the torrent client through it. The torrent client
|
|
runs without privileges and cannot change WROLPi's config, but it can read and write your library. Keep your WROLPi
|
|
upgraded so it has the torrent client's latest security fixes.
|
|
|
|
## Where the VPN is Kept
|
|
|
|
The VPN config and login are kept in `config/vpn/`, and its settings in the `vpn` section of `controller.yaml`. WROLPi
|
|
never serves `config/vpn/` on your network, and a [secondary WROLPi](../../system/sync.md) does not copy it.
|
|
|
|
On a Raspberry Pi or Debian, the VPN is the `wrolpi-vpn` service and the torrent client is the `wrolpi-torrent`
|
|
service; see [Services](../../system/systemd.md). In Docker, both are in the `vpn` container.
|