oidc-auth

command
v0.53.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 19, 2026 License: Apache-2.0 Imports: 9 Imported by: 0

README

OIDC/JWT Authentication

This example demonstrates how to configure an HTTP server with OpenID Connect (OIDC) and JWT authentication.

Running the Example

go run github.com/dioad/net/examples/oidc-auth

Or build and run:

cd examples/oidc-auth
go build
./oidc-auth

Then test with a valid OIDC token:

curl -H 'Authorization: Bearer <your-token>' http://localhost:8080/secure

What It Demonstrates

  • Creating an OIDC validator configuration
  • Setting up GitHub Actions OIDC authentication
  • Using OAuth2 validator as global middleware
  • Token validation for protected endpoints

Code

See main.go for the complete executable example.

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL