middleware

package
v1.3.4 Latest Latest
Warning

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

Go to latest
Published: Apr 17, 2022 License: GPL-3.0 Imports: 11 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

View Source
var IdentityImpl = new(apipb.IdentityClientImpl)
View Source
var Validate = validator.New()

Functions

func AuthRequired

func AuthRequired(c *gin.Context)

func AuthRequiredWithRPC added in v1.0.1

func AuthRequiredWithRPC(c *gin.Context)

func Authenticate added in v1.0.1

func Authenticate(t, method, url string, checkAuth bool) (*apipb.CurrentUser, int, error)

func GetAccessToken

func GetAccessToken(c *gin.Context) string

func GetTenantID

func GetTenantID(c *gin.Context) string

func GetTransID

func GetTransID(c *gin.Context) string

func GetUser

func GetUser(c *gin.Context) (bool, *apipb.CurrentUser)

func GetUserID

func GetUserID(c *gin.Context) string

func GetUserName

func GetUserName(c *gin.Context) string

func InitIdentity added in v1.0.1

func InitIdentity()

Types

This section is empty.

Jump to

Keyboard shortcuts

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