session

package
v0.0.0-...-43020c5 Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2020 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrSessionNotFound = errors.New("session not found.")
)

Functions

Types

type Session

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

func (Session) SessionID

func (sess Session) SessionID() string

type SessionContext

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

func (*SessionContext) Cert

func (ctx *SessionContext) Cert() []byte

func (*SessionContext) Org

func (ctx *SessionContext) Org() string

func (*SessionContext) SessionID

func (ctx *SessionContext) SessionID() string

func (*SessionContext) UserData

func (ctx *SessionContext) UserData() *fabMspPvdr.UserData

func (*SessionContext) UserName

func (ctx *SessionContext) UserName() string

type SessionDB

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

func NewSessionDB

func NewSessionDB(cfg config.SQLDBConfig) (*SessionDB, error)

func (*SessionDB) GetSessionContext

func (sessDB *SessionDB) GetSessionContext(username, org, sessionID string) (session.SessionContext, error)

func (*SessionDB) WriteSessionContext

func (sessDB *SessionDB) WriteSessionContext(ctx session.SessionContext) error

type SessionManager

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

func (*SessionManager) GetSession

func (mgr *SessionManager) GetSession(username, org, sessionID string) (sessPvdr.Session, error)

func (*SessionManager) NewSession

func (mgr *SessionManager) NewSession(username, org string, cert []byte) (sessPvdr.Session, error)

Jump to

Keyboard shortcuts

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