session

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Oct 8, 2022 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Session

type Session struct {
	Key      []byte
	Hash     []byte
	Salt     int64
	Hostname string
}

Sesion is a basic data of specific session. Typically, session stores default hostname of mtproto server (cause all accounts ties to specific server after sign in), session key, server hash and salt.

type SessionLoader

type SessionLoader interface {
	Load() (*Session, error)
	Store(*Session) error
}

SessionLoader is the interface which allows you to access sessions from different storages (like filesystem, database, s3 storage, etc.)

func NewFromFile

func NewFromFile(path string) SessionLoader

Jump to

Keyboard shortcuts

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