Documentation
¶
Overview ¶
Package conciergeclient provides login helpers for the Pinniped concierge.
Index ¶
- Constants
- type Client
- type Option
- func WithAPIGroupSuffix(apiGroupSuffix string) Option
- func WithAuthenticator(authType, authName string) Option
- func WithBase64CABundle(caBundleBase64 string) Option
- func WithCABundle(caBundle string) Option
- func WithEndpoint(endpoint string) Option
- func WithTransportWrapper(wrapper transport.WrapperFunc) Option
Constants ¶
const ErrLoginFailed = constable.Error("login failed")
ErrLoginFailed is returned by Client.ExchangeToken when the concierge server rejects the login request for any reason.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is a configuration for talking to the Pinniped concierge.
func (*Client) ExchangeToken ¶
func (c *Client) ExchangeToken(ctx context.Context, token string) (*clientauthenticationv1beta1.ExecCredential, error)
ExchangeToken performs a TokenCredentialRequest against the Pinniped concierge and returns the result as an ExecCredential.
type Option ¶
Option is an optional configuration for New().
func WithAPIGroupSuffix ¶ added in v0.5.0
WithAPIGroupSuffix configures the concierge's API group suffix (e.g., "pinniped.dev").
func WithAuthenticator ¶
WithAuthenticator configures the authenticator reference (spec.authenticator) of the TokenCredentialRequests.
func WithBase64CABundle ¶
WithBase64CABundle configures the base64-encoded, PEM-formatted TLS certificate authority to trust when connecting to the concierge.
func WithCABundle ¶
WithCABundle configures the PEM-formatted TLS certificate authority to trust when connecting to the concierge.
func WithEndpoint ¶
WithEndpoint configures the base API endpoint URL of the concierge service (same as Kubernetes API server).
func WithTransportWrapper ¶ added in v0.36.0
func WithTransportWrapper(wrapper transport.WrapperFunc) Option