auth

package
v0.0.0-...-336e61a Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 24, 2016 License: Apache-2.0 Imports: 8 Imported by: 2

Documentation

Index

Constants

View Source
const (

	// DefAuthDirectory default directory used to store files
	// to authenticate request
	DefAuthDirectory = "/etc/ingress-controller/auth"
)

Variables

View Source
var (

	// ErrInvalidAuthType is return in case of unsupported authentication type
	ErrInvalidAuthType = errors.New("invalid authentication type")

	// ErrMissingSecretName is returned when the name of the secret is missing
	ErrMissingSecretName = errors.New("secret name is missing")

	// ErrMissingAuthInSecret is returned when there is no auth key in secret data
	ErrMissingAuthInSecret = errors.New("the secret does not contains the auth key")
)

Functions

This section is empty.

Types

type BasicDigest

type BasicDigest struct {
	Type    string
	Realm   string
	File    string
	Secured bool
}

BasicDigest returns authentication configuration for an Ingress rule

func ParseAnnotations

func ParseAnnotations(ing *extensions.Ingress, authDir string, fn func(string) (*api.Secret, error)) (*BasicDigest, error)

ParseAnnotations parses the annotations contained in the ingress rule used to add authentication in the paths defined in the rule and generated an htpasswd compatible file to be used as source during the authentication process

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL