repo

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Mar 4, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Account

type Account struct {
	ID             uint32
	Username       string
	Salt           []byte
	Verifier       []byte
	SessionKeyAuth []byte
	Locked         bool
	LastIP         string
}

type AccountRepo

type AccountRepo interface {
	AccountByUserName(ctx context.Context, username string) (*Account, error)
}

func NewAccountMySQLRepo

func NewAccountMySQLRepo(db *sql.DB, stmtBuilder StatementsBuilder) (AccountRepo, error)

type AuthStmtType

type AuthStmtType uint8
const (
	AuthStmtTypeGetAccountByUsername AuthStmtType = iota
)

type StatementsBuilder

type StatementsBuilder interface {
	StmtForType(AuthStmtType) string
}

func StatementsBuilderForSchema

func StatementsBuilderForSchema(schemaType repo.SupportedSchemaType) StatementsBuilder

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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