Documentation ¶
Overview ¶
Package auth contains APIServer authentication helpers.
Index ¶
- Constants
- func NewHeaderAuthenticator() authenticator.Request
- func NewHeaderRoundTripper(rt http.RoundTripper, userHeader string, groupHeaders, extraHeaders []string) *headerRoundTripper
- func NewTransportWrapperFunc(userHeader string, groupHeaders, extraHeaders []string) func(rt http.RoundTripper) http.RoundTripper
- func NewX509Authenticator(clientCAPath string) (authenticator.Request, error)
Constants ¶
View Source
const ( UserHeaderKey = "X-Remote-User" GroupHeaderKey = "X-Remote-Group" ExtraHeaderKey = "X-Remote-Extra-" )
Variables ¶
This section is empty.
Functions ¶
func NewHeaderAuthenticator ¶
func NewHeaderAuthenticator() authenticator.Request
NewHeaderAuthenticator returns a new authenticator.Request that authenticates requests based on the X-Remote-User, X-Remote-Group, and X-Remote-Extra headers.
func NewHeaderRoundTripper ¶
func NewHeaderRoundTripper(rt http.RoundTripper, userHeader string, groupHeaders, extraHeaders []string) *headerRoundTripper
NewHeaderRoundTripper returns a new round tripper that adds the given headers to the request.
func NewTransportWrapperFunc ¶
func NewTransportWrapperFunc(userHeader string, groupHeaders, extraHeaders []string) func(rt http.RoundTripper) http.RoundTripper
NewTransportWrapperFunc returns a new transport.WrapperFunc that adds the given headers to the request.
func NewX509Authenticator ¶
func NewX509Authenticator(clientCAPath string) (authenticator.Request, error)
NewX509Authenticator creates a new authenticator that authenticates requests based on the provided client certificate.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.