Skip to content
프로젝트

소개

POSIX 셸로 WARP WireGuard 설정을 생성합니다.

시스템 및 인프라

이 수치를 측정하는 방법

측정된 스타 증가

in 24h
0
in 7 days
0
in 15 days
0
in 1 month
기록 수집 중

서로 겹치는 기간의 순증가량이며 일별 합계가 아닙니다. 측정값이 없으면 비워 둡니다. 스타는 관심도를 나타내며 품질을 보장하지 않습니다.

README.md

Original

warp.sh

By using this you agree to Cloudflare's ToS: https://www.cloudflare.com/application/terms/

Quick Guide #1

Make sure to have jq, curl, and wireguard-tools (for wg genkey and wg pubkey) installed before using this shell script.

git clone https://github.com/rany2/warp.sh.git
cd warp.sh
./warp.sh

The generated wireguard config will be printed to stdout.

Quick Guide #2

To execute this script on GitHub Codespaces without the need to set up a local environment, follow these steps:

  1. Open the repository and locate the green buttons. Click on "Code" then select "Codespaces" and finally choose "Create codespace on master".
  2. Wait for the codespace to be created. Once it's ready, open the terminal and run the command ./warp.sh.
  3. After you've finished using the codespace, it's important to delete it to maintain cleanliness and save resources.

Please note that deleting the codespace will remove all the changes and configurations made within it, so make sure to save any important files or settings before closing.

Usage options

Usage ./warp.sh [options]
  -4  use ipv4 for curl
  -6  use ipv6 for curl
  -T  teams JWT token (default no JWT token is sent)
  -R  refresh token (format is token,device_id,wg_private_key; specify this to get a refreshed config)
  -t  show cloudflare trace and exit only
  -h  show this help page and exit only

Regarding Teams enrollment

  1. Visit https://<teams id>.cloudflareaccess.com/warp
  2. Authenticate yourself as you would with the official client
  3. Check the source code of the page for the JWT token or use the following code in the "Web Console" (Ctrl+Shift+K):
console.log(document.querySelector("meta[http-equiv='refresh']").content.split("=")[2])
  1. Pass the output as the value for the parameter -T. The final command will look like:
./warp.sh -T eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.....

Regarding -T and -R options

-T and -R both could take a file as an argument. The file should be in the same format as the command line argument. This is so that the token wouldn't be exposed in the shell history or process list.

관련 프로젝트 살펴보기

불러오는 중…