Tool to automate the OAuth 2.0/OIDC flows
Find a file
2024-02-22 10:57:39 -07:00
bin Added build script 2024-02-21 17:53:50 -07:00
cmd Added access token fetching 2024-02-22 10:57:39 -07:00
internal Added access token fetching 2024-02-22 10:57:39 -07:00
.gitignore Fixed login file name and added to .gitignore 2024-02-21 17:56:32 -07:00
go.mod Added ability to get authorization code 2024-02-21 20:26:25 -07:00
go.sum Added ability to get authorization code 2024-02-21 20:26:25 -07:00
main.go Added CLI and more functionality 2024-02-21 17:51:59 -07:00
README.md Updated README.md and fixed issue fetching token 2024-02-21 20:59:48 -07:00

OpenID Connect Authentication Helper

This is a small, simple, experimental helper tool that automates the authorization code flow for logging in with an identity provider like GitHub or GitLab. This tool acts as an OAuth app, contains client secrets, and should not be exposed to users!

To use this tool, you will have to register an OAuth2 application with you identity provider. Make sure you register the application first before proceeding, then set the callback URL to {your host}/oauth/callback.

To get started with the authentication flow, run the following commands:

./oidc config ./config.yaml
./oidc login --config config.yaml

These commands will create a default config, then start the login process. Initially, you'll have to click on the link created based on you configuration, login with your IdP, then authorize the client to within the set scope.