Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrUnsupportedSASLMechanism = errors.New("unsupported SASL mechanism")
)
SASL specific error types.
View Source
var SHA256 scram.HashGeneratorFcn = func() hash.Hash { return sha256.New() }
SHA256 generates the SHA256 hash
View Source
var SHA512 scram.HashGeneratorFcn = func() hash.Hash { return sha512.New() }
SHA512 generates the SHA512 hash
Functions ¶
Types ¶
type Config ¶
type Config struct { Enabled bool `json:"enabled" yaml:"enabled"` // DEPRECATED Mechanism string `json:"mechanism" yaml:"mechanism"` User string `json:"user" yaml:"user"` Password string `json:"password" yaml:"password"` AccessToken string `json:"access_token" yaml:"access_token"` TokenCache string `json:"token_cache" yaml:"token_cache"` TokenKey string `json:"token_key" yaml:"token_key"` }
Config contains configuration for SASL based authentication. TODO: V4 Remove "enabled" and set a default mechanism
type XDGSCRAMClient ¶
type XDGSCRAMClient struct { *scram.Client *scram.ClientConversation scram.HashGeneratorFcn }
XDGSCRAMClient represents struct to XDG Scram client to initialize conversation
func (*XDGSCRAMClient) Begin ¶
func (x *XDGSCRAMClient) Begin(userName, password, authzID string) (err error)
Begin initializes new client and conversation to securely transmit the provided credentials to Kafka
func (*XDGSCRAMClient) Done ¶
func (x *XDGSCRAMClient) Done() bool
Done returns true if the conversation is completed or has errored.
Click to show internal directories.
Click to hide internal directories.