user

package
v0.12.0-unstable34 Latest Latest
Warning

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

Go to latest
Published: Nov 2, 2023 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func API2FA

func API2FA(w http.ResponseWriter, req *http.Request)

func Check2FA

func Check2FA(w http.ResponseWriter, req *http.Request)

func Delete2FA

func Delete2FA(w http.ResponseWriter, req *http.Request)

func GetUserR

func GetUserR(req *http.Request) (string, string)

func Me

func Me(w http.ResponseWriter, req *http.Request)

func New2FA

func New2FA(w http.ResponseWriter, req *http.Request)

func RefreshUserToken

func RefreshUserToken(w http.ResponseWriter, req *http.Request) (utils.User, error)

func ResetPassword

func ResetPassword(w http.ResponseWriter, req *http.Request)

func SendAdminPasswordEmail

func SendAdminPasswordEmail(nickname string, email string, link string) error

func SendInviteEmail

func SendInviteEmail(nickname string, email string, link string) error

func SendPasswordEmail

func SendPasswordEmail(nickname string, email string, link string) error

func SendUserToken

func SendUserToken(w http.ResponseWriter, req *http.Request, user utils.User, mfaDone bool)

func UserCreate

func UserCreate(w http.ResponseWriter, req *http.Request)

func UserDelete

func UserDelete(w http.ResponseWriter, req *http.Request)

func UserEdit

func UserEdit(w http.ResponseWriter, req *http.Request)

func UserGet

func UserGet(w http.ResponseWriter, req *http.Request)

func UserList

func UserList(w http.ResponseWriter, req *http.Request)

func UserLogin

func UserLogin(w http.ResponseWriter, req *http.Request)

func UserLogout

func UserLogout(w http.ResponseWriter, req *http.Request)

func UserRegister

func UserRegister(w http.ResponseWriter, req *http.Request)
func UserResendInviteLink(w http.ResponseWriter, req *http.Request)

func UsersIdRoute

func UsersIdRoute(w http.ResponseWriter, req *http.Request)

func UsersRoute

func UsersRoute(w http.ResponseWriter, req *http.Request)

Types

type CreateRequestJSON

type CreateRequestJSON struct {
	Nickname string `validate:"required,min=3,max=32,alphanum"`
	Email    string `validate:"omitempty,email"`
}

type EditRequestJSON

type EditRequestJSON struct {
	Email string `validate:"email"`
}

type InviteRequestJSON

type InviteRequestJSON struct {
	Nickname string `validate:"required,min=3,max=32,alphanum"`
	FormType string
}

type LoginRequestJSON

type LoginRequestJSON struct {
	Nickname string `validate:"required,min=3,max=32,alphanum"`
	Password string `` /* 175-byte string literal not displayed */
}

type PasswordResetRequestJSON

type PasswordResetRequestJSON struct {
	Nickname string `validate:"required,min=3,max=32,alphanum"`
	Email    string `validate:"required,min=3,max=32,alphanum"`
}

type RegisterRequestJSON

type RegisterRequestJSON struct {
	Nickname    string `validate:"required,min=3,max=32,alphanum"`
	Password    string `` /* 175-byte string literal not displayed */
	RegisterKey string `validate:"required,min=1,max=512,alphanum"`
}

type User2FACheckRequest

type User2FACheckRequest struct {
	Token string
}

type User2FAResetRequest

type User2FAResetRequest struct {
	Nickname string
}

Jump to

Keyboard shortcuts

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