authfile

package
v0.0.0-...-b0d25e1 Latest Latest
Warning

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

Go to latest
Published: Oct 30, 2023 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Type         = "authfile"
	DefaultName  = "authfile"
	DefaultRealm = "default realm"
)

Variables

View Source
var Log *logrus.Entry = logging.GetLogger("authfile").WithField("pkg", "auth/backend/authfile")

Functions

This section is empty.

Types

type AuthFile

type AuthFile struct {
	// contains filtered or unexported fields
}

func New

func New(config *Config) (*AuthFile, error)

func (*AuthFile) Authenticate

func (fa *AuthFile) Authenticate(pctx *auth.AuthContext, creds *auth.Credentials) (*auth.AuthContext, bool)

func (*AuthFile) CredentialType

func (fa *AuthFile) CredentialType() string

func (*AuthFile) Name

func (fa *AuthFile) Name() string

func (*AuthFile) Realm

func (fa *AuthFile) Realm() string

func (*AuthFile) Reload

func (fa *AuthFile) Reload() error

func (*AuthFile) Type

func (fa *AuthFile) Type() string

type Config

type Config struct {
	Name  string
	Realm string
	Path  string
}
var Defaults *Config = &Config{
	Name:  DefaultName,
	Realm: DefaultRealm,
	Path:  path.Join(globals.ConfDir(), "auth_users.yaml"),
}

type UserEntry

type UserEntry struct {
	Name            string
	Password        string
	Principals      []string
	CriticalOptions map[string]string
	Extensions      map[string]string
}

Jump to

Keyboard shortcuts

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