Go Authentication and OAuth

Open-source Go projects categorized as Authentication and OAuth | Edit details

Top 23 Go Authentication and OAuth Projects

  • GitHub repo casbin

    An authorization library that supports access control models like ACL, RBAC, ABAC in Golang

    Project mention: What do you use for fine grained authorization? (or ABAC) | reddit.com/r/golang | 2021-08-26

    For example, I found some very good looking packages for auth: 1. keto which is apparently based on the same system Google docs itself uses. 2. casbin which looks well supported and full featured.

  • GitHub repo jwt-go

    ARCHIVE - Golang implementation of JSON Web Tokens (JWT). This project is now maintained at:

    Project mention: New version of JWT middleware for Fiber (v2.16.0) | reddit.com/r/golang | 2021-08-03

    Abandon https://github.com/dgrijalva/jwt-go library due security issues. Now I use https://github.com/golang-jwt/jwt#jwt-go

  • Scout APM

    Scout APM: A developer's best friend. Try free for 14-days. Scout APM uses tracing logic that ties bottlenecks to source code so you know the exact line of code causing performance issues and can get back to building a great product faster.

  • GitHub repo authelia

    The Single Sign-On Multi-Factor portal for web apps

    Project mention: Not a normal dashboard post, because it isn't mine! Learn security people | reddit.com/r/selfhosted | 2021-09-20

    Tip you can use a SSO like Authelia or vouch-proxy. Never expose services on internet without authentication.

  • GitHub repo oauth2

    Go OAuth2

    Project mention: What do if no progress in MR about year? | reddit.com/r/golang | 2021-09-10

    My wife sent MR into golang oauth2 library https://github.com/golang/oauth2/pull/450

  • GitHub repo goth

    Package goth provides a simple, clean, and idiomatic way to write authentication packages for Go web applications.

  • GitHub repo authboss

    The boss of http auth.

  • GitHub repo go-oauth2-server

    A standalone, specification-compliant, OAuth2 server written in Golang.

  • Nanos

    Run Linux Software Faster and Safer than Linux with Unikernels.

  • GitHub repo loginsrv

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

  • GitHub repo gologin

    Go login handlers for authentication providers (OAuth1, OAuth2)

  • GitHub repo gorbac

    goRBAC provides a lightweight role-based access control (RBAC) implementation in Golang.

  • GitHub repo scs

    HTTP Session Management for Go

    Project mention: REST API + limit number of seats | reddit.com/r/golang | 2021-09-02

    Unfortunately I haven't written a cookie/session based auth flow in Golang before so can't recommend any libraries. A quick google led me to https://github.com/alexedwards/scs which may or may not be helpful.

  • GitHub repo paseto

    Platform-Agnostic Security Tokens implementation in GO (Golang) (by o1egl)

    Project mention: Am I doing authorization correctly? I'm doing http-only cookie-based auth and to get the current user I call an API route that reads the cookie and returns the info | reddit.com/r/golang | 2021-08-15

    Check out paseto tokens

  • GitHub repo permissions2

    :closed_lock_with_key: Middleware for keeping track of users, login states and permissions

  • GitHub repo go-guardian

    Go-Guardian is a golang library that provides a simple, clean, and idiomatic way to create powerful modern API and web authentication.

    Project mention: After 2 years of Django, I'm starting using Go for building web servers. Do you guys have any suggestions? | reddit.com/r/golang | 2021-05-24

    https://github.com/labstack/echo This is going to be my next project I look at. Alternatively you can incorporate the security bits manually by importing something like: https://github.com/shaj13/go-guardian

  • GitHub repo jeff

    🍍Jeff provides the simplest way to manage web sessions in Go.

  • GitHub repo httpauth

    HTTP Authentication middlewares

  • GitHub repo jwt-auth

    This package provides json web token (jwt) middleware for goLang http servers (by adam-hanna)

  • GitHub repo auth

    Authenticator via oauth2 (by go-pkgz)

  • GitHub repo branca

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

    Project mention: SAML is insecure by design | reddit.com/r/programming | 2021-08-06

    Better alternatives would be PASETO or Branca.

  • GitHub repo webauthn

    Go package for easy WebAuthn integration (by koesie10)

  • GitHub repo yubigo

    Yubigo is a Yubikey client API library that provides an easy way to integrate the Yubico Yubikey into your existing Go-based user authentication infrastructure.

  • GitHub repo sessionup

    Straightforward HTTP session management

  • GitHub repo otpgen

    Library to generate TOTP/HOTP codes

    Project mention: Show HN: Otpgen – Library to generate TOTP/HOTP codes written in Go | news.ycombinator.com | 2021-08-15
NOTE: The open source projects on this list are ordered by number of github stars. The number of mentions indicates repo mentiontions in the last 12 Months or since we started tracking (Dec 2020). The latest post mention was on 2021-09-20.


What are some of the best open-source Authentication and OAuth projects in Go? This list will help you:

Project Stars
1 casbin 10,265
2 jwt-go 9,926
3 authelia 8,317
4 oauth2 3,829
5 goth 3,336
6 authboss 2,843
7 go-oauth2-server 1,810
8 loginsrv 1,809
9 gologin 1,433
10 gorbac 1,211
11 scs 930
12 paseto 537
13 permissions2 435
14 go-guardian 303
15 jeff 231
16 httpauth 207
17 jwt-auth 206
18 auth 163
19 branca 155
20 webauthn 139
21 yubigo 115
22 sessionup 113
23 otpgen 105
Find remote jobs at our new job board 99remotejobs.com. There are 25 new remote jobs listed recently.
Are you hiring? Post a new remote job listing for free.
SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives