Commit Graph
2236 Commits
Author SHA1 Message Date
Brian Joerger 78c19bd65c feat: Hardware Key Agent - Add hardwarekey.Service interface with adapted PIV implementation (#53674)
* Add hardware key service interface; Add mock service for tests.

* Add piv implementation of hardware key service.

* Remove old yubikey parsing logic in favor of hardwarekey.PrivateKeyRef.

* Remove HardwareSigner in favor of hardwarekey.PrivateKey.

* Add test; Cleanup comment; Don't require pin/touch prompts in tests with MockHarwdareKeyService by default.

* Fix tests.

* Add TODOs.

* Use unhashed digest for WarmupHardwareKey.

* Address comments.

* Fix race condition in test service.

* Address comments.
2025-04-09 22:14:19 +00:00
Gavin Frazar fb9eb52fb6 Add tctl support for health check config resources (#53745) 2025-04-09 18:03:38 +00:00
rosstimothy 1f6cd45387 Add benchmark tests to capture init cost (#53637)
https://github.com/gravitational/teleport/issues/53050 was a result
of some expensive initialization that ended up impacting end users.
Existing benchmark tests did not cover this because they do not
actually launch the entire teleport binary.

The cost can be observed via `inittrace`, though it is documented
that the output is not stable and may be changed at any time.

```
GODEBUG='inittrace=1' ./releases/17.4.1/teleport version 2>&1 | rg '^init' | awk '{print $5 " ms " $2}' | sort -n -r | head -10
170 ms github.com/go-mysql-org/go-mysql/server
2.6 ms github.com/microsoft/go-mssqldb/internal/cp
2.6 ms github.com/goccy/go-json/internal/decoder
2.2 ms cloud.google.com/go/compute/apiv1/computepb
2.0 ms github.com/aws/aws-sdk-go/aws/endpoints
1.8 ms k8s.io/client-go/kubernetes/scheme
1.2 ms github.com/gravitational/teleport/lib/kube/proxy
1.2 ms github.com/gogo/protobuf/types
0.78 ms k8s.io/kubectl/pkg/scheme
0.73 ms github.com/gravitational/teleport/lib/kube/proxy/testing/kube_server
```

In order to cover in a stable way, new tests were added to the tool
package of each binary. The tests does one basic thing, re-execute
the test binary and exits. The re-execution is required to account
for any initialization costs that would otherwise be missed since
they happen prior to TestMain being called.
2025-04-09 15:11:39 +00:00
Andrew Burke 1563f87db1 Add session details for agentless sftp sessions (#53360)
This change updates SFTP to emit sftp and sftp_summary events
for sessions on agentless nodes.
2025-04-08 17:36:10 +00:00
Stephen Levine 362fce8c3d [teleport-update] Add local updater metadata (#53602)
* add metadata

* newline

* cleanup status error

* refactor status error

* fix print

* order

* fix test on linux

* Truncate time to ms

* add host param to request

* jitter locally

* rename host to id

* rename func var
2025-04-07 22:05:56 +00:00
Brian Joerger 58f71101d8 feat: Hardware Key Agent - Add api/utils/keys/hardwarekey package (#53671)
* Move hardware key files into new hardwarekey package.

* Tidy up PIVSlot logic and remove its piv-go dependency.

* Add godoc comments to cliPrompt methods; Update cliprompt.go license year.

* Add godocs.
2025-04-07 19:31:11 +00:00
Zac Bergquist 693d110642 fix: use Go 1.18+ build tag syntax (#53746)
All of our supported release branches are well past Go 1.18, so
we don't need to support the old build tag syntax.

Changes made by running `go fix ./...`.
2025-04-07 12:35:51 +00:00
Edoardo Spadolini 2fca5820ed SPIFFE X.509 issuer override: CRUD (#53088)
* SPIFFE X.509 issuer override: CRUD

* tctl support for workload_identity_x509_issuer_override

* Define audit log events

* Emit audit log events

* Add comments to point at the e implementation

* audit events fixtures

* Use DisallowUnknown in tctl
2025-03-28 13:26:09 +00:00
Edoardo Spadolini ccffd6b5be Allow unknown fields when unmarshaling protojson resources (#53469)
* Prohibit implicitly strict protojson unmarshaling

* Avoid jsonpb.Unmarshal

* Define marshal option to disallow unknown fields

* Avoid protojson.Unmarshal

* Disallow unknown fields in tctl create

* Disallow unknown fields in the web UI
2025-03-27 14:35:37 +00:00
Sakshyam Shah 82add5c7ef support awsic plugin --assume-role-arn flag (#53403)
* support awsic plugin assume-role-arn flag

* review comments:
- fix command typo useSystemCredentials -> use-system-credentials
- explain why use-system-credentials is required
2025-03-26 21:47:22 +00:00
Zac Bergquist 8b3a416274 Decouple LDAP from cert generation (#53306)
No functional changes, just a better abstraction. LDAP can be used to
fetch metadata that is included in certificate requests, but LDAP is not
required in order to issue certificates.
2025-03-25 22:18:40 +00:00
Noah Stride eb90f7c179 Workload Identity: Roles Anywhere tbot service. (#52426)
* Add config for WorkloadIdenttiyAWSRAService

* Add CLI command

* Start hacking on service impl

* Write credentials in AWS credentials file format

* Fix go.mod/go.sum

* Go mod tidy

* Add ARN validation

* Add specific config for AWS session duration/renewal

* Update golden file

* Fix gomod/gosum

* Refactor CheckAndSetDefaults

* Initialize service

* Update CLI flags

* Refactor & add tests

* Use *Context slog calls

* Update service name to include full `roles-anywhere`

* Add mocked AWS rolesanywhere API based test

* Validate region
2025-03-25 15:06:20 +00:00
rosstimothy be8fe5c76d Join Kubernetes sessions in the web ui (#52993)
Adds the ability to join existing Kubernetes sessions in the web ui
as peers, observers, or modertators.

Closes #52315.
2025-03-25 14:14:48 +00:00
rosstimothy 6d13e969a5 Reduce resource consumption of ListUnifiedResources (#53213)
The changes here were a result of examining CPU and memory profiles
of BenchmarkListUnifiedResources. The biggest inefficiencies stemmed
from the authorizer and `(types.Server) MatchSearch`.

When the authorizer computes lock targets it will call `(types.LockTarget) Equals`,
which was relying on proto.Equals to determine if nine strings were
equivalent. The fields are now individually checked and a test
was added to ensure that if any new fields are added they must
be added to the check for the test to pass.

ListUnifiedResources attempts to be smart and evaluate whether the
user has read/list access to a particular resource kind once. However,
it was always checking if users had access to _all_ supported resources
instead of just the resources that the user was requesting. While most
of the checks are not very expensive, checking all resources is still
worse than only checking the required resources.

Lastly, the `(types.Server) MatchSearch` implementation is no longer
allocating a slice of search fields and using `types.MatchSearch`.
Instead a variant of the loop from `types.MatchSearch` is inlined.
While this was only applied to `types.Server` it should likely
be extended to other resource types in the future - or `types.MatchSearch`
should be refactored in a way that does not require callers to allocate.

```bash
$ benchstat old.txt new.txt
goos: darwin
goarch: arm64
pkg: github.com/gravitational/teleport/lib/auth
cpu: Apple M2 Pro
                                              │   old.txt   │               new.txt               │
                                              │   sec/op    │   sec/op     vs base                │
ListUnifiedResourcesFilter/labels-12            195.0m ± 6%   173.3m ± 2%  -11.12% (p=0.000 n=10)
ListUnifiedResourcesFilter/predicate_path-12    230.6m ± 3%   210.8m ± 4%   -8.57% (p=0.000 n=10)
ListUnifiedResourcesFilter/predicate_index-12   229.8m ± 5%   209.0m ± 7%   -9.08% (p=0.000 n=10)
ListUnifiedResourcesFilter/search_lower-12      600.6m ± 3%   364.3m ± 1%  -39.35% (p=0.000 n=10)
ListUnifiedResourcesFilter/search_upper-12      687.0m ± 2%   423.4m ± 1%  -38.37% (p=0.000 n=10)
geomean                                         335.7m        259.5m       -22.69%

                                              │    old.txt     │               new.txt                │
                                              │      B/op      │     B/op      vs base                │
ListUnifiedResourcesFilter/labels-12              868.8Ki ± 0%   414.1Ki ± 0%  -52.34% (p=0.000 n=10)
ListUnifiedResourcesFilter/predicate_path-12      7.731Mi ± 0%   7.287Mi ± 0%   -5.74% (p=0.000 n=10)
ListUnifiedResourcesFilter/predicate_index-12     7.731Mi ± 0%   7.288Mi ± 0%   -5.74% (p=0.000 n=10)
ListUnifiedResourcesFilter/search_lower-12      22106.9Ki ± 0%   486.8Ki ± 0%  -97.80% (p=0.000 n=10)
ListUnifiedResourcesFilter/search_upper-12      22107.0Ki ± 0%   486.3Ki ± 0%  -97.80% (p=0.000 n=10)
geomean                                           7.494Mi        1.371Mi       -81.70%

                                              │    old.txt    │               new.txt               │
                                              │   allocs/op   │  allocs/op   vs base                │
ListUnifiedResourcesFilter/labels-12             11.401k ± 0%   4.865k ± 0%  -57.32% (p=0.000 n=10)
ListUnifiedResourcesFilter/predicate_path-12      161.5k ± 0%   155.0k ± 0%   -4.04% (p=0.000 n=10)
ListUnifiedResourcesFilter/predicate_index-12     161.5k ± 0%   155.0k ± 0%   -4.04% (p=0.000 n=10)
ListUnifiedResourcesFilter/search_lower-12      162.212k ± 0%   5.277k ± 0%  -96.75% (p=0.000 n=10)
ListUnifiedResourcesFilter/search_upper-12      162.224k ± 0%   5.275k ± 0%  -96.75% (p=0.000 n=10)
geomean                                           95.22k        20.07k       -78.93%

```
2025-03-21 19:20:55 +00:00
STeve (Xin) Huang 5ea6361215 make sure db route is converted from tlsca to proto (#53246) 2025-03-21 14:20:37 +00:00
Noah StrideandMarco Dinis 0586278cde Migrate GetClusterName to gRPC (#53164)
* Adjust GetClusterName method signature to include context.Context

* Start hacking on gRPC GetClusterName impl

* Fix test mocks to match signature

* Fix integration tests

* Fix integrations tests

* Missing ctx

* New GetClusterName RPC implementatin

* Add fallback cluster name

* Correct godoc comment

* Remove unused method

* Remove unused import

* Fix E2E test

* Fix tests

* Fix deferred context cancel in test conflicting with parallel subtests

* Fix import

* Fix imports

* Update lib/auth/auth_with_roles.go

Co-authored-by: Marco Dinis <marco.dinis@goteleport.com>

---------

Co-authored-by: Marco Dinis <marco.dinis@goteleport.com>
2025-03-20 10:07:02 +00:00
Krzysztof Skrzętnicki 7d7e9d3fe3 Support -oSendEnv in tsh (#53010)
* Support `-oSendEnv` in `tsh`

* Fix spelling
2025-03-20 07:52:45 +00:00
Hugo Shaka 81494f1051 Add autoupdate trigger/mark-done/rollback commands (#52933) 2025-03-19 18:17:20 +00:00
Stephen Levine ca30c3d84a [teleport-update] Additional log message and UX cleanup (#53180)
* More teleport-update UX cleanup

* cleanup overwrite error

* cleanup

* more cleanup
2025-03-19 17:04:50 +00:00
Noah Stride f0f3e5c2a6 Remove deprecated ReverseTunnel functions (#53084)
* Remove deprecated ReverseTunnel functions

* Add notimplemented handler
2025-03-19 14:42:00 +00:00
Trent ClarkeandZac Bergquist 2a0b76e749 Adds AWS Role ARN to IC Integration settings (#53024)
* Adds AWS Role ARN to IC Integration settings

The Identity Center integration needs to be able to assume an AWS role
when using the ambient system credentials. This patch updates the IC
integration protobuf definition to include the role ARN, by refactoring
the settings block to replace the CredentialSource enumeration with a
`Credentials` type containing a `oneof` union of System and OIDC credential blocks.

The CredentalSource value is preserved for backwards compatibility with previous
Teleport releases.

This patch includes
- the updated protobuf message and generated types
- update tests, etc
- updated `tctl` to handle new plugin settings structure

Chagnges required to actually use this information are coming in a later PR.

* Apply suggestions from code review

Co-authored-by: Zac Bergquist <zac.bergquist@goteleport.com>

* Rename role ARN

---------

Co-authored-by: Zac Bergquist <zac.bergquist@goteleport.com>
2025-03-13 15:14:12 +00:00
William Loyandrosstimothy bb142edbbf Adding --join-method flag to teleport configure command (#52937)
* Update teleport.go

* added all newly supported join methods

* Added Tim's suggestions

* Update tool/teleport/common/teleport.go

Co-authored-by: rosstimothy <39066650+rosstimothy@users.noreply.github.com>

* Update tool/teleport/common/teleport.go

Co-authored-by: rosstimothy <39066650+rosstimothy@users.noreply.github.com>

---------

Co-authored-by: rosstimothy <39066650+rosstimothy@users.noreply.github.com>
2025-03-13 02:56:58 +00:00
Stephen Levine 50dad3ecdd [teleport-update] Improve clarity of error logs and address UX edge cases (#52777)
* Usability fixes

* cancel jitter

* root + fix logs

* check extra case

* cleanup

* extra warning

* tests

* feedback

* add newlines

* adjust message

* consistent error type
2025-03-12 18:53:00 +00:00
Forrest ee8fd94082 implement ssh access decision method prototype (#52542)
* implement ssh access decision method prototype

* improve internal ssh extension handling
2025-03-11 10:31:55 +00:00
Zac Bergquist b0049ecc2a Remove the custom current user lookup function (#52144)
We added this function to mitigate slow user.Current() calls in
Windows Active Directory environments. Go 1.24 ships with an optimized
verison of user.Current, rendering this utility unnecessary.

Closes #41922
2025-03-04 23:43:54 +00:00
Stephen Levine 2ce55778f5 [teleport-update] Set umask 0022 for teleport-update to avoid errors on enable (#52725)
* Set umask 0022 for teleport-update

* init -> main

* refactor

* move const

* add flag

* missed not

* fix inequality

* remove flag

* dead code

* docs

* docs 2

* feedback
2025-03-04 16:44:12 +00:00
Hugo Shaka 6e95ac6b87 Set the autoupdate singleton names (#52646) 2025-03-03 14:22:46 +00:00
Steven Martin e95534e975 Update Platform name to Teleport Infrastructure Identity Platform (#52464) 2025-02-28 20:38:53 +00:00
0212ee6730 Update tctl reference docs with autoupdate commands (#52455)
* Update `tctl` reference docs with autoupdate commands

* Documentation feedback

---------

Co-authored-by: Paul Gottschling <paul.gottschling@goteleport.com>

* Update docs/pages/reference/cli/tctl.mdx

Co-authored-by: Zac Bergquist <zac.bergquist@goteleport.com>

---------

Co-authored-by: Paul Gottschling <paul.gottschling@goteleport.com>
Co-authored-by: Zac Bergquist <zac.bergquist@goteleport.com>
2025-02-28 17:39:02 +00:00
Steven Martin 9cbd1fa353 Fix spelling for key agent error message (#52611) 2025-02-28 16:51:21 +00:00
Gabriel Corado d1642024ad Migrate app access endpoint resolution to AWS SDK V2 (#52042)
* refactor: remove aws access endpoint url mode

* refactor(app): remove depency on aws resolved endpoint struct

* test(aws): update handler tests

* refactor(tsh): remove remaining references to endpoint-url mode

* refactor(aws): simplify resolveEndpoint function

* chore(changelog): add breaking change note

* fix(aws): incorrect resolve function call

* fix(aws): fix wrong auth header usage

* refactor(aws): code review suggetion
2025-02-28 16:17:02 +00:00
Stephen Levine f3d2b45ac4 [teleport-update] Fix usage of default $PATH dir (#52604)
* Fix usage of default path

* fix other overrides

* fix hang on start
2025-02-28 03:39:50 +00:00
Trent ClarkeandMarek Smoliński af764c78f5 Adds edit support for IC plugin to tctl edit (#52243)
* Adds edit support for IC plugin to `tctl edit`

This patch expands the plugin resource unmarshaler in `tctl` to handle the
heterogenous filters used by the Identity Center plugin settings. It also adds
support for the IC status block.

These changes allow a user to edit the plugin resource via `tctl edit` after
installation.

* Why not use protojson? Well...

* Update collection.go

* Add json.(un)MarshalJSON implementations father than structure unpacking

* Dead code removal

* Apply suggestions from code review

Co-authored-by: Marek Smoliński <marek@goteleport.com>

* Apply review feedback

---------

Co-authored-by: Marek Smoliński <marek@goteleport.com>
2025-02-28 01:15:18 +00:00
Rafał Cieślak 10f8b7629d Run diag checks periodically in Connect (#52461)
* RouteConflictDiag: Refetch routes if no VNet routes found

* Run diagnostics periodically in Connect

* Handle manual diag re-run being superseded by periodic diag run

* Dismiss alerts until re-running diags manually

* Filter out command output from Connect logs
2025-02-27 08:05:41 +00:00
rosstimothy 48d685ebf4 Fix test flakes related to Kubernetes user cert generation (#52442)
#52109 added a dependency on the unified resource cache to user
cert generation to reduce resource consumption. A number of tests
that exercise generating Kubernetes user certs were either not
waiting for the Kubernetes resources to exist prior to authentication
and getting lucky, or checking that the resources were in the auth
cache, but not the unified resource cache.

This attempts to cover any tests which generate Kubernetes user
certificates to verify that the unified resource cache contains
the expected cluster before proceeding.

Fixes #52157.
Fixes #52441.
2025-02-26 18:51:10 +00:00
Noah StrideandDan Upton 0fb8f91c29 Workload Identity Revocations Signing (#52353)
* Add initial implementation of CRL signing

* Clarify

* Add basic support for streaming signed CRL to `tctl`

* Add log messages

* Start adding CRL support to tbot

* Wire in CRL support to workload-identity-x509

* Wire up crlCache to dependent services

* Fix missing cluster name injectiont

* Run the background goroutine

* FIx notification mechanism

* Add CRL assertions to TestBotWorkloadIdentityX509

* Add appropriate backoff to RevocationService

* Start work on TestRevocationService_CRL

* Change comparison in test

* Finish TestRevocationService_CRL

* Add CRL assertion to TestBotWorkloadIdentityAPI

* Fix linter complaint

* Update lib/tbot/service_workload_identity_api_test.go

Co-authored-by: Dan Upton <daniel.upton@goteleport.com>

* Update lib/tbot/service_workload_identity_api_test.go

Co-authored-by: Dan Upton <daniel.upton@goteleport.com>

* Rename KeyStorer

* Trigger CRL signing every ten minutes

* ADd SVIDCRLPemPath to Describe

---------

Co-authored-by: Dan Upton <daniel.upton@goteleport.com>
2025-02-26 11:03:01 +00:00
STeve (Xin) Huang a344745017 GitHub proxy: git to prompt for password when tsh session expires (#51305)
* GitHub proxy: git to prompt for password when tsh session expires

* replace reference

* set ctx
2025-02-25 16:14:15 +00:00
Vadym Popov fe85a7304f Add re-executed from version to version command output (#52409) 2025-02-24 22:39:25 +00:00
Steven Martin 9ce2eb2c9c Update references to Kubernetes in cli and error messages (#52411) 2025-02-24 11:45:29 +00:00
Hugo Shaka 59ded01eb3 Add install script using teleport-update and oneoff.sh (#52155) 2025-02-21 15:22:43 +00:00
Nic Klaassen 023f50b0ea [vnet] add vnet-(un)install-service commands for Windows (#52164) 2025-02-20 18:37:37 +00:00
Marco Dinis 4fc9727324 WebAPI: Add state as filter for UserTasks listing endpoint (#52191)
* WebAPI: Add state as filter for UserTasks listing endpoint

* fix pagination bug

* Add filters param to ListUserTasks
2025-02-20 09:24:06 +00:00
8f02eb11df Add tctl plugins install awsic (#51239)
* Adds `tctl plugins install awsic`

Adds a comand-line installation tool for the AWS Identity Center integration.

Co-authored-by: Marek Smoliński <marek@goteleport.com>
Co-authored-by: Trent Clatke <trent@goteleport.com>

* Apply suggestions from code review

Co-authored-by: Zac Bergquist <zac.bergquist@goteleport.com>

---------

Co-authored-by: Trent Clatke <trent@goteleport.com>
Co-authored-by: Zac Bergquist <zac.bergquist@goteleport.com>
2025-02-19 22:29:29 +00:00
Noah Stride dac3faaac0 tctl support for Workload Identity revocations (#52122)
* Add support to basic tctl resource commands

* First pass at adding CRUD commands

* Add tests

* Remove unused field
2025-02-19 13:28:07 +00:00
Rafał Cieślak a06fc22de7 VNet diag report: Add protos and tshd implementation (#52066)
* lib/teleterm/vnet: Collect CIDR ranges while listing DNS zones

This will be used for the diagnostic report.

* Include IPv6Prefix in NetworkStackInfo

* Refactor RouteConflict into a protobuf struct

* Add protos for diagnostic report

* Add Diagnostician for generating diag report

* Add netstat command for route conflict check

* Send diag report from tshd to Electron app

* Remove unnecessary Diagnostician struct

* Return nil instead of an empty slice

* s/is supposed to return/returns/

* Capture stderr of failed command attempt

* Check if command stdout and stderr are valid UTF-8 text
2025-02-19 12:10:32 +00:00
Stephen Levine df433832ca [teleport-update] Ensure stable interface between versions of teleport-update (#52152)
* refactor data dir

* finish refactor

* fix path

* cleanup

* more tests

* lint

* prevent notice failure without systemd

* feedback

* url
2025-02-18 23:26:13 +00:00
rosstimothy 7624a36db5 Prevent loading default config in tctl on Windows (#52184)
On Windows tctl will attempt to load a teleport config file from
the default path of C:\etc\teleport.yaml. However, on Windows,
C:\etc\ does not exist by default, and may be created by any user.

This could potentially allow an unprivileged user to trick tctl
into loading a malicious teleport.yaml file and perform some kind
of MITM attack. In practice, this attack would have to be quite
sophisticated since tctl does check the data directory defined in
the config file and requires a host_uuid and a valid admin identity
before proceeding with using the local credentials.

If this behavior is to be restored in the future, the default
config path on Windows should be changed to something that respects
Windows path conventions.
2025-02-14 17:05:49 +00:00
Dan Upton fd2edb678c Machine ID: Per-ouput credential_ttl and renewal_interval (#51956)
* Move `CertificateTTL` and `RenewalInterval` into a `CertificateLifetime` struct

These values are always required together, and moving them into a struct will
make it more straightforward to override them per-service/output.

* Support custom `certificate_ttl` and `renewal_interval` on identity output

* Support custom `certificate_ttl` and `renewal_interval` on application output

* Support custom `certificate_ttl` and `renewal_interval` on application tunnel

* Support custom `certificate_ttl` and `renewal_interval` on Kubernetes output

* Support custom `certificate_ttl` and `renewal_interval` on Kubernetes V2 output

* Support custom `certificate_ttl` and `renewal_interval` on database tunnel

* Support custom `certificate_ttl` and `renewal_interval` on SSH host output

* Support custom `certificate_ttl` and `renewal_interval` on SSH multiplexer

* Support custom `certificate_ttl` and `renewal_interval` on SPIFFE SVID output

* Support custom `certificate_ttl` and `renewal_interval` on database output

* Support custom `certificate_ttl` and `renewal_interval` on workload API

* Support custom `certificate_ttl` and `renewal_interval` on workload identity output

* Add `GetCertificateLifetime` to service config interface

* Update the docs

* Add more examples to the standard config

* Rename `CertificateLifetime` to `CredentialLifetime`

So it can be used for non-certificate credentials like JWTs

* Deprecate `certificate_ttl` option and replace it with `credential_ttl`

* Return TTL warnings as errors and let the caller decide what to do with them

* Add `CredentialLifetime` to the "full" service config tests

* Support `credential_ttl` and `renewal_interval` in workload-identity-jwt service

* Silence sloglint

* Replace duplicated helper with `cmp.Or`
2025-02-14 14:42:17 +00:00
Noah Stride 23e697ab60 Deprecate old Workload Identity UX (#52074)
* Add deprecation warnings regarding old Workload Identity RPC/Config

* Fix RPC name in log warning

* Hide deprecated command group in tsh
2025-02-14 09:22:38 +00:00
rosstimothy 8a5107ceea Reduce resource consumption when generating Kubernetes certificates (#52109)
Closes https://github.com/gravitational/teleport/issues/52073.

The requested Kubernetes cluster is now cross referenced with the
KubeServers in the unified resource cache. This results in a
reduction in CPU, memory, and cert generation latency. This also
cleans up some of the helper functions in lib/kube/utils that
were no longer needed, and suboptimal.

The client side changes here shouldn't have any impact, as the
server is performing the same check, and returning the equivalent
error the client side code used to. This will also cut the time
of `tctl auth sign` in half as both the client and server were
performing the same expensive CheckKubeCluster operation.
2025-02-13 19:27:19 +00:00