config

package
v0.6.7 Latest Latest
Warning

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

Go to latest
Published: Dec 4, 2016 License: Apache-2.0 Imports: 32 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	// These are used by client commands
	ClusterURL   string `mapstructure:"CLUSTER_URL" yaml:"cluster_url"`
	ClientID     string `mapstructure:"CLIENT_ID" yaml:"client_id,omitempty"`
	ClientSecret string `mapstructure:"CLIENT_SECRET" yaml:"client_secret,omitempty"`

	// These are used by the host command
	BindPort               int    `mapstructure:"PORT" yaml:"-"`
	BindHost               string `mapstructure:"HOST" yaml:"-"`
	Issuer                 string `mapstructure:"ISSUER" yaml:"-"`
	SystemSecret           string `mapstructure:"SYSTEM_SECRET" yaml:"-"`
	DatabaseURL            string `mapstructure:"DATABASE_URL" yaml:"-"`
	ConsentURL             string `mapstructure:"CONSENT_URL" yaml:"-"`
	AllowTLSTermination    string `mapstructure:"HTTPS_ALLOW_TERMINATION_FROM" yaml:"-"`
	BCryptWorkFactor       int    `mapstructure:"BCRYPT_COST" yaml:"-"`
	AccessTokenLifespan    string `mapstructure:"ACCESS_TOKEN_LIFESPAN" yaml:"-"`
	AuthCodeLifespan       string `mapstructure:"AUTH_CODE_LIFESPAN" yaml:"-"`
	IDTokenLifespan        string `mapstructure:"ID_TOKEN_LIFESPAN" yaml:"-"`
	ChallengeTokenLifespan string `mapstructure:"CHALLENGE_TOKEN_LIFESPAN" yaml:"-"`
	ForceHTTP              bool   `yaml:"-"`
	// contains filtered or unexported fields
}

func (*Config) Context

func (c *Config) Context() *Context

func (*Config) DoesRequestSatisfyTermination

func (c *Config) DoesRequestSatisfyTermination(r *http.Request) error

func (*Config) GetAccessTokenLifespan

func (c *Config) GetAccessTokenLifespan() time.Duration

func (*Config) GetAddress

func (c *Config) GetAddress() string

func (*Config) GetAuthCodeLifespan

func (c *Config) GetAuthCodeLifespan() time.Duration

func (*Config) GetChallengeTokenLifespan

func (c *Config) GetChallengeTokenLifespan() time.Duration

func (*Config) GetIDTokenLifespan

func (c *Config) GetIDTokenLifespan() time.Duration

func (*Config) GetSystemSecret

func (c *Config) GetSystemSecret() []byte

func (*Config) OAuth2Client

func (c *Config) OAuth2Client(cmd *cobra.Command) *http.Client

func (*Config) Persist

func (c *Config) Persist() error

func (*Config) Resolve

func (c *Config) Resolve(join ...string) *url.URL

type Context

type Context struct {
	Connection interface{}

	Hasher         fosite.Hasher
	Warden         firewall.Firewall
	LadonManager   ladon.Manager
	FositeStrategy oauth2.CoreStrategy
	FositeStore    pkg.FositeStorer
	KeyManager     jwk.Manager
}

type MemoryConnection

type MemoryConnection struct{}

type RedisConnection added in v0.6.5

type RedisConnection struct {
	URL *url.URL
	// contains filtered or unexported fields
}

func (*RedisConnection) RedisSession added in v0.6.5

func (c *RedisConnection) RedisSession() *redis.Client

type RethinkDBConnection

type RethinkDBConnection struct {
	URL *url.URL
	// contains filtered or unexported fields
}

func (*RethinkDBConnection) CreateTableIfNotExists

func (c *RethinkDBConnection) CreateTableIfNotExists(table string)

func (*RethinkDBConnection) GetSession

func (c *RethinkDBConnection) GetSession() *r.Session

type SQLConnection added in v0.6.0

type SQLConnection struct {
	URL *url.URL
	// contains filtered or unexported fields
}

func (*SQLConnection) GetDatabase added in v0.6.0

func (c *SQLConnection) GetDatabase() *sqlx.DB

Jump to

Keyboard shortcuts

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