diff --git a/cmd/spire-agent/cli/api/api_posix_test.go b/cmd/spire-agent/cli/api/api_posix_test.go index f9616f27ed..0e9856168e 100644 --- a/cmd/spire-agent/cli/api/api_posix_test.go +++ b/cmd/spire-agent/cli/api/api_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package api diff --git a/cmd/spire-agent/cli/api/api_windows_test.go b/cmd/spire-agent/cli/api/api_windows_test.go index cc1dd6a95c..cc6510e4cd 100644 --- a/cmd/spire-agent/cli/api/api_windows_test.go +++ b/cmd/spire-agent/cli/api/api_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package api diff --git a/cmd/spire-agent/cli/common/config_posix.go b/cmd/spire-agent/cli/common/config_posix.go index e2656cded5..acea475137 100644 --- a/cmd/spire-agent/cli/common/config_posix.go +++ b/cmd/spire-agent/cli/common/config_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package common diff --git a/cmd/spire-agent/cli/common/config_windows.go b/cmd/spire-agent/cli/common/config_windows.go index 4ed50b673f..e63782bbe7 100644 --- a/cmd/spire-agent/cli/common/config_windows.go +++ b/cmd/spire-agent/cli/common/config_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package common diff --git a/cmd/spire-agent/cli/common/defaults_posix.go b/cmd/spire-agent/cli/common/defaults_posix.go index 8f1dfe0c96..af6c7d0c9a 100644 --- a/cmd/spire-agent/cli/common/defaults_posix.go +++ b/cmd/spire-agent/cli/common/defaults_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package common diff --git a/cmd/spire-agent/cli/common/defaults_windows.go b/cmd/spire-agent/cli/common/defaults_windows.go index 71145ba264..1d868252ad 100644 --- a/cmd/spire-agent/cli/common/defaults_windows.go +++ b/cmd/spire-agent/cli/common/defaults_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package common diff --git a/cmd/spire-agent/cli/healthcheck/healthcheck_posix.go b/cmd/spire-agent/cli/healthcheck/healthcheck_posix.go index b8cd1a4610..f668904c92 100644 --- a/cmd/spire-agent/cli/healthcheck/healthcheck_posix.go +++ b/cmd/spire-agent/cli/healthcheck/healthcheck_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package healthcheck diff --git a/cmd/spire-agent/cli/healthcheck/healthcheck_posix_test.go b/cmd/spire-agent/cli/healthcheck/healthcheck_posix_test.go index ac640001b1..7781e48489 100644 --- a/cmd/spire-agent/cli/healthcheck/healthcheck_posix_test.go +++ b/cmd/spire-agent/cli/healthcheck/healthcheck_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package healthcheck diff --git a/cmd/spire-agent/cli/healthcheck/healthcheck_windows.go b/cmd/spire-agent/cli/healthcheck/healthcheck_windows.go index ef16c07344..ffc0aafc8e 100644 --- a/cmd/spire-agent/cli/healthcheck/healthcheck_windows.go +++ b/cmd/spire-agent/cli/healthcheck/healthcheck_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package healthcheck diff --git a/cmd/spire-agent/cli/healthcheck/healthcheck_windows_test.go b/cmd/spire-agent/cli/healthcheck/healthcheck_windows_test.go index a5880c5f39..29cfaf56fb 100644 --- a/cmd/spire-agent/cli/healthcheck/healthcheck_windows_test.go +++ b/cmd/spire-agent/cli/healthcheck/healthcheck_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package healthcheck diff --git a/cmd/spire-agent/cli/run/run_posix.go b/cmd/spire-agent/cli/run/run_posix.go index 4c1037c5ba..4c8ddd9d03 100644 --- a/cmd/spire-agent/cli/run/run_posix.go +++ b/cmd/spire-agent/cli/run/run_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package run diff --git a/cmd/spire-agent/cli/run/run_posix_test.go b/cmd/spire-agent/cli/run/run_posix_test.go index c020621174..5c1519adce 100644 --- a/cmd/spire-agent/cli/run/run_posix_test.go +++ b/cmd/spire-agent/cli/run/run_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package run diff --git a/cmd/spire-agent/cli/run/run_windows.go b/cmd/spire-agent/cli/run/run_windows.go index 93be9f3f09..015bbc3420 100644 --- a/cmd/spire-agent/cli/run/run_windows.go +++ b/cmd/spire-agent/cli/run/run_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package run diff --git a/cmd/spire-agent/cli/run/run_windows_test.go b/cmd/spire-agent/cli/run/run_windows_test.go index 5433bc6c77..cde7f985aa 100644 --- a/cmd/spire-agent/cli/run/run_windows_test.go +++ b/cmd/spire-agent/cli/run/run_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package run diff --git a/cmd/spire-server/cli/agent/agent_posix_test.go b/cmd/spire-server/cli/agent/agent_posix_test.go index 6154ef5e96..a1e6568bc6 100644 --- a/cmd/spire-server/cli/agent/agent_posix_test.go +++ b/cmd/spire-server/cli/agent/agent_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package agent_test diff --git a/cmd/spire-server/cli/agent/agent_windows_test.go b/cmd/spire-server/cli/agent/agent_windows_test.go index 7e723c9718..965ab5c3a7 100644 --- a/cmd/spire-server/cli/agent/agent_windows_test.go +++ b/cmd/spire-server/cli/agent/agent_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package agent_test diff --git a/cmd/spire-server/cli/agent/count.go b/cmd/spire-server/cli/agent/count.go index 1904136765..4b46f77f0d 100644 --- a/cmd/spire-server/cli/agent/count.go +++ b/cmd/spire-server/cli/agent/count.go @@ -1,6 +1,7 @@ package agent import ( + "context" "errors" "flag" "fmt" @@ -10,7 +11,6 @@ import ( "github.com/spiffe/spire/cmd/spire-server/util" commoncli "github.com/spiffe/spire/pkg/common/cli" "github.com/spiffe/spire/pkg/common/cliprinter" - "golang.org/x/net/context" ) type countCommand struct { diff --git a/cmd/spire-server/cli/agent/evict.go b/cmd/spire-server/cli/agent/evict.go index 42e79b506a..b89b463262 100644 --- a/cmd/spire-server/cli/agent/evict.go +++ b/cmd/spire-server/cli/agent/evict.go @@ -1,6 +1,7 @@ package agent import ( + "context" "errors" "flag" @@ -11,7 +12,6 @@ import ( commoncli "github.com/spiffe/spire/pkg/common/cli" "github.com/spiffe/spire/pkg/common/cliprinter" "github.com/spiffe/spire/pkg/server/api" - "golang.org/x/net/context" ) type evictCommand struct { diff --git a/cmd/spire-server/cli/agent/list.go b/cmd/spire-server/cli/agent/list.go index b8b7b361aa..80b66989ec 100644 --- a/cmd/spire-server/cli/agent/list.go +++ b/cmd/spire-server/cli/agent/list.go @@ -1,6 +1,7 @@ package agent import ( + "context" "errors" "flag" "fmt" @@ -13,7 +14,6 @@ import ( commoncli "github.com/spiffe/spire/pkg/common/cli" "github.com/spiffe/spire/pkg/common/cliprinter" "github.com/spiffe/spire/pkg/common/idutil" - "golang.org/x/net/context" ) type listCommand struct { diff --git a/cmd/spire-server/cli/agent/purge.go b/cmd/spire-server/cli/agent/purge.go index 183d8303c7..48f0d45c78 100644 --- a/cmd/spire-server/cli/agent/purge.go +++ b/cmd/spire-server/cli/agent/purge.go @@ -1,6 +1,7 @@ package agent import ( + "context" "flag" "fmt" "time" @@ -13,7 +14,6 @@ import ( commoncli "github.com/spiffe/spire/pkg/common/cli" "github.com/spiffe/spire/pkg/common/cliprinter" "github.com/spiffe/spire/pkg/common/idutil" - "golang.org/x/net/context" "google.golang.org/protobuf/types/known/wrapperspb" ) diff --git a/cmd/spire-server/cli/agent/show.go b/cmd/spire-server/cli/agent/show.go index e57a9faa98..70a44f4cd8 100644 --- a/cmd/spire-server/cli/agent/show.go +++ b/cmd/spire-server/cli/agent/show.go @@ -1,6 +1,7 @@ package agent import ( + "context" "errors" "flag" @@ -12,7 +13,6 @@ import ( commoncli "github.com/spiffe/spire/pkg/common/cli" "github.com/spiffe/spire/pkg/common/cliprinter" "github.com/spiffe/spire/pkg/server/api" - "golang.org/x/net/context" ) type showCommand struct { diff --git a/cmd/spire-server/cli/bundle/bundle_posix_test.go b/cmd/spire-server/cli/bundle/bundle_posix_test.go index ab18144c65..040087a0f9 100644 --- a/cmd/spire-server/cli/bundle/bundle_posix_test.go +++ b/cmd/spire-server/cli/bundle/bundle_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package bundle diff --git a/cmd/spire-server/cli/bundle/bundle_windows_test.go b/cmd/spire-server/cli/bundle/bundle_windows_test.go index c1e002f24d..50cb993dc7 100644 --- a/cmd/spire-server/cli/bundle/bundle_windows_test.go +++ b/cmd/spire-server/cli/bundle/bundle_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package bundle diff --git a/cmd/spire-server/cli/bundle/count.go b/cmd/spire-server/cli/bundle/count.go index 80b8e4c24f..084faadae9 100644 --- a/cmd/spire-server/cli/bundle/count.go +++ b/cmd/spire-server/cli/bundle/count.go @@ -1,6 +1,7 @@ package bundle import ( + "context" "flag" "fmt" @@ -10,8 +11,6 @@ import ( bundlev1 "github.com/spiffe/spire-api-sdk/proto/spire/api/server/bundle/v1" "github.com/spiffe/spire/cmd/spire-server/util" commoncli "github.com/spiffe/spire/pkg/common/cli" - - "golang.org/x/net/context" ) type countCommand struct { diff --git a/cmd/spire-server/cli/common/common_posix.go b/cmd/spire-server/cli/common/common_posix.go index e070af8e91..ff1adea6d2 100644 --- a/cmd/spire-server/cli/common/common_posix.go +++ b/cmd/spire-server/cli/common/common_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package common diff --git a/cmd/spire-server/cli/common/common_windows.go b/cmd/spire-server/cli/common/common_windows.go index f2ed0f474b..2cc3dd87c4 100644 --- a/cmd/spire-server/cli/common/common_windows.go +++ b/cmd/spire-server/cli/common/common_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package common diff --git a/cmd/spire-server/cli/entry/count.go b/cmd/spire-server/cli/entry/count.go index 16882d85ba..c095e76899 100644 --- a/cmd/spire-server/cli/entry/count.go +++ b/cmd/spire-server/cli/entry/count.go @@ -1,17 +1,15 @@ package entry import ( + "context" "flag" "fmt" "github.com/mitchellh/cli" - "github.com/spiffe/spire/pkg/common/cliprinter" - entryv1 "github.com/spiffe/spire-api-sdk/proto/spire/api/server/entry/v1" "github.com/spiffe/spire/cmd/spire-server/util" commoncli "github.com/spiffe/spire/pkg/common/cli" - - "golang.org/x/net/context" + "github.com/spiffe/spire/pkg/common/cliprinter" ) type countCommand struct { diff --git a/cmd/spire-server/cli/entry/create.go b/cmd/spire-server/cli/entry/create.go index c34155add8..31cc157991 100644 --- a/cmd/spire-server/cli/entry/create.go +++ b/cmd/spire-server/cli/entry/create.go @@ -1,6 +1,7 @@ package entry import ( + "context" "errors" "flag" @@ -12,8 +13,6 @@ import ( "github.com/spiffe/spire/pkg/common/cliprinter" "github.com/spiffe/spire/pkg/common/idutil" "google.golang.org/grpc/codes" - - "golang.org/x/net/context" ) // NewCreateCommand creates a new "create" subcommand for "entry" command. diff --git a/cmd/spire-server/cli/entry/delete.go b/cmd/spire-server/cli/entry/delete.go index 64f514c770..f3f27cd6bd 100644 --- a/cmd/spire-server/cli/entry/delete.go +++ b/cmd/spire-server/cli/entry/delete.go @@ -1,6 +1,7 @@ package entry import ( + "context" "encoding/json" "errors" "flag" @@ -13,8 +14,6 @@ import ( commoncli "github.com/spiffe/spire/pkg/common/cli" "github.com/spiffe/spire/pkg/common/cliprinter" "google.golang.org/grpc/codes" - - "golang.org/x/net/context" ) // NewDeleteCommand creates a new "delete" subcommand for "entry" command. diff --git a/cmd/spire-server/cli/entry/show.go b/cmd/spire-server/cli/entry/show.go index 7921053278..5cbfdf10e8 100644 --- a/cmd/spire-server/cli/entry/show.go +++ b/cmd/spire-server/cli/entry/show.go @@ -1,6 +1,7 @@ package entry import ( + "context" "errors" "flag" "fmt" @@ -13,8 +14,6 @@ import ( "github.com/spiffe/spire/pkg/common/cliprinter" commonutil "github.com/spiffe/spire/pkg/common/util" "google.golang.org/protobuf/types/known/wrapperspb" - - "golang.org/x/net/context" ) const listEntriesRequestPageSize = 500 diff --git a/cmd/spire-server/cli/entry/update.go b/cmd/spire-server/cli/entry/update.go index 1478b535bf..e2a22a5b92 100644 --- a/cmd/spire-server/cli/entry/update.go +++ b/cmd/spire-server/cli/entry/update.go @@ -1,6 +1,7 @@ package entry import ( + "context" "errors" "flag" @@ -11,8 +12,6 @@ import ( commoncli "github.com/spiffe/spire/pkg/common/cli" "github.com/spiffe/spire/pkg/common/cliprinter" "google.golang.org/grpc/codes" - - "golang.org/x/net/context" ) // NewUpdateCommand creates a new "update" subcommand for "entry" command. diff --git a/cmd/spire-server/cli/entry/util_posix_test.go b/cmd/spire-server/cli/entry/util_posix_test.go index e8615dffbe..d3825c1298 100644 --- a/cmd/spire-server/cli/entry/util_posix_test.go +++ b/cmd/spire-server/cli/entry/util_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package entry diff --git a/cmd/spire-server/cli/entry/util_test.go b/cmd/spire-server/cli/entry/util_test.go index 1ecf688778..3148e80366 100644 --- a/cmd/spire-server/cli/entry/util_test.go +++ b/cmd/spire-server/cli/entry/util_test.go @@ -2,6 +2,7 @@ package entry import ( "bytes" + "context" "os" "path" "testing" @@ -15,7 +16,6 @@ import ( "github.com/spiffe/spire/test/util" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" - "golang.org/x/net/context" "google.golang.org/grpc" ) diff --git a/cmd/spire-server/cli/entry/util_windows_test.go b/cmd/spire-server/cli/entry/util_windows_test.go index 9f72d1df6c..75e1d1929b 100644 --- a/cmd/spire-server/cli/entry/util_windows_test.go +++ b/cmd/spire-server/cli/entry/util_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package entry diff --git a/cmd/spire-server/cli/federation/util_posix_test.go b/cmd/spire-server/cli/federation/util_posix_test.go index 61549af1be..4e4227fbc6 100644 --- a/cmd/spire-server/cli/federation/util_posix_test.go +++ b/cmd/spire-server/cli/federation/util_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package federation diff --git a/cmd/spire-server/cli/federation/util_windows_test.go b/cmd/spire-server/cli/federation/util_windows_test.go index 3a694743dc..379fc10be9 100644 --- a/cmd/spire-server/cli/federation/util_windows_test.go +++ b/cmd/spire-server/cli/federation/util_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package federation diff --git a/cmd/spire-server/cli/healthcheck/healthcheck_posix_test.go b/cmd/spire-server/cli/healthcheck/healthcheck_posix_test.go index b59a6677af..d56a982cf1 100644 --- a/cmd/spire-server/cli/healthcheck/healthcheck_posix_test.go +++ b/cmd/spire-server/cli/healthcheck/healthcheck_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package healthcheck diff --git a/cmd/spire-server/cli/healthcheck/healthcheck_windows_test.go b/cmd/spire-server/cli/healthcheck/healthcheck_windows_test.go index 01125bef06..71644c1ac8 100644 --- a/cmd/spire-server/cli/healthcheck/healthcheck_windows_test.go +++ b/cmd/spire-server/cli/healthcheck/healthcheck_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package healthcheck diff --git a/cmd/spire-server/cli/run/run_posix.go b/cmd/spire-server/cli/run/run_posix.go index 22693992a2..2d23b63343 100644 --- a/cmd/spire-server/cli/run/run_posix.go +++ b/cmd/spire-server/cli/run/run_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package run diff --git a/cmd/spire-server/cli/run/run_posix_test.go b/cmd/spire-server/cli/run/run_posix_test.go index 2479a87f5d..14ad295946 100644 --- a/cmd/spire-server/cli/run/run_posix_test.go +++ b/cmd/spire-server/cli/run/run_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package run diff --git a/cmd/spire-server/cli/run/run_windows.go b/cmd/spire-server/cli/run/run_windows.go index a5d8bce065..9162225bd6 100644 --- a/cmd/spire-server/cli/run/run_windows.go +++ b/cmd/spire-server/cli/run/run_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package run diff --git a/cmd/spire-server/cli/run/run_windows_test.go b/cmd/spire-server/cli/run/run_windows_test.go index 3d8d61457b..3f4731fcd0 100644 --- a/cmd/spire-server/cli/run/run_windows_test.go +++ b/cmd/spire-server/cli/run/run_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package run diff --git a/cmd/spire-server/cli/token/generate.go b/cmd/spire-server/cli/token/generate.go index 98eeeddb18..7410f05597 100644 --- a/cmd/spire-server/cli/token/generate.go +++ b/cmd/spire-server/cli/token/generate.go @@ -1,6 +1,7 @@ package token import ( + "context" "flag" "github.com/mitchellh/cli" @@ -8,11 +9,8 @@ import ( agentv1 "github.com/spiffe/spire-api-sdk/proto/spire/api/server/agent/v1" prototypes "github.com/spiffe/spire-api-sdk/proto/spire/api/types" "github.com/spiffe/spire/cmd/spire-server/util" - commoncli "github.com/spiffe/spire/pkg/common/cli" "github.com/spiffe/spire/pkg/common/cliprinter" - - "golang.org/x/net/context" ) func NewGenerateCommand() cli.Command { diff --git a/cmd/spire-server/cli/token/generate_test.go b/cmd/spire-server/cli/token/generate_test.go index 3b584a4b03..a5414ea843 100644 --- a/cmd/spire-server/cli/token/generate_test.go +++ b/cmd/spire-server/cli/token/generate_test.go @@ -2,6 +2,7 @@ package token import ( "bytes" + "context" "fmt" "testing" @@ -12,7 +13,6 @@ import ( common_cli "github.com/spiffe/spire/pkg/common/cli" "github.com/spiffe/spire/test/spiretest" "github.com/stretchr/testify/require" - "golang.org/x/net/context" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" diff --git a/cmd/spire-server/util/util_posix.go b/cmd/spire-server/util/util_posix.go index 02ebbba85c..a86da5c8e6 100644 --- a/cmd/spire-server/util/util_posix.go +++ b/cmd/spire-server/util/util_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package util diff --git a/cmd/spire-server/util/util_windows.go b/cmd/spire-server/util/util_windows.go index 40585d843e..be31ad7aaa 100644 --- a/cmd/spire-server/util/util_windows.go +++ b/cmd/spire-server/util/util_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package util diff --git a/pkg/agent/api/endpoints_posix.go b/pkg/agent/api/endpoints_posix.go index db1218f5dd..abcf6efd2f 100644 --- a/pkg/agent/api/endpoints_posix.go +++ b/pkg/agent/api/endpoints_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package api diff --git a/pkg/agent/api/endpoints_windows.go b/pkg/agent/api/endpoints_windows.go index c155f741da..d3aee33ed5 100644 --- a/pkg/agent/api/endpoints_windows.go +++ b/pkg/agent/api/endpoints_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package api diff --git a/pkg/agent/endpoints/endpoints_posix.go b/pkg/agent/endpoints/endpoints_posix.go index 4141c31782..5a005ba38d 100644 --- a/pkg/agent/endpoints/endpoints_posix.go +++ b/pkg/agent/endpoints/endpoints_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package endpoints diff --git a/pkg/agent/endpoints/endpoints_posix_test.go b/pkg/agent/endpoints/endpoints_posix_test.go index 57595964dc..28f741a438 100644 --- a/pkg/agent/endpoints/endpoints_posix_test.go +++ b/pkg/agent/endpoints/endpoints_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package endpoints diff --git a/pkg/agent/endpoints/endpoints_windows.go b/pkg/agent/endpoints/endpoints_windows.go index b0ef912318..266bc12cf6 100644 --- a/pkg/agent/endpoints/endpoints_windows.go +++ b/pkg/agent/endpoints/endpoints_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package endpoints diff --git a/pkg/agent/endpoints/endpoints_windows_test.go b/pkg/agent/endpoints/endpoints_windows_test.go index af4f3601b4..74d52e52b3 100644 --- a/pkg/agent/endpoints/endpoints_windows_test.go +++ b/pkg/agent/endpoints/endpoints_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package endpoints diff --git a/pkg/agent/plugin/nodeattestor/k8spsat/psat_posix.go b/pkg/agent/plugin/nodeattestor/k8spsat/psat_posix.go index 5734d4e4e9..3d4f01708e 100644 --- a/pkg/agent/plugin/nodeattestor/k8spsat/psat_posix.go +++ b/pkg/agent/plugin/nodeattestor/k8spsat/psat_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package k8spsat diff --git a/pkg/agent/plugin/nodeattestor/k8spsat/psat_posix_test.go b/pkg/agent/plugin/nodeattestor/k8spsat/psat_posix_test.go index c8cdd31f23..05be271683 100644 --- a/pkg/agent/plugin/nodeattestor/k8spsat/psat_posix_test.go +++ b/pkg/agent/plugin/nodeattestor/k8spsat/psat_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package k8spsat diff --git a/pkg/agent/plugin/nodeattestor/k8spsat/psat_windows.go b/pkg/agent/plugin/nodeattestor/k8spsat/psat_windows.go index e40ca493a3..7ecc958e41 100644 --- a/pkg/agent/plugin/nodeattestor/k8spsat/psat_windows.go +++ b/pkg/agent/plugin/nodeattestor/k8spsat/psat_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package k8spsat diff --git a/pkg/agent/plugin/nodeattestor/k8spsat/psat_windows_test.go b/pkg/agent/plugin/nodeattestor/k8spsat/psat_windows_test.go index 366a9bde7e..a5c2378f8d 100644 --- a/pkg/agent/plugin/nodeattestor/k8spsat/psat_windows_test.go +++ b/pkg/agent/plugin/nodeattestor/k8spsat/psat_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package k8spsat diff --git a/pkg/agent/plugin/nodeattestor/k8ssat/sat_posix.go b/pkg/agent/plugin/nodeattestor/k8ssat/sat_posix.go index cdedf09150..adc6dc0ee7 100644 --- a/pkg/agent/plugin/nodeattestor/k8ssat/sat_posix.go +++ b/pkg/agent/plugin/nodeattestor/k8ssat/sat_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package k8ssat diff --git a/pkg/agent/plugin/nodeattestor/k8ssat/sat_posix_test.go b/pkg/agent/plugin/nodeattestor/k8ssat/sat_posix_test.go index 2414e8f943..7692a0055b 100644 --- a/pkg/agent/plugin/nodeattestor/k8ssat/sat_posix_test.go +++ b/pkg/agent/plugin/nodeattestor/k8ssat/sat_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package k8ssat diff --git a/pkg/agent/plugin/nodeattestor/k8ssat/sat_windows.go b/pkg/agent/plugin/nodeattestor/k8ssat/sat_windows.go index d89eb2841a..ff25688658 100644 --- a/pkg/agent/plugin/nodeattestor/k8ssat/sat_windows.go +++ b/pkg/agent/plugin/nodeattestor/k8ssat/sat_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package k8ssat diff --git a/pkg/agent/plugin/nodeattestor/k8ssat/sat_windows_test.go b/pkg/agent/plugin/nodeattestor/k8ssat/sat_windows_test.go index 05bd5949a5..40753dc8d7 100644 --- a/pkg/agent/plugin/nodeattestor/k8ssat/sat_windows_test.go +++ b/pkg/agent/plugin/nodeattestor/k8ssat/sat_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package k8ssat diff --git a/pkg/agent/plugin/nodeattestor/tpmdevid/devid_test.go b/pkg/agent/plugin/nodeattestor/tpmdevid/devid_test.go index 512cc0f52f..e164342d2b 100644 --- a/pkg/agent/plugin/nodeattestor/tpmdevid/devid_test.go +++ b/pkg/agent/plugin/nodeattestor/tpmdevid/devid_test.go @@ -1,5 +1,4 @@ //go:build !darwin -// +build !darwin package tpmdevid_test diff --git a/pkg/agent/plugin/nodeattestor/tpmdevid/tpmutil/open.go b/pkg/agent/plugin/nodeattestor/tpmdevid/tpmutil/open.go index 8ba09f1d52..915142f8a2 100644 --- a/pkg/agent/plugin/nodeattestor/tpmdevid/tpmutil/open.go +++ b/pkg/agent/plugin/nodeattestor/tpmdevid/tpmutil/open.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package tpmutil diff --git a/pkg/agent/plugin/nodeattestor/tpmdevid/tpmutil/open_windows.go b/pkg/agent/plugin/nodeattestor/tpmdevid/tpmutil/open_windows.go index fedc0121d0..2cb1972f7c 100644 --- a/pkg/agent/plugin/nodeattestor/tpmdevid/tpmutil/open_windows.go +++ b/pkg/agent/plugin/nodeattestor/tpmdevid/tpmutil/open_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package tpmutil diff --git a/pkg/agent/plugin/nodeattestor/tpmdevid/tpmutil/session_test.go b/pkg/agent/plugin/nodeattestor/tpmdevid/tpmutil/session_test.go index 42e669c5e7..53bff71073 100644 --- a/pkg/agent/plugin/nodeattestor/tpmdevid/tpmutil/session_test.go +++ b/pkg/agent/plugin/nodeattestor/tpmdevid/tpmutil/session_test.go @@ -1,5 +1,4 @@ //go:build !darwin -// +build !darwin package tpmutil_test diff --git a/pkg/agent/plugin/workloadattestor/docker/docker_posix.go b/pkg/agent/plugin/workloadattestor/docker/docker_posix.go index dbe833d0c1..74045a1e9e 100644 --- a/pkg/agent/plugin/workloadattestor/docker/docker_posix.go +++ b/pkg/agent/plugin/workloadattestor/docker/docker_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package docker diff --git a/pkg/agent/plugin/workloadattestor/docker/docker_posix_test.go b/pkg/agent/plugin/workloadattestor/docker/docker_posix_test.go index 77071cc24c..acd957cf6e 100644 --- a/pkg/agent/plugin/workloadattestor/docker/docker_posix_test.go +++ b/pkg/agent/plugin/workloadattestor/docker/docker_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package docker diff --git a/pkg/agent/plugin/workloadattestor/docker/docker_windows.go b/pkg/agent/plugin/workloadattestor/docker/docker_windows.go index a8c55f2998..a4f7326e93 100644 --- a/pkg/agent/plugin/workloadattestor/docker/docker_windows.go +++ b/pkg/agent/plugin/workloadattestor/docker/docker_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package docker diff --git a/pkg/agent/plugin/workloadattestor/docker/docker_windows_test.go b/pkg/agent/plugin/workloadattestor/docker/docker_windows_test.go index 84af165aad..68da00986e 100644 --- a/pkg/agent/plugin/workloadattestor/docker/docker_windows_test.go +++ b/pkg/agent/plugin/workloadattestor/docker/docker_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package docker diff --git a/pkg/agent/plugin/workloadattestor/k8s/k8s_posix.go b/pkg/agent/plugin/workloadattestor/k8s/k8s_posix.go index 953fb2a95c..82ceaabb07 100644 --- a/pkg/agent/plugin/workloadattestor/k8s/k8s_posix.go +++ b/pkg/agent/plugin/workloadattestor/k8s/k8s_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package k8s diff --git a/pkg/agent/plugin/workloadattestor/k8s/k8s_posix_test.go b/pkg/agent/plugin/workloadattestor/k8s/k8s_posix_test.go index ad39cfa629..ae44b249a6 100644 --- a/pkg/agent/plugin/workloadattestor/k8s/k8s_posix_test.go +++ b/pkg/agent/plugin/workloadattestor/k8s/k8s_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package k8s diff --git a/pkg/agent/plugin/workloadattestor/k8s/k8s_windows.go b/pkg/agent/plugin/workloadattestor/k8s/k8s_windows.go index 3a463ea225..21f0299b4c 100644 --- a/pkg/agent/plugin/workloadattestor/k8s/k8s_windows.go +++ b/pkg/agent/plugin/workloadattestor/k8s/k8s_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package k8s diff --git a/pkg/agent/plugin/workloadattestor/k8s/k8s_windows_test.go b/pkg/agent/plugin/workloadattestor/k8s/k8s_windows_test.go index 6d5ecf911f..188ae00262 100644 --- a/pkg/agent/plugin/workloadattestor/k8s/k8s_windows_test.go +++ b/pkg/agent/plugin/workloadattestor/k8s/k8s_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package k8s diff --git a/pkg/agent/plugin/workloadattestor/k8s/sigstore/sigstore.go b/pkg/agent/plugin/workloadattestor/k8s/sigstore/sigstore.go index 04c42d1340..8a14e5c6b3 100644 --- a/pkg/agent/plugin/workloadattestor/k8s/sigstore/sigstore.go +++ b/pkg/agent/plugin/workloadattestor/k8s/sigstore/sigstore.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package sigstore diff --git a/pkg/agent/plugin/workloadattestor/k8s/sigstore/sigstore_test.go b/pkg/agent/plugin/workloadattestor/k8s/sigstore/sigstore_test.go index 82044ac2cc..d7ceef9f9b 100644 --- a/pkg/agent/plugin/workloadattestor/k8s/sigstore/sigstore_test.go +++ b/pkg/agent/plugin/workloadattestor/k8s/sigstore/sigstore_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package sigstore diff --git a/pkg/agent/plugin/workloadattestor/k8s/sigstore/sigstorecache.go b/pkg/agent/plugin/workloadattestor/k8s/sigstore/sigstorecache.go index 4d556a679d..debbf14f51 100644 --- a/pkg/agent/plugin/workloadattestor/k8s/sigstore/sigstorecache.go +++ b/pkg/agent/plugin/workloadattestor/k8s/sigstore/sigstorecache.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package sigstore diff --git a/pkg/agent/plugin/workloadattestor/k8s/sigstore/sigstorecache_test.go b/pkg/agent/plugin/workloadattestor/k8s/sigstore/sigstorecache_test.go index cf50ef6aeb..c90824cb36 100644 --- a/pkg/agent/plugin/workloadattestor/k8s/sigstore/sigstorecache_test.go +++ b/pkg/agent/plugin/workloadattestor/k8s/sigstore/sigstorecache_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package sigstore diff --git a/pkg/agent/plugin/workloadattestor/systemd/systemd_posix.go b/pkg/agent/plugin/workloadattestor/systemd/systemd_posix.go index 6f8fe02c31..44c276bd09 100644 --- a/pkg/agent/plugin/workloadattestor/systemd/systemd_posix.go +++ b/pkg/agent/plugin/workloadattestor/systemd/systemd_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package systemd diff --git a/pkg/agent/plugin/workloadattestor/systemd/systemd_posix_test.go b/pkg/agent/plugin/workloadattestor/systemd/systemd_posix_test.go index 936af09563..a947a642e9 100644 --- a/pkg/agent/plugin/workloadattestor/systemd/systemd_posix_test.go +++ b/pkg/agent/plugin/workloadattestor/systemd/systemd_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package systemd diff --git a/pkg/agent/plugin/workloadattestor/systemd/systemd_windows.go b/pkg/agent/plugin/workloadattestor/systemd/systemd_windows.go index 0919c898a2..c35bdce462 100644 --- a/pkg/agent/plugin/workloadattestor/systemd/systemd_windows.go +++ b/pkg/agent/plugin/workloadattestor/systemd/systemd_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package systemd diff --git a/pkg/agent/plugin/workloadattestor/systemd/systemd_windows_test.go b/pkg/agent/plugin/workloadattestor/systemd/systemd_windows_test.go index ed5946c9b1..d6c88773ee 100644 --- a/pkg/agent/plugin/workloadattestor/systemd/systemd_windows_test.go +++ b/pkg/agent/plugin/workloadattestor/systemd/systemd_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package systemd diff --git a/pkg/agent/plugin/workloadattestor/unix/unix_posix.go b/pkg/agent/plugin/workloadattestor/unix/unix_posix.go index 6a3659722a..6c2d781304 100644 --- a/pkg/agent/plugin/workloadattestor/unix/unix_posix.go +++ b/pkg/agent/plugin/workloadattestor/unix/unix_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package unix diff --git a/pkg/agent/plugin/workloadattestor/unix/unix_posix_test.go b/pkg/agent/plugin/workloadattestor/unix/unix_posix_test.go index 942a784f32..c00509491a 100644 --- a/pkg/agent/plugin/workloadattestor/unix/unix_posix_test.go +++ b/pkg/agent/plugin/workloadattestor/unix/unix_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package unix diff --git a/pkg/agent/plugin/workloadattestor/unix/unix_windows.go b/pkg/agent/plugin/workloadattestor/unix/unix_windows.go index 888699c528..ed5befd262 100644 --- a/pkg/agent/plugin/workloadattestor/unix/unix_windows.go +++ b/pkg/agent/plugin/workloadattestor/unix/unix_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package unix diff --git a/pkg/agent/plugin/workloadattestor/unix/unix_windows_test.go b/pkg/agent/plugin/workloadattestor/unix/unix_windows_test.go index 89a8cb358a..1c30ceb797 100644 --- a/pkg/agent/plugin/workloadattestor/unix/unix_windows_test.go +++ b/pkg/agent/plugin/workloadattestor/unix/unix_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package unix diff --git a/pkg/agent/plugin/workloadattestor/windows/windows_posix.go b/pkg/agent/plugin/workloadattestor/windows/windows_posix.go index 7daaf90ca9..30840b9bfa 100644 --- a/pkg/agent/plugin/workloadattestor/windows/windows_posix.go +++ b/pkg/agent/plugin/workloadattestor/windows/windows_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package windows diff --git a/pkg/agent/plugin/workloadattestor/windows/windows_posix_test.go b/pkg/agent/plugin/workloadattestor/windows/windows_posix_test.go index 27b7ad0569..cffe2fe11a 100644 --- a/pkg/agent/plugin/workloadattestor/windows/windows_posix_test.go +++ b/pkg/agent/plugin/workloadattestor/windows/windows_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package windows diff --git a/pkg/agent/plugin/workloadattestor/windows/windows_windows.go b/pkg/agent/plugin/workloadattestor/windows/windows_windows.go index b24f749dc0..822288de95 100644 --- a/pkg/agent/plugin/workloadattestor/windows/windows_windows.go +++ b/pkg/agent/plugin/workloadattestor/windows/windows_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package windows diff --git a/pkg/agent/plugin/workloadattestor/windows/windows_windows_test.go b/pkg/agent/plugin/workloadattestor/windows/windows_windows_test.go index 12556ac751..b0dcbacdae 100644 --- a/pkg/agent/plugin/workloadattestor/windows/windows_windows_test.go +++ b/pkg/agent/plugin/workloadattestor/windows/windows_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package windows diff --git a/pkg/common/catalog/testplugin/main.go b/pkg/common/catalog/testplugin/main.go index 79093741bd..3be9462a33 100644 --- a/pkg/common/catalog/testplugin/main.go +++ b/pkg/common/catalog/testplugin/main.go @@ -1,4 +1,4 @@ -// +build ignore +//go:build ignore package main diff --git a/pkg/common/cli/umask_windows.go b/pkg/common/cli/umask_windows.go index 006da0d760..49ef2fbe1e 100644 --- a/pkg/common/cli/umask_windows.go +++ b/pkg/common/cli/umask_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package cli diff --git a/pkg/common/container/process/helper.go b/pkg/common/container/process/helper.go index 568ba471c3..8e45291182 100644 --- a/pkg/common/container/process/helper.go +++ b/pkg/common/container/process/helper.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package process diff --git a/pkg/common/container/process/helper_test.go b/pkg/common/container/process/helper_test.go index 53ed22d405..a7802aed5a 100644 --- a/pkg/common/container/process/helper_test.go +++ b/pkg/common/container/process/helper_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package process diff --git a/pkg/common/container/process/winapi.go b/pkg/common/container/process/winapi.go index 87ab25b03c..9d28edf8f2 100644 --- a/pkg/common/container/process/winapi.go +++ b/pkg/common/container/process/winapi.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package process diff --git a/pkg/common/diskutil/file_posix.go b/pkg/common/diskutil/file_posix.go index 09b56d3a82..a47825fd5b 100644 --- a/pkg/common/diskutil/file_posix.go +++ b/pkg/common/diskutil/file_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package diskutil diff --git a/pkg/common/diskutil/file_posix_test.go b/pkg/common/diskutil/file_posix_test.go index 02a629452d..bab3479188 100644 --- a/pkg/common/diskutil/file_posix_test.go +++ b/pkg/common/diskutil/file_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package diskutil diff --git a/pkg/common/diskutil/file_windows.go b/pkg/common/diskutil/file_windows.go index b315d2ce9d..89aff0f6df 100644 --- a/pkg/common/diskutil/file_windows.go +++ b/pkg/common/diskutil/file_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package diskutil diff --git a/pkg/common/diskutil/file_windows_test.go b/pkg/common/diskutil/file_windows_test.go index 99c7c6fb7a..cf6789d87c 100644 --- a/pkg/common/diskutil/file_windows_test.go +++ b/pkg/common/diskutil/file_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package diskutil diff --git a/pkg/common/entrypoint/entrypoint_posix.go b/pkg/common/entrypoint/entrypoint_posix.go index cca596d704..15f64c07d6 100644 --- a/pkg/common/entrypoint/entrypoint_posix.go +++ b/pkg/common/entrypoint/entrypoint_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package entrypoint diff --git a/pkg/common/entrypoint/entrypoint_posix_test.go b/pkg/common/entrypoint/entrypoint_posix_test.go index 81be978781..e6fd62fc8e 100644 --- a/pkg/common/entrypoint/entrypoint_posix_test.go +++ b/pkg/common/entrypoint/entrypoint_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package entrypoint diff --git a/pkg/common/entrypoint/entrypoint_windows.go b/pkg/common/entrypoint/entrypoint_windows.go index eb9d3697cb..c075cea088 100644 --- a/pkg/common/entrypoint/entrypoint_windows.go +++ b/pkg/common/entrypoint/entrypoint_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package entrypoint diff --git a/pkg/common/entrypoint/entrypoint_windows_test.go b/pkg/common/entrypoint/entrypoint_windows_test.go index 457ff4915f..af779ebef0 100644 --- a/pkg/common/entrypoint/entrypoint_windows_test.go +++ b/pkg/common/entrypoint/entrypoint_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package entrypoint diff --git a/pkg/common/entrypoint/service_windows.go b/pkg/common/entrypoint/service_windows.go index b3b27ee2a5..76f8c94553 100644 --- a/pkg/common/entrypoint/service_windows.go +++ b/pkg/common/entrypoint/service_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package entrypoint diff --git a/pkg/common/namedpipe/namedpipe.go b/pkg/common/namedpipe/namedpipe.go index b307ebfb0b..c986b860ed 100644 --- a/pkg/common/namedpipe/namedpipe.go +++ b/pkg/common/namedpipe/namedpipe.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package namedpipe diff --git a/pkg/common/namedpipe/namedpipe_test.go b/pkg/common/namedpipe/namedpipe_test.go index 2268ae8f1b..5211fb0518 100644 --- a/pkg/common/namedpipe/namedpipe_test.go +++ b/pkg/common/namedpipe/namedpipe_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package namedpipe_test diff --git a/pkg/common/peertracker/listener_posix.go b/pkg/common/peertracker/listener_posix.go index 82dae6225c..4fc006586b 100644 --- a/pkg/common/peertracker/listener_posix.go +++ b/pkg/common/peertracker/listener_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package peertracker diff --git a/pkg/common/peertracker/listener_test.go b/pkg/common/peertracker/listener_test.go index c1aaf982fd..6a5cea4119 100644 --- a/pkg/common/peertracker/listener_test.go +++ b/pkg/common/peertracker/listener_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package peertracker diff --git a/pkg/common/peertracker/listener_windows.go b/pkg/common/peertracker/listener_windows.go index 1019028970..58bc94a474 100644 --- a/pkg/common/peertracker/listener_windows.go +++ b/pkg/common/peertracker/listener_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package peertracker diff --git a/pkg/common/peertracker/npipe_fallback.go b/pkg/common/peertracker/npipe_fallback.go index 85e48325f2..8d58f17b66 100644 --- a/pkg/common/peertracker/npipe_fallback.go +++ b/pkg/common/peertracker/npipe_fallback.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package peertracker diff --git a/pkg/common/peertracker/npipe_windows.go b/pkg/common/peertracker/npipe_windows.go index 3bdb9f749c..8dca5b8f5b 100644 --- a/pkg/common/peertracker/npipe_windows.go +++ b/pkg/common/peertracker/npipe_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package peertracker diff --git a/pkg/common/peertracker/peertracker_test_child_posix.go b/pkg/common/peertracker/peertracker_test_child_posix.go index 38a34e66e7..55391d7360 100644 --- a/pkg/common/peertracker/peertracker_test_child_posix.go +++ b/pkg/common/peertracker/peertracker_test_child_posix.go @@ -1,5 +1,4 @@ //go:build ignore -// +build ignore // This file is used during testing. It is built as an external binary // and called from the test suite in order to exercise various peer diff --git a/pkg/common/peertracker/peertracker_test_child_windows.go b/pkg/common/peertracker/peertracker_test_child_windows.go index 546946e4cd..002bf27775 100644 --- a/pkg/common/peertracker/peertracker_test_child_windows.go +++ b/pkg/common/peertracker/peertracker_test_child_windows.go @@ -1,5 +1,4 @@ //go:build ignore -// +build ignore // This file is used during testing. It is built as an external binary // and called from the test suite in order to exercise various peer diff --git a/pkg/common/peertracker/peertracker_test_posix.go b/pkg/common/peertracker/peertracker_test_posix.go index 011787dc80..4096e3929b 100644 --- a/pkg/common/peertracker/peertracker_test_posix.go +++ b/pkg/common/peertracker/peertracker_test_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package peertracker diff --git a/pkg/common/peertracker/peertracker_test_windows.go b/pkg/common/peertracker/peertracker_test_windows.go index 8e68711c33..44fcbfd46b 100644 --- a/pkg/common/peertracker/peertracker_test_windows.go +++ b/pkg/common/peertracker/peertracker_test_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package peertracker diff --git a/pkg/common/peertracker/tracker_bsd.go b/pkg/common/peertracker/tracker_bsd.go index 3b8c9fd7cb..70f96986e8 100644 --- a/pkg/common/peertracker/tracker_bsd.go +++ b/pkg/common/peertracker/tracker_bsd.go @@ -1,5 +1,4 @@ //go:build darwin || freebsd || netbsd || openbsd -// +build darwin freebsd netbsd openbsd package peertracker diff --git a/pkg/common/peertracker/tracker_fallback.go b/pkg/common/peertracker/tracker_fallback.go index 7ac3ba1783..09299502b9 100644 --- a/pkg/common/peertracker/tracker_fallback.go +++ b/pkg/common/peertracker/tracker_fallback.go @@ -1,5 +1,4 @@ //go:build !linux && !darwin && !freebsd && !netbsd && !openbsd && !windows -// +build !linux,!darwin,!freebsd,!netbsd,!openbsd,!windows package peertracker diff --git a/pkg/common/peertracker/tracker_windows.go b/pkg/common/peertracker/tracker_windows.go index 09fbca95d2..9e88618797 100644 --- a/pkg/common/peertracker/tracker_windows.go +++ b/pkg/common/peertracker/tracker_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package peertracker diff --git a/pkg/common/peertracker/tracker_windows_test.go b/pkg/common/peertracker/tracker_windows_test.go index 15d3ed0b01..5904dd78f3 100644 --- a/pkg/common/peertracker/tracker_windows_test.go +++ b/pkg/common/peertracker/tracker_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package peertracker diff --git a/pkg/common/peertracker/uds_bsd.go b/pkg/common/peertracker/uds_bsd.go index 0816e1bd98..8bcedc7318 100644 --- a/pkg/common/peertracker/uds_bsd.go +++ b/pkg/common/peertracker/uds_bsd.go @@ -1,5 +1,4 @@ //go:build darwin || freebsd || netbsd || openbsd -// +build darwin freebsd netbsd openbsd package peertracker diff --git a/pkg/common/peertracker/uds_fallback.go b/pkg/common/peertracker/uds_fallback.go index 4b4d19365e..ee586c05b2 100644 --- a/pkg/common/peertracker/uds_fallback.go +++ b/pkg/common/peertracker/uds_fallback.go @@ -1,5 +1,4 @@ //go:build !linux && !darwin && !freebsd && !netbsd && !openbsd -// +build !linux,!darwin,!freebsd,!netbsd,!openbsd package peertracker diff --git a/pkg/common/sddl/sddl_windows.go b/pkg/common/sddl/sddl_windows.go index 5bd91390b8..eb4621bbb0 100644 --- a/pkg/common/sddl/sddl_windows.go +++ b/pkg/common/sddl/sddl_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package sddl diff --git a/pkg/common/util/addr_posix.go b/pkg/common/util/addr_posix.go index 51f8af8f8d..0af8427cc7 100644 --- a/pkg/common/util/addr_posix.go +++ b/pkg/common/util/addr_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package util diff --git a/pkg/common/util/addr_windows.go b/pkg/common/util/addr_windows.go index 2e8845567f..02398f0dbd 100644 --- a/pkg/common/util/addr_windows.go +++ b/pkg/common/util/addr_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package util diff --git a/pkg/server/api/middleware/audit_posix.go b/pkg/server/api/middleware/audit_posix.go index 48a7e0c0c9..7a6239596c 100644 --- a/pkg/server/api/middleware/audit_posix.go +++ b/pkg/server/api/middleware/audit_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package middleware diff --git a/pkg/server/api/middleware/audit_windows.go b/pkg/server/api/middleware/audit_windows.go index b1638929f5..4f83aa1571 100644 --- a/pkg/server/api/middleware/audit_windows.go +++ b/pkg/server/api/middleware/audit_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package middleware diff --git a/pkg/server/cache/dscache/cache.go b/pkg/server/cache/dscache/cache.go index 90c3958303..5f87a499c6 100644 --- a/pkg/server/cache/dscache/cache.go +++ b/pkg/server/cache/dscache/cache.go @@ -1,6 +1,7 @@ package dscache import ( + "context" "crypto" "sync" "time" @@ -8,7 +9,6 @@ import ( "github.com/andres-erbsen/clock" "github.com/spiffe/spire/pkg/server/datastore" "github.com/spiffe/spire/proto/spire/common" - "golang.org/x/net/context" ) const ( diff --git a/pkg/server/cache/dscache/cache_test.go b/pkg/server/cache/dscache/cache_test.go index bec6017a82..d23c2373ae 100644 --- a/pkg/server/cache/dscache/cache_test.go +++ b/pkg/server/cache/dscache/cache_test.go @@ -1,6 +1,7 @@ package dscache import ( + "context" "encoding/base64" "fmt" "testing" @@ -14,7 +15,6 @@ import ( "github.com/spiffe/spire/test/spiretest" "github.com/spiffe/spire/test/testca" "github.com/stretchr/testify/require" - "golang.org/x/net/context" "google.golang.org/protobuf/proto" ) diff --git a/pkg/server/datastore/sqlstore/sqlite.go b/pkg/server/datastore/sqlstore/sqlite.go index ac1e346f9e..a3e4ff56e2 100644 --- a/pkg/server/datastore/sqlstore/sqlite.go +++ b/pkg/server/datastore/sqlstore/sqlite.go @@ -1,5 +1,4 @@ //go:build cgo -// +build cgo package sqlstore diff --git a/pkg/server/datastore/sqlstore/sqlite_no_cgo.go b/pkg/server/datastore/sqlstore/sqlite_no_cgo.go index 0c48d3333b..a3a9c8805b 100644 --- a/pkg/server/datastore/sqlstore/sqlite_no_cgo.go +++ b/pkg/server/datastore/sqlstore/sqlite_no_cgo.go @@ -1,4 +1,4 @@ -// +build !cgo +//go:build !cgo package sqlstore diff --git a/pkg/server/endpoints/config.go b/pkg/server/endpoints/config.go index ab215061ff..3fd4c33554 100644 --- a/pkg/server/endpoints/config.go +++ b/pkg/server/endpoints/config.go @@ -1,6 +1,7 @@ package endpoints import ( + "context" "crypto" "crypto/x509" "errors" @@ -29,7 +30,6 @@ import ( "github.com/spiffe/spire/pkg/server/catalog" "github.com/spiffe/spire/pkg/server/endpoints/bundle" "github.com/spiffe/spire/pkg/server/svid" - "golang.org/x/net/context" ) // Config is a configuration for endpoints diff --git a/pkg/server/endpoints/endpoints.go b/pkg/server/endpoints/endpoints.go index bb316c0f21..fe3a0116e5 100644 --- a/pkg/server/endpoints/endpoints.go +++ b/pkg/server/endpoints/endpoints.go @@ -1,6 +1,7 @@ package endpoints import ( + "context" "crypto/tls" "crypto/x509" "errors" @@ -11,7 +12,6 @@ import ( "github.com/spiffe/go-spiffe/v2/spiffetls/tlsconfig" "github.com/spiffe/spire/pkg/server/cache/entrycache" "github.com/spiffe/spire/pkg/server/endpoints/bundle" - "golang.org/x/net/context" "golang.org/x/net/http2" "google.golang.org/grpc" "google.golang.org/grpc/credentials" @@ -248,7 +248,8 @@ func (e *Endpoints) runTCPServer(ctx context.Context, server *grpc.Server) error defer l.Close() log := e.Log.WithFields(logrus.Fields{ telemetry.Network: l.Addr().Network(), - telemetry.Address: l.Addr().String()}) + telemetry.Address: l.Addr().String(), + }) // Skip use of tomb here so we don't pollute a clean shutdown with errors log.Info("Starting Server APIs") @@ -291,7 +292,8 @@ func (e *Endpoints) runLocalAccess(ctx context.Context, server *grpc.Server) err log := e.Log.WithFields(logrus.Fields{ telemetry.Network: l.Addr().Network(), - telemetry.Address: l.Addr().String()}) + telemetry.Address: l.Addr().String(), + }) // Skip use of tomb here so we don't pollute a clean shutdown with errors log.Info("Starting Server APIs") diff --git a/pkg/server/endpoints/endpoints_posix.go b/pkg/server/endpoints/endpoints_posix.go index 3c6d81c40c..2d5d719570 100644 --- a/pkg/server/endpoints/endpoints_posix.go +++ b/pkg/server/endpoints/endpoints_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package endpoints diff --git a/pkg/server/endpoints/endpoints_posix_test.go b/pkg/server/endpoints/endpoints_posix_test.go index dcc659b09e..3892b31fd2 100644 --- a/pkg/server/endpoints/endpoints_posix_test.go +++ b/pkg/server/endpoints/endpoints_posix_test.go @@ -1,15 +1,14 @@ //go:build !windows -// +build !windows package endpoints import ( + "context" "net" "path/filepath" "testing" "github.com/spiffe/spire/test/spiretest" - "golang.org/x/net/context" ) func getLocalAddr(t *testing.T) net.Addr { diff --git a/pkg/server/endpoints/endpoints_windows.go b/pkg/server/endpoints/endpoints_windows.go index 64ef371624..2a7266c872 100644 --- a/pkg/server/endpoints/endpoints_windows.go +++ b/pkg/server/endpoints/endpoints_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package endpoints diff --git a/pkg/server/endpoints/endpoints_windows_test.go b/pkg/server/endpoints/endpoints_windows_test.go index 2ced337aee..d003a3f1f5 100644 --- a/pkg/server/endpoints/endpoints_windows_test.go +++ b/pkg/server/endpoints/endpoints_windows_test.go @@ -1,9 +1,9 @@ //go:build windows -// +build windows package endpoints import ( + "context" "fmt" "net" "os" @@ -13,7 +13,6 @@ import ( "github.com/spiffe/spire/pkg/common/util" "github.com/spiffe/spire/test/spiretest" "github.com/stretchr/testify/require" - "golang.org/x/net/context" "golang.org/x/sys/windows" "google.golang.org/grpc" ) diff --git a/pkg/server/endpoints/middleware.go b/pkg/server/endpoints/middleware.go index 1856f095d9..fb4d68de36 100644 --- a/pkg/server/endpoints/middleware.go +++ b/pkg/server/endpoints/middleware.go @@ -1,6 +1,7 @@ package endpoints import ( + "context" "crypto/x509" "github.com/sirupsen/logrus" @@ -18,7 +19,6 @@ import ( "github.com/spiffe/spire/pkg/server/datastore" "github.com/spiffe/spire/proto/spire/common" "github.com/spiffe/spire/test/clock" - "golang.org/x/net/context" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" ) diff --git a/pkg/server/plugin/nodeattestor/tpmdevid/devid_test.go b/pkg/server/plugin/nodeattestor/tpmdevid/devid_test.go index 4a48308f9d..a674505946 100644 --- a/pkg/server/plugin/nodeattestor/tpmdevid/devid_test.go +++ b/pkg/server/plugin/nodeattestor/tpmdevid/devid_test.go @@ -1,5 +1,4 @@ //go:build !darwin -// +build !darwin package tpmdevid_test diff --git a/pkg/server/plugin/upstreamauthority/spire/spire_posix.go b/pkg/server/plugin/upstreamauthority/spire/spire_posix.go index ccaedc2f59..2cfcd3fb37 100644 --- a/pkg/server/plugin/upstreamauthority/spire/spire_posix.go +++ b/pkg/server/plugin/upstreamauthority/spire/spire_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package spireplugin diff --git a/pkg/server/plugin/upstreamauthority/spire/spire_posix_test.go b/pkg/server/plugin/upstreamauthority/spire/spire_posix_test.go index dc30894b32..eaa8654906 100644 --- a/pkg/server/plugin/upstreamauthority/spire/spire_posix_test.go +++ b/pkg/server/plugin/upstreamauthority/spire/spire_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package spireplugin diff --git a/pkg/server/plugin/upstreamauthority/spire/spire_windows.go b/pkg/server/plugin/upstreamauthority/spire/spire_windows.go index e65ca24e3b..85b43d6cb0 100644 --- a/pkg/server/plugin/upstreamauthority/spire/spire_windows.go +++ b/pkg/server/plugin/upstreamauthority/spire/spire_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package spireplugin diff --git a/pkg/server/plugin/upstreamauthority/spire/spire_windows_test.go b/pkg/server/plugin/upstreamauthority/spire/spire_windows_test.go index 584e5d4a50..05467e8d9e 100644 --- a/pkg/server/plugin/upstreamauthority/spire/spire_windows_test.go +++ b/pkg/server/plugin/upstreamauthority/spire/spire_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package spireplugin diff --git a/support/oidc-discovery-provider/config_posix_test.go b/support/oidc-discovery-provider/config_posix_test.go index d19e5f7c1c..55b78b51ab 100644 --- a/support/oidc-discovery-provider/config_posix_test.go +++ b/support/oidc-discovery-provider/config_posix_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package main diff --git a/support/oidc-discovery-provider/config_windows_test.go b/support/oidc-discovery-provider/config_windows_test.go index 896da1d7ed..ffffd8d916 100644 --- a/support/oidc-discovery-provider/config_windows_test.go +++ b/support/oidc-discovery-provider/config_windows_test.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package main diff --git a/support/oidc-discovery-provider/main_posix.go b/support/oidc-discovery-provider/main_posix.go index 7883f51ac9..d61d1091a6 100644 --- a/support/oidc-discovery-provider/main_posix.go +++ b/support/oidc-discovery-provider/main_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package main diff --git a/support/oidc-discovery-provider/main_windows.go b/support/oidc-discovery-provider/main_windows.go index 17c1993efd..a05b5fd32e 100644 --- a/support/oidc-discovery-provider/main_windows.go +++ b/support/oidc-discovery-provider/main_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package main diff --git a/test/integration/setup/svidstore/plugin/disk.go b/test/integration/setup/svidstore/plugin/disk.go index 4c25d28249..407509e596 100644 --- a/test/integration/setup/svidstore/plugin/disk.go +++ b/test/integration/setup/svidstore/plugin/disk.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package main diff --git a/test/integration/setup/svidstore/plugin/disk_test.go b/test/integration/setup/svidstore/plugin/disk_test.go index 6895c8a661..0be39365f7 100644 --- a/test/integration/setup/svidstore/plugin/disk_test.go +++ b/test/integration/setup/svidstore/plugin/disk_test.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package main diff --git a/test/spiretest/errors_posix.go b/test/spiretest/errors_posix.go index acd813c3c1..b8978daa8b 100644 --- a/test/spiretest/errors_posix.go +++ b/test/spiretest/errors_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package spiretest diff --git a/test/spiretest/errors_windows.go b/test/spiretest/errors_windows.go index 6ed6bce50d..c63790169f 100644 --- a/test/spiretest/errors_windows.go +++ b/test/spiretest/errors_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package spiretest diff --git a/test/spiretest/socketapi_posix.go b/test/spiretest/socketapi_posix.go index 4f5f8cdf1e..8a4ff4b1cf 100644 --- a/test/spiretest/socketapi_posix.go +++ b/test/spiretest/socketapi_posix.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package spiretest diff --git a/test/spiretest/socketapi_windows.go b/test/spiretest/socketapi_windows.go index 3b426969bc..567e09ee90 100644 --- a/test/spiretest/socketapi_windows.go +++ b/test/spiretest/socketapi_windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package spiretest diff --git a/test/tpmsimulator/simulator.go b/test/tpmsimulator/simulator.go index d4c44d80c3..83e2c3c6b1 100644 --- a/test/tpmsimulator/simulator.go +++ b/test/tpmsimulator/simulator.go @@ -1,5 +1,4 @@ //go:build !darwin -// +build !darwin package tpmsimulator