auth

package
v1.6.2 Latest Latest
Warning

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

Go to latest
Published: Apr 27, 2025 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

Package auth defines the authentication layer of the application.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateProviders

func GenerateProviders(
	ctx context.Context,
	config Config,
	redirectURL string,
) (pp map[string]oauth.Provider, err error)

GenerateProviders generates a map of provider based on the given configuration.

func Logout added in v1.6.0

func Logout(w http.ResponseWriter, r *http.Request)

Logout removes session cookies and redirect to home.

Types

type Config

type Config struct {
	Providers     []oauth.ProviderConfig `yaml:"providers"`
	SelfHostUsers bool                   `yaml:"selfHostUsers"`
}

Config is the authentication configuration definition for the application.

Directories

Path Synopsis
Package oauth defines the authentication layer of the application.
Package oauth defines the authentication layer of the application.
Package webauthn handles WebAuthn related functionalities.
Package webauthn handles WebAuthn related functionalities.
session
Package session handles the login/register sessions of webauthn.
Package session handles the login/register sessions of webauthn.
session/memory
Package memory implements a session store in-memory.
Package memory implements a session store in-memory.
user
Package user describes the methods to handle users needed for webauthn.
Package user describes the methods to handle users needed for webauthn.

Jump to

Keyboard shortcuts

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