Documentation
¶
Index ¶
- Constants
- Variables
- type Config
- type ConfigMultiError
- type ConfigValidationError
- type ConsumerConfig
- func (*ConsumerConfig) Descriptor() ([]byte, []int)deprecated
- func (x *ConsumerConfig) GetKey() string
- func (conf *ConsumerConfig) Index() string
- func (*ConsumerConfig) ProtoMessage()
- func (x *ConsumerConfig) ProtoReflect() protoreflect.Message
- func (x *ConsumerConfig) Reset()
- func (x *ConsumerConfig) String() string
- func (m *ConsumerConfig) Validate() error
- func (m *ConsumerConfig) ValidateAll() error
- type ConsumerConfigMultiError
- type ConsumerConfigValidationError
- func (e ConsumerConfigValidationError) Cause() error
- func (e ConsumerConfigValidationError) Error() string
- func (e ConsumerConfigValidationError) ErrorName() string
- func (e ConsumerConfigValidationError) Field() string
- func (e ConsumerConfigValidationError) Key() bool
- func (e ConsumerConfigValidationError) Reason() string
- type Key
- func (*Key) Descriptor() ([]byte, []int)deprecated
- func (x *Key) GetName() string
- func (x *Key) GetSource() Source
- func (*Key) ProtoMessage()
- func (x *Key) ProtoReflect() protoreflect.Message
- func (x *Key) Reset()
- func (x *Key) String() string
- func (m *Key) Validate() error
- func (m *Key) ValidateAll() error
- type KeyMultiError
- type KeyValidationError
- type Plugin
- type Source
Constants ¶
const (
Name = "keyAuth"
)
Variables ¶
var ( Source_name = map[int32]string{ 0: "HEADER", 1: "QUERY", } Source_value = map[string]int32{ "HEADER": 0, "QUERY": 1, } )
Enum value maps for Source.
var File_types_plugins_keyauth_config_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Keys []*Key `protobuf:"bytes,1,rep,name=keys,proto3" json:"keys,omitempty"` // contains filtered or unexported fields }
func (*Config) Descriptor
deprecated
func (*Config) ProtoMessage ¶
func (*Config) ProtoMessage()
func (*Config) ProtoReflect ¶
func (x *Config) ProtoReflect() protoreflect.Message
func (*Config) Validate ¶
Validate checks the field values on Config with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.
func (*Config) ValidateAll ¶
ValidateAll checks the field values on Config with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in ConfigMultiError, or nil if none found.
type ConfigMultiError ¶
type ConfigMultiError []error
ConfigMultiError is an error wrapping multiple validation errors returned by Config.ValidateAll() if the designated constraints aren't met.
func (ConfigMultiError) AllErrors ¶
func (m ConfigMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (ConfigMultiError) Error ¶
func (m ConfigMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type ConfigValidationError ¶
type ConfigValidationError struct {
// contains filtered or unexported fields
}
ConfigValidationError is the validation error returned by Config.Validate if the designated constraints aren't met.
func (ConfigValidationError) Cause ¶
func (e ConfigValidationError) Cause() error
Cause function returns cause value.
func (ConfigValidationError) Error ¶
func (e ConfigValidationError) Error() string
Error satisfies the builtin error interface
func (ConfigValidationError) ErrorName ¶
func (e ConfigValidationError) ErrorName() string
ErrorName returns error name.
func (ConfigValidationError) Field ¶
func (e ConfigValidationError) Field() string
Field function returns field value.
func (ConfigValidationError) Key ¶
func (e ConfigValidationError) Key() bool
Key function returns key value.
func (ConfigValidationError) Reason ¶
func (e ConfigValidationError) Reason() string
Reason function returns reason value.
type ConsumerConfig ¶
type ConsumerConfig struct { Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` // contains filtered or unexported fields }
func (*ConsumerConfig) Descriptor
deprecated
func (*ConsumerConfig) Descriptor() ([]byte, []int)
Deprecated: Use ConsumerConfig.ProtoReflect.Descriptor instead.
func (*ConsumerConfig) GetKey ¶
func (x *ConsumerConfig) GetKey() string
func (*ConsumerConfig) Index ¶
func (conf *ConsumerConfig) Index() string
func (*ConsumerConfig) ProtoMessage ¶
func (*ConsumerConfig) ProtoMessage()
func (*ConsumerConfig) ProtoReflect ¶
func (x *ConsumerConfig) ProtoReflect() protoreflect.Message
func (*ConsumerConfig) Reset ¶
func (x *ConsumerConfig) Reset()
func (*ConsumerConfig) String ¶
func (x *ConsumerConfig) String() string
func (*ConsumerConfig) Validate ¶
func (m *ConsumerConfig) Validate() error
Validate checks the field values on ConsumerConfig with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.
func (*ConsumerConfig) ValidateAll ¶
func (m *ConsumerConfig) ValidateAll() error
ValidateAll checks the field values on ConsumerConfig with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in ConsumerConfigMultiError, or nil if none found.
type ConsumerConfigMultiError ¶
type ConsumerConfigMultiError []error
ConsumerConfigMultiError is an error wrapping multiple validation errors returned by ConsumerConfig.ValidateAll() if the designated constraints aren't met.
func (ConsumerConfigMultiError) AllErrors ¶
func (m ConsumerConfigMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (ConsumerConfigMultiError) Error ¶
func (m ConsumerConfigMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type ConsumerConfigValidationError ¶
type ConsumerConfigValidationError struct {
// contains filtered or unexported fields
}
ConsumerConfigValidationError is the validation error returned by ConsumerConfig.Validate if the designated constraints aren't met.
func (ConsumerConfigValidationError) Cause ¶
func (e ConsumerConfigValidationError) Cause() error
Cause function returns cause value.
func (ConsumerConfigValidationError) Error ¶
func (e ConsumerConfigValidationError) Error() string
Error satisfies the builtin error interface
func (ConsumerConfigValidationError) ErrorName ¶
func (e ConsumerConfigValidationError) ErrorName() string
ErrorName returns error name.
func (ConsumerConfigValidationError) Field ¶
func (e ConsumerConfigValidationError) Field() string
Field function returns field value.
func (ConsumerConfigValidationError) Key ¶
func (e ConsumerConfigValidationError) Key() bool
Key function returns key value.
func (ConsumerConfigValidationError) Reason ¶
func (e ConsumerConfigValidationError) Reason() string
Reason function returns reason value.
type Key ¶
type Key struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // default to header Source Source `protobuf:"varint,2,opt,name=source,proto3,enum=types.plugins.keyauth.Source" json:"source,omitempty"` // contains filtered or unexported fields }
func (*Key) Descriptor
deprecated
func (*Key) ProtoMessage ¶
func (*Key) ProtoMessage()
func (*Key) ProtoReflect ¶
func (x *Key) ProtoReflect() protoreflect.Message
func (*Key) Validate ¶
Validate checks the field values on Key with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.
func (*Key) ValidateAll ¶
ValidateAll checks the field values on Key with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in KeyMultiError, or nil if none found.
type KeyMultiError ¶
type KeyMultiError []error
KeyMultiError is an error wrapping multiple validation errors returned by Key.ValidateAll() if the designated constraints aren't met.
func (KeyMultiError) AllErrors ¶
func (m KeyMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (KeyMultiError) Error ¶
func (m KeyMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type KeyValidationError ¶
type KeyValidationError struct {
// contains filtered or unexported fields
}
KeyValidationError is the validation error returned by Key.Validate if the designated constraints aren't met.
func (KeyValidationError) Cause ¶
func (e KeyValidationError) Cause() error
Cause function returns cause value.
func (KeyValidationError) Error ¶
func (e KeyValidationError) Error() string
Error satisfies the builtin error interface
func (KeyValidationError) ErrorName ¶
func (e KeyValidationError) ErrorName() string
ErrorName returns error name.
func (KeyValidationError) Field ¶
func (e KeyValidationError) Field() string
Field function returns field value.
func (KeyValidationError) Key ¶
func (e KeyValidationError) Key() bool
Key function returns key value.
func (KeyValidationError) Reason ¶
func (e KeyValidationError) Reason() string
Reason function returns reason value.
type Plugin ¶
type Plugin struct {
plugins.PluginMethodDefaultImpl
}
func (*Plugin) Config ¶
func (p *Plugin) Config() api.PluginConfig
func (*Plugin) ConsumerConfig ¶
func (p *Plugin) ConsumerConfig() api.PluginConsumerConfig
func (*Plugin) Order ¶
func (p *Plugin) Order() plugins.PluginOrder
func (*Plugin) Type ¶
func (p *Plugin) Type() plugins.PluginType
type Source ¶
type Source int32
func (Source) Descriptor ¶
func (Source) Descriptor() protoreflect.EnumDescriptor
func (Source) EnumDescriptor
deprecated
func (Source) Number ¶
func (x Source) Number() protoreflect.EnumNumber
func (Source) Type ¶
func (Source) Type() protoreflect.EnumType