It is a JWT based implement of identity server.

JWTAuth 安裝說明

基本需求


  • 安裝 docker 服務
  • 安裝 OpenSSL

安裝指令


  • 建立 OS 系統的 jwtauth 帳號

    sudo useradd -m jwtauth

  • 給予 JWTAuth 帳號可以操作 docker 的權限

    sudo usermod -aG docker jwtauth

  • 更改檔案擁有者

    sudo chown jwtauth:jwtauth ./JwtAuthSys.tar.gz

  • 搬 JwtAuthSys.tar.gz 到 jwtauth 的家目錄

    sudo mv ./JwtAuthSys.tar.gz /home/jwtauth/

  • 使用 jwtauth 身分執行以下指令

    su jwtauth

  • 解壓縮建立 JWTAuth 系統的檔案系統結構 tar 檔

    tar -zvxf ./JwtAuthSys.tar.gz ./

  • 修改 ./JWTAuthSys/SetJWTAuth.sh ,把裡面的環境變數密碼區的設定改一下

    # 設立四個 postgresql 密碼環境變數
    PG_SUPER_PASS="#JWTAuth1234#"
    PG_ADMIN_PASS="#JWTAuth1234#"
    PG_OP_PASS="#JWTAuth1234#"
    PG_QRY_PASS="#JWTAuth1234#"

    # 設定 redis cluster 中會用到的密碼環境變數
    REDIS_OP_PASS="#JWTAuth1234#"
    REDIS_READER_PASS="#JWTAuth1234#"
    REDIS_REP_PASS="#JWTAuth1234#"
    REDIS_MASTER_AUTH_PASS="#JWTAuth1234#"
    HAPROXY_AUTH_PASS="#JWTAuth1234#"

    # 設定 JWTAuth 安全參數
    JWT_SEC_KEY="696ceb369e628963ddd6e17ba4acc76c9a812d19fbfaad68d58581ca513e76e0"
    USER_PASS_SALT="ba541f1d5d01df17b01833f3255b722d540acd719bedc05af8091ac9d40e1f8e"
    JWT_AUTH_IP="xx.xx.xx.xx"
    JWT_AUTH_PORT="20001"

    20001 是預設值,請依照 SetJWTAuth.sh 中建立 JWTAuthSvr 開放的 port 決定這個值。

  • 修改 ./JWTAuthSys/JWTAuthSvr/.env.template

    # 憑證設定
    sshCert=./SSL/ForTest.crt
    sshKey=./SSL/ForTest.key

    雖然在這裡會暫時提供自簽的憑證,
    但是如果你使用自簽的憑證,就要自己處理憑證信任問題。
    這一點請特別注意。
    設定檔請依實際條件修改。

  • 執行 SetJWTAuth.sh

    sudo ./JWTAuthSys/SetJWTAuth.sh

Similar Resources

Golang based User creation and Management application. GORM, Fiber, JWT

User Creation and Management app (BACK-END) Auth Features: Create Clients (regular password + 6 one-time passwords + (optional) QR code and Secret for

Dec 2, 2022

This repository contains a set of tools to help you implement IndieAuth, both server and client, in Go.

This repository contains a set of tools to help you implement IndieAuth, both server and client, in Go.

Nov 26, 2022

:key: Secure alternative to JWT. Authenticated Encrypted API Tokens for Go.

branca branca is a secure alternative to JWT, This implementation is written in pure Go (no cgo dependencies) and implements the branca token specific

Dec 29, 2022

An implementation of JOSE standards (JWE, JWS, JWT) in Go

Go JOSE Package jose aims to provide an implementation of the Javascript Object Signing and Encryption set of standards. This includes support for JSO

Dec 18, 2022

This is an implementation of JWT in golang!

jwt This is a minimal implementation of JWT designed with simplicity in mind. What is JWT? Jwt is a signed JSON object used for claims based authentic

Oct 25, 2022

This package provides json web token (jwt) middleware for goLang http servers

jwt-auth jwt auth middleware in goLang. If you're interested in using sessions, checkout my sessions library! README Contents: Quickstart Performance

Dec 5, 2022

Golang implementation of JSON Web Tokens (JWT)

jwt-go A go (or 'golang' for search engine friendliness) implementation of JSON Web Tokens NEW VERSION COMING: There have been a lot of improvements s

Jan 6, 2023

JWT login microservice with plugable backends such as OAuth2, Google, Github, htpasswd, osiam, ..

JWT login microservice with plugable backends such as OAuth2, Google, Github, htpasswd, osiam, ..

loginsrv loginsrv is a standalone minimalistic login server providing a JWT login for multiple login backends. ** Attention: Update to v1.3.0 for Goog

Dec 24, 2022

Simple JWT Golang

sjwt Simple JSON Web Token - Uses HMAC SHA-256 Example // Set Claims claims := New() claims.Set("username", "billymister") claims.Set("account_id", 86

Dec 8, 2022
Identity - An OAuth2 identity provider that operates over gRPC

Otter Social > Identity Provider An OAuth2 identity provider that operates over

May 2, 2022
JWT wrapper library which makes it simple to use ECDSA based JWT signing

JWT JWT wrapper library which makes it simple to user ECDSA based JWT signing. Usage package main import ( "context" "github.com/infiniteloopcloud

Feb 10, 2022
Go-gin-jwt - Secure web api using jwt token and caching mechanism

Project Description This project demonstrate how to create api and secure it wit

Jan 27, 2022
Account-jwt-go - Simple JWT api with go, gorm, gin
Account-jwt-go - Simple JWT api with go, gorm, gin

Account JWT on Go Go, gorm, Gin web framework 를 활용하여 만든 간단한 JWT API 입니다. Dajngo의

Apr 14, 2022
Krakend-jwt-header-rewriter - Kraken Plugin - JWT Header Rewriter

Kraken Plugin - JWT Header Rewriter 1 Plugin Configuration Name Desciption Defau

Feb 15, 2022
ZITADEL - Identity Experience Platform
ZITADEL - Identity Experience Platform

What Is ZITADEL ZITADEL is a "Cloud Native Identity and Access Management" solution built for the cloud era. ZITADEL uses a modern software stack cons

Jan 1, 2023
Demonstration of sharing secret data between an OAuth/OIDC client and an Identity Providers web client.

OAuth / OIDC Cubbyhole Share secret data between client applications. This is mostly a demonstration of some of the work I've been evaluating at Storj

Mar 21, 2022
Authenticating using Workload Identity Federation to Cloud Run, Cloud Functions
Authenticating using Workload Identity Federation to Cloud Run, Cloud Functions

Authenticating using Workload Identity Federation to Cloud Run, Cloud Functions This tutorial and code samples cover how customers that use Workload i

Dec 3, 2022
Small Lambda function which performs a Aws:Sts:AssumeRole based on the presented JWT-Token

About This implements a AWS Lambda handler which takes a JWT-Token, validates it and then performs a Aws:Sts:AssumeRole based on preconfigured rules.

Aug 8, 2022
HMAC-based JWT written in Go

JWT JSON Web Tokens JSON Web Tokens are an open, industry standard RFC 7519 method for representing claims securely between two parties. Usage of jwt:

Nov 16, 2021