🚤 Cross-platform, unofficial CLI for Cloudflare Warp

wgcf

wgcf is an unofficial, cross-platform CLI for Cloudflare Warp

Features

  • Register new account
  • Change license key to use existing Warp+ subscription
  • Generate WireGuard profile
  • Check account status
  • Print trace information to debug Warp/Warp+ status

Download

You can find pre-compiled binaries on the releases page.

Usage

Run wgcf in a terminal without any arguments to display the help screen. All commands and parameters are documented.

Register new account

Run the following command in a terminal:

wgcf register

The new account will be saved under wgcf-account.toml

Generate WireGuard profile

Run the following command in a terminal:

wgcf generate

The WireGuard profile will be saved under wgcf-profile.conf. For more information on how to use it, please check the official WireGuard Quick Start.

Maximum transmission unit (MTU)

To ensure maximum compatibility, the generated profile will have a MTU of 1280, just like the official Android app. If you are experiencing performance issues, you may be able to improve your speed by increasing this value. For more information, please check #40.

Change license key

If you have an existing Warp+ subscription, for an example on your phone, you can bind the account generated by this tool to your phone's account, sharing its Warp+ status. Please note that there is a current limit of maximum 5 linked devices active at a time.

⚠️ This device's private key will be changed!

First, get your Warp+ account license key. To view it on Android:

  1. Open the 1.1.1.1 app
  2. Click on the hamburger menu button on the top-right corner
  3. Navigate to: Account > Key

Edit wgcf-account.toml directly with the new license key and run:

wgcf update

or, using an environment variable:

WGCF_LICENSE_KEY="123412341234" wgcf update

The license will be applied, and a new private key will be created for your account. Regenerate your WireGuard configuration and use the new private key.

Check device status

Run the following command in a terminal:

wgcf status

Verify Warp/Warp+ works

Connect to the WireGuard profile generated by this tool, then run:

wgcf trace

If you look at the last line, it should say warp=on or warp=plus, depending on whether you have Warp or Warp+ respectively.

Development

Sub-packages

  • api_tests - Tests for API documentation generation
  • spec_format - OpenAPI3 specification formatter to post-process the spec generated by Optic

API

This project uses Optic to automatically generate API documentation using the tests defined in api_tests. These tests cover all endpoints used by wgcf. The documentation is exported as an OpenAPI3 specification, which is then used with openapi-generator to generate the Go client API code under wgcf/openapi.

To update the API documentation, install Optic, then run:

api start

Resolve and save all the differences in the Web UI.

To regenerate the Go client API code, install openapi-generator, then run:

bash generate-api.sh

This script supports both Linux and WSL.

Notice of Non-Affiliation and Disclaimer

We are not affiliated, associated, authorized, endorsed by, or in any way officially connected with Cloudflare, or any of its subsidiaries or its affiliates. The official Cloudflare website can be found at https://www.cloudflare.com/.

The names Cloudflare Warp and Cloudflare as well as related names, marks, emblems and images are registered trademarks of their respective owners.

