diff --git a/.github/workflows/integration-install.yml b/.github/workflows/integration-install.yml index 9909da99..28edbc6d 100644 --- a/.github/workflows/integration-install.yml +++ b/.github/workflows/integration-install.yml @@ -43,6 +43,9 @@ jobs: elif command -v /c/Users/runneradmin/.local/bin/draft &> /dev/null then echo "install_dir=/c/Users/runneradmin/.local/bin/draft" >> $GITHUB_ENV + elif command -v /Users/runner/.local/bin/draft &> /dev/null + then + echo "install_dir=/Users/runner/.local/bin/draft" >> $GITHUB_ENV else echo "draft could not be found" exit 1 diff --git a/Dockerfile b/Dockerfile index bd8d2b25..f0c88f82 100644 --- a/Dockerfile +++ b/Dockerfile @@ -5,7 +5,7 @@ WORKDIR /draft RUN apk add gcc musl-dev python3-dev libffi-dev openssl-dev cargo make RUN apk add py3-pip -RUN python3 -m venv az-cli-env +RUN python3 -m venv az-cli-env RUN az-cli-env/bin/pip install --upgrade pip RUN az-cli-env/bin/pip install --upgrade azure-cli RUN az-cli-env/bin/az --version @@ -18,4 +18,4 @@ COPY . ./ RUN make go-generate RUN go mod vendor -ENTRYPOINT ["go"] +ENTRYPOINT ["go"] \ No newline at end of file diff --git a/README.md b/README.md index f69e47d4..c62888ad 100644 --- a/README.md +++ b/README.md @@ -11,12 +11,12 @@ · Request Feature - [![Draft Unit Tests](https://github.com/Azure/draft/actions/workflows/unit-tests.yml/badge.svg)](https://github.com/Azure/draft/actions/workflows/unit-tests.yml) + [![Draft Unit Tests](https://github.com/Azure/draft/actions/workflows/unit-tests.yml/badge.svg?branch=main)](https://github.com/Azure/draft/actions/workflows/unit-tests.yml?query=branch:main) [![GoDoc](https://godoc.org/github.com/Azure/draft?status.svg)](https://godoc.org/github.com/Azure/draft) - [![Go Report Card](https://goreportcard.com/badge/github.com/Azure/draft)](https://goreportcard.com/report/github.com/Azure/draft) - [![CodeQL](https://github.com/Azure/draft/actions/workflows/codeql-analysis.yml/badge.svg)](https://github.com/Azure/draft/actions/workflows/codeql-analysis.yml) - [![Draft Linux Integrations](https://github.com/Azure/draft/actions/workflows/integration-linux.yml/badge.svg)](https://github.com/Azure/draft/actions/workflows/integration-linux.yml) - [![Draft Release & Publish](https://github.com/Azure/draft/actions/workflows/release-and-publish.yml/badge.svg)](https://github.com/Azure/draft/actions/workflows/release-and-publish.yml) + [![Go Report Card](https://goreportcard.com/badge/github.com/Azure/draft?branch=main)](https://goreportcard.com/report/github.com/Azure/draft) + [![CodeQL](https://github.com/Azure/draft/actions/workflows/codeql-analysis.yml/badge.svg?branch=main)](https://github.com/Azure/draft/actions/workflows/codeql-analysis.yml?query=branch:main) + [![Draft Linux Integrations](https://github.com/Azure/draft/actions/workflows/integration-linux.yml/badge.svg?branch=main)](https://github.com/Azure/draft/actions/workflows/integration-linux.yml?query=branch:main) + [![Draft Release & Publish](https://github.com/Azure/draft/actions/workflows/release-and-publish.yml/badge.svg?branch=main)](https://github.com/Azure/draft/actions/workflows/release-and-publish.yml?query=branch:main)

diff --git a/cmd/root.go b/cmd/root.go index b8969816..da2cfebd 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -39,6 +39,7 @@ For more information, please visit the Draft Github page: https://github.com/Azu logrus.SetOutput(&logger.OutputSplitter{}) logrus.SetFormatter(new(logger.CustomFormatter)) }, + SilenceErrors: true, } // Execute adds all child commands to the root command and sets flags appropriately. diff --git a/cmd/setup-gh.go b/cmd/setup-gh.go index 3c5efeea..e75ad9f5 100644 --- a/cmd/setup-gh.go +++ b/cmd/setup-gh.go @@ -1,13 +1,19 @@ package cmd import ( + "context" "errors" "fmt" - "strings" + "github.com/Azure/azure-sdk-for-go/sdk/azcore/cloud" + "github.com/Azure/azure-sdk-for-go/sdk/azidentity" + "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/subscription/armsubscription" + "github.com/Azure/draft/pkg/cred" "github.com/manifoldco/promptui" + msgraph "github.com/microsoftgraph/msgraph-sdk-go" log "github.com/sirupsen/logrus" "github.com/spf13/cobra" + "strings" "github.com/Azure/draft/pkg/providers" "github.com/Azure/draft/pkg/spinner" @@ -23,11 +29,32 @@ func newSetUpCmd() *cobra.Command { Long: `This command will automate the Github OIDC setup process by creating an Azure Active Directory application and service principle, and will configure that application to trust github.`, RunE: func(cmd *cobra.Command, args []string) error { + ctx := cmd.Context() + + azCred, err := cred.GetCred() + if err != nil { + return fmt.Errorf("getting credentials: %w", err) + } + + client, err := armsubscription.NewTenantsClient(azCred, nil) + if err != nil { + return fmt.Errorf("creating tenants client: %w", err) + } + + sc.AzClient.AzTenantClient = client + + graphClient, err := createGraphClient(azCred) + if err != nil { + return fmt.Errorf("getting client: %w", err) + } + + sc.AzClient.GraphClient = graphClient + fillSetUpConfig(sc) s := spinner.CreateSpinner("--> Setting up Github OIDC...") s.Start() - err := runProviderSetUp(sc, s) + err = runProviderSetUp(ctx, sc, s) s.Stop() if err != nil { return err @@ -49,6 +76,14 @@ application and service principle, and will configure that application to trust return cmd } +func createGraphClient(azCred *azidentity.DefaultAzureCredential) (providers.GraphClient, error) { + client, err := msgraph.NewGraphServiceClientWithCredentials(azCred, []string{cloud.AzurePublic.Services[cloud.ResourceManager].Endpoint + "/.default"}) + if err != nil { + return nil, fmt.Errorf("creating graph service client: %w", err) + } + return &providers.GraphServiceClient{Client: client}, nil +} + func fillSetUpConfig(sc *providers.SetUpCmd) { if sc.AppName == "" { sc.AppName = getAppName() @@ -72,11 +107,11 @@ func fillSetUpConfig(sc *providers.SetUpCmd) { } } -func runProviderSetUp(sc *providers.SetUpCmd, s spinner.Spinner) error { +func runProviderSetUp(ctx context.Context, sc *providers.SetUpCmd, s spinner.Spinner) error { provider := strings.ToLower(sc.Provider) if provider == "azure" { // call azure provider logic - return providers.InitiateAzureOIDCFlow(sc, s) + return providers.InitiateAzureOIDCFlow(ctx, sc, s) } else { // call logic for user-submitted provider @@ -204,5 +239,4 @@ func GetAzSubscriptionId(subIds []string) string { func init() { rootCmd.AddCommand(newSetUpCmd()) - } diff --git a/cmd/setup-gh_test.go b/cmd/setup-gh_test.go index 4dc0c4dc..9d2ac247 100644 --- a/cmd/setup-gh_test.go +++ b/cmd/setup-gh_test.go @@ -1,6 +1,7 @@ package cmd import ( + "context" "testing" "github.com/stretchr/testify/assert" @@ -10,6 +11,7 @@ import ( ) func TestSetUpConfig(t *testing.T) { + ctx := context.Background() mockSetUpCmd := &providers.SetUpCmd{} mockSetUpCmd.AppName = "testingSetUpCommand" mockSetUpCmd.Provider = "Google" @@ -20,7 +22,7 @@ func TestSetUpConfig(t *testing.T) { fillSetUpConfig(mockSetUpCmd) - err := runProviderSetUp(mockSetUpCmd, s) + err := runProviderSetUp(ctx, mockSetUpCmd, s) assert.True(t, err == nil) -} \ No newline at end of file +} diff --git a/cmd/validate.go b/cmd/validate.go index bdd8b9aa..39d19179 100644 --- a/cmd/validate.go +++ b/cmd/validate.go @@ -3,14 +3,10 @@ package cmd import ( "context" "fmt" - "io/fs" - "os" - "path" - "path/filepath" - "github.com/Azure/draft/pkg/safeguards" log "github.com/sirupsen/logrus" "github.com/spf13/cobra" + "path" ) type validateCmd struct { @@ -44,81 +40,25 @@ func newValidateCmd() *cobra.Command { return cmd } -// isDirectory determines if a file represented by path is a directory or not -func isDirectory(path string) (bool, error) { - fileInfo, err := os.Stat(path) - if err != nil { - return false, err - } - - return fileInfo.IsDir(), nil -} - -// isYAML determines if a file is of the YAML extension or not -func isYAML(path string) bool { - return filepath.Ext(path) == ".yaml" || filepath.Ext(path) == ".yml" -} - -// getManifests uses filepath.Walk to retrieve a list of the manifest files within the given manifest path -func getManifestFiles(p string) ([]safeguards.ManifestFile, error) { - var manifestFiles []safeguards.ManifestFile - - noYamlFiles := true - err := filepath.Walk(p, func(walkPath string, info fs.FileInfo, err error) error { - manifest := safeguards.ManifestFile{} - // skip when walkPath is just given path and also a directory - if p == walkPath && info.IsDir() { - return nil - } - - if err != nil { - return fmt.Errorf("error walking path %s with error: %w", walkPath, err) - } - - if !info.IsDir() && info.Name() != "" && isYAML(walkPath) { - log.Debugf("%s is not a directory, appending to manifestFiles", info.Name()) - noYamlFiles = false - - manifest.Name = info.Name() - manifest.Path = walkPath - manifestFiles = append(manifestFiles, manifest) - } else if !isYAML(p) { - log.Debugf("%s is not a manifest file, skipping...", info.Name()) - } else { - log.Debugf("%s is a directory, skipping...", info.Name()) - } - - return nil - }) - if err != nil { - return nil, fmt.Errorf("could not walk directory: %w", err) - } - if noYamlFiles { - return nil, fmt.Errorf("no manifest files found within given path") - } - - return manifestFiles, nil -} - -// run is our entry point to GetManifestViolations +// run is our entry point to GetManifestResults func (vc *validateCmd) run(c *cobra.Command) error { if vc.manifestPath == "" { return fmt.Errorf("path to the manifests cannot be empty") } ctx := context.Background() - isDir, err := isDirectory(vc.manifestPath) + isDir, err := safeguards.IsDirectory(vc.manifestPath) if err != nil { return fmt.Errorf("not a valid file or directory: %w", err) } var manifestFiles []safeguards.ManifestFile if isDir { - manifestFiles, err = getManifestFiles(vc.manifestPath) + manifestFiles, err = safeguards.GetManifestFiles(vc.manifestPath) if err != nil { return err } - } else if isYAML(vc.manifestPath) { + } else if safeguards.IsYAML(vc.manifestPath) { manifestFiles = append(manifestFiles, safeguards.ManifestFile{ Name: path.Base(vc.manifestPath), Path: vc.manifestPath, @@ -132,15 +72,15 @@ func (vc *validateCmd) run(c *cobra.Command) error { } log.Debugf("validating manifests") - manifestViolations, err := safeguards.GetManifestViolations(ctx, manifestFiles) + manifestViolations, err := safeguards.GetManifestResults(ctx, manifestFiles) if err != nil { log.Errorf("validating safeguards: %s", err.Error()) return err } + manifestViolationsFound := false for _, v := range manifestViolations { log.Printf("Analyzing %s for violations", v.Name) - manifestViolationsFound := false // returning the full list of violations after each manifest is checked for file, violations := range v.ObjectViolations { log.Printf(" %s:", file) @@ -154,8 +94,9 @@ func (vc *validateCmd) run(c *cobra.Command) error { } } - if len(manifestViolations) > 0 { + if manifestViolationsFound { c.SilenceUsage = true + return fmt.Errorf("violations found") } else { log.Printf("✅ No violations found in \"%s\".", vc.manifestPath) } diff --git a/cmd/validate_test.go b/cmd/validate_test.go index 8eb5592d..d6fd91ab 100644 --- a/cmd/validate_test.go +++ b/cmd/validate_test.go @@ -19,15 +19,15 @@ func TestIsDirectory(t *testing.T) { pathFalse := path.Join(testWd, "validate.go") pathError := "" - isDir, err := isDirectory(pathTrue) + isDir, err := safeguards.IsDirectory(pathTrue) assert.True(t, isDir) assert.Nil(t, err) - isDir, err = isDirectory(pathFalse) + isDir, err = safeguards.IsDirectory(pathFalse) assert.False(t, isDir) assert.Nil(t, err) - isDir, err = isDirectory(pathError) + isDir, err = safeguards.IsDirectory(pathError) assert.False(t, isDir) assert.NotNil(t, err) } @@ -39,14 +39,14 @@ func TestIsYAML(t *testing.T) { fileNotYaml, _ := filepath.Abs("../pkg/safeguards/tests/not-yaml/readme.md") fileYaml, _ := filepath.Abs("../pkg/safeguards/tests/all/success/all-success-manifest-1.yaml") - assert.False(t, isYAML(fileNotYaml)) - assert.True(t, isYAML(fileYaml)) + assert.False(t, safeguards.IsYAML(fileNotYaml)) + assert.True(t, safeguards.IsYAML(fileYaml)) - manifestFiles, err := getManifestFiles(dirNotYaml) + manifestFiles, err := safeguards.GetManifestFiles(dirNotYaml) assert.Nil(t, manifestFiles) assert.NotNil(t, err) - manifestFiles, err = getManifestFiles(dirYaml) + manifestFiles, err = safeguards.GetManifestFiles(dirYaml) assert.NotNil(t, manifestFiles) assert.Nil(t, err) } @@ -62,35 +62,35 @@ func TestRunValidate(t *testing.T) { var manifestFiles []safeguards.ManifestFile // Scenario 1: empty manifest path should error - _, err := safeguards.GetManifestViolations(ctx, manifestFilesEmpty) + _, err := safeguards.GetManifestResults(ctx, manifestFilesEmpty) assert.NotNil(t, err) // Scenario 2a: manifest path leads to a directory of manifestFiles - expect success - manifestFiles, err = getManifestFiles(manifestPathDirectorySuccess) + manifestFiles, err = safeguards.GetManifestFiles(manifestPathDirectorySuccess) assert.Nil(t, err) - v, err := safeguards.GetManifestViolations(ctx, manifestFiles) + v, err := safeguards.GetManifestResults(ctx, manifestFiles) assert.Nil(t, err) numViolations := countTestViolations(v) assert.Equal(t, numViolations, 0) // Scenario 2b: manifest path leads to a directory of manifestFiles - expect failure - manifestFiles, err = getManifestFiles(manifestPathDirectoryError) + manifestFiles, err = safeguards.GetManifestFiles(manifestPathDirectoryError) assert.Nil(t, err) - v, err = safeguards.GetManifestViolations(ctx, manifestFiles) + v, err = safeguards.GetManifestResults(ctx, manifestFiles) assert.Nil(t, err) numViolations = countTestViolations(v) assert.Greater(t, numViolations, 0) // Scenario 3a: manifest path leads to one manifest file - expect success - manifestFiles, err = getManifestFiles(manifestPathFileSuccess) - v, err = safeguards.GetManifestViolations(ctx, manifestFiles) + manifestFiles, err = safeguards.GetManifestFiles(manifestPathFileSuccess) + v, err = safeguards.GetManifestResults(ctx, manifestFiles) assert.Nil(t, err) numViolations = countTestViolations(v) assert.Equal(t, numViolations, 0) // Scenario 3b: manifest path leads to one manifest file - expect failure - manifestFiles, err = getManifestFiles(manifestPathFileError) - v, err = safeguards.GetManifestViolations(ctx, manifestFiles) + manifestFiles, err = safeguards.GetManifestFiles(manifestPathFileError) + v, err = safeguards.GetManifestResults(ctx, manifestFiles) assert.Nil(t, err) numViolations = countTestViolations(v) assert.Greater(t, numViolations, 0) diff --git a/cmd/validate_test_helpers.go b/cmd/validate_test_helpers.go index 7c68562f..4fd638b1 100644 --- a/cmd/validate_test_helpers.go +++ b/cmd/validate_test_helpers.go @@ -2,10 +2,10 @@ package cmd import "github.com/Azure/draft/pkg/safeguards" -func countTestViolations(violations []safeguards.ManifestViolation) int { +func countTestViolations(results []safeguards.ManifestResult) int { numViolations := 0 - for _, v := range violations { - numViolations += len(v.ObjectViolations) + for _, r := range results { + numViolations += len(r.ObjectViolations) } return numViolations diff --git a/go.mod b/go.mod index 97ed76cf..4b1dfb3c 100644 --- a/go.mod +++ b/go.mod @@ -1,10 +1,13 @@ module github.com/Azure/draft -go 1.22 +go 1.22.0 require ( + github.com/Azure/azure-sdk-for-go/sdk/azcore v1.11.1 + github.com/Azure/azure-sdk-for-go/sdk/azidentity v1.5.2 + github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/subscription/armsubscription v1.2.0 github.com/briandowns/spinner v1.23.0 - github.com/cenkalti/backoff/v4 v4.2.1 + github.com/cenkalti/backoff/v4 v4.3.0 github.com/fatih/color v1.16.0 github.com/ghodss/yaml v1.0.0 github.com/hashicorp/go-version v1.6.0 @@ -12,26 +15,30 @@ require ( github.com/ivanpirog/coloredcobra v1.0.1 github.com/jbrukh/bayesian v0.0.0-20231117143245-13ae6f916c7a github.com/manifoldco/promptui v0.9.0 - github.com/open-policy-agent/frameworks/constraint v0.0.0-20240206175643-9de2e6ab07f8 - github.com/open-policy-agent/gatekeeper/v3 v3.15.0 + github.com/microsoftgraph/msgraph-sdk-go v1.38.0 + github.com/open-policy-agent/frameworks/constraint v0.0.0-20240411024313-c2efb00269a8 + github.com/open-policy-agent/gatekeeper/v3 v3.15.1 github.com/sirupsen/logrus v1.9.3 github.com/spf13/cobra v1.8.0 - github.com/stretchr/testify v1.8.4 - golang.org/x/exp v0.0.0-20240205201215-2c58cdc269a3 - golang.org/x/mod v0.14.0 + github.com/stretchr/testify v1.9.0 + go.uber.org/mock v0.4.0 + golang.org/x/exp v0.0.0-20240416160154-fe59bbe5cc7f + golang.org/x/mod v0.17.0 gopkg.in/yaml.v3 v3.0.1 - helm.sh/helm/v3 v3.14.0 - k8s.io/api v0.29.1 - k8s.io/apimachinery v0.29.1 - k8s.io/cli-runtime v0.29.1 - k8s.io/client-go v0.29.1 - sigs.k8s.io/kustomize/api v0.16.0 - sigs.k8s.io/kustomize/kyaml v0.16.0 + helm.sh/helm/v3 v3.14.4 + k8s.io/api v0.29.3 + k8s.io/apimachinery v0.29.3 + k8s.io/cli-runtime v0.29.0 + k8s.io/client-go v0.29.3 + sigs.k8s.io/kustomize/api v0.17.1 + sigs.k8s.io/kustomize/kyaml v0.17.0 ) require ( github.com/AdaLogics/go-fuzz-headers v0.0.0-20230811130428-ced1acdcaa24 // indirect + github.com/Azure/azure-sdk-for-go/sdk/internal v1.5.2 // indirect github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161 // indirect + github.com/AzureAD/microsoft-authentication-library-for-go v1.2.2 // indirect github.com/Masterminds/semver/v3 v3.2.1 // indirect github.com/Microsoft/hcsshim v0.11.4 // indirect github.com/OneOfOne/xxhash v1.2.8 // indirect @@ -42,9 +49,10 @@ require ( github.com/blang/semver/v4 v4.0.0 // indirect github.com/cespare/xxhash/v2 v2.2.0 // indirect github.com/chzyer/readline v1.5.1 // indirect - github.com/containerd/containerd v1.7.13 // indirect + github.com/cjlapao/common-go v0.0.39 // indirect + github.com/containerd/containerd v1.7.14 // indirect github.com/containerd/log v0.1.0 // indirect - github.com/davecgh/go-spew v1.1.1 // indirect + github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect github.com/distribution/reference v0.5.0 // indirect github.com/docker/cli v25.0.3+incompatible // indirect github.com/docker/distribution v2.8.3+incompatible // indirect @@ -66,8 +74,9 @@ require ( github.com/go-openapi/swag v0.22.9 // indirect github.com/gobwas/glob v0.2.3 // indirect github.com/gogo/protobuf v1.3.2 // indirect - github.com/golang/glog v1.2.0 // indirect - github.com/golang/protobuf v1.5.3 // indirect + github.com/golang-jwt/jwt/v5 v5.2.1 // indirect + github.com/golang/glog v1.2.1 // indirect + github.com/golang/protobuf v1.5.4 // indirect github.com/google/cel-go v0.19.0 // indirect github.com/google/gnostic-models v0.6.8 // indirect github.com/google/go-cmp v0.6.0 // indirect @@ -83,27 +92,38 @@ require ( github.com/josharian/intern v1.0.0 // indirect github.com/json-iterator/go v1.1.12 // indirect github.com/klauspost/compress v1.17.6 // indirect + github.com/kylelemons/godebug v1.1.0 // indirect github.com/liggitt/tabwriter v0.0.0-20181228230101-89fcab3d43de // indirect github.com/mailru/easyjson v0.7.7 // indirect github.com/mattn/go-colorable v0.1.13 // indirect github.com/mattn/go-isatty v0.0.20 // indirect + github.com/microsoft/kiota-abstractions-go v1.6.0 // indirect + github.com/microsoft/kiota-authentication-azure-go v1.0.2 // indirect + github.com/microsoft/kiota-http-go v1.3.1 // indirect + github.com/microsoft/kiota-serialization-form-go v1.0.0 // indirect + github.com/microsoft/kiota-serialization-json-go v1.0.7 // indirect + github.com/microsoft/kiota-serialization-multipart-go v1.0.0 // indirect + github.com/microsoft/kiota-serialization-text-go v1.0.0 // indirect + github.com/microsoftgraph/msgraph-sdk-go-core v1.1.0 // indirect github.com/moby/locker v1.0.1 // indirect github.com/moby/term v0.5.0 // indirect github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect github.com/modern-go/reflect2 v1.0.2 // indirect github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00 // indirect github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect - github.com/open-policy-agent/opa v0.61.0 // indirect + github.com/open-policy-agent/opa v0.63.0 // indirect github.com/opencontainers/go-digest v1.0.0 // indirect github.com/opencontainers/image-spec v1.1.0-rc6 // indirect + github.com/pkg/browser v0.0.0-20240102092130-5ac0b6a4141c // indirect github.com/pkg/errors v0.9.1 // indirect - github.com/pmezard/go-difflib v1.0.0 // indirect - github.com/prometheus/client_golang v1.18.0 // indirect + github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect + github.com/prometheus/client_golang v1.19.0 // indirect github.com/prometheus/client_model v0.5.0 // indirect - github.com/prometheus/common v0.46.0 // indirect + github.com/prometheus/common v0.48.0 // indirect github.com/prometheus/procfs v0.12.0 // indirect github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 // indirect github.com/spf13/pflag v1.0.5 // indirect + github.com/std-uritemplate/std-uritemplate/go v0.0.55 // indirect github.com/stoewer/go-strcase v1.3.0 // indirect github.com/tchap/go-patricia/v2 v2.3.1 // indirect github.com/xeipuuv/gojsonpointer v0.0.0-20190905194746-02993c407bfb // indirect @@ -113,39 +133,40 @@ require ( github.com/yashtewari/glob-intersection v0.2.0 // indirect go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.47.0 // indirect go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.48.0 // indirect - go.opentelemetry.io/otel v1.23.0 // indirect + go.opentelemetry.io/otel v1.24.0 // indirect go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.23.0 // indirect go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.23.0 // indirect - go.opentelemetry.io/otel/metric v1.23.0 // indirect + go.opentelemetry.io/otel/metric v1.24.0 // indirect go.opentelemetry.io/otel/sdk v1.23.0 // indirect - go.opentelemetry.io/otel/trace v1.23.0 // indirect + go.opentelemetry.io/otel/trace v1.24.0 // indirect go.opentelemetry.io/proto/otlp v1.1.0 // indirect go.starlark.net v0.0.0-20240123142251-f86470692795 // indirect - golang.org/x/net v0.20.0 // indirect + golang.org/x/crypto v0.22.0 // indirect + golang.org/x/net v0.24.0 // indirect golang.org/x/oauth2 v0.16.0 // indirect - golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.17.0 // indirect - golang.org/x/term v0.17.0 // indirect + golang.org/x/sync v0.7.0 // indirect + golang.org/x/sys v0.19.0 // indirect + golang.org/x/term v0.19.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/time v0.5.0 // indirect gomodules.xyz/jsonpatch/v2 v2.4.0 // indirect google.golang.org/appengine v1.6.8 // indirect google.golang.org/genproto/googleapis/api v0.0.0-20240205150955-31a09d347014 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20240205150955-31a09d347014 // indirect - google.golang.org/grpc v1.61.0 // indirect - google.golang.org/protobuf v1.32.0 // indirect - gopkg.in/evanphx/json-patch.v5 v5.9.0 // indirect + google.golang.org/grpc v1.62.1 // indirect + google.golang.org/protobuf v1.33.0 // indirect + gopkg.in/evanphx/json-patch.v4 v4.12.0 // indirect gopkg.in/inf.v0 v0.9.1 // indirect gopkg.in/yaml.v2 v2.4.0 // indirect - k8s.io/apiextensions-apiserver v0.29.1 // indirect - k8s.io/apiserver v0.29.1 // indirect - k8s.io/component-base v0.29.1 // indirect + k8s.io/apiextensions-apiserver v0.29.3 // indirect + k8s.io/apiserver v0.29.3 // indirect + k8s.io/component-base v0.29.3 // indirect k8s.io/klog/v2 v2.120.1 // indirect - k8s.io/kube-openapi v0.0.0-20240126223410-2919ad4fcfec // indirect + k8s.io/kube-openapi v0.0.0-20240228011516-70dd3763d340 // indirect k8s.io/utils v0.0.0-20240102154912-e7106e64919e // indirect oras.land/oras-go v1.2.5 // indirect sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.29.0 // indirect - sigs.k8s.io/controller-runtime v0.17.0 // indirect + sigs.k8s.io/controller-runtime v0.17.3 // indirect sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect sigs.k8s.io/structured-merge-diff/v4 v4.4.1 // indirect sigs.k8s.io/yaml v1.4.0 // indirect diff --git a/go.sum b/go.sum index 78f90d8b..b5197cd7 100644 --- a/go.sum +++ b/go.sum @@ -6,40 +6,33 @@ cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxK cloud.google.com/go v0.45.1/go.mod h1:RpBamKRgapWJb87xiFSdk4g1CME7QZg3uwTez+TSTjc= cloud.google.com/go v0.46.3/go.mod h1:a6bKKbmY7er1mI7TEI4lsAkts/mkhTSZK8w33B4RAg0= cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o= -cloud.google.com/go/compute v1.23.3/go.mod h1:VCgBUoMnIVIR0CscqQiPJLAG25E3ZRZMzcFZeQ+h8CI= -cloud.google.com/go/compute/metadata v0.2.3/go.mod h1:VAV5nSsACxMJvgaAuX6Pk2AawlZn8kiOGuCv6gTkwuA= cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE= cloud.google.com/go/firestore v1.1.0/go.mod h1:ulACoGHTpvq5r8rxGJ4ddJZBZqakUQqClKRT5SZwBmk= -cloud.google.com/go/monitoring v1.16.1/go.mod h1:6HsxddR+3y9j+o/cMJH6q/KJ/CBTvM/38L/1m7bTRJ4= cloud.google.com/go/pubsub v1.0.1/go.mod h1:R0Gpsv3s54REJCy4fxDixWD93lHJMoZTyQ2kNxGRt3I= cloud.google.com/go/storage v1.0.0/go.mod h1:IhtSnM/ZTZV8YYJWCY8RULGVqBDmpoyjwiyrjsg+URw= -cloud.google.com/go/trace v1.10.4/go.mod h1:Nso99EDIK8Mj5/zmB+iGr9dosS/bzWCJ8wGmE6TXNWY= -dario.cat/mergo v1.0.0/go.mod h1:uNxQE+84aUszobStD9th8a29P2fMDhsBdgRYvZOxGmk= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= github.com/AdaLogics/go-fuzz-headers v0.0.0-20230811130428-ced1acdcaa24 h1:bvDV9vkmnHYOMsOr4WLk+Vo07yKIzd94sVoIqshQ4bU= github.com/AdaLogics/go-fuzz-headers v0.0.0-20230811130428-ced1acdcaa24/go.mod h1:8o94RPi1/7XTJvwPpRSzSUedZrtlirdB3r9Z20bi2f8= -github.com/AdamKorcz/go-118-fuzz-build v0.0.0-20230306123547-8075edf89bb0/go.mod h1:OahwfttHWG6eJ0clwcfBAHoDI6X/LV/15hx/wlMZSrU= +github.com/Azure/azure-sdk-for-go/sdk/azcore v1.11.1 h1:E+OJmp2tPvt1W+amx48v1eqbjDYsgN+RzP4q16yV5eM= +github.com/Azure/azure-sdk-for-go/sdk/azcore v1.11.1/go.mod h1:a6xsAQUZg+VsS3TJ05SRp524Hs4pZ/AeFSr5ENf0Yjo= +github.com/Azure/azure-sdk-for-go/sdk/azidentity v1.5.2 h1:FDif4R1+UUR+00q6wquyX90K7A8dN+R5E8GEadoP7sU= +github.com/Azure/azure-sdk-for-go/sdk/azidentity v1.5.2/go.mod h1:aiYBYui4BJ/BJCAIKs92XiPyQfTaBWqvHujDwKb6CBU= +github.com/Azure/azure-sdk-for-go/sdk/internal v1.5.2 h1:LqbJ/WzJUwBf8UiaSzgX7aMclParm9/5Vgp+TY51uBQ= +github.com/Azure/azure-sdk-for-go/sdk/internal v1.5.2/go.mod h1:yInRyqWXAuaPrgI7p70+lDDgh3mlBohis29jGMISnmc= +github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/subscription/armsubscription v1.2.0 h1:UrGzkHueDwAWDdjQxC+QaXHd4tVCkISYE9j7fSSXF8k= +github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/subscription/armsubscription v1.2.0/go.mod h1:qskvSQeW+cxEE2bcKYyKimB1/KiQ9xpJ99bcHY0BX6c= github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161 h1:L/gRVlceqvL25UVaW/CKtUDjefjrs0SPonmDGUVOYP0= github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= +github.com/AzureAD/microsoft-authentication-library-for-go v1.2.2 h1:XHOnouVk1mxXfQidrMEnLlPk9UMeRtyBTnEFtxkV0kU= +github.com/AzureAD/microsoft-authentication-library-for-go v1.2.2/go.mod h1:wP83P5OoQ5p6ip3ScPr0BAq0BvuPAvacpEuSzyouqAI= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= -github.com/BurntSushi/toml v1.3.2/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= -github.com/DATA-DOG/go-sqlmock v1.5.0/go.mod h1:f/Ixk793poVmq4qj/V1dPUg2JEAKC73Q5eFN3EC/SaM= -github.com/GoogleCloudPlatform/opentelemetry-operations-go/detectors/gcp v1.20.0/go.mod h1:Xx0VKh7GJ4si3rmElbh19Mejxz68ibWg/J30ZOMrqzU= -github.com/GoogleCloudPlatform/opentelemetry-operations-go/exporter/metric v0.44.0/go.mod h1:shFWgjEP9WVKRUJbgyp61kOiFAd0AUPUyy16fgyhJ5Q= -github.com/GoogleCloudPlatform/opentelemetry-operations-go/internal/resourcemapping v0.44.0/go.mod h1:qkFPtMouQjW5ugdHIOthiTbweVHUTqbS0Qsu55KqXks= -github.com/MakeNowJust/heredoc v1.0.0/go.mod h1:mG5amYoWBHf8vpLOuehzbGGw0EHxpZZ6lCpQ4fNJ8LE= -github.com/Masterminds/goutils v1.1.1/go.mod h1:8cTjp+g8YejhMuvIA5y2vz3BpJxksy863GQaJW2MFNU= github.com/Masterminds/semver/v3 v3.2.1 h1:RN9w6+7QoMeJVGyfmbcgs28Br8cvmnucEXnY0rYXWg0= github.com/Masterminds/semver/v3 v3.2.1/go.mod h1:qvl/7zhW3nngYb5+80sSMF+FG2BjYrf8m9wsX0PNOMQ= -github.com/Masterminds/sprig/v3 v3.2.3/go.mod h1:rXcFaZ2zZbLRJv/xSysmlgIM1u11eBaRMhvYXJNkGuM= -github.com/Masterminds/squirrel v1.5.4/go.mod h1:NNaOrjSoIDfDA40n7sr2tPNZRfjzjA400rg+riTZj10= -github.com/Masterminds/vcs v1.13.3/go.mod h1:TiE7xuEjl1N4j016moRd6vezp6e6Lz23gypeXfzXeW8= github.com/Microsoft/go-winio v0.6.1 h1:9/kr64B9VUZrLm5YYwbGtUJnMgqWVOdUAXu6Migciow= github.com/Microsoft/go-winio v0.6.1/go.mod h1:LRdKpFKfdobln8UmuiYcKPot9D2v6svN5+sAH+4kjUM= github.com/Microsoft/hcsshim v0.11.4 h1:68vKo2VN8DE9AdN4tnkWnmdhqdbpUFM8OF3Airm7fz8= github.com/Microsoft/hcsshim v0.11.4/go.mod h1:smjE4dvqPX9Zldna+t5FG3rnoHhaB7QYxPRqGcpAD9w= -github.com/NYTimes/gziphandler v1.1.1/go.mod h1:n/CVRwUEOgIxrgPvAQhUUr9oeUtvrhMomdKFjzJNB0c= github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= github.com/OneOfOne/xxhash v1.2.8 h1:31czK/TI9sNkxIKfaUfGlU47BAxQ0ztGgd9vPyqimf8= github.com/OneOfOne/xxhash v1.2.8/go.mod h1:eZbhyaAYD41SGSSsnmcpxVoRiQ/MPUTjUdIIOT9Um7Q= @@ -47,13 +40,8 @@ github.com/Shopify/logrus-bugsnag v0.0.0-20171204204709-577dee27f20d h1:UrqY+r/O github.com/Shopify/logrus-bugsnag v0.0.0-20171204204709-577dee27f20d/go.mod h1:HI8ITrYtUY+O+ZhtlqUnD8+KwNPOyugEhfP9fdUIaEQ= github.com/agnivade/levenshtein v1.1.1 h1:QY8M92nrzkmr798gCo3kmMyqXFzdQVpxLlGPRBij0P8= github.com/agnivade/levenshtein v1.1.1/go.mod h1:veldBMzWxcCG2ZvUTKD2kJNRdCk5hVbJomOvKkmgYbo= -github.com/akavel/rsrc v0.10.2/go.mod h1:uLoCtb9J+EyAqh+26kdrTgmzRBFPGOolLWKpdxkKq+c= -github.com/alecthomas/kingpin/v2 v2.4.0/go.mod h1:0gyi0zQnjuFk8xrkNKamJoyUo382HRL7ATRpFZCw6tE= github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= -github.com/alecthomas/units v0.0.0-20211218093645-b94a6e3cc137/go.mod h1:OMCwj8VM1Kc9e19TLln2VL61YJF0x1XFtfdL4JdbSyE= -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/antlr/antlr4/runtime/Go/antlr/v4 v4.0.0-20230305170008-8188dc5388df h1:7RFfzj4SSt6nnvCPbCqijJi1nWCd+TqAT3bYCStRC18= github.com/antlr/antlr4/runtime/Go/antlr/v4 v4.0.0-20230305170008-8188dc5388df/go.mod h1:pSwJ0fSY5KhvocuWSx4fz3BA8OrA1bQn+K1Eli3BRwM= github.com/arbovm/levenshtein v0.0.0-20160628152529-48b4e1c0c4d0 h1:jfIu9sQUG6Ig+0+Ap1h4unLjW6YQJpKZVmUzxsD4E/Q= @@ -61,10 +49,8 @@ github.com/arbovm/levenshtein v0.0.0-20160628152529-48b4e1c0c4d0/go.mod h1:t2tdK github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e/go.mod h1:3U/XgcO3hCbHZ8TKRvWD2dDTCfh9M9ya+I9JpbB7O8o= github.com/armon/go-metrics v0.0.0-20180917152333-f0300d1749da/go.mod h1:Q73ZrmVTwzkszR9V5SSuryQ31EELlFMUz1kKyl939pY= github.com/armon/go-radix v0.0.0-20180808171621-7fddfc383310/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8= -github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs= github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2 h1:DklsrG3dyBCFEj5IhUbnKptjxatkF07cF2ak3yi77so= github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2/go.mod h1:WaHUgvxTVq04UNunO+XhnAqY/wQc+bxr74GqbsZ/Jqw= -github.com/aws/aws-sdk-go v1.47.9/go.mod h1:LF8svs817+Nz+DmiMQKTO3ubZ/6IaTpq3TjupRn3Eqk= github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q= github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= @@ -85,14 +71,12 @@ github.com/bugsnag/panicwrap v0.0.0-20151223152923-e2c28503fcd0 h1:nvj0OLI3YqYXe github.com/bugsnag/panicwrap v0.0.0-20151223152923-e2c28503fcd0/go.mod h1:D/8v3kj0zr8ZAKg1AQ6crr+5VwKN5eIywRkfhyM/+dE= github.com/bytecodealliance/wasmtime-go/v3 v3.0.2 h1:3uZCA/BLTIu+DqCfguByNMJa2HVHpXvjfy0Dy7g6fuA= github.com/bytecodealliance/wasmtime-go/v3 v3.0.2/go.mod h1:RnUjnIXxEJcL6BgCvNyzCCRzZcxCgsZCi+RNlvYor5Q= -github.com/cenkalti/backoff/v4 v4.2.1 h1:y4OZtCnogmCPw98Zjyt5a6+QwPLGkiQsYW5oUqylYbM= -github.com/cenkalti/backoff/v4 v4.2.1/go.mod h1:Y3VNntkOUPxTVeUxJ/G5vcM//AlwfmyYozVcomhLiZE= -github.com/census-instrumentation/opencensus-proto v0.4.1/go.mod h1:4T9NM4+4Vw91VeyqjLS6ao50K5bOcLKN6Q42XnYaRYw= +github.com/cenkalti/backoff/v4 v4.3.0 h1:MyRJ/UdXutAwSAT+s3wNd7MfTIcy71VQueUuFK343L8= +github.com/cenkalti/backoff/v4 v4.3.0/go.mod h1:Y3VNntkOUPxTVeUxJ/G5vcM//AlwfmyYozVcomhLiZE= github.com/cespare/xxhash v1.1.0 h1:a6HrQnmkObjyL+Gs60czilIUGqrzKutQD6XZog3p+ko= github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc= github.com/cespare/xxhash/v2 v2.2.0 h1:DC2CZ1Ep5Y4k3ZQ899DldepgrayRUGE6BBZ/cd9Cj44= github.com/cespare/xxhash/v2 v2.2.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= -github.com/chai2010/gettext-go v1.0.2/go.mod h1:y+wnP2cHYaVj19NZhYKAwEMH2CI1gNHeQQ+5AjwawxA= github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= github.com/chzyer/logex v1.2.1 h1:XHDu3E6q+gdHgsdTPH6ImJMIp436vR6MPtH8gP05QzM= github.com/chzyer/logex v1.2.1/go.mod h1:JLbx6lG2kDbNRFnfkgvh4eRJRPX1QCoOIWomwysCBrQ= @@ -102,39 +86,19 @@ github.com/chzyer/readline v1.5.1/go.mod h1:Eh+b79XXUwfKfcPLepksvw2tcLE/Ct21YObk github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= github.com/chzyer/test v1.0.0 h1:p3BQDXSxOhOG0P9z6/hGnII4LGiEPOYBhs8asl/fC04= github.com/chzyer/test v1.0.0/go.mod h1:2JlltgoNkt4TW/z9V/IzDdFaMTM2JPIi26O1pF38GC8= -github.com/cilium/ebpf v0.9.1/go.mod h1:+OhNOIXx/Fnu1IE8bJz2dzOA+VSfyTfdNUVdlQnxUFY= +github.com/cjlapao/common-go v0.0.39 h1:bAAUrj2B9v0kMzbAOhzjSmiyDy+rd56r2sy7oEiQLlA= +github.com/cjlapao/common-go v0.0.39/go.mod h1:M3dzazLjTjEtZJbbxoA5ZDiGCiHmpwqW9l4UWaddwOA= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= -github.com/cncf/udpa/go v0.0.0-20220112060539-c52dc94e7fbe/go.mod h1:6pvJx4me5XPnfI9Z40ddWsdw2W/uZgQLFXToKeRcDiI= -github.com/cncf/xds/go v0.0.0-20231109132714-523115ebc101/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= -github.com/common-nighthawk/go-figure v0.0.0-20210622060536-734e95fb86be/go.mod h1:mk5IQ+Y0ZeO87b858TlA645sVcEcbiX6YqP98kt+7+w= -github.com/containerd/aufs v1.0.0/go.mod h1:kL5kd6KM5TzQjR79jljyi4olc1Vrx6XBlcyj3gNv2PU= -github.com/containerd/btrfs/v2 v2.0.0/go.mod h1:swkD/7j9HApWpzl8OHfrHNxppPd9l44DFZdF94BUj9k= github.com/containerd/cgroups v1.1.0 h1:v8rEWFl6EoqHB+swVNjVoCJE8o3jX7e8nqBGPLaDFBM= github.com/containerd/cgroups v1.1.0/go.mod h1:6ppBcbh/NOOUU+dMKrykgaBnK9lCIBxHqJDGwsa1mIw= -github.com/containerd/cgroups/v3 v3.0.2/go.mod h1:JUgITrzdFqp42uI2ryGA+ge0ap/nxzYgkGmIcetmErE= -github.com/containerd/console v1.0.3/go.mod h1:7LqA/THxQ86k76b8c/EMSiaJ3h1eZkMkXar0TQ1gf3U= -github.com/containerd/containerd v1.7.13 h1:wPYKIeGMN8vaggSKuV1X0wZulpMz4CrgEsZdaCyB6Is= -github.com/containerd/containerd v1.7.13/go.mod h1:zT3up6yTRfEUa6+GsITYIJNgSVL9NQ4x4h1RPzk0Wu4= +github.com/containerd/containerd v1.7.14 h1:H/XLzbnGuenZEGK+v0RkwTdv2u1QFAruMe5N0GNPJwA= +github.com/containerd/containerd v1.7.14/go.mod h1:YMC9Qt5yzNqXx/fO4j/5yYVIHXSRrlB3H7sxkUTvspg= github.com/containerd/continuity v0.4.2 h1:v3y/4Yz5jwnvqPKJJ+7Wf93fyWoCB3F5EclWG023MDM= github.com/containerd/continuity v0.4.2/go.mod h1:F6PTNCKepoxEaXLQp3wDAjygEnImnZ/7o4JzpodfroQ= -github.com/containerd/fifo v1.1.0/go.mod h1:bmC4NWMbXlt2EZ0Hc7Fx7QzTFxgPID13eH0Qu+MAb2o= -github.com/containerd/go-cni v1.1.9/go.mod h1:XYrZJ1d5W6E2VOvjffL3IZq0Dz6bsVlERHbekNK90PM= -github.com/containerd/go-runc v1.0.0/go.mod h1:cNU0ZbCgCQVZK4lgG3P+9tn9/PaJNmoDXPpoJhDR+Ok= -github.com/containerd/imgcrypt v1.1.7/go.mod h1:FD8gqIcX5aTotCtOmjeCsi3A1dHmTZpnMISGKSczt4k= github.com/containerd/log v0.1.0 h1:TCJt7ioM2cr/tfR8GPbGf9/VRAX8D2B4PjzCpfX540I= github.com/containerd/log v0.1.0/go.mod h1:VRRf09a7mHDIRezVKTRCrOq78v577GXq3bSa3EhrzVo= -github.com/containerd/nri v0.4.0/go.mod h1:Zw9q2lP16sdg0zYybemZ9yTDy8g7fPCIB3KXOGlggXI= -github.com/containerd/stargz-snapshotter/estargz v0.14.3/go.mod h1:KY//uOCIkSuNAHhJogcZtrNHdKrA99/FCCRjE3HD36o= -github.com/containerd/ttrpc v1.2.2/go.mod h1:sIT6l32Ph/H9cvnJsfXM5drIVzTr5A2flTf1G5tYZak= -github.com/containerd/typeurl v1.0.2/go.mod h1:9trJWW2sRlGub4wZJRTW83VtbOLS6hwcDZXTn6oPz9s= -github.com/containerd/typeurl/v2 v2.1.1/go.mod h1:IDp2JFvbwZ31H8dQbEIY7sDl2L3o3HZj1hsSQlywkQ0= -github.com/containerd/zfs v1.1.0/go.mod h1:oZF9wBnrnQjpWLaPKEinrx3TQ9a+W/RJO7Zb41d8YLE= -github.com/containernetworking/cni v1.1.2/go.mod h1:sDpYKmGVENF3s6uvMvGgldDWeG8dMxakj/u+i9ht9vw= -github.com/containernetworking/plugins v1.2.0/go.mod h1:/VjX4uHecW5vVimFa1wkG4s+r/s9qIfPdqlLF4TW8c4= -github.com/containers/ocicrypt v1.1.6/go.mod h1:WgjxPWdTJMqYMjf3M6cuIFFA1/MpyyhIM99YInA+Rvc= github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk= github.com/coreos/etcd v3.3.13+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= -github.com/coreos/go-oidc v2.2.1+incompatible/go.mod h1:CgnwVTmzoESiwO9qyAFEMiHoZ1nMCKZlZ9V6mm3/LKc= github.com/coreos/go-semver v0.3.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= github.com/coreos/go-semver v0.3.1 h1:yi21YpKnrx1gt5R+la8n5WgS0kCrsPp33dmEyHReZr4= github.com/coreos/go-semver v0.3.1/go.mod h1:irMmmIw/7yzSRPWryHsK7EYSg09caPQL03VsM8rvUec= @@ -147,19 +111,15 @@ github.com/cpuguy83/go-md2man/v2 v2.0.1/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46t github.com/cpuguy83/go-md2man/v2 v2.0.3/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/creack/pty v1.1.18 h1:n56/Zwd5o6whRC5PMGretI4IdRLlmBXYNjScPaBgsbY= github.com/creack/pty v1.1.18/go.mod h1:MOBLtS5ELjhRRrroQr9kyvTxUAFNvYEK993ew/Vr4O4= -github.com/cyphar/filepath-securejoin v0.2.4/go.mod h1:aPGpWjXOXUn2NCNjFvBE6aRxGGx79pTxQpKOJNYHHl4= -github.com/danieljoos/wincred v1.2.1/go.mod h1:uGaFL9fDn3OLTvzCGulzE+SzjEe5NGlh5FdCcyfPwps= -github.com/dapr/go-sdk v1.8.0/go.mod h1:MBcTKXg8PmBc8A968tVWQg1Xt+DZtmeVR6zVVVGcmeA= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.0-20210816181553-5444fa50b93d/go.mod h1:tmAIfUFEirG/Y8jhZ9M+h36obRZAk/1fcSpXwAVlfqE= +github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc h1:U9qPSI2PIWSS1VwoXQT9A3Wy9MM3WgvqSxFWenqJduM= +github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/dgraph-io/badger/v3 v3.2103.5 h1:ylPa6qzbjYRQMU6jokoj4wzcaweHylt//CH0AKt0akg= github.com/dgraph-io/badger/v3 v3.2103.5/go.mod h1:4MPiseMeDQ3FNCYwRbbcBOGJLf5jsE0PPFzRiKjtcdw= github.com/dgraph-io/ristretto v0.1.1 h1:6CWw5tJNgpegArSHpNHJKldNeq03FQCwYvfMVWajOK8= github.com/dgraph-io/ristretto v0.1.1/go.mod h1:S1GPSBCYCIhmVNfcth17y2zZtQT6wzkzgwUve0VDWWA= github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ= -github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no= github.com/dgryski/trifles v0.0.0-20200323201526-dd97f9abfb48 h1:fRzb/w+pyskVMQ+UbP35JkH8yB7MYb4q/qhBarqZE6g= github.com/dgryski/trifles v0.0.0-20200323201526-dd97f9abfb48/go.mod h1:if7Fbed8SFyPtHLHbg49SI7NAdJiC5WIA09pe59rfAA= @@ -167,6 +127,8 @@ github.com/distribution/distribution/v3 v3.0.0-20221208165359-362910506bc2 h1:aB github.com/distribution/distribution/v3 v3.0.0-20221208165359-362910506bc2/go.mod h1:WHNsWjnIn2V1LYOrME7e8KxSeKunYHsxEm4am0BUtcI= github.com/distribution/reference v0.5.0 h1:/FUIFXtfc/x2gpa5/VGfiGLuOIdYa1t65IKK2OFGvA0= github.com/distribution/reference v0.5.0/go.mod h1:BbU0aIcezP1/5jX/8MP0YiH4SdvB5Y4f/wlDRiLyi3E= +github.com/dnaeon/go-vcr v1.2.0 h1:zHCHvJYTMh1N7xnV7zf1m1GPBF9Ad0Jk/whtQ1663qI= +github.com/dnaeon/go-vcr v1.2.0/go.mod h1:R4UdLID7HZT3taECzJs4YgbbH6PIGXB6W/sc5OLb6RQ= github.com/docker/cli v25.0.3+incompatible h1:KLeNs7zws74oFuVhgZQ5ONGZiXUUdgsdy6/EsX/6284= github.com/docker/cli v25.0.3+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= github.com/docker/distribution v2.8.3+incompatible h1:AtKxIZ36LoNK51+Z6RpzLpddBirtxJnzDrHLEKxTAYk= @@ -181,21 +143,16 @@ github.com/docker/go-events v0.0.0-20190806004212-e31b211e4f1c h1:+pKlWGMw7gf6bQ github.com/docker/go-events v0.0.0-20190806004212-e31b211e4f1c/go.mod h1:Uw6UezgYA44ePAFQYUehOuCzmy5zmg/+nl2ZfMWGkpA= github.com/docker/go-metrics v0.0.1 h1:AgB/0SvBxihN0X8OR4SjsblXkbMvalQ8cjmtKQ2rQV8= github.com/docker/go-metrics v0.0.1/go.mod h1:cG1hvH2utMXtqgqqYE9plW6lDxS3/5ayHzueweSI3Vw= -github.com/docker/go-units v0.5.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= github.com/docker/libtrust v0.0.0-20150114040149-fa567046d9b1 h1:ZClxb8laGDf5arXfYcAtECDFgAgHklGI8CxgjHnXKJ4= github.com/docker/libtrust v0.0.0-20150114040149-fa567046d9b1/go.mod h1:cyGadeNEkKy96OOhEzfZl+yxihPEzKnqJwvfuSUqbZE= -github.com/dominikbraun/graph v0.16.2/go.mod h1:yOjYyogZLY1LSG9E33JWZJiq5k83Qy2C6POAuiViluc= github.com/dustin/go-humanize v1.0.1 h1:GzkhY7T5VNhEkwH0PVJgjz+fX1rhBrR7pRT3mDkpeCY= github.com/dustin/go-humanize v1.0.1/go.mod h1:Mu1zIs6XwVuF/gI1OepvI0qD18qycQx+mFykh5fBlto= github.com/emicklei/go-restful/v3 v3.11.2 h1:1onLa9DcsMYO9P+CXaL0dStDqQ2EHHXLiz+BtnqkLAU= github.com/emicklei/go-restful/v3 v3.11.2/go.mod h1:6n3XBCmQQb25CM2LCACGz8ukIrRry+4bhvbpWn3mrbc= -github.com/envoyproxy/go-control-plane v0.11.1/go.mod h1:uhMcXKCQMEJHiAb0w+YGefQLaTEw+YhGluxZkrTmD0g= -github.com/envoyproxy/protoc-gen-validate v1.0.2/go.mod h1:GpiZQP3dDbg4JouG/NNS7QWXpgx6x8QiMKdmN72jogE= github.com/evanphx/json-patch v5.9.0+incompatible h1:fBXyNpNMuTTDdquAq/uisOr2lShz4oaXpDTX2bLe7ls= github.com/evanphx/json-patch v5.9.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk= github.com/evanphx/json-patch/v5 v5.9.0 h1:kcBlZQbplgElYIlo/n1hJbls2z/1awpXxpRi0/FOJfg= github.com/evanphx/json-patch/v5 v5.9.0/go.mod h1:VNkHZ/282BpEyt/tObQO8s5CMPmYYq14uClGH4abBuQ= -github.com/exponent-io/jsonpath v0.0.0-20151013193312-d6023ce2651d/go.mod h1:ZZMPRZwes7CROmyNKgQzC3XPs6L/G2EJLHddWejkmf4= github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= github.com/fatih/color v1.10.0/go.mod h1:ELkj/draVOlAH/xkhN6mQ50Qd0MPOk5AAr3maGEBuJM= github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk= @@ -205,27 +162,21 @@ github.com/felixge/httpsnoop v1.0.4 h1:NFTV2Zj1bL4mc9sqWACXbQFVBBg2W3GPvqp8/ESS2 github.com/felixge/httpsnoop v1.0.4/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= github.com/fortytw2/leaktest v1.3.0 h1:u8491cBMTQ8ft8aeV+adlcytMZylmA5nnwwkRZjI8vw= github.com/fortytw2/leaktest v1.3.0/go.mod h1:jDsjWgpAGjm2CA7WthBh/CdZYEPF31XHquHwclZch5g= -github.com/foxcpp/go-mockdns v1.0.0 h1:7jBqxd3WDWwi/6WhDvacvH1XsN3rOLXyHM1uhvIx6FI= -github.com/foxcpp/go-mockdns v1.0.0/go.mod h1:lgRN6+KxQBawyIghpnl5CezHFGS9VLzvtVlwxvzXTQ4= +github.com/foxcpp/go-mockdns v1.1.0 h1:jI0rD8M0wuYAxL7r/ynTrCQQq0BVqfB99Vgk7DlmewI= +github.com/foxcpp/go-mockdns v1.1.0/go.mod h1:IhLeSFGed3mJIAXPH2aiRQB+kqz7oqu8ld2qVbOu7Wk= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/fsnotify/fsnotify v1.7.0 h1:8JEhPFa5W2WU7YfeZzPNqzMP6Lwt7L2715Ggo0nosvA= github.com/fsnotify/fsnotify v1.7.0/go.mod h1:40Bi/Hjc2AVfZrqy+aj+yEI+/bRxZnMJyTJwOpGvigM= -github.com/fvbommel/sortorder v1.1.0/go.mod h1:uk88iVf1ovNn1iLfgUVU2F9o5eO30ui720w+kxuqRs0= -github.com/fxamacker/cbor/v2 v2.4.0/go.mod h1:TA1xS00nchWmaBnEIxPSE5oHLuJBAVvqrtAnWBwBCVo= github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= -github.com/go-chi/chi/v5 v5.0.8/go.mod h1:DslCQbL2OYiznFReuXYUmQ2hGd1aDpCnlMNITLSKoi8= github.com/go-errors/errors v1.5.1 h1:ZwEMSLRCapFLflTpT7NKaAc7ukJ8ZPEjzlxt8rPN8bk= github.com/go-errors/errors v1.5.1/go.mod h1:sIVyrIiJhuEF+Pj9Ebtd6P/rEYROXFi3BopGUQ5a5Og= github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= -github.com/go-gorp/gorp/v3 v3.1.0/go.mod h1:dLEjIyyRNiXvNZ8PSmzpt1GsWAUK8kjVhEpjH8TixEw= github.com/go-ini/ini v1.67.0 h1:z6ZrTEZqSWOTyH2FlglNbNgARyHG8oLW9gMELqKr06A= github.com/go-ini/ini v1.67.0/go.mod h1:ByCAeIL28uOIIG0E3PJtZPDL8WnHpFKFOtgjp+3Ies8= github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= -github.com/go-kit/log v0.2.1/go.mod h1:NwTd00d/i8cPZ3xOwwiv2PO5MOcx78fFErGNcVmBjv0= github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE= github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk= -github.com/go-logfmt/logfmt v0.5.1/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= github.com/go-logr/logr v1.4.1 h1:pKouT5E8xu9zeFC39JXRDukb6JFQPXM5p5I91188VAQ= github.com/go-logr/logr v1.4.1/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= @@ -244,38 +195,34 @@ github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 h1:tfuBGBXKqDEe github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572/go.mod h1:9Pwr4B2jHnOSGXyyzV8ROjYa2ojvAY6HCGYYfMoC3Ls= github.com/gobwas/glob v0.2.3 h1:A4xDbljILXROh+kObIiy5kIaPYD8e96x1tgBhUI5J+Y= github.com/gobwas/glob v0.2.3/go.mod h1:d3Ez4x06l9bZtSvzIay5+Yzi0fmZzPgnTbPcKjJAkT8= -github.com/goccy/go-json v0.9.7/go.mod h1:6MelG93GURQebXPDq3khkgXZkazVtN9CRI+MGFi0w8I= -github.com/godbus/dbus/v5 v5.1.0/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= -github.com/gofrs/flock v0.8.1/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= github.com/gogo/protobuf v1.2.1/go.mod h1:hp+jE20tsWTFYpLwKvXlhS1hjn+gTNwPg2I6zVXpSg4= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= -github.com/golang-jwt/jwt/v4 v4.5.0/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= +github.com/golang-jwt/jwt/v5 v5.2.1 h1:OuVbFODueb089Lh128TAcimifWaLhJwVflnrgM17wHk= +github.com/golang-jwt/jwt/v5 v5.2.1/go.mod h1:pqrtFR0X4osieyHYxtmOUWsAWrfe1Q5UVIyoH402zdk= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= -github.com/golang/glog v1.2.0 h1:uCdmnmatrKCgMBlM4rMuJZWOkPDqdbZPnrMXDY4gI68= -github.com/golang/glog v1.2.0/go.mod h1:6AhwSGph0fcJtXVM/PEHPqZlFeoLxhs7/t5UDAwmO+w= +github.com/golang/glog v1.2.1 h1:OptwRhECazUx5ix5TTWC3EZhsZEHWcYWY4FQHTIubm4= +github.com/golang/glog v1.2.1/go.mod h1:6AhwSGph0fcJtXVM/PEHPqZlFeoLxhs7/t5UDAwmO+w= github.com/golang/groupcache v0.0.0-20190129154638-5b532d6fd5ef/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da h1:oI5xCqsCo564l8iNU+DwB5epxmsaqB+rhGL0m5jtYqE= github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= github.com/golang/mock v1.2.0/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= github.com/golang/mock v1.3.1/go.mod h1:sBzyDLLjw3U8JLTeZvSv8jJB+tU5PVekmnlKIyFUx0Y= -github.com/golang/mock v1.6.0/go.mod h1:p6yTPP+5HYm5mzsMV8JkE6ZKdX+/wYM6Hr+LicevLPs= github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= -github.com/golang/protobuf v1.5.3 h1:KhyjKVUg7Usr/dYsdSqoFveMYd5ko72D+zANwlG1mmg= -github.com/golang/protobuf v1.5.3/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= +github.com/golang/protobuf v1.5.4 h1:i7eJL8qZTpSEXOPTxNKhASYpMn+8e5Q6AdndVa1dWek= +github.com/golang/protobuf v1.5.4/go.mod h1:lnTiLA8Wa4RWRcIUkrtSVa5nRhsEGBg48fD6rSs7xps= github.com/golang/snappy v0.0.4 h1:yAGX7huGHXlcLOEtBnF4w7FQwA26wojNCwOYAEhLjQM= github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/gomodule/redigo v1.8.2 h1:H5XSIre1MB5NbPYFp+i1NBbb5qN1W8Y8YAQoAYbkm8k= github.com/gomodule/redigo v1.8.2/go.mod h1:P9dn9mFrCBvWhGE1wpxx6fgq7BAeLBk+UUUzlpkBYO0= github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= -github.com/google/btree v1.0.1/go.mod h1:xXMiIv4Fb/0kKde4SpL7qlzvu5cMJDRkFDxJfI9uaxA= github.com/google/cel-go v0.17.7 h1:6ebJFzu1xO2n7TLtN+UBqShGBhlD85bhvglh5DpcfqQ= github.com/google/cel-go v0.17.7/go.mod h1:HXZKzB0LXqer5lHHgfWAnlYwJaQBDKMjxjulNQzhwhY= github.com/google/flatbuffers v1.12.1 h1:MVlul7pQNoDzWRLTw5imwYsl+usrS1TXG2H4jg6ImGw= @@ -288,7 +235,6 @@ github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/ github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= -github.com/google/go-containerregistry v0.14.0/go.mod h1:aiJ2fp/SXvkWgmYHioXnbMdlgB8eXiiYOY55gfN91Wk= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= github.com/google/gofuzz v1.2.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= @@ -298,30 +244,22 @@ github.com/google/pprof v0.0.0-20190515194954-54271f7e092f/go.mod h1:zfwlbNMJ+OI github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1 h1:K6RDEckDVWvDI9JAJYCmNdQXq6neHJOYx3V6jnqNEec= github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= -github.com/google/s2a-go v0.1.7/go.mod h1:50CgR4k1jNlWBu4UfS4AcfhVe1r6pdZPygJ3R8F0Qdw= github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510 h1:El6M4kTTCOh6aBiKaUGG7oYTSPP8MxqL4YI3kZKwcP4= github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510/go.mod h1:pupxD2MaaD3pAXIBCelhxNneeOaAeabZDe5s4K6zSpQ= github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0= github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/googleapis/enterprise-certificate-proxy v0.3.2/go.mod h1:VLSiSSBs/ksPL8kq3OBOQ6WRI2QnaFynd1DCjZ62+V0= github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= -github.com/googleapis/gax-go/v2 v2.12.0/go.mod h1:y+aIqrI5eb1YGMVJfuV3185Ts/D7qKpsEkdD5+I6QGU= github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= github.com/gorilla/handlers v1.5.1 h1:9lRY6j8DEeeBT10CvO9hGW0gmky0BprnvDI5vfhUHH4= github.com/gorilla/handlers v1.5.1/go.mod h1:t8XrUpc4KVXb7HGyJ4/cEnwQiaxrX/hz1Zv/4g96P1Q= github.com/gorilla/mux v1.8.1 h1:TuBL49tXwgrFYWhqrNgrUNEY92u81SPhu7sTdzQEiWY= github.com/gorilla/mux v1.8.1/go.mod h1:AKf9I4AEqPTmMytcMc0KkNouC66V3BtZ4qD5fmWSiMQ= github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= -github.com/gorilla/websocket v1.5.0/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= -github.com/gosuri/uitable v0.0.4/go.mod h1:tKR86bXuXPZazfOTG1FIzvjIdXzd0mo4Vtn16vt0PJo= -github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA= github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= -github.com/grpc-ecosystem/go-grpc-middleware v1.3.0/go.mod h1:z0ButlSOZa5vEBq9m2m2hlwIgKw+rp3sdCBRoJY+30Y= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92BcuyuQ/YW4NSIpoGtfXNho= 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.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= github.com/grpc-ecosystem/grpc-gateway/v2 v2.19.1 h1:/c3QmbOGMGTOumP2iT/rCwB7b0QDGLKzqOmktBjT+Is= github.com/grpc-ecosystem/grpc-gateway/v2 v2.19.1/go.mod h1:5SN9VR2LTsRFsrEC6FHgRbTWrTHu6tqPeKxEQv15giM= github.com/hashicorp/consul/api v1.1.0/go.mod h1:VmuI/Lkw1nC05EYQWNKwWGbkg+FbDBtguAZLlVdkD9Q= @@ -352,7 +290,6 @@ github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO github.com/hashicorp/mdns v1.0.0/go.mod h1:tL+uN++7HEJ6SQLQ2/p+z2pH24WQKWjBPkE0mNTz8vQ= github.com/hashicorp/memberlist v0.1.3/go.mod h1:ajVTdAv/9Im8oMAAj5G31PhhMCZJV2pPBoIllUwCN7I= github.com/hashicorp/serf v0.8.2/go.mod h1:6hOLApaqBFA1NXqRQAsxw9QxuDEvNxSQRwA/JwenrHc= -github.com/huandu/xstrings v1.4.0/go.mod h1:y5/lhBue+AyNmUVz9RLU9xbLR0o4KIIExikq4ovT0aE= github.com/imdario/mergo v0.3.16 h1:wwQJbIsHYGMUyLSPrEq1CT16AhnhNJQ51+4fdHUnCl4= github.com/imdario/mergo v0.3.16/go.mod h1:WBLT9ZmE3lPoWsEzCh9LPo3TiwVN+ZKEjmz+hD27ysY= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= @@ -360,20 +297,13 @@ github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2 github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= github.com/instrumenta/kubeval v0.16.1 h1:PticHzCrCqRjwfse1YmlgsN5313Du1PyJ2QnRGVNdVg= github.com/instrumenta/kubeval v0.16.1/go.mod h1:K9fO5e4B/bznyi5cKzthudanzcPzPBP2OuB5uE9G1TU= -github.com/intel/goresctrl v0.3.0/go.mod h1:fdz3mD85cmP9sHD8JUlrNWAxvwM86CrbmVXltEKd7zk= github.com/ivanpirog/coloredcobra v1.0.1 h1:aURSdEmlR90/tSiWS0dMjdwOvCVUeYLfltLfbgNxrN4= github.com/ivanpirog/coloredcobra v1.0.1/go.mod h1:iho4nEKcnwZFiniGSdcgdvRgZNjxm+h20acv8vqmN6Q= github.com/jbrukh/bayesian v0.0.0-20231117143245-13ae6f916c7a h1:zSc8tkEGo49/E6cQ9o00si0L9Q/Lu1Hsg8JWKCvzEDU= github.com/jbrukh/bayesian v0.0.0-20231117143245-13ae6f916c7a/go.mod h1:SELxwZQq/mPnfPCR2mchLmT4TQaPJvYtLcCtDWSM7vM= -github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= -github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo= -github.com/jmoiron/sqlx v1.3.5/go.mod h1:nRVWtLre0KfCLJvgxzCsLVMogSvQ1zNJtpYr2Ccp0mQ= github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo= -github.com/jonboulle/clockwork v0.2.2/go.mod h1:Pkfl5aHPm1nk2H9h0bjmnJD/BcgbGXUBGnn1kMkgxc8= -github.com/josephspurrier/goversioninfo v1.4.0/go.mod h1:JWzv5rKQr+MmW+LvM412ToT/IkYDZjaclF2pKDss8IY= github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY= github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y= -github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX5e0EB2j4= github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= github.com/json-iterator/go v1.1.7/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= @@ -381,13 +311,11 @@ github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHm github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w= -github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= github.com/klauspost/compress v1.17.6 h1:60eq2E/jlfwQXtvZEeBUYADs+BwKBWURIY+Gj2eRGjI= github.com/klauspost/compress v1.17.6/go.mod h1:/dCuZOvVtNoHsyb+cuJD3itjs3NbnF6KH9zAO4BDxPM= -github.com/klauspost/cpuid/v2 v2.0.4/go.mod h1:FInQzS24/EEf25PyTYn52gqo7WaD8xa0213Md/qVLRg= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= @@ -397,18 +325,10 @@ github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= -github.com/lann/builder v0.0.0-20180802200727-47ae307949d0/go.mod h1:dXGbAdH5GtBTC4WfIxhKZfyBF/HBFgRZSWwZ9g/He9o= -github.com/lann/ps v0.0.0-20150810152359-62de8c46ede0/go.mod h1:vmVJ0l/dxyfGW6FmdpVm2joNMFikkuWg0EoCKLGUMNw= -github.com/lestrrat-go/backoff/v2 v2.0.8/go.mod h1:rHP/q/r9aT27n24JQLa7JhSQZCKBBOiM/uP402WwN8Y= -github.com/lestrrat-go/blackmagic v1.0.0/go.mod h1:TNgH//0vYSs8VXDCfkZLgIrVTTXQELZffUV0tz3MtdQ= -github.com/lestrrat-go/httpcc v1.0.1/go.mod h1:qiltp3Mt56+55GPVCbTdM9MlqhvzyuL6W/NMDA8vA5E= -github.com/lestrrat-go/iter v1.0.1/go.mod h1:zIdgO1mRKhn8l9vrZJZz9TUMMFbQbLeTsbqPDrJ/OJc= -github.com/lestrrat-go/jwx v1.2.25/go.mod h1:zoNuZymNl5lgdcu6P7K6ie2QRll5HVfF4xwxBBK1NxY= -github.com/lestrrat-go/option v1.0.0/go.mod h1:5ZHFbivi4xwXxhxY9XHDe2FHo6/Z7WWmtT7T5nBBp3I= -github.com/lib/pq v1.10.9/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= +github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc= +github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= github.com/liggitt/tabwriter v0.0.0-20181228230101-89fcab3d43de h1:9TO3cAIGXtEhnIaL+V+BEER86oLrvS+kWobKpbJuye0= github.com/liggitt/tabwriter v0.0.0-20181228230101-89fcab3d43de/go.mod h1:zAbeS9B/r2mtpb6U+EI2rYA5OAXxsYw6wTamcNW+zcE= -github.com/linuxkit/virtsock v0.0.0-20201010232012-f8cee7dfc7a3/go.mod h1:3r6x7q95whyfWQpmGZTu3gk3v2YkMi05HEzl7Tf7YEo= github.com/magiconair/properties v1.8.1/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= github.com/mailru/easyjson v0.7.7 h1:UGYAvKxe3sBsEDzO8ZeWOSlIQfWFlxbzLZe7hwFURr0= github.com/mailru/easyjson v0.7.7/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc= @@ -425,37 +345,39 @@ github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27k github.com/mattn/go-isatty v0.0.16/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= github.com/mattn/go-isatty v0.0.20 h1:xfD0iDuEKnDkl03q4limB+vH+GxLEtL/jb4xVJSWWEY= github.com/mattn/go-isatty v0.0.20/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y= -github.com/mattn/go-runewidth v0.0.9/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI= -github.com/mattn/go-shellwords v1.0.12/go.mod h1:EZzvwXDESEeg03EKmM+RmDnNOPKG4lLtQsUlTZDWQ8Y= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= -github.com/matttproud/golang_protobuf_extensions v1.0.4/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= -github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0/go.mod h1:QUyp042oQthUoa9bqDv0ER0wrtXnBruoNd7aNjkbP+k= +github.com/microsoft/kiota-abstractions-go v1.6.0 h1:qbGBNMU0/o5myKbikCBXJFohVCFrrpx2cO15Rta2WyA= +github.com/microsoft/kiota-abstractions-go v1.6.0/go.mod h1:7YH20ZbRWXGfHSSvdHkdztzgCB9mRdtFx13+hrYIEpo= +github.com/microsoft/kiota-authentication-azure-go v1.0.2 h1:tClGeyFZJ+4Bakf8u0euPM4wqy4ethycdOgx3jyH3pI= +github.com/microsoft/kiota-authentication-azure-go v1.0.2/go.mod h1:aTcti0bUJEcq7kBfQG4Sr4ElvRNuaalXcFEu4iEyQ6M= +github.com/microsoft/kiota-http-go v1.3.1 h1:S+ZDxE7Pc/Z06hbfqpFHkoq5xiC8/7d12iNovcgl+7o= +github.com/microsoft/kiota-http-go v1.3.1/go.mod h1:4QjB+as08swnZXZLx5I+ZHZ8U/tVy7Zu49RNTmWgw48= +github.com/microsoft/kiota-serialization-form-go v1.0.0 h1:UNdrkMnLFqUCccQZerKjblsyVgifS11b3WCx+eFEsAI= +github.com/microsoft/kiota-serialization-form-go v1.0.0/go.mod h1:h4mQOO6KVTNciMF6azi1J9QB19ujSw3ULKcSNyXXOMA= +github.com/microsoft/kiota-serialization-json-go v1.0.7 h1:yMbckSTPrjZdM4EMXgzLZSA3CtDaUBI350u0VoYRz7Y= +github.com/microsoft/kiota-serialization-json-go v1.0.7/go.mod h1:1krrY7DYl3ivPIzl4xTaBpew6akYNa8/Tal8g+kb0cc= +github.com/microsoft/kiota-serialization-multipart-go v1.0.0 h1:3O5sb5Zj+moLBiJympbXNaeV07K0d46IfuEd5v9+pBs= +github.com/microsoft/kiota-serialization-multipart-go v1.0.0/go.mod h1:yauLeBTpANk4L03XD985akNysG24SnRJGaveZf+p4so= +github.com/microsoft/kiota-serialization-text-go v1.0.0 h1:XOaRhAXy+g8ZVpcq7x7a0jlETWnWrEum0RhmbYrTFnA= +github.com/microsoft/kiota-serialization-text-go v1.0.0/go.mod h1:sM1/C6ecnQ7IquQOGUrUldaO5wj+9+v7G2W3sQ3fy6M= +github.com/microsoftgraph/msgraph-sdk-go v1.38.0 h1:pxVMih65Iul2yIUVE5PUqdw5Q4eFuH+eb4ZTxR3oGag= +github.com/microsoftgraph/msgraph-sdk-go v1.38.0/go.mod h1:u/ciVhK5eBqzQvsVnTVdeEl+Jgy9WbUoUHHKgcw54hk= +github.com/microsoftgraph/msgraph-sdk-go-core v1.1.0 h1:NB7c/n4Knj+TLaLfjsahhSqoUqoN/CtyNB0XIe/nJnM= +github.com/microsoftgraph/msgraph-sdk-go-core v1.1.0/go.mod h1:M3w/5IFJ1u/DpwOyjsjNSVEA43y1rLOeX58suyfBhGk= github.com/miekg/dns v1.0.14/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg= -github.com/miekg/dns v1.1.48 h1:Ucfr7IIVyMBz4lRE8qmGUuZ4Wt3/ZGu9hmcMT3Uu4tQ= -github.com/miekg/dns v1.1.48/go.mod h1:e3IlAVfNqAllflbibAZEWOXOQ+Ynzk/dDozDxY7XnME= -github.com/miekg/pkcs11 v1.1.1/go.mod h1:XsNlhZGX73bx86s2hdc/FuaLm2CPZJemRLMA+WTFxgs= -github.com/minio/sha256-simd v1.0.0/go.mod h1:OuYzVNI5vcoYIAmbIvHPl3N3jUzVedXbKy5RFepssQM= -github.com/mistifyio/go-zfs/v3 v3.0.1/go.mod h1:CzVgeB0RvF2EGzQnytKVvVSDwmKJXxkOTUGbNrTja/k= +github.com/miekg/dns v1.1.57 h1:Jzi7ApEIzwEPLHWRcafCN9LZSBbqQpxjt/wpgvg7wcM= +github.com/miekg/dns v1.1.57/go.mod h1:uqRjCRUuEAA6qsOiJvDd+CFo/vW+y5WR6SNmHE55hZk= github.com/mitchellh/cli v1.0.0/go.mod h1:hNIlj7HEI86fIcpObd7a0FcrxTWetlwJDGcceTlRvqc= -github.com/mitchellh/copystructure v1.2.0/go.mod h1:qLl+cE2AmVv+CoeAwDPye/v+N2HKCj9FbZEVFJRxO9s= github.com/mitchellh/go-homedir v1.0.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= -github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= github.com/mitchellh/go-testing-interface v1.0.0/go.mod h1:kRemZodwjscx+RGhAo8eIhFbs2+BFgRtFPeD/KE+zxI= -github.com/mitchellh/go-wordwrap v1.0.1/go.mod h1:R62XHJLzvMFRBbcrT7m7WgmE1eOyTSsCt+hzestvNj0= github.com/mitchellh/gox v0.4.0/go.mod h1:Sd9lOJ0+aimLBi73mGofS1ycjY8lL3uZM3JPS42BGNg= github.com/mitchellh/iochan v1.0.0/go.mod h1:JwYml1nuB7xOzsp52dPpHFffvOCDupsG0QubkSMEySY= github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= -github.com/mitchellh/reflectwalk v1.0.2/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= github.com/moby/locker v1.0.1 h1:fOXqR41zeveg4fFODix+1Ch4mj/gT0NE1XJbp/epuBg= github.com/moby/locker v1.0.1/go.mod h1:S7SDdo5zpBK84bzzVlKr2V0hz+7x9hWbYC/kq7oQppc= -github.com/moby/spdystream v0.2.0/go.mod h1:f7i0iNDQJ059oMTcWxx8MA/zKFIuD/lY+0GqbN2Wy8c= github.com/moby/sys/mountinfo v0.6.2 h1:BzJjoreD5BMFNmD9Rus6gdd1pLuecOFPt8wC+Vygl78= github.com/moby/sys/mountinfo v0.6.2/go.mod h1:IJb6JQeOklcdMU9F5xQ8ZALD+CUr5VlGpwtX+VE0rpI= -github.com/moby/sys/sequential v0.5.0/go.mod h1:tH2cOOs5V9MlPiXcQzRC+eEyab644PWKGRYaaV5ZZlo= -github.com/moby/sys/signal v0.7.0/go.mod h1:GQ6ObYZfqacOwTtlXvcmh9A26dVRul/hbOZn88Kg8Tg= -github.com/moby/sys/symlink v0.2.0/go.mod h1:7uZVF2dqJjG/NsClqul95CqKOBRQyYSNnJ6BMgR/gFs= -github.com/moby/sys/user v0.1.0/go.mod h1:fKJhFOnsCN6xZ5gSfbM6zaHGgDJMrqt9/reuj4T7MmU= github.com/moby/term v0.5.0 h1:xt8Q1nalod/v7BqbG21f8mQPqH+xAaC9C3N3wfWbVP0= github.com/moby/term v0.5.0/go.mod h1:8FzsFHVUBGZdbDsJw/ot+X+d5HLUbvklYLJ9uGfcI3Y= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= @@ -467,55 +389,44 @@ github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9G github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00 h1:n6/2gBQ3RWajuToeY6ZtZTIKv2v7ThUy5KKusIT0yc0= github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00/go.mod h1:Pm3mSP3c5uWn86xMLZ5Sa7JB9GsEZySvHYXCTK4E9q4= -github.com/morikuni/aec v1.0.0/go.mod h1:BbKIizmSmc5MMPqRYbxO4ZU0S0+P200+tUnFx7PXmsc= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq1c1nUAm88MOHcQC9l5mIlSMApZMrHA= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= -github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= -github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f/go.mod h1:ZdcZmHo+o7JKHSa8/e818NopupXU1YMK5fe1lsApnBw= -github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno= github.com/oklog/ulid v1.3.1/go.mod h1:CirwcVhetQ6Lv90oh/F+FBtV6XMibvdAFo93nm5qn4U= -github.com/olekukonko/tablewriter v0.0.5/go.mod h1:hPp6KlRPjbx+hW8ykQs1w3UBbZlj6HuIJcUGPhkA7kY= github.com/onsi/ginkgo/v2 v2.14.0 h1:vSmGj2Z5YPb9JwCWT6z6ihcUvDhuXLc3sJiqd3jMKAY= github.com/onsi/ginkgo/v2 v2.14.0/go.mod h1:JkUdW7JkN0V6rFvsHcJ478egV3XH9NxpD27Hal/PhZw= github.com/onsi/gomega v1.31.1 h1:KYppCUK+bUgAZwHOu7EXVBKyQA6ILvOESHkn/tgoqvo= github.com/onsi/gomega v1.31.1/go.mod h1:y40C95dwAD1Nz36SsEnxvfFe8FFfNxzI5eJ0EYGyAy0= -github.com/open-policy-agent/cert-controller v0.8.0/go.mod h1:alotCQRwX4M6VEwEgO53FB6nGLSlvah6L0pWxSRslIk= -github.com/open-policy-agent/frameworks/constraint v0.0.0-20240206175643-9de2e6ab07f8 h1:quf5LwbmLe/QDwmY2+0LIKJOr/5A0WRpyJI7Iws2oq4= -github.com/open-policy-agent/frameworks/constraint v0.0.0-20240206175643-9de2e6ab07f8/go.mod h1:kO8Ly6ezUl4t9qnWNrcY2RZhZ+MWsh7TuQONUz1+ENg= -github.com/open-policy-agent/gatekeeper/v3 v3.15.0 h1:P4fWglkolrcdeGTWLT/5pYmYAbznDO6kkJVDdyEhNI4= -github.com/open-policy-agent/gatekeeper/v3 v3.15.0/go.mod h1:KWMdiktxK7eQnF9Qm55A4NHCxFBcyJaihWwIg1XNYWI= -github.com/open-policy-agent/opa v0.61.0 h1:nhncQ2CAYtQTV/SMBhDDPsCpCQsUW+zO/1j+T5V7oZg= -github.com/open-policy-agent/opa v0.61.0/go.mod h1:7OUuzJnsS9yHf8lw0ApfcbrnaRG1EkN3J2fuuqi4G/E= +github.com/open-policy-agent/frameworks/constraint v0.0.0-20240411024313-c2efb00269a8 h1:+3lwaywVgMn4XfcYASBJs2V19XjsKlsRmUEne+Zn8eY= +github.com/open-policy-agent/frameworks/constraint v0.0.0-20240411024313-c2efb00269a8/go.mod h1:6olMPE+rOIu3A1fNk9FaMAe18fTlJbElZUDz+Oi+MkU= +github.com/open-policy-agent/gatekeeper/v3 v3.15.1 h1:OZwnjjos2Y5IjxoO4Y0sHIW2AApOAROzST7lwnrRzSU= +github.com/open-policy-agent/gatekeeper/v3 v3.15.1/go.mod h1:KWMdiktxK7eQnF9Qm55A4NHCxFBcyJaihWwIg1XNYWI= +github.com/open-policy-agent/opa v0.63.0 h1:ztNNste1v8kH0/vJMJNquE45lRvqwrM5mY9Ctr9xIXw= +github.com/open-policy-agent/opa v0.63.0/go.mod h1:9VQPqEfoB2N//AToTxzZ1pVTVPUoF2Mhd64szzjWPpU= github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8Oi/yOhh5U= github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= github.com/opencontainers/image-spec v1.1.0-rc6 h1:XDqvyKsJEbRtATzkgItUqBA7QHk58yxX1Ov9HERHNqU= github.com/opencontainers/image-spec v1.1.0-rc6/go.mod h1:W4s4sFTMaBeK1BQLXbG4AdM2szdn85PY75RI83NrTrM= -github.com/opencontainers/runc v1.1.5/go.mod h1:1J5XiS+vdZ3wCyZybsuxXZWGrgSr8fFJHLXuG2PsnNg= -github.com/opencontainers/runtime-spec v1.1.0/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0= -github.com/opencontainers/runtime-tools v0.9.1-0.20221107090550-2e043c6bd626/go.mod h1:BRHJJd0E+cx42OybVYSgUvZmU0B8P9gZuRXlZUP7TKI= -github.com/opencontainers/selinux v1.11.0/go.mod h1:E5dMC3VPuVvVHDYmi78qvhJp8+M586T4DlDRYpFkyec= github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= -github.com/pelletier/go-toml v1.9.5/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= -github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU= -github.com/peterh/liner v1.2.2/go.mod h1:xFwJyiKIXJZUKItq5dGHZSTBRAuG/CpeNpWLyiNRNwI= github.com/phayes/freeport v0.0.0-20220201140144-74d24b5ae9f5 h1:Ii+DKncOVM8Cu1Hc+ETb5K+23HdAMvESYE3ZJ5b5cMI= github.com/phayes/freeport v0.0.0-20220201140144-74d24b5ae9f5/go.mod h1:iIss55rKnNBTvrwdmkUpLnDpZoAHvWaiq5+iMmen4AE= +github.com/pkg/browser v0.0.0-20240102092130-5ac0b6a4141c h1:+mdjkGKdHQG3305AYmdv1U2eRNDiU2ErMBj1gwrq8eQ= +github.com/pkg/browser v0.0.0-20240102092130-5ac0b6a4141c/go.mod h1:7rwL4CYBLnjLxUqIJNnCWiEdr3bn6IUYi15bNlnbCCU= github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= -github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= +github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 h1:Jamvg5psRIccs7FGNTlIRMkT8wgtp5eCXdBlqhYGL6U= +github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI= -github.com/pquerna/cachecontrol v0.1.0/go.mod h1:NrUG3Z7Rdu85UNR3vm7SOsl1nFIeSiQnrHV5K9mBcUI= github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw= github.com/prometheus/client_golang v0.9.3/go.mod h1:/TN21ttK/J9q6uSwhBd54HahCDft0ttaMvbicHlPoso= github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5FsnadC4Ky3P0J6CfImo= github.com/prometheus/client_golang v1.1.0/go.mod h1:I1FGZT9+L76gKKOs5djB6ezCbFQP1xR9D75/vuwEF3g= -github.com/prometheus/client_golang v1.18.0 h1:HzFfmkOzH5Q8L8G+kSJKUx5dtG87sewO+FoDDqP5Tbk= -github.com/prometheus/client_golang v1.18.0/go.mod h1:T+GXkCk5wSJyOqMIzVgvvjFDlkOQntgjkJWKrN5txjA= +github.com/prometheus/client_golang v1.19.0 h1:ygXvpU1AoN1MhdzckN+PyD9QJOSD4x7kmXYlnfbA6JU= +github.com/prometheus/client_golang v1.19.0/go.mod h1:ZRM9uEAypZakd+q/x7+gmsvXdURP+DABIEIjnmDdp+k= github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.5.0 h1:VQw1hfvPvk3Uv6Qf29VrPF32JB6rtbgI6cYPYQjL0Qw= @@ -524,8 +435,8 @@ github.com/prometheus/common v0.0.0-20181113130724-41aa239b4cce/go.mod h1:daVV7q github.com/prometheus/common v0.4.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= github.com/prometheus/common v0.6.0/go.mod h1:eBmuwkDJBwy6iBfxCBob6t6dR6ENT/y+J+Zk0j9GMYc= -github.com/prometheus/common v0.46.0 h1:doXzt5ybi1HBKpsZOL0sSkaNHJJqkyfEWZGGqqScV0Y= -github.com/prometheus/common v0.46.0/go.mod h1:Tp0qkxpb9Jsg54QMe+EAmqXkSV7Evdy1BTn+g2pa/hQ= +github.com/prometheus/common v0.48.0 h1:QO8U2CdOzSn1BBsmXJXduaaW+dY/5QLjfB8svtSzKKE= +github.com/prometheus/common v0.48.0/go.mod h1:0/KsvlIEfPQCQ5I2iNSAWKPZziNCvRs5EC6ILDTlAPc= github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= github.com/prometheus/procfs v0.0.0-20190507164030-5867b95ac084/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= @@ -536,29 +447,23 @@ github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40T github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 h1:N/ElC8H3+5XpJzTSTfLsJV/mx9Q9g7kxmchpfZyxgzM= github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475/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/rogpeppe/go-internal v1.11.0 h1:cWPaGQEPrBb5/AsnsZesgZZ9yb1OQ+GOISoDNXVBh4M= github.com/rogpeppe/go-internal v1.11.0/go.mod h1:ddIwULY96R17DhadqLgMfk9H9tvdUzkipdSkR5nkCZA= -github.com/rubenv/sql-migrate v1.5.2/go.mod h1:H38GW8Vqf8F0Su5XignRyaRcbXbJunSWxs+kmzlg0Is= -github.com/russross/blackfriday v1.6.0/go.mod h1:ti0ldHuxg49ri4ksnFxlkCfN+hvslNlmVHqNRXXJNAY= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= github.com/sergi/go-diff v1.3.1 h1:xkr+Oxo4BOQKmkn/B9eMK0g5Kg/983T9DqqPHwYqD+8= github.com/sergi/go-diff v1.3.1/go.mod h1:aMJSSKb2lpPvRNec0+w3fl7LP9IOFzdc9Pa4NFbPK1I= -github.com/shopspring/decimal v1.3.1/go.mod h1:DKyhrW/HYNuLGql+MJL6WCR6knT2jwCFRcu2hWCYk4o= github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ= github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA= github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM= -github.com/soheilhy/cmux v0.1.5/go.mod h1:T7TcVDs9LWfQgPlPsdngu6I6QIoyIFZDDC6sNE1GqG0= github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ= github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= -github.com/spf13/cast v1.5.0/go.mod h1:SpXXQ5YoyJw6s3/6cMTQuxvgRl3PCJiyaX9p6b155UU= github.com/spf13/cobra v0.0.0-20180820174524-ff0d02e85550/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ= github.com/spf13/cobra v1.4.0/go.mod h1:Wo4iy3BUC+X2Fybo0PDqwJIv3dNRiZLHQymsfxlB84g= github.com/spf13/cobra v1.8.0 h1:7aJaZx1B85qltLMc546zn58BxxfZdR/W22ej9CFoEf0= @@ -568,35 +473,28 @@ github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnIn github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= github.com/spf13/viper v1.7.1/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg= -github.com/stefanberger/go-pkcs11uri v0.0.0-20201008174630-78d3cae3a980/go.mod h1:AO3tvPzVZ/ayst6UlUKUv6rcPQInYe3IknH3jYhAKu8= +github.com/std-uritemplate/std-uritemplate/go v0.0.55 h1:muSH037g97K7U2f94G9LUuE8tZlJsoSSrPsO9V281WY= +github.com/std-uritemplate/std-uritemplate/go v0.0.55/go.mod h1:rG/bqh/ThY4xE5de7Rap3vaDkYUT76B0GPJ0loYeTTc= github.com/stoewer/go-strcase v1.3.0 h1:g0eASXYtp+yvN9fK8sH94oCIk0fau9uV1/ZdJ0AVEzs= github.com/stoewer/go-strcase v1.3.0/go.mod h1:fAH5hQ5pehh+j3nZfvwdk2RgEgQjAoM8wodgtPmh1xo= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= -github.com/stretchr/objx v0.5.0 h1:1zr/of2m5FGMsad5YfcqgdqdWrIhu+EBEJRhR1U7z/c= github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= +github.com/stretchr/objx v0.5.2 h1:xuMeJ0Sdp5ZMRXx/aWO6RZxdr3beISkG5/G/aIRr3pY= +github.com/stretchr/objx v0.5.2/go.mod h1:FRsXN1f5AsAjCGJKqEizvkpNtU+EGNCLh3NxZ/8L+MA= github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= -github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= -github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= +github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg= +github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw= -github.com/syndtr/gocapability v0.0.0-20200815063812-42c35b437635/go.mod h1:hkRG7XYTFWNJGYcbNJQlaLq0fg1yr4J4t/NcTQtrfww= github.com/tchap/go-patricia/v2 v2.3.1 h1:6rQp39lgIYZ+MHmdEq4xzuk1t7OdC35z/xm0BGhTkes= github.com/tchap/go-patricia/v2 v2.3.1/go.mod h1:VZRHKAb53DLaG+nA9EaYYiaEx6YztwDlLElMsnSHD4k= github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= -github.com/tmc/grpc-websocket-proxy v0.0.0-20220101234140-673ab2c3ae75/go.mod h1:KO6IkyS8Y3j8OdNO85qEYBsRPuteD+YciPomcXdrMnk= -github.com/urfave/cli v1.22.12/go.mod h1:sSBEIC79qR6OvcmsD4U3KABeOTxDqQtdDnaFuUN30b8= -github.com/vbatts/tar-split v0.11.2/go.mod h1:vV3ZuO2yWSVsz+pfFzDG/upWH1JhjOiEaWq6kXyQ3VI= -github.com/vektah/gqlparser/v2 v2.4.5/go.mod h1:flJWIR04IMQPGz+BXLrORkrARBxv/rtyIAFvd/MceW0= -github.com/veraison/go-cose v1.0.0-rc.1/go.mod h1:7ziE85vSq4ScFTg6wyoMXjucIGOf4JkFEZi/an96Ct4= -github.com/vishvananda/netlink v1.2.1-beta.2/go.mod h1:twkDnbuQxJYemMlGd4JFIcuhgX83tXhKS2B/PRMpOho= -github.com/vishvananda/netns v0.0.0-20210104183010-2eb08e3e575f/go.mod h1:DD4vA1DwXk04H54A1oHXtwZmA0grkVMdPxx/VGLCah0= -github.com/x448/float16 v0.8.4/go.mod h1:14CWIYCyZA/cWjXOioeEpHeN/83MdbZDRQHoFcYsOfg= github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= github.com/xeipuuv/gojsonpointer v0.0.0-20190905194746-02993c407bfb h1:zGWFAtiMcyryUHoUjUJX0/lt1H2+i2Ka2n+D3DImSNo= github.com/xeipuuv/gojsonpointer v0.0.0-20190905194746-02993c407bfb/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= @@ -605,7 +503,6 @@ github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1: github.com/xeipuuv/gojsonschema v0.0.0-20180816142147-da425ebb7609/go.mod h1:5yf86TLmAcydyeJq5YvxkGPE2fm/u4myDekKRoLuqhs= github.com/xeipuuv/gojsonschema v1.2.0 h1:LhYJRs+L4fBtjZUfuSZIKGeVu0QRy8e5Xi7D17UxZ74= github.com/xeipuuv/gojsonschema v1.2.0/go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y= -github.com/xhit/go-str2duration/v2 v2.1.0/go.mod h1:ohY8p+0f07DiV6Em5LKB0s2YpLtXVyJfNt1+BlmyAsU= github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= github.com/xlab/treeprint v1.2.0 h1:HzHnuAF1plUN2zGlAFHbSQP2qJ0ZAD3XF5XD7OesXRQ= github.com/xlab/treeprint v1.2.0/go.mod h1:gj5Gd3gPdKtR1ikdDK6fnFLdmIS0X30kTTuNd/WEJu0= @@ -621,54 +518,41 @@ github.com/yvasiyarov/gorelic v0.0.0-20141212073537-a9bba5b9ab50/go.mod h1:NUSPS github.com/yvasiyarov/newrelic_platform_go v0.0.0-20140908184405-b21fdbd4370f h1:ERexzlUfuTvpE74urLSbIQW0Z/6hF9t8U4NsJLaioAY= github.com/yvasiyarov/newrelic_platform_go v0.0.0-20140908184405-b21fdbd4370f/go.mod h1:GlGEuHIJweS1mbCqG+7vt2nvWLzLLnRHbXz5JKd/Qbg= go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= -go.etcd.io/bbolt v1.3.8/go.mod h1:N9Mkw9X8x5fupy0IKsmuqVtoGDyxsaDlbk4Rd05IAQw= go.etcd.io/etcd/api/v3 v3.5.10 h1:szRajuUUbLyppkhs9K6BRtjY37l66XQQmw7oZRANE4k= go.etcd.io/etcd/api/v3 v3.5.10/go.mod h1:TidfmT4Uycad3NM/o25fG3J07odo4GBB9hoxaodFCtI= go.etcd.io/etcd/client/pkg/v3 v3.5.10 h1:kfYIdQftBnbAq8pUWFXfpuuxFSKzlmM5cSn76JByiT0= go.etcd.io/etcd/client/pkg/v3 v3.5.10/go.mod h1:DYivfIviIuQ8+/lCq4vcxuseg2P2XbHygkKwFo9fc8U= -go.etcd.io/etcd/client/v2 v2.305.10/go.mod h1:m3CKZi69HzilhVqtPDcjhSGp+kA1OmbNn0qamH80xjA= go.etcd.io/etcd/client/v3 v3.5.10 h1:W9TXNZ+oB3MCd/8UjxHTWK5J9Nquw9fQBLJd5ne5/Ao= go.etcd.io/etcd/client/v3 v3.5.10/go.mod h1:RVeBnDz2PUEZqTpgqwAtUd8nAPf5kjyFyND7P1VkOKc= -go.etcd.io/etcd/pkg/v3 v3.5.10/go.mod h1:TKTuCKKcF1zxmfKWDkfz5qqYaE3JncKKZPFf8c1nFUs= -go.etcd.io/etcd/raft/v3 v3.5.10/go.mod h1:odD6kr8XQXTy9oQnyMPBOr0TVe+gT0neQhElQ6jbGRc= -go.etcd.io/etcd/server/v3 v3.5.10/go.mod h1:gBplPHfs6YI0L+RpGkTQO7buDbHv5HJGG/Bst0/zIPo= -go.mozilla.org/pkcs7 v0.0.0-20200128120323-432b2356ecb1/go.mod h1:SNgMg+EgDFwmvSmLRTNKC5fegJjB7v23qTQ0XLGUNHk= go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU= go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8= go.opencensus.io v0.24.0 h1:y73uSU6J157QMP2kn2r30vwW1A2W2WFwSCGnAVxeaD0= go.opencensus.io v0.24.0/go.mod h1:vNK8G9p7aAivkbmorf4v+7Hgx+Zs0yY+0fOtgBfjQKo= -go.opentelemetry.io/contrib/detectors/aws/ec2 v1.21.1/go.mod h1:8X6bRmDQ4PMy7iVK7qor/eHnI00S2+q4BM0ukcMEl0s= -go.opentelemetry.io/contrib/detectors/gcp v1.21.1/go.mod h1:yL1WBcIgLFgqHhuMqmxp6ddaXoNFPeUgk6ATnF4wBhI= go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.47.0 h1:UNQQKPfTDe1J81ViolILjTKPr9WetKW6uei2hFgJmFs= go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.47.0/go.mod h1:r9vWsPS/3AQItv3OSlEJ/E4mbrhUbbw18meOjArPtKQ= go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.48.0 h1:doUP+ExOpH3spVTLS0FcWGLnQrPct/hD/bCPbDRUEAU= go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.48.0/go.mod h1:rdENBZMT2OE6Ne/KLwpiXudnAsbdrdBaqBvTN8M8BgA= -go.opentelemetry.io/otel v1.23.0 h1:Df0pqjqExIywbMCMTxkAwzjLZtRf+bBKLbUcpxO2C9E= -go.opentelemetry.io/otel v1.23.0/go.mod h1:YCycw9ZeKhcJFrb34iVSkyT0iczq/zYDtZYFufObyB0= -go.opentelemetry.io/otel/exporters/otlp/otlpmetric v0.42.0/go.mod h1:hG4Fj/y8TR/tlEDREo8tWstl9fO9gcFkn4xrx0Io8xU= -go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp v0.42.0/go.mod h1:YfbDdXAAkemWJK3H/DshvlrxqFB2rtW4rY6ky/3x/H0= +go.opentelemetry.io/otel v1.24.0 h1:0LAOdjNmQeSTzGBzduGe/rU4tZhMwL5rWgtp9Ku5Jfo= +go.opentelemetry.io/otel v1.24.0/go.mod h1:W7b9Ozg4nkF5tWI5zsXkaKKDjdVjpD4oAt9Qi/MArHo= go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.23.0 h1:D/cXD+03/UOphyyT87NX6h+DlU+BnplN6/P6KJwsgGc= go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.23.0/go.mod h1:L669qRGbPBwLcftXLFnTVFO6ES/GyMAvITLdvRjEAIM= go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.23.0 h1:VZrBiTXzP3FErizsdF1JQj0qf0yA8Ktt6LAcjUhZqbc= go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.23.0/go.mod h1:xkkwo777b9MEfsyD1yUZa4g+7MCqqWAP3r2tTSZePRc= -go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.19.0/go.mod h1:oVdCUtjq9MK9BlS7TtucsQwUcXcymNiEDjgDD2jMtZU= -go.opentelemetry.io/otel/exporters/prometheus v0.40.0/go.mod h1:5USWZ0ovyQB5CIM3IO3bGRSoDPMXiT3t+15gu8Zo9HQ= -go.opentelemetry.io/otel/metric v1.23.0 h1:pazkx7ss4LFVVYSxYew7L5I6qvLXHA0Ap2pwV+9Cnpo= -go.opentelemetry.io/otel/metric v1.23.0/go.mod h1:MqUW2X2a6Q8RN96E2/nqNoT+z9BSms20Jb7Bbp+HiTo= +go.opentelemetry.io/otel/metric v1.24.0 h1:6EhoGWWK28x1fbpA4tYTOWBkPefTDQnb8WSGXlc88kI= +go.opentelemetry.io/otel/metric v1.24.0/go.mod h1:VYhLe1rFfxuTXLgj4CBiyz+9WYBA8pNGJgDcSFRKBco= go.opentelemetry.io/otel/sdk v1.23.0 h1:0KM9Zl2esnl+WSukEmlaAEjVY5HDZANOHferLq36BPc= go.opentelemetry.io/otel/sdk v1.23.0/go.mod h1:wUscup7byToqyKJSilEtMf34FgdCAsFpFOjXnAwFfO0= -go.opentelemetry.io/otel/sdk/metric v1.19.0/go.mod h1:XjG0jQyFJrv2PbMvwND7LwCEhsJzCzV5210euduKcKY= -go.opentelemetry.io/otel/trace v1.23.0 h1:37Ik5Ib7xfYVb4V1UtnT97T1jI+AoIYkJyPkuL4iJgI= -go.opentelemetry.io/otel/trace v1.23.0/go.mod h1:GSGTbIClEsuZrGIzoEHqsVfxgn5UkggkflQwDScNUsk= +go.opentelemetry.io/otel/trace v1.24.0 h1:CsKnnL4dUAr/0llH9FKuc698G04IrpWV0MQA/Y1YELI= +go.opentelemetry.io/otel/trace v1.24.0/go.mod h1:HPc3Xr/cOApsBI154IU0OI0HJexz+aw5uPdbs3UCjNU= go.opentelemetry.io/proto/otlp v1.1.0 h1:2Di21piLrCqJ3U3eXGCTPHE9R8Nh+0uglSnOyxikMeI= go.opentelemetry.io/proto/otlp v1.1.0/go.mod h1:GpBHCBWiqvVLDqmHZsoMM3C5ySeKTC7ej/RNTae6MdY= go.starlark.net v0.0.0-20240123142251-f86470692795 h1:LmbG8Pq7KDGkglKVn8VpZOZj6vb9b8nKEGcg9l03epM= go.starlark.net v0.0.0-20240123142251-f86470692795/go.mod h1:LcLNIzVOMp4oV+uusnpk+VU+SzXaJakUuBjoCSWH5dM= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= -go.uber.org/atomic v1.11.0/go.mod h1:LUxbIzbOniOlMKjJjyPfpl4v+PKK2cNJn91OQbhoJI0= -go.uber.org/automaxprocs v1.5.3/go.mod h1:eRbA25aqJrxAbsLO0xy5jVwPt7FQnRgjW+efnwa1WM0= go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto= go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE= +go.uber.org/mock v0.4.0 h1:VcM4ZOtdbR4f6VXfiOpwpVJDL6lCReaZ6mw31wqh7KU= +go.uber.org/mock v0.4.0/go.mod h1:a6FSlNadKUHUa9IP5Vyt1zh4fC7uAwxMutEAscFbkZc= go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0= go.uber.org/multierr v1.11.0 h1:blXXJkSxSSfBVBlC76pxqeO+LN3aDfLQo+309xJstO0= go.uber.org/multierr v1.11.0/go.mod h1:20+QtiLqy0Nd6FdQB9TLXag12DsQkrbs3htMFfDN80Y= @@ -683,15 +567,15 @@ golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= -golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= +golang.org/x/crypto v0.22.0 h1:g1v0xeRhjcugydODzvb3mEM9SQ0HGp9s/nh3COQ/C30= +golang.org/x/crypto v0.22.0/go.mod h1:vr6Su+7cTlO45qkww3VDJlzDn0ctJvRgYbC2NvXHt+M= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= golang.org/x/exp v0.0.0-20190829153037-c13cbed26979/go.mod h1:86+5VVa7VpoJ4kLfm080zCjGlMRFzhUhsZKEZO7MGek= golang.org/x/exp v0.0.0-20191030013958-a1ab85dbe136/go.mod h1:JXzH8nQsPlswgeRAPE3MuO9GYsAcnJvJ4vnMwN/5qkY= -golang.org/x/exp v0.0.0-20240205201215-2c58cdc269a3 h1:/RIbNt/Zr7rVhIkQhooTxCxFcdWLGIKnZA4IXNFSrvo= -golang.org/x/exp v0.0.0-20240205201215-2c58cdc269a3/go.mod h1:idGWGoKP1toJGkd5/ig9ZLuPcZBC3ewk7SzmH0uou08= +golang.org/x/exp v0.0.0-20240416160154-fe59bbe5cc7f h1:99ci1mjWVBWwJiEKYY6jWa4d2nTQVIEhZIptnrVb1XY= +golang.org/x/exp v0.0.0-20240416160154-fe59bbe5cc7f/go.mod h1:/lliqkxwWAhPjf5oSOIJup2XcqJaw8RGS6k3TGEc7GI= golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js= golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= @@ -708,8 +592,8 @@ golang.org/x/mod v0.1.0/go.mod h1:0QHyrYULN0/3qlju5TqG8bIK38QM8yzMo5ekMj3DlcY= golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= -golang.org/x/mod v0.14.0 h1:dGoOF9QVLYng8IHTm7BAyWqCqSheQ5pYWGhzW00YJr0= -golang.org/x/mod v0.14.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c= +golang.org/x/mod v0.17.0 h1:zY54UmvipHiNd+pm+m0x9KhZ9hl1/7QNMyxXbc6ICqA= +golang.org/x/mod v0.17.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c= golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20181023162649-9b4f9f5ad519/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= @@ -729,8 +613,8 @@ golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLL golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= -golang.org/x/net v0.20.0 h1:aCL9BSgETF1k+blQaYUBx9hJ9LOGP3gAVemcZlf1Kpo= -golang.org/x/net v0.20.0/go.mod h1:z8BVo6PvndSri0LbOE3hAn0apkU+1YvI6E70E9jsnvY= +golang.org/x/net v0.24.0 h1:1PcaxkF854Fu3+lvBIx5SYn9wRlBzzcnHZSiaFFAb0w= +golang.org/x/net v0.24.0/go.mod h1:2Q7sJY5mzlzWjKtYUEXSlBWCdyaioyXzRB2RtU8KVE8= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -744,8 +628,8 @@ golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.6.0 h1:5BMeUDZ7vkXGfEr1x9B4bRcTH4lpkTkpdh0T/J+qjbQ= -golang.org/x/sync v0.6.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= +golang.org/x/sync v0.7.0 h1:YsImfSBoP9QPYL0xyKJPq0gcaJdG3rInoqxTWbfQu9M= +golang.org/x/sync v0.7.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -773,13 +657,14 @@ golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.17.0 h1:25cE3gD+tdBA7lp7QfhuV+rJiE9YXTcS3VG1SqssI/Y= -golang.org/x/sys v0.17.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.19.0 h1:q5f1RH2jigJ1MoAWp2KTp3gm5zAGFUTarQZ5U386+4o= +golang.org/x/sys v0.19.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= -golang.org/x/term v0.17.0 h1:mkTF7LCd6WGJNL3K1Ad7kwxNfYAW6a8a8QqtMblp/4U= -golang.org/x/term v0.17.0/go.mod h1:lLRBjIVuehSbZlaOtGMbcMncT+aqLLLmKrsjNrUguwk= +golang.org/x/term v0.19.0 h1:+ThwsDv+tYfnJFhF4L8jITxu1tdTWRTZpdsWgEgjL6Q= +golang.org/x/term v0.19.0/go.mod h1:2CuTdWZ7KHSQwUzKva0cbMg6q2DMI3Mmxp+gKJbskEk= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= @@ -813,13 +698,12 @@ golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtn golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= -golang.org/x/tools v0.17.0 h1:FvmRgNOcs3kOa+T20R1uhfP9F6HgG2mfxDv1vrx1Htc= -golang.org/x/tools v0.17.0/go.mod h1:xsh6VxdV005rRVaS6SSAf9oiAqljS7UZUacMZ8Bnsps= +golang.org/x/tools v0.20.0 h1:hz/CVckiOxybQvFw6h7b/q80NTr9IUQb4s1IIzW7KNY= +golang.org/x/tools v0.20.0/go.mod h1:WvitBU7JJf6A4jOdg4S1tviW9bhUxkgeCui/0JHctQg= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= gomodules.xyz/jsonpatch/v2 v2.4.0 h1:Ci3iUJyx9UeRx7CeFN8ARgGbkESwJK+KB9lLcWxY/Zw= gomodules.xyz/jsonpatch/v2 v2.4.0/go.mod h1:AH3dM2RI6uoBZxn3LVrfvJ3E0/9dG4cSrbuBJT4moAY= google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE= @@ -827,7 +711,6 @@ google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E google.golang.org/api v0.8.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= google.golang.org/api v0.9.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= google.golang.org/api v0.13.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI= -google.golang.org/api v0.149.0/go.mod h1:Mwn1B7JTXrzXtnvmzQE2BD6bYZQ8DShKZDZbeN9I7qI= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= @@ -852,26 +735,24 @@ google.golang.org/genproto/googleapis/rpc v0.0.0-20240205150955-31a09d347014/go. google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= -google.golang.org/grpc v1.61.0 h1:TOvOcuXn30kRao+gfcvsebNEa5iZIiLkisYEkf7R7o0= -google.golang.org/grpc v1.61.0/go.mod h1:VUbo7IFqmF1QtCAstipjG0GIoq49KvMe9+h1jFLBNJs= +google.golang.org/grpc v1.62.1 h1:B4n+nfKzOICUXMgyrNd19h/I9oH0L1pizfk1d4zSgTk= +google.golang.org/grpc v1.62.1/go.mod h1:IWTG0VlJLCh1SkC58F7np9ka9mx/WNkjl4PGJaiq+QE= google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= -google.golang.org/protobuf v1.32.0 h1:pPC6BG5ex8PDFnkbrGU3EixyhKcQ2aDuBS36lqK/C7I= -google.golang.org/protobuf v1.32.0/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= +google.golang.org/protobuf v1.33.0 h1:uNO2rsAINq/JlFpSdYEKIZ0uKD/R9cpdv0T+yoGwGmI= +google.golang.org/protobuf v1.33.0/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= -gopkg.in/evanphx/json-patch.v5 v5.9.0 h1:hx1VU2SGj4F8r9b8GUwJLdc8DNO8sy79ZGui0G05GLo= -gopkg.in/evanphx/json-patch.v5 v5.9.0/go.mod h1:/kvTRh1TVm5wuM6OkHxqXtE/1nUZZpihg29RtuIyfvk= +gopkg.in/evanphx/json-patch.v4 v4.12.0 h1:n6jtcsulIzXPJaxegRbvFNNrZDjbij7ny3gmSPG+6V4= +gopkg.in/evanphx/json-patch.v4 v4.12.0/go.mod h1:p8EYWUEYMpynmqDbY58zCKCFZw8pRWMG4EsWvDvM72M= gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc= gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= gopkg.in/ini.v1 v1.51.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= -gopkg.in/natefinch/lumberjack.v2 v2.2.1/go.mod h1:YD8tP3GAjkrDg1eZH7EGmyESg/lsYskCTPBJVb9jqSc= gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo= -gopkg.in/square/go-jose.v2 v2.6.0/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI= 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.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= @@ -883,56 +764,47 @@ gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gotest.tools/v3 v3.4.0 h1:ZazjZUfuVeZGLAmlKKuyv3IKP5orXcwtOwDQH6YVr6o= gotest.tools/v3 v3.4.0/go.mod h1:CtbdzLSsqVhDgMtKsx03ird5YTGB3ar27v0u/yKBW5g= -helm.sh/helm/v3 v3.14.0 h1:TaZIH6uOchn7L27ptwnnuHJiFrT/BsD4dFdp/HLT2nM= -helm.sh/helm/v3 v3.14.0/go.mod h1:2itvvDv2WSZXTllknfQo6j7u3VVgMAvm8POCDgYH424= +helm.sh/helm/v3 v3.14.4 h1:6FSpEfqyDalHq3kUr4gOMThhgY55kXUEjdQoyODYnrM= +helm.sh/helm/v3 v3.14.4/go.mod h1:Tje7LL4gprZpuBNTbG34d1Xn5NmRT3OWfBRwpOSer9I= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg= -k8s.io/api v0.29.1 h1:DAjwWX/9YT7NQD4INu49ROJuZAAAP/Ijki48GUPzxqw= -k8s.io/api v0.29.1/go.mod h1:7Kl10vBRUXhnQQI8YR/R327zXC8eJ7887/+Ybta+RoQ= -k8s.io/apiextensions-apiserver v0.29.1 h1:S9xOtyk9M3Sk1tIpQMu9wXHm5O2MX6Y1kIpPMimZBZw= -k8s.io/apiextensions-apiserver v0.29.1/go.mod h1:zZECpujY5yTW58co8V2EQR4BD6A9pktVgHhvc0uLfeU= -k8s.io/apimachinery v0.29.1 h1:KY4/E6km/wLBguvCZv8cKTeOwwOBqFNjwJIdMkMbbRc= -k8s.io/apimachinery v0.29.1/go.mod h1:6HVkd1FwxIagpYrHSwJlQqZI3G9LfYWRPAkUvLnXTKU= -k8s.io/apiserver v0.29.1 h1:e2wwHUfEmMsa8+cuft8MT56+16EONIEK8A/gpBSco+g= -k8s.io/apiserver v0.29.1/go.mod h1:V0EpkTRrJymyVT3M49we8uh2RvXf7fWC5XLB0P3SwRw= -k8s.io/cli-runtime v0.29.1 h1:By3WVOlEWYfyxhGko0f/IuAOLQcbBSMzwSaDren2JUs= -k8s.io/cli-runtime v0.29.1/go.mod h1:vjEY9slFp8j8UoMhV5AlO8uulX9xk6ogfIesHobyBDU= -k8s.io/client-go v0.29.1 h1:19B/+2NGEwnFLzt0uB5kNJnfTsbV8w6TgQRz9l7ti7A= -k8s.io/client-go v0.29.1/go.mod h1:TDG/psL9hdet0TI9mGyHJSgRkW3H9JZk2dNEUS7bRks= -k8s.io/code-generator v0.29.1/go.mod h1:FwFi3C9jCrmbPjekhaCYcYG1n07CYiW1+PAPCockaos= -k8s.io/component-base v0.29.1 h1:MUimqJPCRnnHsskTTjKD+IC1EHBbRCVyi37IoFBrkYw= -k8s.io/component-base v0.29.1/go.mod h1:fP9GFjxYrLERq1GcWWZAE3bqbNcDKDytn2srWuHTtKc= -k8s.io/cri-api v0.27.1/go.mod h1:+Ts/AVYbIo04S86XbTD73UPp/DkTiYxtsFeOFEu32L0= -k8s.io/gengo v0.0.0-20230829151522-9cce18d56c01/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAEV2be7d5xI0vBa/VySYy3E= +k8s.io/api v0.29.3 h1:2ORfZ7+bGC3YJqGpV0KSDDEVf8hdGQ6A03/50vj8pmw= +k8s.io/api v0.29.3/go.mod h1:y2yg2NTyHUUkIoTC+phinTnEa3KFM6RZ3szxt014a80= +k8s.io/apiextensions-apiserver v0.29.3 h1:9HF+EtZaVpFjStakF4yVufnXGPRppWFEQ87qnO91YeI= +k8s.io/apiextensions-apiserver v0.29.3/go.mod h1:po0XiY5scnpJfFizNGo6puNU6Fq6D70UJY2Cb2KwAVc= +k8s.io/apimachinery v0.29.3 h1:2tbx+5L7RNvqJjn7RIuIKu9XTsIZ9Z5wX2G22XAa5EU= +k8s.io/apimachinery v0.29.3/go.mod h1:hx/S4V2PNW4OMg3WizRrHutyB5la0iCUbZym+W0EQIU= +k8s.io/apiserver v0.29.3 h1:xR7ELlJ/BZSr2n4CnD3lfA4gzFivh0wwfNfz9L0WZcE= +k8s.io/apiserver v0.29.3/go.mod h1:hrvXlwfRulbMbBgmWRQlFru2b/JySDpmzvQwwk4GUOs= +k8s.io/cli-runtime v0.29.0 h1:q2kC3cex4rOBLfPOnMSzV2BIrrQlx97gxHJs21KxKS4= +k8s.io/cli-runtime v0.29.0/go.mod h1:VKudXp3X7wR45L+nER85YUzOQIru28HQpXr0mTdeCrk= +k8s.io/client-go v0.29.3 h1:R/zaZbEAxqComZ9FHeQwOh3Y1ZUs7FaHKZdQtIc2WZg= +k8s.io/client-go v0.29.3/go.mod h1:tkDisCvgPfiRpxGnOORfkljmS+UrW+WtXAy2fTvXJB0= +k8s.io/component-base v0.29.3 h1:Oq9/nddUxlnrCuuR2K/jp6aflVvc0uDvxMzAWxnGzAo= +k8s.io/component-base v0.29.3/go.mod h1:Yuj33XXjuOk2BAaHsIGHhCKZQAgYKhqIxIjIr2UXYio= k8s.io/klog/v2 v2.120.1 h1:QXU6cPEOIslTGvZaXvFWiP9VKyeet3sawzTOvdXb4Vw= k8s.io/klog/v2 v2.120.1/go.mod h1:3Jpz1GvMt720eyJH1ckRHK1EDfpxISzJ7I9OYgaDtPE= -k8s.io/kms v0.29.1/go.mod h1:Hqkx3zEGWThUTbcSkK508DUv4c1HOJOB5qihSoLBWgU= -k8s.io/kube-openapi v0.0.0-20240126223410-2919ad4fcfec h1:iGTel2aR8vCZdxJDgmbeY0zrlXy9Qcvyw4R2sB4HLrA= -k8s.io/kube-openapi v0.0.0-20240126223410-2919ad4fcfec/go.mod h1:Pa1PvrP7ACSkuX6I7KYomY6cmMA0Tx86waBhDUgoKPw= -k8s.io/kubectl v0.29.0/go.mod h1:0jMjGWIcMIQzmUaMgAzhSELv5WtHo2a8pq67DtviAJs= +k8s.io/kube-openapi v0.0.0-20240228011516-70dd3763d340 h1:BZqlfIlq5YbRMFko6/PM7FjZpUb45WallggurYhKGag= +k8s.io/kube-openapi v0.0.0-20240228011516-70dd3763d340/go.mod h1:yD4MZYeKMBwQKVht279WycxKyM84kkAx2DPrTXaeb98= k8s.io/utils v0.0.0-20240102154912-e7106e64919e h1:eQ/4ljkx21sObifjzXwlPKpdGLrCfRziVtos3ofG/sQ= k8s.io/utils v0.0.0-20240102154912-e7106e64919e/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0= oras.land/oras-go v1.2.5 h1:XpYuAwAb0DfQsunIyMfeET92emK8km3W4yEzZvUbsTo= oras.land/oras-go v1.2.5/go.mod h1:PuAwRShRZCsZb7g8Ar3jKKQR/2A/qN+pkYxIOd/FAoo= -oras.land/oras-go/v2 v2.3.1/go.mod h1:5AQXVEu1X/FKp1F9DMOb5ZItZBOa0y5dha0yCm4NR9c= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.29.0 h1:/U5vjBbQn3RChhv7P11uhYvCSm5G2GaIi5AIGBS6r4c= sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.29.0/go.mod h1:z7+wmGM2dfIiLRfrC6jb5kV2Mq/sK1ZP303cxzkV5Y4= -sigs.k8s.io/controller-runtime v0.17.0 h1:fjJQf8Ukya+VjogLO6/bNX9HE6Y2xpsO5+fyS26ur/s= -sigs.k8s.io/controller-runtime v0.17.0/go.mod h1:+MngTvIQQQhfXtwfdGw/UOQ/aIaqsYywfCINOtwMO/s= +sigs.k8s.io/controller-runtime v0.17.3 h1:65QmN7r3FWgTxDMz9fvGnO1kbf2nu+acg9p2R9oYYYk= +sigs.k8s.io/controller-runtime v0.17.3/go.mod h1:N0jpP5Lo7lMTF9aL56Z/B2oWBJjey6StQM0jRbKQXtY= sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd h1:EDPBXCAspyGV4jQlpZSudPeMmr1bNJefnuqLsRAsHZo= sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd/go.mod h1:B8JuhiUyNFVKdsE8h686QcCxMaH6HrOAZj4vswFpcB0= -sigs.k8s.io/kustomize/api v0.16.0 h1:/zAR4FOQDCkgSDmVzV2uiFbuy9bhu3jEzthrHCuvm1g= -sigs.k8s.io/kustomize/api v0.16.0/go.mod h1:MnFZ7IP2YqVyVwMWoRxPtgl/5hpA+eCCrQR/866cm5c= -sigs.k8s.io/kustomize/kyaml v0.16.0 h1:6J33uKSoATlKZH16unr2XOhDI+otoe2sR3M8PDzW3K0= -sigs.k8s.io/kustomize/kyaml v0.16.0/go.mod h1:xOK/7i+vmE14N2FdFyugIshB8eF6ALpy7jI87Q2nRh4= -sigs.k8s.io/release-utils v0.7.7/go.mod h1:iU7DGVNi3umZJ8q6aHyUFzsDUIaYwNnNKGHo3YE5E3s= +sigs.k8s.io/kustomize/api v0.17.1 h1:MYJBOP/yQ3/5tp4/sf6HiiMfNNyO97LmtnirH9SLNr4= +sigs.k8s.io/kustomize/api v0.17.1/go.mod h1:ffn5491s2EiNrJSmgqcWGzQUVhc/pB0OKNI0HsT/0tA= +sigs.k8s.io/kustomize/kyaml v0.17.0 h1:G2bWs03V9Ur2PinHLzTUJ8Ded+30SzXZKiO92SRDs3c= +sigs.k8s.io/kustomize/kyaml v0.17.0/go.mod h1:6lxkYF1Cv9Ic8g/N7I86cvxNc5iinUo/P2vKsHNmpyE= sigs.k8s.io/structured-merge-diff/v4 v4.4.1 h1:150L+0vs/8DA78h1u02ooW1/fFq/Lwr+sGiqlzvrtq4= sigs.k8s.io/structured-merge-diff/v4 v4.4.1/go.mod h1:N8hJocpFajUSSeSJ9bOZ77VzejKZaXsTtZo4/u7Io08= sigs.k8s.io/yaml v1.2.0/go.mod h1:yfXDCHCao9+ENCvLSE62v9VSji2MKu5jeNfTrofGhJc= sigs.k8s.io/yaml v1.4.0 h1:Mk1wCc2gy/F0THH0TAp1QYyJNzRm2KCLy3o5ASXVI5E= sigs.k8s.io/yaml v1.4.0/go.mod h1:Ejl7/uTz7PSA4eKMyQCUTnhZYNmLIl+5c2lQPGR2BPY= -tags.cncf.io/container-device-interface v0.6.2/go.mod h1:Shusyhjs1A5Na/kqPVLL0KqnHQHuunol9LFeUNkuGVE= -tags.cncf.io/container-device-interface/specs-go v0.6.0/go.mod h1:hMAwAbMZyBLdmYqWgYcKH0F/yctNpV3P35f+/088A80= diff --git a/pkg/cred/cred.go b/pkg/cred/cred.go new file mode 100644 index 00000000..fbf419b2 --- /dev/null +++ b/pkg/cred/cred.go @@ -0,0 +1,24 @@ +package cred + +import ( + "fmt" + "github.com/Azure/azure-sdk-for-go/sdk/azidentity" +) + +var ( + cred *azidentity.DefaultAzureCredential +) + +func GetCred() (*azidentity.DefaultAzureCredential, error) { + if cred != nil { + return cred, nil + } + + var err error + cred, err = azidentity.NewDefaultAzureCredential(nil) + if err != nil { + return nil, fmt.Errorf("authenticating to Azure: %w", err) + } + + return cred, nil +} diff --git a/pkg/languages/defaults/python_test.go b/pkg/languages/defaults/python_test.go index 996f776e..93d324b4 100644 --- a/pkg/languages/defaults/python_test.go +++ b/pkg/languages/defaults/python_test.go @@ -54,15 +54,15 @@ func TestPythonExtractor_ReadDefaults(t *testing.T) { { name: "extract first python file as entrypoint", args: args{ - r: reporeader.FakeRepoReader{ + r: reporeader.FakeRepoReader{ // maps order isn't defined but FakeRepoReader sorts the keys Files: map[string][]byte{ - "foo.py": []byte("print('hello world')"), "bar.py": []byte("print('hello world')"), + "foo.py": []byte("print('hello world')"), }, }, }, want: map[string]string{ - "ENTRYPOINT": "foo.py", + "ENTRYPOINT": "bar.py", }, wantErr: false, }, diff --git a/pkg/providers/az-client.go b/pkg/providers/az-client.go new file mode 100644 index 00000000..0c483435 --- /dev/null +++ b/pkg/providers/az-client.go @@ -0,0 +1,45 @@ +package providers + +import ( + "context" + "errors" + "fmt" + "github.com/Azure/azure-sdk-for-go/sdk/azcore/runtime" + "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/subscription/armsubscription" + msgraph "github.com/microsoftgraph/msgraph-sdk-go" +) + +type AzClient struct { + AzTenantClient azTenantClient + GraphClient GraphClient +} + +//go:generate mockgen -source=./az-client.go -destination=./mock/az-client.go . +type azTenantClient interface { + NewListPager(options *armsubscription.TenantsClientListOptions) *runtime.Pager[armsubscription.TenantsClientListResponse] +} + +// GraphServiceClient implements the GraphClient interface. +type GraphServiceClient struct { + Client *msgraph.GraphServiceClient +} + +type GraphClient interface { + GetApplicationObjectId(ctx context.Context, appId string) (string, error) +} + +var _ GraphClient = &GraphServiceClient{} + +func (g *GraphServiceClient) GetApplicationObjectId(ctx context.Context, appId string) (string, error) { + req := g.Client.Applications().ByApplicationId(appId) + + app, err := req.Get(ctx, nil) + if err != nil { + return "", fmt.Errorf("getting application details: %w", err) + } + appObjectId := app.GetAppId() + if appObjectId == nil || *appObjectId == "" { + return "", errors.New("application object ID is empty") + } + return *appObjectId, nil +} diff --git a/pkg/providers/azure.go b/pkg/providers/azure.go index 99de537b..d1f3affd 100644 --- a/pkg/providers/azure.go +++ b/pkg/providers/azure.go @@ -1,9 +1,11 @@ package providers import ( + "context" "encoding/json" "errors" "fmt" + "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/subscription/armsubscription" "os/exec" "time" @@ -23,9 +25,10 @@ type SetUpCmd struct { tenantId string appObjectId string spObjectId string + AzClient AzClient } -func InitiateAzureOIDCFlow(sc *SetUpCmd, s spinner.Spinner) error { +func InitiateAzureOIDCFlow(ctx context.Context, sc *SetUpCmd, s spinner.Spinner) error { log.Debug("Commencing github connection with azure...") if !HasGhCli() || !IsLoggedInToGh() { @@ -50,11 +53,11 @@ func InitiateAzureOIDCFlow(sc *SetUpCmd, s spinner.Spinner) error { return err } - if err := sc.getTenantId(); err != nil { + if err := sc.getTenantId(ctx); err != nil { return err } - if err := sc.getAppObjectId(); err != nil { + if err := sc.getAppObjectId(ctx); err != nil { return err } @@ -176,26 +179,50 @@ func (sc *SetUpCmd) assignSpRole() error { return nil } -func (sc *SetUpCmd) getTenantId() error { - log.Debug("Fetching Azure account tenant ID") - getTenantIdCmd := exec.Command("az", "account", "show", "--query", "tenantId", "--only-show-errors") - out, err := getTenantIdCmd.CombinedOutput() +func (sc *SetUpCmd) getTenantId(ctx context.Context) error { + log.Debug("getting Azure tenant ID") + + tenants, err := sc.listTenants(ctx) if err != nil { - log.Printf("%s\n", out) - return err + return fmt.Errorf("listing tenants: %w", err) } - var tenantId string - if err := json.Unmarshal(out, &tenantId); err != nil { - return err + if len(tenants) == 0 { + return errors.New("no tenants found") } - tenantId = fmt.Sprint(tenantId) - - sc.tenantId = tenantId + if len(tenants) > 1 { + return errors.New("multiple tenants found") + } + sc.tenantId = *tenants[0].TenantID return nil } +func (sc *SetUpCmd) listTenants(ctx context.Context) ([]armsubscription.TenantIDDescription, error) { + log.Debug("listing Azure subscriptions") + + var tenants []armsubscription.TenantIDDescription + + pager := sc.AzClient.AzTenantClient.NewListPager(nil) + + for pager.More() { + page, err := pager.NextPage(ctx) + if err != nil { + return nil, fmt.Errorf("listing tenants page: %w", err) + } + + for _, t := range page.Value { + if t == nil { + return nil, errors.New("nil tenant") // this should never happen but it's good to check just in case + } + tenants = append(tenants, *t) + } + } + + log.Debug("finished listing Azure tenants") + return tenants, nil +} + func (sc *SetUpCmd) ValidateSetUpConfig() error { log.Debug("Checking that provided information is valid...") @@ -284,21 +311,15 @@ func (sc *SetUpCmd) createFederatedCredentials() error { } -func (sc *SetUpCmd) getAppObjectId() error { +func (sc *SetUpCmd) getAppObjectId(ctx context.Context) error { log.Debug("Fetching Azure application object ID") - getObjectIdCmd := exec.Command("az", "ad", "app", "show", "--only-show-errors", "--id", sc.appId, "--query", "id") - out, err := getObjectIdCmd.CombinedOutput() - if err != nil { - log.Printf("%s\n", out) - return err - } - var objectId string - if err := json.Unmarshal(out, &objectId); err != nil { - return err + appID, err := sc.AzClient.GraphClient.GetApplicationObjectId(ctx, sc.appId) + if err != nil { + return fmt.Errorf("getting application object Id: %w", err) } - sc.appObjectId = objectId + sc.appObjectId = appID return nil } diff --git a/pkg/providers/azure_test.go b/pkg/providers/azure_test.go new file mode 100644 index 00000000..6cc3c284 --- /dev/null +++ b/pkg/providers/azure_test.go @@ -0,0 +1,245 @@ +package providers + +import ( + "context" + "errors" + "github.com/Azure/azure-sdk-for-go/sdk/azcore/runtime" + "github.com/Azure/azure-sdk-for-go/sdk/azcore/tracing" + "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/subscription/armsubscription" + mock_providers "github.com/Azure/draft/pkg/providers/mock" + "go.uber.org/mock/gomock" + "strings" + "testing" +) + +func setupMockClientAndPager(ctrl *gomock.Controller, responses []armsubscription.TenantsClientListResponse) *mock_providers.MockazTenantClient { + mockClient := mock_providers.NewMockazTenantClient(ctrl) + + // Define a minimal paging handler function that returns the provided responses + mockPagerHandler := runtime.PagingHandler[armsubscription.TenantsClientListResponse]{ + More: func(t armsubscription.TenantsClientListResponse) bool { return false }, + Fetcher: func(ctx context.Context, response *armsubscription.TenantsClientListResponse) (armsubscription.TenantsClientListResponse, error) { + if len(responses) == 0 { + return armsubscription.TenantsClientListResponse{}, nil + } + resp := responses[0] + responses = responses[1:] + return resp, nil + }, + Tracer: tracing.Tracer{}, + } + + // Create a mock pager with the paging handler + mockPager := runtime.NewPager[armsubscription.TenantsClientListResponse](mockPagerHandler) + + mockClient.EXPECT().NewListPager(gomock.Nil()).Return(mockPager).Times(1) + + return mockClient +} + +func TestGetTenantId(t *testing.T) { + ctrl := gomock.NewController(t) + defer ctrl.Finish() + + // Define test data + testId := "00000000-0000-0000-0000-000000000000" + testTenantId := "/tenants/00000000-0000-0000-0000-000000000000" + testNextLink := "https://pkg.go.dev/github.com" + testTenantDesc := armsubscription.TenantIDDescription{ID: &testId, TenantID: &testTenantId} + testTenantDescArray := []*armsubscription.TenantIDDescription{&testTenantDesc} + testTenantListResult := armsubscription.TenantListResult{NextLink: &testNextLink, Value: testTenantDescArray} + responses := []armsubscription.TenantsClientListResponse{{testTenantListResult}} + + mockClient := setupMockClientAndPager(ctrl, responses) + + sc := &SetUpCmd{ + AzClient: AzClient{ + AzTenantClient: mockClient, + }, + } + + err := sc.getTenantId(context.Background()) + + if err != nil { + t.Errorf("Unexpected error: %v", err) + } +} + +// Test case for the getTenantId function when listing tenants encounters an error +func TestGetTenantId_ListTenantsError(t *testing.T) { + ctrl := gomock.NewController(t) + defer ctrl.Finish() + + // Setup mock client and pager to return an error when listing tenants + mockClient := mock_providers.NewMockazTenantClient(ctrl) + mockPager := runtime.NewPager[armsubscription.TenantsClientListResponse](runtime.PagingHandler[armsubscription.TenantsClientListResponse]{ + More: func(t armsubscription.TenantsClientListResponse) bool { return false }, + Fetcher: func(ctx context.Context, response *armsubscription.TenantsClientListResponse) (armsubscription.TenantsClientListResponse, error) { + return armsubscription.TenantsClientListResponse{}, errors.New("error listing tenants") + }, + Tracer: tracing.Tracer{}, + }) + mockClient.EXPECT().NewListPager(gomock.Nil()).Return(mockPager).Times(1) + + sc := &SetUpCmd{ + AzClient: AzClient{ + AzTenantClient: mockClient, + }, + } + + err := sc.getTenantId(context.Background()) + + if err == nil || !strings.Contains(err.Error(), "error listing tenants") { + t.Errorf("Expected error listing tenants, got: %v", err) + } +} + +// Test case for the getTenantId function when tenant list is empty +func TestGetTenantId_EmptyTenantList(t *testing.T) { + ctrl := gomock.NewController(t) + defer ctrl.Finish() + + // Setup mock client and pager with no responses + mockClient := setupMockClientAndPager(ctrl, []armsubscription.TenantsClientListResponse{}) + + sc := &SetUpCmd{ + AzClient: AzClient{ + AzTenantClient: mockClient, + }, + } + + err := sc.getTenantId(context.Background()) + + if err == nil || !strings.Contains(err.Error(), "no tenants found") { + t.Errorf("Expected error no tenants found, got: %v", err) + } +} + +// Test case for the getTenantId function when a nil tenant is encountered in the list +func TestGetTenantId_NilTenantInList(t *testing.T) { + ctrl := gomock.NewController(t) + defer ctrl.Finish() + + // Define test data with a nil tenant in the list + testTenantDescArray := []*armsubscription.TenantIDDescription{nil} + + mockClient := setupMockClientAndPager(ctrl, []armsubscription.TenantsClientListResponse{{TenantListResult: armsubscription.TenantListResult{Value: testTenantDescArray}}}) + + sc := &SetUpCmd{ + AzClient: AzClient{ + AzTenantClient: mockClient, + }, + } + + err := sc.getTenantId(context.Background()) + + if err == nil || !strings.Contains(err.Error(), "nil tenant") { + t.Errorf("Expected error nil tenant, got: %v", err) + } +} + +func TestGetAppObjectId(t *testing.T) { + ctrl := gomock.NewController(t) + defer ctrl.Finish() + + mockGraphClient := mock_providers.NewMockGraphClient(ctrl) + + appID := "testAppID" + expectedAppID := "mockAppID" + mockGraphClient.EXPECT().GetApplicationObjectId(gomock.Any(), appID).Return(expectedAppID, nil) + + sc := &SetUpCmd{ + appId: appID, + AzClient: AzClient{ + GraphClient: mockGraphClient, + }, + } + + err := sc.getAppObjectId(context.Background()) + + if err != nil { + t.Errorf("Expected no error, got: %v", err) + } + if sc.appObjectId != expectedAppID { + t.Errorf("Expected application ID %s, got: %s", expectedAppID, sc.appObjectId) + } +} + +func TestGetAppObjectId_Error(t *testing.T) { + ctrl := gomock.NewController(t) + defer ctrl.Finish() + + mockGraphClient := mock_providers.NewMockGraphClient(ctrl) + + appID := "testAppID" + expectedError := errors.New("mock error") + mockGraphClient.EXPECT().GetApplicationObjectId(gomock.Any(), appID).Return("", expectedError) + + sc := &SetUpCmd{ + appId: appID, + AzClient: AzClient{ + GraphClient: mockGraphClient, + }, + } + + err := sc.getAppObjectId(context.Background()) + + if err == nil { + t.Error("Expected an error, got nil") + } +} + +// Test case - when the GraphClient returns an error +func TestGetAppObjectId_ErrorFromGraphClient(t *testing.T) { + ctrl := gomock.NewController(t) + defer ctrl.Finish() + + mockGraphClient := mock_providers.NewMockGraphClient(ctrl) + + appID := "testAppID" + expectedError := errors.New("mock error") + mockGraphClient.EXPECT().GetApplicationObjectId(gomock.Any(), appID).Return("", expectedError) + + sc := &SetUpCmd{ + appId: appID, + AzClient: AzClient{ + GraphClient: mockGraphClient, + }, + } + + err := sc.getAppObjectId(context.Background()) + if err == nil { + t.Error("Expected an error, got nil") + } + expectedErrorMsg := "getting application object Id: mock error" + if err.Error() != expectedErrorMsg { + t.Errorf("Expected error message '%s', got '%s'", expectedErrorMsg, err.Error()) + } +} + +// Test case - when the GraphClient returns an empty application ID: +func TestGetAppObjectId_EmptyAppIdFromGraphClient(t *testing.T) { + ctrl := gomock.NewController(t) + defer ctrl.Finish() + + mockGraphClient := mock_providers.NewMockGraphClient(ctrl) + + appID := "testAppID" + expectedError := errors.New("application object ID is empty") + mockGraphClient.EXPECT().GetApplicationObjectId(gomock.Any(), appID).Return("", expectedError) + + sc := &SetUpCmd{ + appId: appID, + AzClient: AzClient{ + GraphClient: mockGraphClient, + }, + } + + err := sc.getAppObjectId(context.Background()) + + if err == nil { + t.Error("Expected an error, got nil") + } else if !strings.Contains(err.Error(), expectedError.Error()) { + t.Errorf("Expected error '%v', got '%v'", expectedError, err) + } +} diff --git a/pkg/providers/mock/az-client.go b/pkg/providers/mock/az-client.go new file mode 100644 index 00000000..bcf69751 --- /dev/null +++ b/pkg/providers/mock/az-client.go @@ -0,0 +1,94 @@ +// Code generated by MockGen. DO NOT EDIT. +// Source: ./az-client.go +// +// Generated by this command: +// +// mockgen -source=./az-client.go -destination=./mock/az-client.go . +// + +// Package mock_providers is a generated GoMock package. +package mock_providers + +import ( + context "context" + reflect "reflect" + + runtime "github.com/Azure/azure-sdk-for-go/sdk/azcore/runtime" + armsubscription "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/subscription/armsubscription" + gomock "go.uber.org/mock/gomock" +) + +// MockazTenantClient is a mock of azTenantClient interface. +type MockazTenantClient struct { + ctrl *gomock.Controller + recorder *MockazTenantClientMockRecorder +} + +// MockazTenantClientMockRecorder is the mock recorder for MockazTenantClient. +type MockazTenantClientMockRecorder struct { + mock *MockazTenantClient +} + +// NewMockazTenantClient creates a new mock instance. +func NewMockazTenantClient(ctrl *gomock.Controller) *MockazTenantClient { + mock := &MockazTenantClient{ctrl: ctrl} + mock.recorder = &MockazTenantClientMockRecorder{mock} + return mock +} + +// EXPECT returns an object that allows the caller to indicate expected use. +func (m *MockazTenantClient) EXPECT() *MockazTenantClientMockRecorder { + return m.recorder +} + +// NewListPager mocks base method. +func (m *MockazTenantClient) NewListPager(options *armsubscription.TenantsClientListOptions) *runtime.Pager[armsubscription.TenantsClientListResponse] { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "NewListPager", options) + ret0, _ := ret[0].(*runtime.Pager[armsubscription.TenantsClientListResponse]) + return ret0 +} + +// NewListPager indicates an expected call of NewListPager. +func (mr *MockazTenantClientMockRecorder) NewListPager(options any) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewListPager", reflect.TypeOf((*MockazTenantClient)(nil).NewListPager), options) +} + +// MockGraphClient is a mock of GraphClient interface. +type MockGraphClient struct { + ctrl *gomock.Controller + recorder *MockGraphClientMockRecorder +} + +// MockGraphClientMockRecorder is the mock recorder for MockGraphClient. +type MockGraphClientMockRecorder struct { + mock *MockGraphClient +} + +// NewMockGraphClient creates a new mock instance. +func NewMockGraphClient(ctrl *gomock.Controller) *MockGraphClient { + mock := &MockGraphClient{ctrl: ctrl} + mock.recorder = &MockGraphClientMockRecorder{mock} + return mock +} + +// EXPECT returns an object that allows the caller to indicate expected use. +func (m *MockGraphClient) EXPECT() *MockGraphClientMockRecorder { + return m.recorder +} + +// GetApplicationObjectId mocks base method. +func (m *MockGraphClient) GetApplicationObjectId(ctx context.Context, appId string) (string, error) { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "GetApplicationObjectId", ctx, appId) + ret0, _ := ret[0].(string) + ret1, _ := ret[1].(error) + return ret0, ret1 +} + +// GetApplicationObjectId indicates an expected call of GetApplicationObjectId. +func (mr *MockGraphClientMockRecorder) GetApplicationObjectId(ctx, appId any) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetApplicationObjectId", reflect.TypeOf((*MockGraphClient)(nil).GetApplicationObjectId), ctx, appId) +} diff --git a/pkg/reporeader/reporeader.go b/pkg/reporeader/reporeader.go index ffab238f..b8447601 100644 --- a/pkg/reporeader/reporeader.go +++ b/pkg/reporeader/reporeader.go @@ -2,6 +2,7 @@ package reporeader import ( "path/filepath" + "sort" "strings" ) @@ -55,15 +56,23 @@ func (r FakeRepoReader) FindFiles(path string, patterns []string, maxDepth int) if r.Files == nil { return files, nil } + + // sort files because map iteration order is undefined. lets us control test behavior + sortedFiles := make([]string, 0, len(r.Files)) for k := range r.Files { + sortedFiles = append(sortedFiles, k) + } + sort.Strings(sortedFiles) + + for _, file := range sortedFiles { for _, pattern := range patterns { - if matched, err := filepath.Match(pattern, filepath.Base(k)); err != nil { + if matched, err := filepath.Match(pattern, filepath.Base(file)); err != nil { return nil, err } else if matched { - splitPath := strings.Split(k, string(filepath.Separator)) + splitPath := strings.Split(file, string(filepath.Separator)) fileDepth := len(splitPath) - 1 if fileDepth <= maxDepth { - files = append(files, k) + files = append(files, file) } } } diff --git a/pkg/safeguards/safeguards_constants.go b/pkg/safeguards/constants.go similarity index 93% rename from pkg/safeguards/safeguards_constants.go rename to pkg/safeguards/constants.go index a65ef235..6b816991 100644 --- a/pkg/safeguards/safeguards_constants.go +++ b/pkg/safeguards/constants.go @@ -7,12 +7,13 @@ import ( const ( Constraint_CAI = "container-allowed-images" Constraint_CEP = "container-enforce-probes" - Constraint_CL = "container-resource-limits" + Constraint_CRL = "container-resource-limits" Constraint_CRIP = "container-restricted-image-pulls" Constraint_DBPDB = "disallowed-bad-pod-disruption-budgets" Constraint_PEA = "pod-enforce-antiaffinity" Constraint_RT = "restricted-taints" Constraint_USS = "unique-service-selectors" + Constraint_all = "all" ) var selectedVersion = "v1.0.0" @@ -37,9 +38,9 @@ var safeguards = []Safeguard{ constraintPath: fmt.Sprintf("lib/%s/%s/%s", selectedVersion, Constraint_CEP, constraintFileName), }, { - name: Constraint_CL, - templatePath: fmt.Sprintf("lib/%s/%s/%s", selectedVersion, Constraint_CL, templateFileName), - constraintPath: fmt.Sprintf("lib/%s/%s/%s", selectedVersion, Constraint_CL, constraintFileName), + name: Constraint_CRL, + templatePath: fmt.Sprintf("lib/%s/%s/%s", selectedVersion, Constraint_CRL, templateFileName), + constraintPath: fmt.Sprintf("lib/%s/%s/%s", selectedVersion, Constraint_CRL, constraintFileName), }, { name: Constraint_CRIP, diff --git a/pkg/safeguards/safeguards_test_constants.go b/pkg/safeguards/constants_test.go similarity index 75% rename from pkg/safeguards/safeguards_test_constants.go rename to pkg/safeguards/constants_test.go index 13d9f6b5..dca381c7 100644 --- a/pkg/safeguards/safeguards_test_constants.go +++ b/pkg/safeguards/constants_test.go @@ -42,14 +42,14 @@ var testManifest_CEP = TestManifest{ ErrorPaths: []string{testError_CEP_Standard}, } -var testError_CL_Standard = fmt.Sprintf("%s/%s/%s", testManifestDirectory, Constraint_CL, "CL-error-manifest.yaml") +var testError_CRL_Standard = fmt.Sprintf("%s/%s/%s", testManifestDirectory, Constraint_CRL, "CRL-error-manifest.yaml") -var testSuccess_CL_Standard = fmt.Sprintf("%s/%s/%s", testManifestDirectory, Constraint_CL, "CL-success-manifest.yaml") +var testSuccess_CRL_Standard = fmt.Sprintf("%s/%s/%s", testManifestDirectory, Constraint_CRL, "CRL-success-manifest.yaml") var testManifest_CL = TestManifest{ - Name: Constraint_CL, - SuccessPaths: []string{testSuccess_CL_Standard}, - ErrorPaths: []string{testError_CL_Standard}, + Name: Constraint_CRL, + SuccessPaths: []string{testSuccess_CRL_Standard}, + ErrorPaths: []string{testError_CRL_Standard}, } var testError_CRIP_Standard = fmt.Sprintf("%s/%s/%s", testManifestDirectory, Constraint_CRIP, "CRIP-error-manifest.yaml") @@ -102,11 +102,13 @@ var testManifest_USS = TestManifest{ ErrorPaths: []string{testError_USS_Standard}, } -var testError_all_Standard = fmt.Sprintf("%s/%s/%s", testManifestDirectory, Constraint_USS, "all-error-manifest.yaml") -var testSuccess_all_Standard = fmt.Sprintf("%s/%s/%s", testManifestDirectory, Constraint_USS, "all-error-manifest.yaml") +var testError_all_Standard_1 = fmt.Sprintf("%s/%s/%s/%s", testManifestDirectory, Constraint_all, "error", "all-error-manifest-1.yaml") +var testError_all_Standard_2 = fmt.Sprintf("%s/%s/%s/%s", testManifestDirectory, Constraint_all, "error", "all-error-manifest-2.yaml") +var testSuccess_all_Standard_1 = fmt.Sprintf("%s/%s/%s/%s", testManifestDirectory, Constraint_all, "success", "all-success-manifest-1.yaml") +var testSuccess_all_Standard_2 = fmt.Sprintf("%s/%s/%s/%s", testManifestDirectory, Constraint_all, "success", "all-success-manifest-2.yaml") var testManifest_all = TestManifest{ Name: "all", - SuccessPaths: []string{testSuccess_all_Standard}, - ErrorPaths: []string{testError_all_Standard}, + SuccessPaths: []string{testSuccess_all_Standard_1, testSuccess_all_Standard_2}, + ErrorPaths: []string{testError_all_Standard_1, testError_all_Standard_2}, } diff --git a/pkg/safeguards/safeguards_helpers.go b/pkg/safeguards/helpers.go similarity index 77% rename from pkg/safeguards/safeguards_helpers.go rename to pkg/safeguards/helpers.go index c5d49629..4c81e9a2 100644 --- a/pkg/safeguards/safeguards_helpers.go +++ b/pkg/safeguards/helpers.go @@ -4,7 +4,9 @@ import ( "bufio" "context" "fmt" + "io/fs" "os" + "path/filepath" constraintclient "github.com/open-policy-agent/frameworks/constraint/pkg/client" "github.com/open-policy-agent/frameworks/constraint/pkg/client/drivers/rego" @@ -172,20 +174,76 @@ func loadManifestObjects(ctx context.Context, c *constraintclient.Client, object return nil } +// IsDirectory determines if a file represented by path is a directory or not +func IsDirectory(path string) (bool, error) { + fileInfo, err := os.Stat(path) + if err != nil { + return false, err + } + + return fileInfo.IsDir(), nil +} + +// IsYAML determines if a file is of the YAML extension or not +func IsYAML(path string) bool { + return filepath.Ext(path) == ".yaml" || filepath.Ext(path) == ".yml" +} + +// GetManifestFiles uses filepath.Walk to retrieve a list of the manifest files within the given manifest path +func GetManifestFiles(p string) ([]ManifestFile, error) { + var manifestFiles []ManifestFile + + noYamlFiles := true + err := filepath.Walk(p, func(walkPath string, info fs.FileInfo, err error) error { + manifest := ManifestFile{} + // skip when walkPath is just given path and also a directory + if p == walkPath && info.IsDir() { + return nil + } + + if err != nil { + return fmt.Errorf("error walking path %s with error: %w", walkPath, err) + } + + if !info.IsDir() && info.Name() != "" && IsYAML(walkPath) { + log.Debugf("%s is not a directory, appending to manifestFiles", info.Name()) + noYamlFiles = false + + manifest.Name = info.Name() + manifest.Path = walkPath + manifestFiles = append(manifestFiles, manifest) + } else if !IsYAML(p) { + log.Debugf("%s is not a manifest file, skipping...", info.Name()) + } else { + log.Debugf("%s is a directory, skipping...", info.Name()) + } + + return nil + }) + if err != nil { + return nil, fmt.Errorf("could not walk directory: %w", err) + } + if noYamlFiles { + return nil, fmt.Errorf("no manifest files found within given path") + } + + return manifestFiles, nil +} + // getObjectViolations executes validation on manifests based on loaded constraint templates and returns a map of manifest name to list of objectViolations func getObjectViolations(ctx context.Context, c *constraintclient.Client, objects []*unstructured.Unstructured) (map[string][]string, error) { // Review makes sure the provided object satisfies all stored constraints. // On error, the responses return value will still be populated so that // partial results can be analyzed. - var violations = make(map[string][]string) // map of object name to slice of objectViolations + var results = make(map[string][]string) // map of object name to slice of objectViolations for _, o := range objects { objectViolations := []string{} log.Debugf("Reviewing %s...", o.GetName()) res, err := c.Review(ctx, o) if err != nil { - return violations, fmt.Errorf("could not review objects: %w", err) + return results, fmt.Errorf("could not review objects: %w", err) } for _, v := range res.ByTarget { @@ -197,9 +255,9 @@ func getObjectViolations(ctx context.Context, c *constraintclient.Client, object } if len(objectViolations) > 0 { - violations[o.GetName()] = objectViolations + results[o.GetName()] = objectViolations } } - return violations, nil + return results, nil } diff --git a/pkg/safeguards/helpers_test.go b/pkg/safeguards/helpers_test.go new file mode 100644 index 00000000..255b7caa --- /dev/null +++ b/pkg/safeguards/helpers_test.go @@ -0,0 +1,67 @@ +package safeguards + +import ( + "context" + "testing" + + constraintclient "github.com/open-policy-agent/frameworks/constraint/pkg/client" + "github.com/stretchr/testify/assert" +) + +func validateOneTestManifestFail(ctx context.Context, t *testing.T, c *constraintclient.Client, testFc FileCrawler, testManifestPaths []string) { + for _, path := range testManifestPaths { + errManifests, err := testFc.ReadManifests(path) + assert.Nil(t, err) + + err = loadManifestObjects(ctx, c, errManifests) + assert.Nil(t, err) + + // error case - should throw error + violations, err := getObjectViolations(ctx, c, errManifests) + assert.Nil(t, err) + assert.Greater(t, len(violations), 0) + } +} + +func validateOneTestManifestSuccess(ctx context.Context, t *testing.T, c *constraintclient.Client, testFc FileCrawler, testManifestPaths []string) { + for _, path := range testManifestPaths { + successManifests, err := testFc.ReadManifests(path) + assert.Nil(t, err) + + err = loadManifestObjects(ctx, c, successManifests) + assert.Nil(t, err) + + // success case - should not throw error + violations, err := getObjectViolations(ctx, c, successManifests) + assert.Nil(t, err) + assert.Equal(t, 0, len(violations)) + } +} + +func validateAllTestManifestsFail(ctx context.Context, t *testing.T, c *constraintclient.Client, testFc FileCrawler, testManifestPaths []string) { + for _, path := range testManifestPaths { + manifestFiles, err := GetManifestFiles(path) + assert.Nil(t, err) + + // error case - should throw error + results, err := GetManifestResults(ctx, manifestFiles) + for _, mr := range results { + assert.Nil(t, err) + assert.Greater(t, mr.ViolationsCount, 0) + } + } +} + +func validateAllTestManifestsSuccess(ctx context.Context, t *testing.T, c *constraintclient.Client, testFc FileCrawler, testManifestPaths []string) { + for _, path := range testManifestPaths { + manifestFiles, err := GetManifestFiles(path) + assert.Nil(t, err) + + // success case - should not throw error + results, err := GetManifestResults(ctx, manifestFiles) + for _, mr := range results { + assert.Nil(t, err) + assert.Equal(t, mr.ViolationsCount, 0) + } + } +} diff --git a/pkg/safeguards/safeguards.go b/pkg/safeguards/manifestresults.go similarity index 78% rename from pkg/safeguards/safeguards.go rename to pkg/safeguards/manifestresults.go index 0903ef20..ed08a679 100644 --- a/pkg/safeguards/safeguards.go +++ b/pkg/safeguards/manifestresults.go @@ -35,38 +35,38 @@ func init() { } } -// GetManifestViolations takes in a list of manifest files and returns a slice of ManifestViolation structs -func GetManifestViolations(ctx context.Context, manifestFiles []ManifestFile) ([]ManifestViolation, error) { +// GetManifestResults takes in a list of manifest files and returns a slice of ManifestViolation structs +func GetManifestResults(ctx context.Context, manifestFiles []ManifestFile) ([]ManifestResult, error) { if len(manifestFiles) == 0 { return nil, fmt.Errorf("path cannot be empty") } - manifestViolations := make([]ManifestViolation, 0) + manifestResults := make([]ManifestResult, 0) // constraint client instantiation c, err := getConstraintClient() if err != nil { - return manifestViolations, err + return manifestResults, err } // retrieval of templates, constraints, and deployment constraintTemplates, err := fc.ReadConstraintTemplates() if err != nil { - return manifestViolations, err + return manifestResults, err } constraints, err := fc.ReadConstraints() if err != nil { - return manifestViolations, err + return manifestResults, err } // loading of templates, constraints into constraint client err = loadConstraintTemplates(ctx, c, constraintTemplates) if err != nil { - return manifestViolations, err + return manifestResults, err } err = loadConstraints(ctx, c, constraints) if err != nil { - return manifestViolations, err + return manifestResults, err } // organized map of manifest object by file name @@ -77,7 +77,7 @@ func GetManifestViolations(ctx context.Context, manifestFiles []ManifestFile) ([ manifestObjects, err := fc.ReadManifests(m.Path) // read all the objects stored in a single file if err != nil { log.Errorf("reading objects %s", err.Error()) - return manifestViolations, err + return manifestResults, err } allManifestObjects = append(allManifestObjects, manifestObjects...) @@ -95,13 +95,14 @@ func GetManifestViolations(ctx context.Context, manifestFiles []ManifestFile) ([ objectViolations, err = getObjectViolations(ctx, c, manifestMap[m.Name]) if err != nil { log.Errorf("validating objects: %s", err.Error()) - return manifestViolations, err + return manifestResults, err } - manifestViolations = append(manifestViolations, ManifestViolation{ + manifestResults = append(manifestResults, ManifestResult{ Name: m.Name, ObjectViolations: objectViolations, + ViolationsCount: len(objectViolations), }) } - return manifestViolations, nil + return manifestResults, nil } diff --git a/pkg/safeguards/manifestresults_test.go b/pkg/safeguards/manifestresults_test.go new file mode 100644 index 00000000..3f06aaf1 --- /dev/null +++ b/pkg/safeguards/manifestresults_test.go @@ -0,0 +1,239 @@ +package safeguards + +import ( + "context" + "testing" + + "github.com/open-policy-agent/frameworks/constraint/pkg/core/templates" + "github.com/stretchr/testify/assert" + + "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured" +) + +var ctx = context.Background() +var testFc FileCrawler + +func init() { + selectedVersion = getLatestSafeguardsVersion() + updateSafeguardPaths() + + testFc = FileCrawler{ + Safeguards: safeguards, + constraintFS: embedFS, + } +} + +// TestValidateDeployment_ContainerAllowedImages tests our Container Allowed Images manifest +func TestValidateDeployment_ContainerAllowedImages(t *testing.T) { + // instantiate constraint client + c, err := getConstraintClient() + assert.Nil(t, err) + + // retrieving template, constraint, and deployments + constraintTemplate, err := testFc.ReadConstraintTemplate(testManifest_CAI.Name) + assert.Nil(t, err) + constraint, err := testFc.ReadConstraint(testManifest_CAI.Name) + assert.Nil(t, err) + + // load template, constraint into constraint client + err = loadConstraintTemplates(ctx, c, []*templates.ConstraintTemplate{constraintTemplate}) + assert.Nil(t, err) + err = loadConstraints(ctx, c, []*unstructured.Unstructured{constraint}) + assert.Nil(t, err) + + // validating deployment manifests + validateOneTestManifestFail(ctx, t, c, testFc, testManifest_CAI.ErrorPaths) + validateOneTestManifestSuccess(ctx, t, c, testFc, testManifest_CAI.SuccessPaths) +} + +// TestValidateDeployment_ContainerEnforceProbes tests our Container Enforce Probes manifest +func TestValidateDeployment_ContainerEnforceProbes(t *testing.T) { + // instantiate constraint client + c, err := getConstraintClient() + assert.Nil(t, err) + + // retrieving template, constraint, and deployments + constraintTemplate, err := testFc.ReadConstraintTemplate(testManifest_CEP.Name) + assert.Nil(t, err) + constraint, err := testFc.ReadConstraint(testManifest_CEP.Name) + assert.Nil(t, err) + + // load template, constraint into constraint client + err = loadConstraintTemplates(ctx, c, []*templates.ConstraintTemplate{constraintTemplate}) + assert.Nil(t, err) + err = loadConstraints(ctx, c, []*unstructured.Unstructured{constraint}) + assert.Nil(t, err) + + // validating deployment manifests + validateOneTestManifestFail(ctx, t, c, testFc, testManifest_CEP.ErrorPaths) + validateOneTestManifestSuccess(ctx, t, c, testFc, testManifest_CEP.SuccessPaths) +} + +// TestValidateDeployment_ContainerResourceLimits tests our Container Resource Limits manifest +func TestValidateDeployment_ContainerResourceLimits(t *testing.T) { + // instantiate constraint client + c, err := getConstraintClient() + assert.Nil(t, err) + + // retrieving template, constraint, and deployments + constraintTemplate, err := testFc.ReadConstraintTemplate(testManifest_CL.Name) + assert.Nil(t, err) + constraint, err := testFc.ReadConstraint(testManifest_CL.Name) + assert.Nil(t, err) + + // load template, constraint into constraint client + err = loadConstraintTemplates(ctx, c, []*templates.ConstraintTemplate{constraintTemplate}) + assert.Nil(t, err) + err = loadConstraints(ctx, c, []*unstructured.Unstructured{constraint}) + assert.Nil(t, err) + + // validating deployment manifests + validateOneTestManifestFail(ctx, t, c, testFc, testManifest_CL.ErrorPaths) + validateOneTestManifestSuccess(ctx, t, c, testFc, testManifest_CL.SuccessPaths) +} + +// TestValidateDeployment_ContainerRestrictedImagePulls tests our Container Restricted Image Pulls manifest +func TestValidateDeployment_ContainerRestrictedImagePulls(t *testing.T) { + // instantiate constraint client + c, err := getConstraintClient() + assert.Nil(t, err) + + // retrieving template, constraint, and deployments + constraintTemplate, err := testFc.ReadConstraintTemplate(testManifest_CRIP.Name) + assert.Nil(t, err) + constraint, err := testFc.ReadConstraint(testManifest_CRIP.Name) + assert.Nil(t, err) + + // load template, constraint into constraint client + err = loadConstraintTemplates(ctx, c, []*templates.ConstraintTemplate{constraintTemplate}) + assert.Nil(t, err) + err = loadConstraints(ctx, c, []*unstructured.Unstructured{constraint}) + assert.Nil(t, err) + + // validating deployment manifests + validateOneTestManifestFail(ctx, t, c, testFc, testManifest_CRIP.ErrorPaths) + validateOneTestManifestSuccess(ctx, t, c, testFc, testManifest_CRIP.SuccessPaths) +} + +// TestValidateDeployment_DisallowedBadPodDisruptionBudget tests our Disallowed Bad Pod Disruption Budget manifest +func TestValidateDeployment_DisallowedBadPodDisruptionBudget(t *testing.T) { + // instantiate constraint client + c, err := getConstraintClient() + assert.Nil(t, err) + + // retrieving template, constraint, and deployments + constraintTemplate, err := testFc.ReadConstraintTemplate(testManifest_DBPDB.Name) + assert.Nil(t, err) + constraint, err := testFc.ReadConstraint(testManifest_DBPDB.Name) + assert.Nil(t, err) + + // load template, constraint into constraint client + err = loadConstraintTemplates(ctx, c, []*templates.ConstraintTemplate{constraintTemplate}) + assert.Nil(t, err) + err = loadConstraints(ctx, c, []*unstructured.Unstructured{constraint}) + assert.Nil(t, err) + + // validating deployment manifests + validateOneTestManifestFail(ctx, t, c, testFc, testManifest_DBPDB.ErrorPaths) + validateOneTestManifestSuccess(ctx, t, c, testFc, testManifest_DBPDB.SuccessPaths) +} + +// TestValidateDeployment_PodEnforceAntiaffinity tests our Pod Enforce Antiaffinity manifest +func TestValidateDeployment_PodEnforceAntiaffinity(t *testing.T) { + // instantiate constraint client + c, err := getConstraintClient() + assert.Nil(t, err) + + // retrieving template, constraint, and deployments + constraintTemplate, err := testFc.ReadConstraintTemplate(testManifest_PEA.Name) + assert.Nil(t, err) + constraint, err := testFc.ReadConstraint(testManifest_PEA.Name) + assert.Nil(t, err) + + // load template, constraint into constraint client + err = loadConstraintTemplates(ctx, c, []*templates.ConstraintTemplate{constraintTemplate}) + assert.Nil(t, err) + err = loadConstraints(ctx, c, []*unstructured.Unstructured{constraint}) + assert.Nil(t, err) + + // validating deployment manifests + validateOneTestManifestFail(ctx, t, c, testFc, testManifest_PEA.ErrorPaths) + validateOneTestManifestSuccess(ctx, t, c, testFc, testManifest_PEA.SuccessPaths) +} + +// TestValidateDeployment_RestrictedTaints tests our Restricted Taints manifest +func TestValidateDeployment_RestrictedTaints(t *testing.T) { + // instantiate constraint client + c, err := getConstraintClient() + assert.Nil(t, err) + + // retrieving template, constraint, and deployments + constraintTemplate, err := testFc.ReadConstraintTemplate(testManifest_RT.Name) + assert.Nil(t, err) + constraint, err := testFc.ReadConstraint(testManifest_RT.Name) + assert.Nil(t, err) + + // load template, constraint into constraint client + err = loadConstraintTemplates(ctx, c, []*templates.ConstraintTemplate{constraintTemplate}) + assert.Nil(t, err) + err = loadConstraints(ctx, c, []*unstructured.Unstructured{constraint}) + assert.Nil(t, err) + + // validating deployment manifests + validateOneTestManifestFail(ctx, t, c, testFc, testManifest_RT.ErrorPaths) + validateOneTestManifestSuccess(ctx, t, c, testFc, testManifest_RT.SuccessPaths) +} + +// TestValidateDeployment_UniqueServiceSelectors tests our Unique Service Selectors manifest +func TestValidateDeployment_UniqueServiceSelectors(t *testing.T) { + // instantiate constraint client + c, err := getConstraintClient() + assert.Nil(t, err) + + // retrieving template, constraint, and deployments + constraintTemplate, err := testFc.ReadConstraintTemplate(testManifest_USS.Name) + assert.Nil(t, err) + constraint, err := testFc.ReadConstraint(testManifest_USS.Name) + assert.Nil(t, err) + + // load template, constraint into constraint client + err = loadConstraintTemplates(ctx, c, []*templates.ConstraintTemplate{constraintTemplate}) + assert.Nil(t, err) + err = loadConstraints(ctx, c, []*unstructured.Unstructured{constraint}) + assert.Nil(t, err) + + // validating deployment manifests + validateOneTestManifestFail(ctx, t, c, testFc, testManifest_USS.ErrorPaths) + validateOneTestManifestSuccess(ctx, t, c, testFc, testManifest_USS.SuccessPaths) +} + +// TestValidateDeployment_All tests all of our manifests in a few given manifest files +func TestValidateDeployment_All(t *testing.T) { + // instantiate constraint client + c, err := getConstraintClient() + assert.Nil(t, err) + + var testTemplates []*templates.ConstraintTemplate + var testConstraints []*unstructured.Unstructured + for _, sg := range safeguards { + // retrieving template, constraint, and deployments + constraintTemplate, err := testFc.ReadConstraintTemplate(sg.name) + assert.Nil(t, err) + testTemplates = append(testTemplates, constraintTemplate) + + constraint, err := testFc.ReadConstraint(sg.name) + assert.Nil(t, err) + testConstraints = append(testConstraints, constraint) + + } + + // load template, constraint into constraint client + err = loadConstraintTemplates(ctx, c, testTemplates) + assert.Nil(t, err) + err = loadConstraints(ctx, c, testConstraints) + assert.Nil(t, err) + + // validating deployment manifests + validateAllTestManifestsFail(ctx, t, c, testFc, testManifest_all.ErrorPaths) + validateAllTestManifestsSuccess(ctx, t, c, testFc, testManifest_all.SuccessPaths) +} diff --git a/pkg/safeguards/safeguards_test.go b/pkg/safeguards/safeguards_test.go deleted file mode 100644 index 200ac5f6..00000000 --- a/pkg/safeguards/safeguards_test.go +++ /dev/null @@ -1,239 +0,0 @@ -package safeguards - -import ( - "context" - "testing" - - "github.com/open-policy-agent/frameworks/constraint/pkg/core/templates" - "github.com/stretchr/testify/assert" - - "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured" -) - -var ctx = context.Background() -var testFc FileCrawler - -func init() { - selectedVersion = getLatestSafeguardsVersion() - updateSafeguardPaths() - - testFc = FileCrawler{ - Safeguards: safeguards, - constraintFS: embedFS, - } -} - -// TODO: rich description here -func TestValidateDeployment_ContainerAllowedImages(t *testing.T) { - // instantiate constraint client - c, err := getConstraintClient() - assert.Nil(t, err) - - // retrieving template, constraint, and deployments - constraintTemplate, err := testFc.ReadConstraintTemplate(testManifest_CAI.Name) - assert.Nil(t, err) - constraint, err := testFc.ReadConstraint(testManifest_CAI.Name) - assert.Nil(t, err) - - // load template, constraint into constraint client - err = loadConstraintTemplates(ctx, c, []*templates.ConstraintTemplate{constraintTemplate}) - assert.Nil(t, err) - err = loadConstraints(ctx, c, []*unstructured.Unstructured{constraint}) - assert.Nil(t, err) - - // validating deployment manifests - validateTestManifestsFail(ctx, t, c, testFc, testManifest_CAI.ErrorPaths) - validateTestManifestsSuccess(ctx, t, c, testFc, testManifest_CAI.SuccessPaths) -} - -// TODO: rich description here -func TestValidateDeployment_ContainerEnforceProbes(t *testing.T) { - // instantiate constraint client - c, err := getConstraintClient() - assert.Nil(t, err) - - // retrieving template, constraint, and deployments - constraintTemplate, err := testFc.ReadConstraintTemplate(testManifest_CEP.Name) - assert.Nil(t, err) - constraint, err := testFc.ReadConstraint(testManifest_CEP.Name) - assert.Nil(t, err) - - // load template, constraint into constraint client - err = loadConstraintTemplates(ctx, c, []*templates.ConstraintTemplate{constraintTemplate}) - assert.Nil(t, err) - err = loadConstraints(ctx, c, []*unstructured.Unstructured{constraint}) - assert.Nil(t, err) - - // validating deployment manifests - validateTestManifestsFail(ctx, t, c, testFc, testManifest_CEP.ErrorPaths) - validateTestManifestsSuccess(ctx, t, c, testFc, testManifest_CEP.SuccessPaths) -} - -// // TODO: rich description here -func TestValidateDeployment_ContainerLimits(t *testing.T) { - // instantiate constraint client - c, err := getConstraintClient() - assert.Nil(t, err) - - // retrieving template, constraint, and deployments - constraintTemplate, err := testFc.ReadConstraintTemplate(testManifest_CL.Name) - assert.Nil(t, err) - constraint, err := testFc.ReadConstraint(testManifest_CL.Name) - assert.Nil(t, err) - - // load template, constraint into constraint client - err = loadConstraintTemplates(ctx, c, []*templates.ConstraintTemplate{constraintTemplate}) - assert.Nil(t, err) - err = loadConstraints(ctx, c, []*unstructured.Unstructured{constraint}) - assert.Nil(t, err) - - // validating deployment manifests - validateTestManifestsFail(ctx, t, c, testFc, testManifest_CL.ErrorPaths) - validateTestManifestsSuccess(ctx, t, c, testFc, testManifest_CL.SuccessPaths) -} - -//// TODO: rich description here -//func TestValidateDeployment_ContainerRestrictedImagePulls(t *testing.T) { -// // instantiate constraint client -// c, err := getConstraintClient() -// assert.Nil(t, err) -// -// // retrieving template, constraint, and deployments -// constraintTemplate, err := testFc.ReadConstraintTemplate(testManifest_CRIP.Name) -// assert.Nil(t, err) -// constraint, err := testFc.ReadConstraint(testManifest_CRIP.Name) -// assert.Nil(t, err) -// -// // load template, constraint into constraint client -// err = loadConstraintTemplates(ctx, c, []*templates.ConstraintTemplate{constraintTemplate}) -// assert.Nil(t, err) -// err = loadConstraints(ctx, c, []*unstructured.Unstructured{constraint}) -// assert.Nil(t, err) -// -// // validating deployment manifests -// validateTestManifests_Fail(ctx, t, c, testFc, testManifest_CRIP.ErrorPaths) -// validateTestManifests_Success(ctx, t, c, testFc, testManifest_CRIP.SuccessPaths) -//} -// -//// TODO: rich description here -//func TestValidateDeployment_DisallowedBadPodDisruptionBudget(t *testing.T) { -// // instantiate constraint client -// c, err := getConstraintClient() -// assert.Nil(t, err) -// -// // retrieving template, constraint, and deployments -// constraintTemplate, err := testFc.ReadConstraintTemplate(testManifest_DBPDB.Name) -// assert.Nil(t, err) -// constraint, err := testFc.ReadConstraint(testManifest_DBPDB.Name) -// assert.Nil(t, err) -// -// // load template, constraint into constraint client -// err = loadConstraintTemplates(ctx, c, []*templates.ConstraintTemplate{constraintTemplate}) -// assert.Nil(t, err) -// err = loadConstraints(ctx, c, []*unstructured.Unstructured{constraint}) -// assert.Nil(t, err) -// -// // validating deployment manifests -// validateTestManifests_Fail(ctx, t, c, testFc, testManifest_DBPDB.ErrorPaths) -// validateTestManifests_Success(ctx, t, c, testFc, testManifest_DBPDB.SuccessPaths) -//} -// -//// TODO: rich description here -//func TestValidateDeployment_PodEnforceAntiaffinity(t *testing.T) { -// // instantiate constraint client -// c, err := getConstraintClient() -// assert.Nil(t, err) -// -// // retrieving template, constraint, and deployments -// constraintTemplate, err := testFc.ReadConstraintTemplate(testManifest_PEA.Name) -// assert.Nil(t, err) -// constraint, err := testFc.ReadConstraint(testManifest_PEA.Name) -// assert.Nil(t, err) -// -// // load template, constraint into constraint client -// err = loadConstraintTemplates(ctx, c, []*templates.ConstraintTemplate{constraintTemplate}) -// assert.Nil(t, err) -// err = loadConstraints(ctx, c, []*unstructured.Unstructured{constraint}) -// assert.Nil(t, err) -// -// // validating deployment manifests -// validateTestManifests_Fail(ctx, t, c, testFc, testManifest_PEA.ErrorPaths) -// validateTestManifests_Success(ctx, t, c, testFc, testManifest_PEA.SuccessPaths) -//} -// -//// TODO: rich description here -//func TestValidateDeployment_RestrictedTaints(t *testing.T) { -// // instantiate constraint client -// c, err := getConstraintClient() -// assert.Nil(t, err) -// -// // retrieving template, constraint, and deployments -// constraintTemplate, err := testFc.ReadConstraintTemplate(testManifest_RT.Name) -// assert.Nil(t, err) -// constraint, err := testFc.ReadConstraint(testManifest_RT.Name) -// assert.Nil(t, err) -// -// // load template, constraint into constraint client -// err = loadConstraintTemplates(ctx, c, []*templates.ConstraintTemplate{constraintTemplate}) -// assert.Nil(t, err) -// err = loadConstraints(ctx, c, []*unstructured.Unstructured{constraint}) -// assert.Nil(t, err) -// -// // validating deployment manifests -// validateTestManifests_Fail(ctx, t, c, testFc, testManifest_RT.ErrorPaths) -// validateTestManifests_Success(ctx, t, c, testFc, testManifest_RT.SuccessPaths) -//} - -// TODO: rich description here -func TestValidateDeployment_UniqueServiceSelectors(t *testing.T) { - // instantiate constraint client - c, err := getConstraintClient() - assert.Nil(t, err) - - // retrieving template, constraint, and deployments - constraintTemplate, err := testFc.ReadConstraintTemplate(testManifest_USS.Name) - assert.Nil(t, err) - constraint, err := testFc.ReadConstraint(testManifest_USS.Name) - assert.Nil(t, err) - - // load template, constraint into constraint client - err = loadConstraintTemplates(ctx, c, []*templates.ConstraintTemplate{constraintTemplate}) - assert.Nil(t, err) - err = loadConstraints(ctx, c, []*unstructured.Unstructured{constraint}) - assert.Nil(t, err) - - // validating deployment manifests - validateTestManifestsFail(ctx, t, c, testFc, testManifest_USS.ErrorPaths) - validateTestManifestsSuccess(ctx, t, c, testFc, testManifest_USS.SuccessPaths) -} - -//// TODO: rich description here -//func TestValidateDeployment_All(t *testing.T) { -// // instantiate constraint client -// c, err := getConstraintClient() -// assert.Nil(t, err) -// -// var testTemplates []*templates.ConstraintTemplate -// var testConstraints []*unstructured.Unstructured -// for _, sg := range safeguards { -// // retrieving template, constraint, and deployments -// constraintTemplate, err := testFc.ReadConstraintTemplate(sg.name) -// assert.Nil(t, err) -// testTemplates = append(testTemplates, constraintTemplate) -// -// constraint, err := testFc.ReadConstraint(sg.name) -// assert.Nil(t, err) -// testConstraints = append(testConstraints, constraint) -// -// } -// -// // load template, constraint into constraint client -// err = loadConstraintTemplates(ctx, c, testTemplates) -// assert.Nil(t, err) -// err = loadConstraints(ctx, c, testConstraints) -// assert.Nil(t, err) -// -// // validating deployment manifests -// validateTestManifests_Fail(ctx, t, c, testFc, testManifest_all.ErrorPaths) -// validateTestManifests_Success(ctx, t, c, testFc, testManifest_all.SuccessPaths) -//} diff --git a/pkg/safeguards/safeguards_test_helpers.go b/pkg/safeguards/safeguards_test_helpers.go deleted file mode 100644 index 598c53ae..00000000 --- a/pkg/safeguards/safeguards_test_helpers.go +++ /dev/null @@ -1,39 +0,0 @@ -package safeguards - -import ( - "context" - "testing" - - constraintclient "github.com/open-policy-agent/frameworks/constraint/pkg/client" - "github.com/stretchr/testify/assert" -) - -func validateTestManifestsFail(ctx context.Context, t *testing.T, c *constraintclient.Client, testFc FileCrawler, testManifestPaths []string) { - for _, path := range testManifestPaths { - errManifests, err := testFc.ReadManifests(path) - assert.Nil(t, err) - - err = loadManifestObjects(ctx, c, errManifests) - assert.Nil(t, err) - - // error case - should throw error - violations, err := getObjectViolations(ctx, c, errManifests) - assert.Nil(t, err) - assert.Greater(t, len(violations), 0) - } -} - -func validateTestManifestsSuccess(ctx context.Context, t *testing.T, c *constraintclient.Client, testFc FileCrawler, testManifestPaths []string) { - for _, path := range testManifestPaths { - successManifests, err := testFc.ReadManifests(path) - assert.Nil(t, err) - - err = loadManifestObjects(ctx, c, successManifests) - assert.Nil(t, err) - - // success case - should not throw error - violations, err := getObjectViolations(ctx, c, successManifests) - assert.Nil(t, err) - assert.Equal(t, 0, len(violations)) - } -} diff --git a/pkg/safeguards/tests/container-resource-limits/CL-error-manifest.yaml b/pkg/safeguards/tests/container-resource-limits/CRL-error-manifest.yaml similarity index 100% rename from pkg/safeguards/tests/container-resource-limits/CL-error-manifest.yaml rename to pkg/safeguards/tests/container-resource-limits/CRL-error-manifest.yaml diff --git a/pkg/safeguards/tests/container-resource-limits/CL-success-manifest.yaml b/pkg/safeguards/tests/container-resource-limits/CRL-success-manifest.yaml similarity index 100% rename from pkg/safeguards/tests/container-resource-limits/CL-success-manifest.yaml rename to pkg/safeguards/tests/container-resource-limits/CRL-success-manifest.yaml diff --git a/pkg/safeguards/tests/disallowed-bad-pod-disruption-budget/DBPDB-error-manifest.yaml b/pkg/safeguards/tests/disallowed-bad-pod-disruption-budget/DBPDB-error-manifest.yaml deleted file mode 100644 index b6f9e8b8..00000000 --- a/pkg/safeguards/tests/disallowed-bad-pod-disruption-budget/DBPDB-error-manifest.yaml +++ /dev/null @@ -1,21 +0,0 @@ -apiVersion: apps/v1 -kind: Deployment -metadata: - name: my-deployment - labels: - app: my-app - environment: production - testLabel3: randomlabel -spec: - replicas: 3 - selector: - matchLabels: - app: my-app - template: - metadata: - labels: - app: my-app - spec: - containers: - - name: my-container - image: nginx:latest \ No newline at end of file diff --git a/pkg/safeguards/tests/disallowed-bad-pod-disruption-budget/DBPDB-success-manifest.yaml b/pkg/safeguards/tests/disallowed-bad-pod-disruption-budget/DBPDB-success-manifest.yaml deleted file mode 100644 index b6f9e8b8..00000000 --- a/pkg/safeguards/tests/disallowed-bad-pod-disruption-budget/DBPDB-success-manifest.yaml +++ /dev/null @@ -1,21 +0,0 @@ -apiVersion: apps/v1 -kind: Deployment -metadata: - name: my-deployment - labels: - app: my-app - environment: production - testLabel3: randomlabel -spec: - replicas: 3 - selector: - matchLabels: - app: my-app - template: - metadata: - labels: - app: my-app - spec: - containers: - - name: my-container - image: nginx:latest \ No newline at end of file diff --git a/pkg/safeguards/tests/disallowed-bad-pod-disruption-budgets/DBPDB-error-manifest.yaml b/pkg/safeguards/tests/disallowed-bad-pod-disruption-budgets/DBPDB-error-manifest.yaml new file mode 100644 index 00000000..052e0434 --- /dev/null +++ b/pkg/safeguards/tests/disallowed-bad-pod-disruption-budgets/DBPDB-error-manifest.yaml @@ -0,0 +1,13 @@ +apiVersion: policy/v1 +kind: PodDisruptionBudget +metadata: + name: error-pdb + labels: + app: my-error-pdb + environment: production +spec: + minAvailable: 0 + maxUnavailable: 0 + selector: + matchLabels: + app: my-error-pdb \ No newline at end of file diff --git a/pkg/safeguards/tests/disallowed-bad-pod-disruption-budgets/DBPDB-success-manifest.yaml b/pkg/safeguards/tests/disallowed-bad-pod-disruption-budgets/DBPDB-success-manifest.yaml new file mode 100644 index 00000000..755e7251 --- /dev/null +++ b/pkg/safeguards/tests/disallowed-bad-pod-disruption-budgets/DBPDB-success-manifest.yaml @@ -0,0 +1,13 @@ +apiVersion: policy/v1 +kind: PodDisruptionBudget +metadata: + name: success-pdb + labels: + app: my-success-pdb + environment: production +spec: + minAvailable: 5 + maxUnavailable: 1 + selector: + matchLabels: + app: my-success-pdb diff --git a/pkg/safeguards/tests/pod-enforce-antiaffinity/PEA-success-manifest.yaml b/pkg/safeguards/tests/pod-enforce-antiaffinity/PEA-success-manifest.yaml index b6f9e8b8..c58b23b3 100644 --- a/pkg/safeguards/tests/pod-enforce-antiaffinity/PEA-success-manifest.yaml +++ b/pkg/safeguards/tests/pod-enforce-antiaffinity/PEA-success-manifest.yaml @@ -16,6 +16,34 @@ spec: labels: app: my-app spec: + affinity: + podAntiAffinity: + requiredDuringSchedulingIgnoredDuringExecution: + - labelSelector: + matchExpressions: + - key: app + operator: In + values: + - store + topologyKey: "kubernetes.io/hostname" containers: - - name: my-container - image: nginx:latest \ No newline at end of file + - name: my-container + image: nginx:latest + livenessProbe: + httpGet: + path: /healthz + port: 8080 + httpHeaders: + - name: my-liveness-probe + value: awesome + initialDelaySeconds: 3 + periodSeconds: 3 + readinessProbe: + httpGet: + path: /healthz + port: 8080 + httpHeaders: + - name: my-readiness-probe + value: awesome + initialDelaySeconds: 3 + periodSeconds: 3 \ No newline at end of file diff --git a/pkg/safeguards/tests/restricted-taints/RT-error-manifest.yaml b/pkg/safeguards/tests/restricted-taints/RT-error-manifest.yaml index b6f9e8b8..4dadee0b 100644 --- a/pkg/safeguards/tests/restricted-taints/RT-error-manifest.yaml +++ b/pkg/safeguards/tests/restricted-taints/RT-error-manifest.yaml @@ -1,21 +1,13 @@ -apiVersion: apps/v1 -kind: Deployment +apiVersion: v1 +kind: Node metadata: - name: my-deployment + name: my-error-node labels: - app: my-app + app: my-error-node + kubernetes.azure.com/mode: "User" environment: production - testLabel3: randomlabel spec: - replicas: 3 - selector: - matchLabels: - app: my-app - template: - metadata: - labels: - app: my-app - spec: - containers: - - name: my-container - image: nginx:latest \ No newline at end of file + taints: + - key: "CriticalAddonsOnly" + effect: "NoSchedule" + value: "value" \ No newline at end of file diff --git a/pkg/safeguards/tests/restricted-taints/RT-success-manifest.yaml b/pkg/safeguards/tests/restricted-taints/RT-success-manifest.yaml index b6f9e8b8..89c040b9 100644 --- a/pkg/safeguards/tests/restricted-taints/RT-success-manifest.yaml +++ b/pkg/safeguards/tests/restricted-taints/RT-success-manifest.yaml @@ -1,21 +1,13 @@ -apiVersion: apps/v1 -kind: Deployment +apiVersion: v1 +kind: Node metadata: - name: my-deployment + name: my-success-node labels: - app: my-app + app: my-success-node + kubernetes.azure.com/mode: "User" environment: production - testLabel3: randomlabel spec: - replicas: 3 - selector: - matchLabels: - app: my-app - template: - metadata: - labels: - app: my-app - spec: - containers: - - name: my-container - image: nginx:latest \ No newline at end of file + taints: + - key: "UserDefinedKey" + effect: "NoSchedule" + value: "value" \ No newline at end of file diff --git a/pkg/safeguards/safeguards_types.go b/pkg/safeguards/types.go similarity index 76% rename from pkg/safeguards/safeguards_types.go rename to pkg/safeguards/types.go index 2414ee2c..bfa42c5d 100644 --- a/pkg/safeguards/safeguards_types.go +++ b/pkg/safeguards/types.go @@ -18,7 +18,8 @@ type ManifestFile struct { Path string } -type ManifestViolation struct { +type ManifestResult struct { Name string // the name of the manifest ObjectViolations map[string][]string // a map of string object names to slice of string objectViolations + ViolationsCount int // a count of how many violations are associated with this manifest } diff --git a/scripts/install.sh b/scripts/install.sh index 39c708c7..83dc303b 100755 --- a/scripts/install.sh +++ b/scripts/install.sh @@ -158,8 +158,9 @@ install() { exit 1 fi - if [[ "$ARCH" != "x86_64" ]]; then - echo "Draft CLI is only available for linux x86_64 architecture" + log INFO "validating ARCH: $ARCH" + if [[ "$ARCH" != "x86_64" && "$ARCH" != "arm64" ]]; then + echo "Draft CLI is only available for linux x86_64 and arm64 architecture" file_issue_prompt exit 1 fi diff --git a/test/integration/go/helm.yaml b/test/integration/go/helm.yaml index 43cf1b74..6fad23ec 100644 --- a/test/integration/go/helm.yaml +++ b/test/integration/go/helm.yaml @@ -12,7 +12,7 @@ deployVariables: value: "host.minikube.internal:5001/testapp" languageVariables: - name: "VERSION" - value: "1.22" + value: "1.22.0" - name: "BUILDERVERSION" value: "null" - name: "PORT" diff --git a/test/integration/go/kustomize.yaml b/test/integration/go/kustomize.yaml index 67bf8feb..96d99bfe 100644 --- a/test/integration/go/kustomize.yaml +++ b/test/integration/go/kustomize.yaml @@ -12,7 +12,7 @@ deployVariables: value: "host.minikube.internal:5001/testapp" languageVariables: - name: "VERSION" - value: "1.22" + value: "1.22.0" - name: "BUILDERVERSION" value: "null" - name: "PORT" diff --git a/test/integration/go/manifest.yaml b/test/integration/go/manifest.yaml index 6739c053..fa4e13aa 100644 --- a/test/integration/go/manifest.yaml +++ b/test/integration/go/manifest.yaml @@ -12,7 +12,7 @@ deployVariables: value: "host.minikube.internal:5001/testapp" languageVariables: - name: "VERSION" - value: "1.22" + value: "1.22.0" - name: "BUILDERVERSION" value: "null" - name: "PORT" diff --git a/test/integration/gomodule/helm.yaml b/test/integration/gomodule/helm.yaml index 8de6fb6c..c703a50d 100644 --- a/test/integration/gomodule/helm.yaml +++ b/test/integration/gomodule/helm.yaml @@ -12,7 +12,7 @@ deployVariables: value: "host.minikube.internal:5001/testapp" languageVariables: - name: "VERSION" - value: "1.18" + value: "1.22.0" - name: "BUILDERVERSION" value: "null" - name: "PORT" diff --git a/test/integration/gomodule/kustomize.yaml b/test/integration/gomodule/kustomize.yaml index 283302d9..db75d9d8 100644 --- a/test/integration/gomodule/kustomize.yaml +++ b/test/integration/gomodule/kustomize.yaml @@ -12,7 +12,7 @@ deployVariables: value: "host.minikube.internal:5001/testapp" languageVariables: - name: "VERSION" - value: "1.18" + value: "1.22.0" - name: "BUILDERVERSION" value: "null" - name: "PORT" diff --git a/test/integration/gomodule/manifest.yaml b/test/integration/gomodule/manifest.yaml index 3042657c..e4fc7a52 100644 --- a/test/integration/gomodule/manifest.yaml +++ b/test/integration/gomodule/manifest.yaml @@ -12,7 +12,7 @@ deployVariables: value: "host.minikube.internal:5001/testapp" languageVariables: - name: "VERSION" - value: "1.18" + value: "1.22.0" - name: "BUILDERVERSION" value: "null" - name: "PORT" diff --git a/test/integration_config.json b/test/integration_config.json index d81f53f8..8873eae3 100644 --- a/test/integration_config.json +++ b/test/integration_config.json @@ -1,14 +1,14 @@ [ { "language": "gomodule", - "version": "1.22", + "version": "1.22.0", "port": "1323", "serviceport": 80, "repo": "gambtho/go_echo" }, { "language": "go", - "version": "1.22", + "version": "1.22.0", "port": "8080", "serviceport": 8080, "repo": "davidgamero/go-echo-no-mod"