Documentation ¶
Index ¶
- func LaunchAuth(fn GenerateAuthInfoFunc) tp.Plugin
- func Proxy(caller Caller) tp.Plugin
- func ProxyPull(fn PullFunc) tp.Plugin
- func ProxyPush(fn PushFunc) tp.Plugin
- func VerifyAuth(fn VerifyAuthInfoFunc) tp.Plugin
- type AuthSession
- type Caller
- type GenerateAuthInfoFunc
- type PullFunc
- type PushFunc
- type VerifyAuthInfoFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LaunchAuth ¶
func LaunchAuth(fn GenerateAuthInfoFunc) tp.Plugin
LaunchAuth creates a plugin for initiating authorization.
func VerifyAuth ¶
func VerifyAuth(fn VerifyAuthInfoFunc) tp.Plugin
VerifyAuth creates a plugin for verifying authorization.
Types ¶
type AuthSession ¶
AuthSession auth session provides Public,Id and SetId methods in early session
type Caller ¶
type Caller interface { Pull(uri string, args interface{}, reply interface{}, setting ...socket.PacketSetting) tp.PullCmd Push(uri string, args interface{}, setting ...socket.PacketSetting) *tp.Rerror }
Caller the object used to pull and push
type GenerateAuthInfoFunc ¶
type GenerateAuthInfoFunc func() string
GenerateAuthInfoFunc the function used to generate auth info
type PullFunc ¶
type PullFunc func(uri string, args interface{}, reply interface{}, setting ...socket.PacketSetting) tp.PullCmd
PullFunc the function used to pull
type PushFunc ¶
type PushFunc func(uri string, args interface{}, setting ...socket.PacketSetting) *tp.Rerror
PushFunc the function used to push
type VerifyAuthInfoFunc ¶
type VerifyAuthInfoFunc func(authInfo string, sess AuthSession) *tp.Rerror
VerifyAuthInfoFunc the function used to verify auth info
Click to show internal directories.
Click to hide internal directories.