tokens

package
v0.5.7 Latest Latest
Warning

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

Go to latest
Published: Apr 26, 2023 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddRecords

func AddRecords(table eacl.Table, toWhom []eacl.Target, operations map[eacl.Operation]eacl.Action) eacl.Table

recomend adding all allow records then all deny records

func BuildBearerToken

func BuildBearerToken(key *keys.PrivateKey, table *eacl.Table, lIat, lNbf, lExp uint64, gateKey *keys.PublicKey) (*bearer.Token, error)

func BuildContainerSessionToken

func BuildContainerSessionToken(key *keys.PrivateKey, lIat, lNbf, lExp uint64, cnrID cid.ID, verb session.ContainerVerb, gateKey keys.PublicKey) (*session.Container, error)

func BuildObjectSessionToken

func BuildObjectSessionToken(key *keys.PrivateKey, lIat, lNbf, lExp uint64, verb session.ObjectVerb, cnrID cid.ID, gateSession *client.ResSessionCreate) (*session.Object, error)

func CalculateEpochsForTime

func CalculateEpochsForTime(ctx context.Context, cli *client.Client, durationInSeconds int64) uint64

CalculateEpochsForTime takes the number of seconds into the future you want the epoch for and estimates it based on the current average time per epoch

func InitTable

func InitTable(cid cid.ID) eacl.Table

Types

This section is empty.

Jump to

Keyboard shortcuts

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