Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrUserNotFound = errors.New("user not found")
Functions ¶
func CheckPassword ¶ added in v0.3.0
func EncryptPassword ¶ added in v0.3.0
func EncryptPassword(plaintextPasswd []byte, params Argon2Params) ([]byte, []byte, error)
Types ¶
type Argon2Params ¶
type Argon2Params struct {
KeyLen uint32 `json:"keyLen"`
Memory uint32 `json:"memory"`
Threads uint8 `json:"threads"`
Time uint32 `json:"time"`
Version int `json:"version"`
}
func (*Argon2Params) ToJSONString ¶ added in v0.3.0
func (a *Argon2Params) ToJSONString() (string, error)
type LocalAuthUser ¶
type User ¶
type User struct {
ID int64 `form:"-"`
Username string `form:"username"`
DisplayName string `form:"display_name"`
IsAdmin bool `form:"is_admin"`
RequiresPasswordChange bool `form:"-"`
AuthRef string `form:"-"`
Preferences UserPreferences
CreatedAt time.Time `form:"-"`
UpdatedAt time.Time `form:"-"`
}
Click to show internal directories.
Click to hide internal directories.