open-consul/vendor/github.com
Hans Hasselberg 02de4c8b76
add primary keys to list keyring (#8522)
During gossip encryption key rotation it would be nice to be able to see if all nodes are using the same key. This PR adds another field to the json response from `GET v1/operator/keyring` which lists the primary keys in use per dc. That way an operator can tell when a key was successfully setup as primary key.

Based on https://github.com/hashicorp/serf/pull/611 to add primary key to list keyring output:

```json
[
  {
    "WAN": true,
    "Datacenter": "dc2",
    "Segment": "",
    "Keys": {
      "0OuM4oC3Os18OblWiBbZUaHA7Hk+tNs/6nhNYtaNduM=": 6,
      "SINm887hKTzmMWeBNKTJReaTLX3mBEJKriDyt88Ad+g=": 6
    },
    "PrimaryKeys": {
      "SINm887hKTzmMWeBNKTJReaTLX3mBEJKriDyt88Ad+g=": 6
    },
    "NumNodes": 6
  },
  {
    "WAN": false,
    "Datacenter": "dc2",
    "Segment": "",
    "Keys": {
      "0OuM4oC3Os18OblWiBbZUaHA7Hk+tNs/6nhNYtaNduM=": 8,
      "SINm887hKTzmMWeBNKTJReaTLX3mBEJKriDyt88Ad+g=": 8
    },
    "PrimaryKeys": {
      "SINm887hKTzmMWeBNKTJReaTLX3mBEJKriDyt88Ad+g=": 8
    },
    "NumNodes": 8
  },
  {
    "WAN": false,
    "Datacenter": "dc1",
    "Segment": "",
    "Keys": {
      "0OuM4oC3Os18OblWiBbZUaHA7Hk+tNs/6nhNYtaNduM=": 3,
      "SINm887hKTzmMWeBNKTJReaTLX3mBEJKriDyt88Ad+g=": 8
    },
    "PrimaryKeys": {
      "SINm887hKTzmMWeBNKTJReaTLX3mBEJKriDyt88Ad+g=": 8
    },
    "NumNodes": 8
  }
]
```

I intentionally did not change the CLI output because I didn't find a good way of displaying this information. There are a couple of options that we could implement later:
* add a flag to show the primary keys
* add a flag to show json output

Fixes #3393.
2020-08-18 09:50:24 +02:00
..
Azure Update go-discover dependency (#7731) 2020-05-04 10:59:48 -04:00
DataDog/datadog-go vendor: Update github.com/armon/go-metrics to v0.3.3 2020-07-23 11:37:33 -07:00
Microsoft/go-winio Update vendoring from go mod. (#5566) 2019-03-26 17:50:42 -04:00
NYTimes/gziphandler Update vendoring from go mod. (#5566) 2019-03-26 17:50:42 -04:00
StackExchange/wmi Connect: allow configuring Envoy for L7 Observability (#5558) 2019-04-29 17:27:57 +01:00
armon Update Go-Metrics 0.3.4 (#8478) 2020-08-11 11:17:43 -05:00
aws/aws-sdk-go Bump go-discover to support EC2 Metadata Service v2 (#6865) 2019-12-04 11:59:16 -05:00
beorn7/perks Added dependency github.com/prometheus/client_golang/prometheus/promhttp 2018-04-06 08:54:37 +02:00
bgentry/speakeasy Update vendoring from go mod. (#5566) 2019-03-26 17:50:42 -04:00
boltdb/bolt Update vendoring from go mod. (#5566) 2019-03-26 17:50:42 -04:00
census-instrumentation/opencensus-proto connect: upgrade github.com/envoyproxy/go-control-plane to v0.9.5 (#8165) 2020-06-23 15:19:56 -05:00
cespare/xxhash/v2 vendor: Update github.com/armon/go-metrics to v0.3.3 2020-07-23 11:37:33 -07:00
circonus-labs agent: transfer leadership when establishLeadership fails (#5247) 2019-06-19 14:50:48 +02:00
cncf/udpa/go connect: upgrade github.com/envoyproxy/go-control-plane to v0.9.5 (#8165) 2020-06-23 15:19:56 -05:00
coredns/coredns Add github.com/coredns/coredns/plugin/pkg/dnsutil files 2018-05-21 22:25:16 +02:00
coreos/go-oidc acl: add auth method for JWTs (#7846) 2020-05-11 20:59:29 -05:00
davecgh/go-spew Update vendoring from go mod. (#5566) 2019-03-26 17:50:42 -04:00
denverdino/aliyungo Update vendoring from go mod. (#5566) 2019-03-26 17:50:42 -04:00
dgrijalva/jwt-go Update vendoring from go mod. (#5566) 2019-03-26 17:50:42 -04:00
digitalocean/godo Update vendoring from go mod. (#5566) 2019-03-26 17:50:42 -04:00
dimchansky/utfbom Bump go-discover to support EC2 Metadata Service v2 (#6865) 2019-12-04 11:59:16 -05:00
docker/go-connections Update vendoring from go mod. (#5566) 2019-03-26 17:50:42 -04:00
elazarl/go-bindata-assetfs Update vendoring from go mod. (#5566) 2019-03-26 17:50:42 -04:00
envoyproxy connect: upgrade github.com/envoyproxy/go-control-plane to v0.9.5 (#8165) 2020-06-23 15:19:56 -05:00
fatih/color Allow users to configure either unstructured or JSON logging (#7130) 2020-01-28 17:50:41 -06:00
go-ole/go-ole Connect: allow configuring Envoy for L7 Observability (#5558) 2019-04-29 17:27:57 +01:00
gogo/protobuf connect: upgrade github.com/envoyproxy/go-control-plane to v0.9.5 (#8165) 2020-06-23 15:19:56 -05:00
golang connect: upgrade github.com/envoyproxy/go-control-plane to v0.9.5 (#8165) 2020-06-23 15:19:56 -05:00
google Update protobuf and golang.org/x/... vendor 2020-06-09 14:46:41 -04:00
googleapis Update google.golang.org/api and stretchr/testify 2020-06-09 16:03:05 -04:00
gophercloud/gophercloud Update go-discover dependency (#7731) 2020-05-04 10:59:48 -04:00
hashicorp add primary keys to list keyring (#8522) 2020-08-18 09:50:24 +02:00
imdario/mergo Update vendoring from go mod. (#5566) 2019-03-26 17:50:42 -04:00
jmespath/go-jmespath connect: Add AWS PCA provider (#6795) 2019-11-21 17:40:29 +00:00
joyent/triton-go Update github.com/joyent/triton-go to latest 2020-04-16 12:34:29 -04:00
json-iterator/go vendor: Update github.com/armon/go-metrics to v0.3.3 2020-07-23 11:37:33 -07:00
konsorten/go-windows-terminal-sequences Update github.com/joyent/triton-go to latest 2020-04-16 12:34:29 -04:00
kr/text replace old fork of text package (#4501) 2018-08-14 12:23:18 -07:00
linode/linodego Switch to go 1.13.7 (#7262) 2020-02-12 10:15:24 -06:00
mattn agent: don't let left nodes hold onto their node-id (#7747) 2020-05-04 18:39:08 +02:00
matttproud/golang_protobuf_extensions Update vendoring from go mod. (#5566) 2019-03-26 17:50:42 -04:00
miekg/dns Switch to go 1.13.7 (#7262) 2020-02-12 10:15:24 -06:00
mitchellh Update mapstructure to v1.3.3 (#8361) 2020-07-22 15:13:21 -04:00
modern-go Update vendoring from go mod. (#5566) 2019-03-26 17:50:42 -04:00
nicolai86/scaleway-sdk Update vendoring from go mod. (#5566) 2019-03-26 17:50:42 -04:00
packethost/packngo Update vendoring from go mod. (#5566) 2019-03-26 17:50:42 -04:00
patrickmn/go-cache acl: add auth method for JWTs (#7846) 2020-05-11 20:59:29 -05:00
pierrec/lz4 connect: intermediate CA certs generated with the vault provider lack URI SANs (#6491) 2019-09-23 12:04:40 -05:00
pkg/errors Update vendoring from go mod. (#5566) 2019-03-26 17:50:42 -04:00
pmezard/go-difflib agent/consul/fsm: begin using testify/assert 2018-03-06 09:48:15 -08:00
posener/complete vendor: fix case issue (#7777) 2020-05-04 21:39:01 +02:00
pquerna/cachecontrol acl: add auth method for JWTs (#7846) 2020-05-11 20:59:29 -05:00
prometheus vendor: Update github.com/armon/go-metrics to v0.3.3 2020-07-23 11:37:33 -07:00
rboyer/safeio cli: ensure that 'snapshot save' is fsync safe and also only writes to the requested file on success (#7698) 2020-04-24 17:34:47 -05:00
renier/xmlrpc Update vendoring from go mod. (#5566) 2019-03-26 17:50:42 -04:00
ryanuber connect: intermediate CA certs generated with the vault provider lack URI SANs (#6491) 2019-09-23 12:04:40 -05:00
sean-/seed Update vendoring from go mod. (#5566) 2019-03-26 17:50:42 -04:00
shirou/gopsutil Update gopsutil (#8208) 2020-07-01 14:47:56 +02:00
sirupsen/logrus Update github.com/joyent/triton-go to latest 2020-04-16 12:34:29 -04:00
softlayer/softlayer-go Update vendoring from go mod. (#5566) 2019-03-26 17:50:42 -04:00
spf13/pflag Update go-discover dependency (#7731) 2020-05-04 10:59:48 -04:00
stretchr Update google.golang.org/api and stretchr/testify 2020-06-09 16:03:05 -04:00
tencentcloud/tencentcloud-sdk-go Bump go-discover to support EC2 Metadata Service v2 (#6865) 2019-12-04 11:59:16 -05:00
tv42/httpunix agent: transfer leadership when establishLeadership fails (#5247) 2019-06-19 14:50:48 +02:00
vmware/govmomi Pull go-discover to fix Sirupsen/logrus (#5598) 2019-04-03 20:07:00 +01:00