authentification

package
v0.0.0-...-d64c4a0 Latest Latest
Warning

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

Go to latest
Published: Jul 10, 2014 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ADDUSER userManagerCommandType = iota
	DELUSER
	CHECKUSER
)

Variables

This section is empty.

Functions

func Go

func Go()

func GoLoginController

func GoLoginController()

func GoUserManager

func GoUserManager()

Types

type AwnserData

type AwnserData struct {
	Success bool        `json:"success"`
	Message interface{} `json:"message,omitempty"`
}

type User

type User struct {
	ID        uint64
	Username  string
	Password  string
	AuthLevel uint8
}

func (*User) HashPassword

func (user *User) HashPassword(rounds int)

func (*User) String

func (user *User) String() string

type UserManager

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

func NewUserManager

func NewUserManager() *UserManager

func (*UserManager) AddUser

func (ptr *UserManager) AddUser(name, password string, authlevel uint8) bool

func (*UserManager) CheckUser

func (ptr *UserManager) CheckUser(name, password string) *User

func (*UserManager) DelUser

func (ptr *UserManager) DelUser(name string) bool

func (*UserManager) Load

func (ptr *UserManager) Load()

func (*UserManager) Save

func (ptr *UserManager) Save()

Jump to

Keyboard shortcuts

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