auth

package
v0.0.0-...-dfa43ee Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2016 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CookieName = "sid"
)

Variables

This section is empty.

Functions

func Login

func Login(login, password string) (string, error)

func Logout

func Logout(sessionID string)

Types

type User

type User struct {
	ID          int32     `db:"user_id"`
	Name        string    `db:"user_name"`
	Login       string    `db:"user_login"`
	Email       string    `db:"user_email"`
	IsSuperuser bool      `db:"is_superuser"`
	CreatedAt   time.Time `db:"created_at"`
}

func GetUser

func GetUser(sessionID string) (*User, error)

Jump to

Keyboard shortcuts

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