mirror of https://github.com/status-im/consul.git
35e67b1d1a
Secondary CA initialization steps are: • Wait until the primary will be capable of signing intermediate certs. We use serf metadata to check the versions of servers in the primary which avoids needing a token like the previous implementation that used RPCs. We require at least one alive server in the primary and the all alive servers meet the version requirement. • Initialize the secondary CA by getting the primary to sign an intermediate When a primary dc is configured, if no existing CA is initialized and for whatever reason we cannot initialize a secondary CA the secondary DC will remain without a CA. As soon as it can it will initialize the secondary CA by pulling the primaries roots and getting the primary to sign an intermediate. This also fixes a segfault that can happen during leadership revocation. There was a spot in the secondaryCARootsWatch that was getting the CA Provider and executing methods on it without nil checking. Under normal circumstances it wont be nil but during leadership revocation it gets nil'ed out. Therefore there is a period of time between closing the stop chan and when the go routine is actually stopped where it could read a nil provider and cause a segfault. |
||
---|---|---|
.. | ||
ae | ||
cache | ||
cache-types | ||
checks | ||
config | ||
connect | ||
consul | ||
debug | ||
exec | ||
local | ||
metadata | ||
mock | ||
pool | ||
proxycfg | ||
proxyprocess | ||
router | ||
structs | ||
systemd | ||
token | ||
xds | ||
acl.go | ||
acl_endpoint.go | ||
acl_endpoint_legacy.go | ||
acl_endpoint_legacy_test.go | ||
acl_endpoint_test.go | ||
acl_test.go | ||
agent.go | ||
agent_endpoint.go | ||
agent_endpoint_test.go | ||
agent_test.go | ||
bindata_assetfs.go | ||
blacklist.go | ||
blacklist_test.go | ||
catalog_endpoint.go | ||
catalog_endpoint_test.go | ||
check.go | ||
config.go | ||
config_endpoint.go | ||
config_endpoint_test.go | ||
connect_auth.go | ||
connect_ca_endpoint.go | ||
connect_ca_endpoint_test.go | ||
coordinate_endpoint.go | ||
coordinate_endpoint_test.go | ||
dns.go | ||
dns_test.go | ||
enterprise_delegate_oss.go | ||
event_endpoint.go | ||
event_endpoint_test.go | ||
health_endpoint.go | ||
health_endpoint_test.go | ||
http.go | ||
http_oss.go | ||
http_oss_test.go | ||
http_test.go | ||
intentions_endpoint.go | ||
intentions_endpoint_test.go | ||
internal_endpoint.go | ||
keyring.go | ||
keyring_test.go | ||
kvs_endpoint.go | ||
kvs_endpoint_test.go | ||
notify.go | ||
notify_test.go | ||
operator_endpoint.go | ||
operator_endpoint_test.go | ||
prepared_query_endpoint.go | ||
prepared_query_endpoint_test.go | ||
remote_exec.go | ||
remote_exec_test.go | ||
retry_join.go | ||
retry_join_test.go | ||
service_manager.go | ||
service_manager_test.go | ||
session_endpoint.go | ||
session_endpoint_test.go | ||
sidecar_service.go | ||
sidecar_service_test.go | ||
signal_unix.go | ||
signal_windows.go | ||
snapshot_endpoint.go | ||
snapshot_endpoint_test.go | ||
status_endpoint.go | ||
status_endpoint_test.go | ||
testagent.go | ||
testagent_test.go | ||
translate_addr.go | ||
txn_endpoint.go | ||
txn_endpoint_test.go | ||
ui_endpoint.go | ||
ui_endpoint_test.go | ||
user_event.go | ||
user_event_test.go | ||
util.go | ||
util_test.go | ||
watch_handler.go | ||
watch_handler_test.go |