Documentation ¶
Index ¶
- func ApiContext(md metadata.MD, opt *AuthOptions) (context.Context, context.CancelFunc, error)
- func ApiContextWithTimeout(md metadata.MD, dur time.Duration, opt *AuthOptions) (context.Context, context.CancelFunc, error)
- func Authenticator(ctx context.Context, opt *AuthOptions) (context.Context, error)
- func CustomIdHeader() string
- func SetCacheExpiration(dur time.Duration)
- func SetRedisAuthPrefix(prefix string)
- func SetTableSecretColumn(column string)
- func SetUsersTable(tableName string)
- type AuthAPI
- type AuthOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ApiContext ¶
func ApiContext(md metadata.MD, opt *AuthOptions) (context.Context, context.CancelFunc, error)
func ApiContextWithTimeout ¶
func ApiContextWithTimeout(md metadata.MD, dur time.Duration, opt *AuthOptions) (context.Context, context.CancelFunc, error)
func Authenticator ¶
Authenticator is a helper to authenticate requests sent to upstream from Kong
func CustomIdHeader ¶
func CustomIdHeader() string
func SetCacheExpiration ¶
SetCacheExpiration sets the expiration.
This happens once even when called mutiple times.
func SetRedisAuthPrefix ¶
func SetRedisAuthPrefix(prefix string)
SetRedisAuthPrefix sets the redis auth prefix.
This happens once even when called mutiple times.
func SetTableSecretColumn ¶
func SetTableSecretColumn(column string)
SetTableSecretColumn sets the users column to use.
This happens once even when called mutiple times.
func SetUsersTable ¶
func SetUsersTable(tableName string)
SetUsersTable sets the users table to use.
This happens once even when called mutiple times.
Types ¶
Click to show internal directories.
Click to hide internal directories.