Skip to content
This repository has been archived by the owner on Aug 24, 2024. It is now read-only.

A simple of cloudflare access login page with using NodeJS

Notifications You must be signed in to change notification settings

kuronekouwu/cloudflare-access-login

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Cloudflare access login

A simple login cloudflare access and store token into .cloudflared with using NodeJS

⚠️ Note

I'm not cloudflared developer. I use code reference from repo Cloudflared. The reason why I made this. Because I use from porject FishTerm.

Install

npm install https://github.com/mrwan200/cloudflare-access-login

or 

yarn add https://github.com/mrwan200/cloudflare-access-login

How to use

1. With CIL

cflogin <URL_ACCESS>

2. With code

import { CloudflreAccess } from "./access";

const cf = new CloudflreAccess();
cf.events.on("login", (url) => {
    // Will return URL for authentication
}));
cf.events.on("complete", (token) => {
    // Will retuen token for access tunnel, etc.
})
cf.login('<ACCESS_URL>').then(() => {})

Enjoy!

IMG

About

A simple of cloudflare access login page with using NodeJS

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published