Skip to content

Simple Reverse Proxy with Http Basic Auth via Cloudflare Workers

Notifications You must be signed in to change notification settings

yqs112358/CFWorker-BasicAuth-Reverse-Proxy

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 

Repository files navigation

Simple Reverse Proxy with Http-Basic Auth via Cloudflare Workers

Forked from https://github.com/dommmel/cloudflare-workers-basic-auth and add simple reverse proxy

Attention!

Never create reverse proxy on Cloudflare Workers without auth protection!

  • Services without auth may be abused, and then lead to your CloudFlare account being locked.
  • Use this project to protect your proxy behind http-basic auth.

Usage

  1. Set secrets and target host name in index.js
const SECRET = "your-secret";               // Set your secret key here
const HOST_NAME = "target-website.com";     // Set target website you want to proxy here
  1. Save and copy index.js to your CloudFlare worker, then deploy
  2. Visit https://your-secret@xxx.workers.dev to pass http-basic auth and access target website through proxy

About

Simple Reverse Proxy with Http Basic Auth via Cloudflare Workers

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%