Documentation ¶
Overview ¶
Package config describes the configuration of the beacon server.
Index ¶
Constants ¶
View Source
const ( // DefaultKeepaliveInterval is the default interval between sending // interface keepalives. DefaultKeepaliveInterval = time.Second // DefaultKeepaliveTimeout is the timeout indicating how long an interface // can receive no keepalive default until it is considered expired. DefaultKeepaliveTimeout = 3 * time.Second // DefaultOriginationInterval is the default interval between originating // beacons in a core BS. DefaultOriginationInterval = 5 * time.Second // DefaultPropagationInterval is the default interval between propagating beacons. DefaultPropagationInterval = 5 * time.Second // DefaultRegistrationInterval is the default interval between registering segments. DefaultRegistrationInterval = 5 * time.Second // DefaultExpiredCheckInterval is the default interval between checking for // expired interfaces. DefaultExpiredCheckInterval = 200 * time.Millisecond // DefaultRevTTL is the default revocation TTL. DefaultRevTTL = path_mgmt.MinRevTTL // DefaultRevOverlap specifies the default for how long before the expiry of an existing // revocation the revoker can reissue a new revocation. DefaultRevOverlap = DefaultRevTTL / 2 // DefaultQueryInterval is the default interval after which the segment // cache expires. DefaultQueryInterval = 5 * time.Minute // DefaultMaxASValidity is the default validity period for renewed AS certificates. DefaultMaxASValidity = 3 * 24 * time.Hour )
View Source
const ( ErrKeyConf common.ErrMsg = "Unable to load KeyConf" ErrCustomers common.ErrMsg = "Unable to load Customers" )
Error values
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BSConfig ¶
type BSConfig struct { // KeepaliveInterval is the interval between sending interface keepalives. KeepaliveInterval util.DurWrap `toml:"keepalive_interval,omitempty"` // KeepaliveTimeout is the timeout indicating how long an interface can // receive no keepalive until it is considered expired. KeepaliveTimeout util.DurWrap `toml:"keepalive_timeout,omitempty"` // OriginationInterval is the interval between originating beacons in a core BS. OriginationInterval util.DurWrap `toml:"origination_interval,omitempty"` // PropagationInterval is the interval between propagating beacons. PropagationInterval util.DurWrap `toml:"propagation_interval,omitempty"` // RegistrationInterval is the interval between registering segments. RegistrationInterval util.DurWrap `toml:"registration_interval,omitempty"` // ExpiredCheckInterval is the interval between checking whether interfaces // have expired and should be revoked. ExpiredCheckInterval util.DurWrap `toml:"expired_check_interval,omitempty"` // RevTTL is the revocation TTL. (default 10s) RevTTL util.DurWrap `toml:"rev_ttl,omitempty"` // RevOverlap specifies for how long before the expiry of an existing revocation the revoker // can reissue a new revocation. (default 5s) RevOverlap util.DurWrap `toml:"rev_overlap,omitempty"` // Policies contains the policy files. Policies Policies `toml:"policies,omitempty"` }
BSConfig holds the configuration specific to the beacon server.
func (*BSConfig) ConfigName ¶
ConfigName is the toml key for the beacon server specific configuration.
func (*BSConfig) InitDefaults ¶
func (cfg *BSConfig) InitDefaults()
InitDefaults the default values for the durations that are equal to zero.
type CA ¶ added in v0.6.0
type CA struct { config.NoDefaulter // MaxASValidity is the maximum AS certificate lifetime. MaxASValidity util.DurWrap `toml:"max_as_validity,omitempty"` }
CA is the CA configuration.
func (*CA) ConfigName ¶ added in v0.6.0
type Config ¶
type Config struct { General env.General `toml:"general,omitempty"` Features env.Features `toml:"features,omitempty"` Logging log.Config `toml:"log,omitempty"` Metrics env.Metrics `toml:"metrics,omitempty"` Tracing env.Tracing `toml:"tracing,omitempty"` QUIC env.QUIC `toml:"quic,omitempty"` BeaconDB storage.DBConfig `toml:"beacon_db,omitempty"` TrustDB storage.DBConfig `toml:"trust_db,omitempty"` RenewalDB storage.DBConfig `toml:"renewal_db,omitempty"` PathDB storage.DBConfig `toml:"path_db,omitempty"` BS BSConfig `toml:"beaconing,omitempty"` PS PSConfig `toml:"path,omitempty"` CA CA `toml:"ca,omitempty"` TrustEngine trustengine.Config `toml:"trustengine,omitempty"` }
Config is the control server configuration.
func (*Config) InitDefaults ¶
func (cfg *Config) InitDefaults()
InitDefaults initializes the default values for all parts of the config.
type PSConfig ¶
type PSConfig struct { // QueryInterval specifies after how much time segments // for a destination should be refetched. QueryInterval util.DurWrap `toml:"query_interval,omitempty"` }
func (*PSConfig) ConfigName ¶
func (*PSConfig) InitDefaults ¶
func (cfg *PSConfig) InitDefaults()
type Policies ¶
type Policies struct { config.NoDefaulter config.NoValidator // Propagation contains the file path for the propagation policy. If this // is the empty string, the default policy is used. Propagation string `toml:"propagation,omitempty"` // CoreRegistration contains the file path for the core registration // policy. If this is the empty string, the default policy is used. In a // non-core beacon server, this field is ignored. CoreRegistration string `toml:"core_registration,omitempty"` // UpRegistration contains the file path for the up registration policy. If // this is the empty string, the default policy is used. In a core beacon // server, this field is ignored. UpRegistration string `toml:"up_registration,omitempty"` // DownRegistration contains the file path for the down registration policy. // If this is the empty string, the default policy is used. In a core beacon // server, this field is ignored. DownRegistration string `toml:"down_registration,omitempty"` // HiddenPathRegistration contains the file path for the hidden path registration policy // and the corresponding hidden path groups. // If this is the empty string, no hidden path functionality is used. // If HiddenPathRegistration begins with http:// or https://, it will be fetched // over the network from the specified URL instead. HiddenPathRegistration string `toml:"hidden_path_registration,omitempty"` }
Policies contains the file paths of the policies.
func (*Policies) ConfigName ¶
ConfigName is the toml key for the beacon server specific configuration.
Click to show internal directories.
Click to hide internal directories.