Automatically create ephemeral ports in Windscribe and update your torrent client to use the new port
Caution
v3 has not been well tested yet, use at your own risk. Feedback welcome.
A while ago Windscribe added Cloudflare CAPTCHA, and their own CAPTCHA to the login endpoint, so we can no longer log in using the normal credentials reliably. Normal web sessions expire, but the session in the Windscribe app doesn't. Turns out that at some point, they decided to merge the APIs, and now the same token that's used in the app also works on the web. This means that you only need to extract it once, and as long as you don't log out of the desktop app, it will keep working.
Download the official app and log in
There is a (vibe coded) Python script available here that will extract it for you (Tested on Linux/Windows)
For manual extraction, the value you're looking for is named authHash and is located inside of the wsnetSettings key in:
$XDG_CONFIG_HOME/Windscribe/Windscribe2.confHKCU\Software\Windscribe\Windscribe2DON'T LOG OUT! It will invalidate the session. If you want to log out without invalidating it, remove the configuration files listed above instead.
Configuration is done using environment variables
At least one torrent client or gluetun is required to be configured.
| Variable | Description | Required | Default |
|---|---|---|---|
| WINDSCRIBE_AUTH_HASH | authHash extracted from the desktop app | YES | |
| DELUGE_URL | The base URL for the deluge web UI | NO | |
| DELUGE_PASSWORD | The password for the deluge web UI | NO | |
| DELUGE_HOST_ID | The internal host id to connect to in the deluge web UI. It will be printed in stdout after the first successful connection to deluge | Only if you have more than one connection configured in connection manager | If you have multiple configured in deluge web ui the app will print them out and crash. If you have only one, that one will be used, and you don't need to specify it explicitly |
| QBITTORRENT_URL | The base URL for the qBittorrent web UI | NO | |
| QBITTORRENT_API_KEY | The API key for the qBittorrent (qBittorrent >= v5.2.0) | NO | |
| TRANSMISSION_URL | The base URL for the transmission web UI (transmission >= 4.1) | NO | |
| TRANSMISSION_USERNAME | The username for the transmission web UI | NO | |
| TRANSMISSION_PASSWORD | The password for the transmission web UI | NO | |
| GLUETUN_URL | The base URL for the gluetun Control server | NO | |
| GLUETUN_API_KEY | The API key for the gluetun Control server (needs /v1/portforward permission) | NO | |
| WINDSCRIBE_RETRY_DELAY | how long to wait (in milliseconds) before retrying after a windscribe error. | NO | 3600000 (1 hour) |
| WINDSCRIBE_EXTRA_DELAY | how long to wait (in milliseconds) after the ephemeral port expires before trying to create a new one. | NO | 60000 (1 minute) |
| TORRENT_RETRY_DELAY | how long to wait (in milliseconds) before retrying after a torrent client error | NO | 300000 (5 minutes) |
services:
windscribe-ephemeral-port-torrent:
image: dumbaspl/windscribe-ephemeral-port-torrent:latest
restart: unless-stopped
environment:
WINDSCRIBE_AUTH_HASH: <authHash>
# DELUGE_URL: http://deluge:8112
# DELUGE_PASSWORD: <password>
# QBITTORRENT_URL: http://qbittorrent:8080
# QBITTORRENT_API_KEY: <apiKey>
# TRANSMISSION_URL: http://transmission:9091
# TRANSMISSION_USERNAME: <username>
# TRANSMISSION_PASSWORD: <password>
# GLUETUN_URL: http://gluetun:8000
# GLUETUN_API_KEY: <apiKey>
make a .env file with the necessary configuration
go build -o windscribe-ephemeral-port-torrent
./windscribe-ephemeral-port-torrent
Make yourself a systemd service or something
Previous versions of this project were fully handwritten by me, this is an AI-assisted rewrite of the original codebase in GO with support for more torrent clients.
All code has been reviewed and tested by me.
With pet projects, I prefer to write things myself. No guarantees that I won't abandon your PR for 2 years and then re-write it. Debugging, testing, and feedback always welcome.
Content type
Image
Digest
sha256:7d1c4d24b…
Size
3.5 MB
Last updated
about 1 month ago
docker pull dumbaspl/windscribe-ephemeral-port-torrent:3.0.0-rc2