db

package
v0.19.4 Latest Latest
Warning

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

Go to latest
Published: May 24, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Authenticate

func Authenticate(user *user_model.User, login, password string) (*user_model.User, error)

Authenticate authenticates the provided user against the DB

Types

type Source

type Source struct{}

Source is a password authentication service

func (*Source) Authenticate

func (source *Source) Authenticate(user *user_model.User, login, password string) (*user_model.User, error)

Authenticate queries if login/password is valid against the PAM, and create a local user if success when enabled.

func (*Source) FromDB

func (source *Source) FromDB(bs []byte) error

FromDB fills up an OAuth2Config from serialized format.

func (*Source) ToDB

func (source *Source) ToDB() ([]byte, error)

ToDB exports an SMTPConfig to a serialized format.

Jump to

Keyboard shortcuts

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