Owner
Victor
Looking for teleportation
Victor
Comments
  • No more warp=plus

    No more warp=plus

    Hi @ViRb3 , looks like a high number of users is losing their warp=plus connectivity. We are wondering if it's something under wgcf or Cloudflare related. Here is our reddit: https://www.reddit.com/r/CloudFlare/comments/hyt703/no_more_warp_for_wgcf/

  • 2020-06-11 20:01:25.925: [TUN] [wgcf-profile] Unable to create Wintun interface: Error registering rings: Error listing NDIS interfaces: no interfaces found

    2020-06-11 20:01:25.925: [TUN] [wgcf-profile] Unable to create Wintun interface: Error registering rings: Error listing NDIS interfaces: no interfaces found

    2020-06-11 20:01:25.925: [TUN] [wgcf-profile] Unable to create Wintun interface: Error registering rings: Error listing NDIS interfaces: no interfaces found hi pls help me

  • API update required

    API update required

    As clear from #64 and #67, the API has changed, and some people are getting rate limited. I will do my best to investigate and release an update before the weekend.

  • "Warp=plus" not working. Help!

    "Warp=plus" I have a warp plus account, but what should I do? I Can't Run warp=plus. ( sorry for the translation I do not know English. )

    20200705_020558

    Can you tell me what to do progressively?

  • 429 Too many requests

    429 Too many requests

    Seems I'm being rate limited trying to register a device. Problem is, the process is still generating an invalid .toml file when this happens. Also, it might be a good idea, if there are any headers to indicate when the request will be available again, to display when this would be.

  • No Ip Change Manjaro

    No Ip Change Manjaro

    Hello, Im using manjaro, after creating and updating profile, i imported config to vpn connection. When i connect it says"connected" but ip is the same. Working on windows. image

  • Wireguard config for Android and iOS

    Wireguard config for Android and iOS

    Are there plans to make wgcf available for use in Android and iOS using the Wireguard app? I understand that there is a Warp app offered by Cloudflare, but it doesn't have an option to set custom DNS servers.

    It'd be nice to generate a config file using wgcf and use it on Wireguard app for Android/iOS.

  • Can't reach 1.1.1.1

    Can't reach 1.1.1.1

    Everything is fine via mobile app, tried key from app, and generated through wgcf. pings can reach 1.1.1.1 just fine but upon bringing wg interface up pinging is no longer possible checked that I'm not going through proxy, my resolv.conf is proper 1.1.1.1/ 1.0.0.1. My connection doesn't have ipv6

    ./wgcf trace
    2020/04/28 18:21:58 Using config file: wgcf-account.toml
    2020/04/28 18:22:08 Get "https://cloudflare.com/cdn-cgi/trace": dial tcp: lookup cloudflare.com on 1.1.1.1:53: read udp 172.16.0.2:38131->1.1.1.1:53: i/o timeout
  • Internet gets disabled when I try to run wg client

    Internet gets disabled when I try to run wg client

    Timeout error as the internet gets disabled when running the wg-quick up wgcf-profile.conf. In my mobile, the app 1.1.1.1 works fine. Also, I didn't get this issue on windows laptop(downloading, browsing all works fine) but on ubuntu after sometime internet gets disabled when try to run wg client.

    ravinder@ravinder-Aspire-A515-51:$ wg-quick up wgcf-profile.conf [#] ip link add wgcf-profile type wireguard [#] wg setconf wgcf-profile /dev/fd/63 [#] ip -4 address add 172.16.0.2/32 dev wgcf-profile [#] ip -6 address add fd01:5ca1:ab1e:8c92:3e75:2f5:4a5e:47d1/128 dev wgcf-profile [#] ip link set mtu 1420 up dev wgcf-profile [#] resolvconf -a tun.wgcf-profile -m 0 -x [#] wg set wgcf-profile fwmark 51820 [#] ip -6 route add ::/0 dev wgcf-profile table 51820 [#] ip -6 rule add not fwmark 51820 table 51820 [#] ip -6 rule add table main suppress_prefixlength 0 [#] ip6tables-restore -n [#] ip -4 route add 0.0.0.0/0 dev wgcf-profile table 51820 [#] ip -4 rule add not fwmark 51820 table 51820 [#] ip -4 rule add table main suppress_prefixlength 0 [#] sysctl -q net.ipv4.conf.all.src_valid_mark=1 [#] iptables-restore -n ravinder@ravinder-Aspire-A515-51:$ ./wgcf_1.0.5_linux_amd64 trace --config "ravinder_private/warp+.toml" 2020/04/25 10:45:54 Using config file: ravinder_private/warp+.toml 2020/04/25 10:46:14 Get "https://cloudflare.com/cdn-cgi/trace": dial tcp: lookup cloudflare.com on 127.0.0.53:53: read udp 127.0.0.1:36291->127.0.0.53:53: i/o timeout ravinder@ravinder-Aspire-A515-51:$ wg-quick down wgcf-profile.conf [#] ip -4 rule delete table 51820 [#] ip -4 rule delete table main suppress_prefixlength 0 [#] ip -6 rule delete table 51820 [#] ip -6 rule delete table main suppress_prefixlength 0 [#] ip link delete dev wgcf-profile [#] resolvconf -d tun.wgcf-profile -f [#] iptables-restore -n [#] ip6tables-restore -n

  • 400 Bad Request when trying to update with warp+ license key

    400 Bad Request when trying to update with warp+ license key

    I downloaded v2.2.8 for windows / AMD64 and ran the following:

    1. Called wgcf_2.2.8_windows_amd64.exe register
    2. Added my own warp+ license key (that I use in the IOS and Windows Cloudflare Applications) to the generated wgcf-account.toml file (also tried the env variable way.. same thing)
    3. Called wgcf_2.2.8_windows_amd64.exe update

    Result:

    2021/08/30 11:03:13 Using config file: wgcf-account.toml
    2021/08/30 11:03:14 Updated license key detected, re-binding device to new account
    2021/08/30 11:03:15 400 Bad Request
    

    .. and that's it. Is there anything I am doing wrong / missing and/or is there any way to find out what is causing the 400 Bad Request response?

    Oh and the license key is only used by the two aforementioned apps / devices, as also visible in them under the Account section:

    image

  • Changing DNS over HTTPS to TLS/Warp

    Changing DNS over HTTPS to TLS/Warp

    @ViRb3 According to https://github.com/ViRb3/wgcf/issues/57 This configuration file used with wireguard works over the HTTPS protocol. Which can be checked over https://cloudflare-dns.com/help

    Is there a way to change DoH to DoT or Warp? Also, what's the gateway=off signify under warp status when wgcf trace is run?

    EDIT: Just when I made this post, I checked again and miraculously it showed me DNS over Warp. (I did not disconnect, merely checked another website which was blocked in my country, which only worked under the DoH and it didn't, so I checked back again on that site) image I hope this is not unstable and doesn't keep switching. Although, when I used the official app that kept switching over and over again on the site, but my blocked site worked fine over it as long as the connection protocol in app was set at DoH and not Warp. nvm, seems like the site is not so stable or sure-fire way to check, checked again and it's back to DoH but my blocked site doesn't work anymore, miraculously it had worked once earlier. Either way, I guess there needs to be a way to switch over DNS over settings manually.

  • fix(deps): bump goreleaser/goreleaser-action from 2.9.1 to 4.1.0

    fix(deps): bump goreleaser/goreleaser-action from 2.9.1 to 4.1.0

    Bumps goreleaser/goreleaser-action from 2.9.1 to 4.1.0.

    Release notes

    Sourced from goreleaser/goreleaser-action's releases.

    v4.1.0

    What's Changed

    New Contributors

    Full Changelog: https://github.com/goreleaser/goreleaser-action/compare/v4...v4.1.0

    v4.0.0

    What's Changed

    Full Changelog: https://github.com/goreleaser/goreleaser-action/compare/v3...v4.0.0

    v3.2.0

    What's Changed

    • chore: remove workaround for setOutput by @​crazy-max (#374)
    • chore(deps): bump @​actions/core from 1.9.1 to 1.10.0 (#372)
    • chore(deps): bump yargs from 17.5.1 to 17.6.0 (#373)

    Full Changelog: https://github.com/goreleaser/goreleaser-action/compare/v3.1.0...v3.2.0

    v3.1.0

    What's Changed

    • fix: dist resolution from config file by @​crazy-max (#369)
    • ci: fix workflow by @​crazy-max (#357)
    • docs: bump actions to latest major by @​crazy-max (#356)
    • chore(deps): bump crazy-max/ghaction-import-gpg from 4 to 5 (#360)
    • chore(deps): bump ghaction-import-gpg to v5 (#359)
    • chore(deps): bump @​actions/core from 1.6.0 to 1.8.2 (#358)
    • chore(deps): bump @​actions/core from 1.8.2 to 1.9.1 (#367)

    Full Changelog: https://github.com/goreleaser/goreleaser-action/compare/v3.0.0...v3.1.0

    v3.0.0

    What's Changed

    ... (truncated)

    Commits
    • 8f67e59 chore: regenerate
    • 78df308 chore(deps): bump minimatch from 3.0.4 to 3.1.2 (#383)
    • 66134d9 Merge remote-tracking branch 'origin/master' into flarco/master
    • 3c08cfd chore(deps): bump yargs from 17.6.0 to 17.6.2
    • 5dc579b docs: add example when using workdir along with upload-artifact (#366)
    • 3b7d1ba feat!: remove auto-snapshot on dirty tag (#382)
    • 23e0ed5 fix: do not override GORELEASER_CURRENT_TAG (#370)
    • 1315dab update build
    • b60ea88 improve install
    • 4d25ab4 Update goreleaser.ts
    • Additional commits viewable in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
  • fix(deps): bump golang from 1.18.3-alpine to 1.19.4-alpine

    fix(deps): bump golang from 1.18.3-alpine to 1.19.4-alpine

    Bumps golang from 1.18.3-alpine to 1.19.4-alpine.

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
  • fix(deps): bump alpine from 3.16.0 to 3.17.0

    fix(deps): bump alpine from 3.16.0 to 3.17.0

    Bumps alpine from 3.16.0 to 3.17.0.

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
  • Optic cli deprecated

    Optic cli deprecated

    Unfortunately the optic "cli" package, which includes the "api" command was deprecated. I wanted to add support for Teams/Zero Trust in wgcf (#56), but I can't get the old api generation system up and running because of deviating node dependencies.

    Is there a known working configuration (npm package file etc.) for the dependencies?

    In the future we should update the api generation to use the new version of optic.

  • fix(deps): bump cycjimmy/semantic-release-action from 3.0.0 to 3.2.0

    fix(deps): bump cycjimmy/semantic-release-action from 3.0.0 to 3.2.0

    Bumps cycjimmy/semantic-release-action from 3.0.0 to 3.2.0.

    Release notes

    Sourced from cycjimmy/semantic-release-action's releases.

    v3.2.0

    3.2.0 (2022-11-04)

    Features

    • added gitHead and gitTag outputs (385af4f)

    v3.1.2

    3.1.2 (2022-10-19)

    Bug Fixes

    • actions: update @​actions/core to cope with new output (3e7aded)

    v3.1.1

    3.1.1 (2022-08-30)

    Bug Fixes

    • set last_release_version output even if no release has been published (b1467cd)

    v3.1.0

    3.1.0 (2022-08-05)

    Features

    • handle versioned extends inputs correctly (4a51b9f)
    Changelog

    Sourced from cycjimmy/semantic-release-action's changelog.

    3.2.0 (2022-11-04)

    Features

    • added gitHead and gitTag outputs (385af4f)

    3.1.2 (2022-10-19)

    Bug Fixes

    • actions: update @​actions/core to cope with new output (3e7aded)

    3.1.1 (2022-08-30)

    Bug Fixes

    • set last_release_version output even if no release has been published (b1467cd)

    3.1.0 (2022-08-05)

    Features

    • handle versioned extends inputs correctly (4a51b9f)
    Commits
    • 8f6ceb9 chore(release): 3.2.0 [skip ci]
    • a297eb1 Merge pull request #135 from dkhunt27/cycjimmy
    • 385af4f feat: added gitHead and gitTag outputs
    • 17e74ff Merge pull request #2 from cycjimmy/main
    • bdd914f docs(README): update broken links
    • be27b56 chore(release): 3.1.2 [skip ci]
    • 37e7c02 Merge pull request #129 from OlivierCuyp/main
    • 3e7aded fix(actions): update @​actions/core to cope with new output
    • 8139709 Merge pull request #126 from cycjimmy/dependabot/npm_and_yarn/actions/core-1....
    • 269aa6b Merge pull request #124 from nickmccurdy/rename-to-main
    • Additional commits viewable in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
A simple CLI app to update dynamic DNS settings for your CloudFlare account

Cloudflare Dynamic DNS Updater (Go) written by Darren Rambaud Why? A simple CLI app to update dynamic DNS settings for your CloudFlare account. Useful

Nov 28, 2021
cross-platform, cli app to perform various operations on string
cross-platform, cli app to perform various operations on string

sttr is command line software that allows you to quickly run various transformation operations on the string.

Dec 30, 2022
ntest is a cross-platform cli app that runs multiple tests against any address.
ntest is a cross-platform cli app that runs multiple tests against any address.

ntest ntest is a cross-platform cli app that runs multiple tests against any address. About ntest Having the ability to run common tests against any d

Jan 3, 2022
remonade - Unofficial Nature Remo CLI
 remonade - Unofficial Nature Remo CLI

remonade - Unofficial Nature Remo CLI Requirements Go 1.16 ~ Installation From source code $ go install github.com/skanehira/remonade@latest From Rele

Jun 29, 2022
An unofficial command line interface (CLI) for ASPEN's Oneliner application

Overview OlxCLI is an unofficial command line interface (CLI) for ASPEN's Oneliner application. The CLI provides commands for running common fault sim

Jan 3, 2022
Hakuna Go: an unofficial CLI for the time-tracking tool Hakuna

Hakuna Go Hakuna Go is an unofficial CLI for the time-tracking tool Hakuna. Inst

Apr 25, 2022
A simple logging interface that supports cross-platform color and concurrency.
A simple logging interface that supports cross-platform color and concurrency.

WLog Package wlog creates simple to use UI structure. The UI is used to simply print to the screen. There a wrappers that will wrap each other to crea

Sep 26, 2022
cross platform command line tool to list, notify and book vaccine using cowin API

Command line tool to List and Book Vaccine cowin-cli is a simple cli tool to book vaccines and list centers using the COWIN API. It also supports auto

Mar 7, 2022
🐘 Cross-platform, neofetch alternative for fetching system info.
 🐘 Cross-platform, neofetch alternative for fetching system info.

elefetch ?? Cross-platform, neofetch alternative for fetching system info. Installation go get: go get -u github.com/burntcarrot/elefetch Binaries Bin

Jan 23, 2022
F2 is a cross-platform command-line tool for batch renaming files and directories quickly and safely. Written in Go!
F2 is a cross-platform command-line tool for batch renaming files and directories quickly and safely. Written in Go!

F2 is a cross-platform command-line tool for batch renaming files and directories quickly and safely.

Dec 31, 2022
Battery - cross-platform get battery status

battery Cross-platform get battery status. Tested on Arch Linux, Debian, Ubuntu, Windows, macOS. import "github.com/caiguanhao/battery" battery.GetSt

Dec 31, 2021
Bibliotheca - Unofficial Bibliotheca cloudLibrary API - in Go

bibliotheca ?? Go library for Bibliotheca cloudLibrary WARNING: This library mak

Jan 4, 2022
Unofficial command line interface for legendastv
Unofficial command line interface for legendastv

legendastv-cli Unofficial command line interface for legendastv Installing Check binaries folder for your distribution. MacOS: wget https://raw.github

Jan 12, 2022
a work time management CLI tool for any platform
a work time management CLI tool for any platform

english |日本語 jobgosh | job management tool made with golang for shell a multi-platform work time management CLI tool to track and improve your day to

May 16, 2022
This tool is a CLI-interactive tool for TA who use eeclass platform

NTHU eeclass TA helper. This tool is a CLI-interactive tool for TA who use eeclass platform. It helps TA to download all the submitted homework, and use CSV to record the score and comment, and upload CSV score directly to the eeclass platform with just 2 Enter key!

Dec 11, 2021
CLI for NoCloud Platform

nocloud-cli Official CLI for NoCloud Platform Table of Contents Usage Installation Notes Usage Check out nocloud -h for list of available commands. Yo

Jan 6, 2022
gopsa is a CLI tool to enter timecard entries to the Salesforce PSA platform.
gopsa is a CLI tool to enter timecard entries to the Salesforce PSA platform.

gopsa Overview gopsa is a CLI tool to enter timecard entries to the Salesforce PSA platform. Credit This project is a rewrite of the excellent work fr

Nov 22, 2021
Elegant CLI wrapper for kubeseal CLI

Overview This is a wrapper CLI ofkubeseal CLI, specifically the raw mode. If you just need to encrypt your secret on RAW mode, this CLI will be the ea

Jan 8, 2022
CLI to run a docker image with R. CLI built using cobra library in go.
CLI  to run a docker image with R. CLI built using cobra library in go.

BlueBeak Installation Guide Task 1: Building the CLI The directory structure looks like Fastest process: 1)cd into bbtools 2)cd into bbtools/bin 3)I h

Dec 20, 2021