Skip to content

Commit

Permalink
SDS v3 endpoints support SPIFFE validator (spiffe#2435)
Browse files Browse the repository at this point in the history
Signed-off-by: Marcos Yacob <marcos.yacob@hpe.com>
  • Loading branch information
MarcosDY authored and evan2645 committed Sep 2, 2021
1 parent 652640f commit c54c090
Show file tree
Hide file tree
Showing 13 changed files with 888 additions and 315 deletions.
23 changes: 15 additions & 8 deletions cmd/spire-agent/cli/run/run.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,11 @@ const (
defaultConfigPath = "conf/agent/agent.conf"

// TODO: Make my defaults sane
defaultDataDir = "."
defaultLogLevel = "INFO"
defaultDefaultSVIDName = "default"
defaultDefaultBundleName = "ROOTCA"
defaultDataDir = "."
defaultLogLevel = "INFO"
defaultDefaultSVIDName = "default"
defaultDefaultBundleName = "ROOTCA"
defaultDefaultAllBundlesName = "ALL"
)

// Config contains all available configurables, arranged by section
Expand Down Expand Up @@ -84,8 +85,9 @@ type agentConfig struct {
}

type sdsConfig struct {
DefaultSVIDName string `hcl:"default_svid_name"`
DefaultBundleName string `hcl:"default_bundle_name"`
DefaultSVIDName string `hcl:"default_svid_name"`
DefaultBundleName string `hcl:"default_bundle_name"`
DefaultAllBundlesName string `hcl:"default_all_bundles_name"`
}

type experimentalConfig struct {
Expand Down Expand Up @@ -400,6 +402,10 @@ func NewAgentConfig(c *Config, logOptions []log.Option, allowUnknownConfig bool)
ac.DataDir = c.Agent.DataDir
ac.DefaultSVIDName = c.Agent.SDS.DefaultSVIDName
ac.DefaultBundleName = c.Agent.SDS.DefaultBundleName
ac.DefaultAllBundlesName = c.Agent.SDS.DefaultAllBundlesName
if ac.DefaultAllBundlesName == ac.DefaultBundleName {
logger.Warn(`The "default_bundle_name" and "default_all_bundles_name" configurables have the same value. "default_all_bundles_name" will be ignored. Please configure distinct values or use the defaults. This will be a configuration error in a future release.`)
}

err = setupTrustBundle(ac, c)
if err != nil {
Expand Down Expand Up @@ -539,8 +545,9 @@ func defaultConfig() *Config {
LogFormat: log.DefaultFormat,
SocketPath: common.DefaultSocketPath,
SDS: sdsConfig{
DefaultBundleName: defaultDefaultBundleName,
DefaultSVIDName: defaultDefaultSVIDName,
DefaultBundleName: defaultDefaultBundleName,
DefaultSVIDName: defaultDefaultSVIDName,
DefaultAllBundlesName: defaultDefaultAllBundlesName,
},
},
}
Expand Down
20 changes: 20 additions & 0 deletions cmd/spire-agent/cli/run/run_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,26 @@ func TestMergeInput(t *testing.T) {
require.Equal(t, "foo", c.Agent.SDS.DefaultBundleName)
},
},
{
msg: "default_all_bundles_name should default value of ALL",
fileInput: func(c *Config) {},
cliInput: func(ac *agentConfig) {},
test: func(t *testing.T, c *Config) {
require.Equal(t, "ALL", c.Agent.SDS.DefaultAllBundlesName)
},
},
{
msg: "default_all_bundles_name should be configurable by file",
fileInput: func(c *Config) {
c.Agent.SDS = sdsConfig{
DefaultAllBundlesName: "foo",
}
},
cliInput: func(ac *agentConfig) {},
test: func(t *testing.T, c *Config) {
require.Equal(t, "foo", c.Agent.SDS.DefaultAllBundlesName)
},
},
{
msg: "insecure_bootstrap should be configurable by file",
fileInput: func(c *Config) {
Expand Down
5 changes: 5 additions & 0 deletions conf/agent/agent_full.conf
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,11 @@ agent {
# # default_bundle_name: The Validation Context resource name to use for the
# # default X.509 bundle with Envoy SDS. Default: ROOTCA.
# # default_bundle_name = "ROOTCA"
#
# # default_all_bundles_name: The Validation Context resource name to use to fetch
# # all bundles (including federated bundles) with Envoy SDS. Cannot be used with
# # Envoy releases prior to 1.18.
# # default_all_bundles_name = "ALL"
# }

# allowed_foreign_jwt_claims: set a list of trusted claims to be returned when validating foreign JWTSVIDs
Expand Down
25 changes: 17 additions & 8 deletions doc/spire_agent.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,10 +67,11 @@ Only one of these three options may be set at a time.

### SDS Configuration

| Configuration | Description | Default |
| --------------------- | --------------------------------------------------------------------------------------- | -------------------- |
| `default_svid_name` | The TLS Certificate resource name to use for the default X509-SVID with Envoy SDS | default |
| `default_bundle_name` | The Validation Context resource name to use for the default X.509 bundle with Envoy SDS | ROOTCA |
| Configuration | Description | Default |
| -------------------------- | ------------------------------------------------------------------------------------------------ | ----------------- |
| `default_svid_name` | The TLS Certificate resource name to use for the default X509-SVID with Envoy SDS | default |
| `default_bundle_name` | The Validation Context resource name to use for the default X.509 bundle with Envoy SDS | ROOTCA |
| `default_all_bundles_name` | The Validation Context resource name to use for all bundles (including federated) with Envoy SDS | ALL |


## Plugin configuration
Expand Down Expand Up @@ -268,10 +269,18 @@ containing the default X509-SVID for the workload (i.e. Envoy) is fetched.
The default name is configurable (see `default_svid_name` under [SDS Configuration](#sds-configuration)).

[`auth.CertificateValidationContext`](https://www.envoyproxy.io/docs/envoy/latest/api-v2/api/v2/auth/cert.proto#auth-certificatevalidationcontext)
resources containing trusted CA certificates can be fetched using the SPIFFE ID of the desired trust domain as the
resource name (e.g. `spiffe://example.org`). Alternatively, if the default name "ROOTCA" is requested, the
`auth.CertificateValidationContext` containing the trusted CA certificates for the agent's trust domain is fetched.
The default name is configurable (see `default_bundle_name` under [SDS Configuration](#sds-configuration)).
resources containing trusted CA certificates can be fetched using the SPIFFE ID
of the desired trust domain as the resource name (e.g. `spiffe://example.org`).
In addition, two other special resource names are available. The first, which
defaults to "ROOTCA", provides the CA certificates for the trust domain the
agent belongs to. The second, which defaults to "ALL", returns the trusted CA
certificates for both the trust domain the agent belongs to as well as any
federated trust domains applicable to the Envoy workload. The default names
for these resource names are configurable via the `default_bundle_name` and
`default_all_bundles_name`, respectively. The "ALL" resource name requires
support for the [SPIFFE Certificate Validator](https://www.envoyproxy.io/docs/envoy/latest/api-v3/extensions/transport_sockets/tls/v3/tls_spiffe_validator_config.proto)
extension, which is only available starting with Envoy 1.18.
The default name is configurable (see `default_all_bundles_name` under [SDS Configuration](#sds-configuration).

## OpenShift Support

Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ require (
github.com/blang/semver v3.5.1+incompatible
github.com/cenkalti/backoff/v3 v3.0.0
github.com/docker/docker v1.4.2-0.20200319182547-c7ad2b866182
github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad
github.com/envoyproxy/go-control-plane v0.9.9-0.20210521033809-0cbd29f7d4f8
github.com/felixge/httpsnoop v1.0.2 // indirect
github.com/go-logr/logr v0.1.0
github.com/go-ole/go-ole v1.2.4 // indirect
Expand Down
13 changes: 11 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@ github.com/alecthomas/units v0.0.0-20190717042225-c3de453c63f4/go.mod h1:ybxpYRF
github.com/andres-erbsen/clock v0.0.0-20160526145045-9e14626cd129 h1:MzBOUgng9orim59UnfUTLRjMpd09C5uEVQ6RPGeCaVI=
github.com/andres-erbsen/clock v0.0.0-20160526145045-9e14626cd129/go.mod h1:rFgpPQZYZ8vdbc+48xibu8ALc3yeyd64IhHS+PU6Yyg=
github.com/andreyvit/diff v0.0.0-20170406064948-c7f18ee00883/go.mod h1:rCTlJbsFo29Kk6CurOXKm700vrz8f0KW0JNfpkRJY/8=
github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY=
github.com/apache/thrift v0.12.0/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ=
github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8=
github.com/armon/go-metrics v0.3.0/go.mod h1:zXjbSimjXTd7vOpY8B0/2LpvNvDoXBuplAD+gJD3GYs=
Expand Down Expand Up @@ -161,8 +162,9 @@ github.com/circonus-labs/circonusllhist v0.1.3/go.mod h1:kMXHVDlOchFAehlya5ePtbp
github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw=
github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc=
github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk=
github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403 h1:cqQfy1jclcSy/FwLjemeg3SR1yaINm74aQyupQ0Bl8M=
github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk=
github.com/cncf/xds/go v0.0.0-20210312221358-fbca930ec8ed h1:OZmjad4L3H8ncOIR8rnb5MREYqG8ixi5+WbeUsquF0c=
github.com/cncf/xds/go v0.0.0-20210312221358-fbca930ec8ed/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8=
github.com/containerd/cgroups v0.0.0-20190919134610-bf292b21730f/go.mod h1:OApqhQ4XNSNC13gXIwDjhOQxjWa/NxkwZXJ1EvqT0ko=
github.com/containerd/console v0.0.0-20180822173158-c12b1e7919c1/go.mod h1:Tj/on1eG8kiEhd0+fhSDzsPAFESxzBBvdyEgyryXffw=
Expand Down Expand Up @@ -224,8 +226,9 @@ github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymF
github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4=
github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98=
github.com/envoyproxy/go-control-plane v0.9.7/go.mod h1:cwu0lG7PUMfa9snN8LXBig5ynNVH9qI8YYLbd1fK2po=
github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad h1:EmNYJhPYy0pOFjCx2PrgtaBXmee0iUX9hLlxE1xHOJE=
github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk=
github.com/envoyproxy/go-control-plane v0.9.9-0.20210521033809-0cbd29f7d4f8 h1:iZy8+SuvO5p9mwWULLg45oJc1BWh80f5kFzZiPuxafg=
github.com/envoyproxy/go-control-plane v0.9.9-0.20210521033809-0cbd29f7d4f8/go.mod h1:hliV/p42l8fGbc6Y9bQ70uLwIvmJyVE5k4iMKlh8wCQ=
github.com/envoyproxy/protoc-gen-validate v0.1.0 h1:EQciDnbrYxy13PgWoY8AqoxGiPrpgBZ1R8UNe3ddc+A=
github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c=
github.com/erikstmartin/go-testdb v0.0.0-20160219214506-8d10e4a1bae5 h1:Yzb9+7DPaBjB8zlTR87/ElzFsnQfuHnVUVqpZZIcV5Y=
Expand Down Expand Up @@ -427,6 +430,7 @@ github.com/grpc-ecosystem/go-grpc-middleware v1.0.1-0.20190118093823-f849b5445de
github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk=
github.com/grpc-ecosystem/grpc-gateway v1.9.0/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY=
github.com/grpc-ecosystem/grpc-gateway v1.9.5/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY=
github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw=
github.com/hashicorp/errwrap v1.0.0 h1:hLrqtEDnRye3+sgx6z4qVLNuviH3MR5aQ0ykNJa/UYA=
github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80=
Expand Down Expand Up @@ -658,6 +662,7 @@ github.com/prometheus/procfs v0.1.3/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4O
github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40TwIPHuXU=
github.com/rcrowley/go-metrics v0.0.0-20181016184325-3113b8401b8a/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4=
github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg=
github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6LYCDYWNEvQ=
github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4=
github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g=
github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
Expand Down Expand Up @@ -744,6 +749,7 @@ go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk=
go.opencensus.io v0.23.0 h1:gqCw0LfLxScz8irSi8exQc7fyQ0fKQU/qnC/X8+V/1M=
go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E=
go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI=
go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
go.uber.org/atomic v1.5.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ=
Expand Down Expand Up @@ -1087,6 +1093,7 @@ google.golang.org/genproto v0.0.0-20200312145019-da6875a35672/go.mod h1:55QSHmfG
google.golang.org/genproto v0.0.0-20200331122359-1ee6d9798940/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
google.golang.org/genproto v0.0.0-20200430143042-b979b6f78d84/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
google.golang.org/genproto v0.0.0-20200511104702-f5ebc3bea380/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
google.golang.org/genproto v0.0.0-20200515170657-fc4c6c6a6587/go.mod h1:YsZOwe1myG/8QRHRsmBRE1LrgQY60beZKjly0O1fX9U=
google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo=
google.golang.org/genproto v0.0.0-20200618031413-b414f8b61790/go.mod h1:jDfRM7FcilCzHH/e9qn6dsT145K34l5v+OpcnNgKAAA=
Expand Down Expand Up @@ -1124,6 +1131,7 @@ google.golang.org/grpc v1.29.1/go.mod h1:itym6AZVZYACWQqET3MqgPpjcuV5QH3BxFS3Iji
google.golang.org/grpc v1.30.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak=
google.golang.org/grpc v1.31.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak=
google.golang.org/grpc v1.31.1/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak=
google.golang.org/grpc v1.33.1/go.mod h1:fr5YgcSWrqhRRxogOsw7RzIpsmvOZ6IcH4kBYTpR3n0=
google.golang.org/grpc v1.33.2/go.mod h1:JMHMWHQWaTccqQQlmk3MJZS+GWXOdAesneDmEnv2fbc=
google.golang.org/grpc v1.34.0/go.mod h1:WotjhfgOW/POjDeRt8vscBtXq+2VjORFy659qA51WJ8=
google.golang.org/grpc v1.35.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU=
Expand Down Expand Up @@ -1171,6 +1179,7 @@ gopkg.in/tomb.v2 v2.0.0-20161208151619-d5d1b5820637/go.mod h1:BHsqpu/nsuzkT5BpiH
gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7/go.mod h1:JAlM8MvJe8wmxCU4Bli9HhUf9+ttbYbLASfIpnQbh74=
gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
gopkg.in/yaml.v2 v2.2.3/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
gopkg.in/yaml.v2 v2.2.5/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
gopkg.in/yaml.v2 v2.2.8 h1:obN1ZagJSUGI0Ek/LBmuj4SNLPfIny3KsKFopxRdj10=
Expand Down
1 change: 1 addition & 0 deletions pkg/agent/agent.go
Original file line number Diff line number Diff line change
Expand Up @@ -217,6 +217,7 @@ func (a *Agent) newEndpoints(cat catalog.Catalog, metrics telemetry.Metrics, mgr
Metrics: metrics,
DefaultSVIDName: a.c.DefaultSVIDName,
DefaultBundleName: a.c.DefaultBundleName,
DefaultAllBundlesName: a.c.DefaultAllBundlesName,
AllowUnauthenticatedVerifiers: a.c.AllowUnauthenticatedVerifiers,
AllowedForeignJWTClaims: a.c.AllowedForeignJWTClaims,
TrustDomain: a.c.TrustDomain,
Expand Down
3 changes: 3 additions & 0 deletions pkg/agent/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ type Config struct {
// Directory to bind the admin api to
AdminBindAddress *net.UnixAddr

// The Validation Context resource name to use when fetching X.509 bundle together with federated bundles with Envoy SDS
DefaultAllBundlesName string

// The Validation Context resource name to use for the default X.509 bundle with Envoy SDS
DefaultBundleName string

Expand Down
3 changes: 3 additions & 0 deletions pkg/agent/endpoints/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,9 @@ type Config struct {
// The TLS Certificate resource name to use for the default X509-SVID with Envoy SDS
DefaultSVIDName string

// The Validation Context resource name to use when fetching X.509 bundle together with federated bundles with Envoy SDS
DefaultAllBundlesName string

// The Validation Context resource name to use for the default X.509 bundle with Envoy SDS
DefaultBundleName string

Expand Down
9 changes: 5 additions & 4 deletions pkg/agent/endpoints/endpoints.go
Original file line number Diff line number Diff line change
Expand Up @@ -81,10 +81,11 @@ func New(c Config) *Endpoints {
})

sdsv3Server := c.newSDSv3Server(sdsv3.Config{
Attestor: attestor,
Manager: c.Manager,
DefaultSVIDName: c.DefaultSVIDName,
DefaultBundleName: c.DefaultBundleName,
Attestor: attestor,
Manager: c.Manager,
DefaultSVIDName: c.DefaultSVIDName,
DefaultBundleName: c.DefaultBundleName,
DefaultAllBundlesName: c.DefaultAllBundlesName,
})

healthServer := c.newHealthServer(healthv1.Config{
Expand Down
2 changes: 2 additions & 0 deletions pkg/agent/endpoints/endpoints_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,7 @@ func TestEndpoints(t *testing.T) {
Manager: FakeManager{},
DefaultSVIDName: "DefaultSVIDName",
DefaultBundleName: "DefaultBundleName",
DefaultAllBundlesName: "DefaultAllBundlesName",
AllowedForeignJWTClaims: tt.allowedClaims,

// Assert the provided config and return a fake Workload API server
Expand Down Expand Up @@ -204,6 +205,7 @@ func TestEndpoints(t *testing.T) {
assert.Equal(t, FakeManager{}, c.Manager)
assert.Equal(t, "DefaultSVIDName", c.DefaultSVIDName)
assert.Equal(t, "DefaultBundleName", c.DefaultBundleName)
assert.Equal(t, "DefaultAllBundlesName", c.DefaultAllBundlesName)
return FakeSDSv3Server{Attestor: attestor}
},

Expand Down

0 comments on commit c54c090

Please sign in to comment.