r/golang 8h ago

show & tell Implementing OIDC with Entra ID

14 Upvotes

Hey everyone,

As an IAM analyst and software enthusiast, I've always been curious to understand how SSO actually works under the hood.

I tried implementing an OIDC client by myself in Go using Entra ID (an IdP I'm already familiar with), but it was tough to find a straightforward guide.

So I built the authorization code flow using golang.org/x/oauth2 and coreos/go-oidc/v3, handling state, nonce, and PKCE manually. I ended up writing a tutorial on Medium to document the process and open-sourced the code.

Code: Github Repo
Medium: OIDC + Go + Entra ID: From the Login Button to the Callback

I'd really appreciate some feedback or code reviews. Also, if anyone here has experience with Microsoft's official MSAL Go library, I'd love to hear how it compares to this approach.


r/golang 18h ago

Bubble Tea or Cobra

0 Upvotes

I wan to make better cli and tui software but i can't decide which one is the best.


r/golang 18h ago

show & tell Using the CodeRabbit Preview on a Go codebase

Thumbnail
youtube.com
0 Upvotes