menshend

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Apr 14, 2017 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AdminFilter

func AdminFilter(req *restful.Request, resp *restful.Response, chain *restful.FilterChain)

AdminFilter fail if the user is not an admin

func CanImpersonate

func CanImpersonate(vaultToken string) bool

CanImpersonate ...

func CheckAdminPermission

func CheckAdminPermission(vaultToken string, vc *vault.Config)

checkAdminPermission ...

func CheckImpersonatePermission

func CheckImpersonatePermission(vaultToken string, vc *vault.Config)

CheckImpersonatePermission check if the user can impersonate other

func GetTokenFromContext

func GetTokenFromContext(r *restful.Request) string

GetUserFromContext ...

func GetTokenFromRequest

func GetTokenFromRequest(r *restful.Request) string

func ImpersonateFilter

func ImpersonateFilter(req *restful.Request, resp *restful.Response, chain *restful.FilterChain)

ImpersonateFilter ....

func IsAdmin

func IsAdmin(vaultToken string) bool

IsAdmin ...

func LoginFilter

func LoginFilter(req *restful.Request, resp *restful.Response, chain *restful.FilterChain)

LoginFilter fail if the user is not logged in

func ParseBearerAuth

func ParseBearerAuth(auth string) (string, bool)

Types

This section is empty.

Jump to

Keyboard shortcuts

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