Retrieving authorization JWT from Go CLI program.

This page summarizes the projects mentioned and recommended in the original post on /r/golang

Our great sponsors
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • WorkOS - The modern identity platform for B2B SaaS
  • SaaSHub - Software Alternatives and Reviews
  • oauth2

    Go OAuth2

  • For OAuth2 I've always used the standard library, which is fine as long as you don't need to handle token refresh -- and assuming you're getting a JWT from an OAuth2 endpoint, I'm guessing you don't. (It can be done, but it's problematic.)

  • jwtauth

    Session-based authentication in Go using JWT & JWS (by lpar)

  • I recommend github.com/lestrrat-go/jwx for your JWT-handling needs. If you want some examples of using it, try here.

  • InfluxDB

    Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.

    InfluxDB logo
  • go-oidc

    A Go OpenID Connect client.

  • If you actually have OpenID Connect then there are some good libraries to use for token management in that case. Iirc I prefer https://github.com/coreos/go-oidc, since it supports auto discovery and key rotation etc.

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts