app

package
v1.0.0-rc2 Latest Latest
Warning

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

Go to latest
Published: May 21, 2023 License: GPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var SignPermissions = []Permission{PermRead, PermWrite, PermSign}

Functions

func AuthNew

func AuthNew(allow []Permission) ([]byte, error)

func Confirm

func Confirm(msg string) (bool, error)

func Password

func Password(isConfirm bool) (string, error)

func SetSecret

func SetSecret(loginScrypt []byte)

Types

type AppFmt

type AppFmt struct {
	Stdin io.Reader
	// contains filtered or unexported fields
}

func NewAppFmt

func NewAppFmt(a *ufcli.App) *AppFmt

func (*AppFmt) Print

func (a *AppFmt) Print(args ...interface{})

func (*AppFmt) Printf

func (a *AppFmt) Printf(fmtstr string, args ...interface{})

func (*AppFmt) Println

func (a *AppFmt) Println(args ...interface{})

func (*AppFmt) Scan

func (a *AppFmt) Scan(args ...interface{}) (int, error)

type Permission

type Permission string
var (
	PermRead  Permission = "read"
	PermWrite Permission = "write"
	PermSign  Permission = "sign"
	PermAdmin Permission = "admin"
)

func AuthVerify

func AuthVerify(token string) ([]Permission, error)

Jump to

Keyboard shortcuts

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