Documentation ¶
Index ¶
Constants ¶
View Source
const ( // https://docs.github.com/en/developers/apps/building-oauth-apps/authorizing-oauth-apps#1-request-a-users-github-identity GithubAuthURL = "https://github.com/login/oauth/authorize" // https://docs.github.com/en/developers/apps/building-oauth-apps/authorizing-oauth-apps#2-users-are-redirected-back-to-your-site-by-github GithubTokenURL = "https://github.com/login/oauth/access_token" GithubUserInfoEndpoint = "https://api.github.com/user" GitHubEmailsEndpoint = "https://api.github.com/user/emails" )
Variables ¶
View Source
var ( AboutPath = "/about" APIPath = "/api" AccountCallbackPath = "/auth/callback" ErrorPath = "/error" ExternalIDPPath = "/external-idp" ForgotPasswordPath = "/forgot-password" HealthzPath = "/healthz" HomePath = "/" LoginPath = "/login" LogoutPath = "/logout" StaticPath = "/static*" //OAuth2CallbackPath = "/oauth2/callback" OAuth2CallbackPath = "@@OAuth2CallbackPath@@" OAuth2TokenEndpointPath = "/token" OIDCAuthorizationEndpointPath = "/oidc/v1/auth" OIDCLoginPath = "/oidc-login" OIDCLoginPasskeyPath = "/oidc-login-passkey" OIDCLoginPasswordPath = "/oidc-login-password" OIDCLoginTOTPPath = "/oidc-login-totp" PasswordResetPath = "/password-reset" ProfilePath = "/profile" PersonalInformationPath = "/profile/personal-information" PasskeyManagementPath = "/passkey-management" ReadyPath = "/ready" SignupPath = "/signup" SwaggerPath = "/swagger/*" TOTPPath = "/totp-management" UserInfoPath = "/v1/userinfo" VerifyCodePath = "/verify-code" WellKnownJWKS = "/.well-known/jwks" WellKnownOpenIDCOnfiguationPath = "/.well-known/openid-configuration" WebAuthN_Register_GetCredentialCreationOptions = "/webauthn/register/get_credential_creation_options" WebAuthN_Register_ProcessRegistrationAttestation = "/webauthn/register/process_registration_attestation" WebAuthN_Login_GetCredentialRequestOptions = "/webauthn/login/get_credential_request_options" WebAuthN_Login_ProcessLoginAssertion = "/webauthn/login/process_login_assertion" WebAuthN_Register_Begin = "/webauthn/register/begin" WebAuthN_Register_Finish = "/webauthn/register/finish" WebAuthN_Login_Begin = "/webauthn/login/begin" WebAuthN_Login_Finish = "/webauthn/login/finish" )
View Source
var GithubScopes = []string{"user:email"}
Functions ¶
func GetGithubConfig ¶
func GetGithubConfig(c echo.Context, protocol *proto_oidc_models.GithubOAuth2Protocol) *oauth2.Config
func GetMyRootPath ¶
Types ¶
type Paths ¶
type Paths struct { About string API string ExternalIDP string Home string Login string Logout string PasskeyManagement string PersonalInformation string Profile string OIDCLogin string OIDCLoginPassword string OIDCLoginPasskey string OIDCLoginTOTP string Signup string TOTP string ForgotPassword string VerifyCode string PasswordReset string }
Click to show internal directories.
Click to hide internal directories.