auth

package
v0.0.0-...-ebb443a Latest Latest
Warning

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

Go to latest
Published: Apr 8, 2019 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Decode

func Decode(tokenStr string) (*user.UserInfo, error)

func Encode

func Encode(user *user.UserInfo) (string, error)

Types

type Auth

type Auth struct {
}

func (*Auth) Commands

func (*Auth) Commands() []cli.Command

func (*Auth) Flags

func (*Auth) Flags() []cli.Flag

func (*Auth) Handler

func (*Auth) Handler() plugin.Handler

func (*Auth) Init

func (*Auth) Init(*cli.Context) error

func (*Auth) String

func (*Auth) String() string

type CustomClaims

type CustomClaims struct {
	User *user.UserInfo
	jwt.StandardClaims
}

自定义的 metadata 在加密后作为 JWT 的第二部分返回给客户端

Jump to

Keyboard shortcuts

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