user

package
v0.14.1 Latest Latest
Warning

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

Go to latest
Published: Nov 22, 2015 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateRandomInt64InRange

func GenerateRandomInt64InRange(base int64, delta int) int64

func Int64Hash

func Int64Hash(value int64) []byte

Types

type CounterHash

type CounterHash interface {
	Hash(key []byte, counter int64) []byte
}

func NewTimeHash

func NewTimeHash(baseHash StringHash) CounterHash

type HMACHash

type HMACHash struct {
}

func (HMACHash) Hash

func (h HMACHash) Hash(key []byte, data []byte) []byte

type RandomInt64InRange

type RandomInt64InRange func(base int64, delta int) int64

type StringHash

type StringHash interface {
	Hash(key []byte, data []byte) []byte
}

type TimeHash

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

func (TimeHash) Hash

func (h TimeHash) Hash(key []byte, counter int64) []byte

type TimedUserSet

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

func (*TimedUserSet) AddUser

func (us *TimedUserSet) AddUser(user config.User) error

func (TimedUserSet) GetUser

func (us TimedUserSet) GetUser(userHash []byte) (config.User, int64, bool)

type UserSet

type UserSet interface {
	AddUser(user config.User) error
	GetUser(timeHash []byte) (config.User, int64, bool)
}

func NewTimedUserSet

func NewTimedUserSet() UserSet

Directories

Path Synopsis
testing

Jump to

Keyboard shortcuts

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