Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewACLAuthorizer ¶
func NewACLAuthorizer(acl ACL) (api.Authorizer, error)
NewACLAuthorizer Creates a new static authorizer with ACL that have been read from the config file
func StringSetIntersection ¶
func ValidateACL ¶
Types ¶
type ACLEntry ¶
type ACLEntry struct { Match *MatchConditions `yaml:"match"` Actions *[]string `yaml:"actions,flow"` Comment *string `yaml:"comment,omitempty"` }
type MatchConditions ¶
type MatchConditions struct { Account *string `yaml:"account,omitempty" json:"account,omitempty"` Type *string `yaml:"type,omitempty" json:"type,omitempty"` Name *string `yaml:"name,omitempty" json:"name,omitempty"` IP *string `yaml:"ip,omitempty" json:"ip,omitempty"` Service *string `yaml:"service,omitempty" json:"service,omitempty"` Labels map[string]string `yaml:"labels,omitempty" json:"labels,omitempty"` }
func (*MatchConditions) Matches ¶
func (mc *MatchConditions) Matches(ai *api.AuthRequestInfo) bool
type PluginAuthz ¶
type PluginAuthz struct {
Authz api.Authorizer
}
func NewPluginAuthzAuthorizer ¶
func NewPluginAuthzAuthorizer(cfg *PluginAuthzConfig) (*PluginAuthz, error)
func (*PluginAuthz) Authorize ¶
func (c *PluginAuthz) Authorize(ai *api.AuthRequestInfo) ([]string, error)
func (*PluginAuthz) Name ¶
func (c *PluginAuthz) Name() string
func (*PluginAuthz) Stop ¶
func (c *PluginAuthz) Stop()
type PluginAuthzConfig ¶
type PluginAuthzConfig struct {
PluginPath string `yaml:"plugin_path"`
}
func (*PluginAuthzConfig) Validate ¶
func (c *PluginAuthzConfig) Validate() error
Click to show internal directories.
Click to hide internal directories.