Commit graph

11425 commits

Author SHA1 Message Date
Zac Bergquist 3cefb38890
Update xterm-addon-fit (#20696)
This resolves an issue when starting an SSH session from the web UI,
and also fixes the out-of-date lock file.
2023-01-25 20:05:58 +00:00
Reed Loden 278e74d260
ci: Use large macOS runner for build-macos workflow (#20713)
Use larger macOS runner with GitHub Actions to speed up builds.

Comment-only change to `client.go` to cause macOS build to be run.
2023-01-25 19:39:22 +00:00
Łukasz Kozłowski 84ac0ed936
Encode PNGs in Rust (#20127)
Encode PNGs in Rust
2023-01-25 18:54:50 +00:00
Nic Klaassen ff9e60fdf0
feat: evaluate login rules for GitHub users (#20627)
This commit enables login rule evaluation during login for users logging
in with a GitHub connector.

The GitHub connector is a bit different from the SAML and OIDC
connectors in that the user roles are not mapped from the traits
(claims/assertions) but from the user's GitHub organizations and teams
directly.
This makes login rules slightly less useful for GitHub logins because
they cannot affect the user's roles, only their traits.
However, GitHub login is mostly an OSS feature and login rules will be
enterprise-only.
Any enterprise users making use of GitHub login will still be able to
use some of the features (trait mapping).
2023-01-25 18:38:33 +00:00
Nic Klaassen 3839483513 feat: add login rule audit event types (#20649)
This commit adds the types necessary in order to add audit events for
login rule resource actions.
The emission of these events will be added in a separate commit to
teleport.e, and the frontend display will be added later (currently
these show up as "Unknown" events).
2023-01-25 10:22:43 -08:00
Nic Klaassen 651fd189b0 feat: add RW verbs for login rules to preset editor role (#20648) 2023-01-25 10:22:43 -08:00
Ryan Clark 42ec01c88a
Refactor features, implement new design for navigation & user menu (#20553) 2023-01-25 17:53:59 +00:00
Ryan Clark 27ad839d47
Move jest, eslint & prettier to the root (#20698)
* Move jest, eslint & prettier to the root

* Update e ref
2023-01-25 17:19:22 +00:00
Gavin Frazar 08e3f75925
Fix SQLServer discovery config generation (#20496)
* Add tests for untested discovery flags (SQLServer, ElastiCache, MemoryDB)
2023-01-25 16:53:18 +00:00
Hugo Shaka 210e59c366
helm: fix operator invalid mounts with TLS secret (#20641)
Fixes an issue where the operator sidecar tries to mount the public TLS certificates but the volume is not declared.

```
$ helm install -n teleport teleport-repro /home/shaka/work/teleport/examples/chart/teleport-cluster --set teleportVersionOverride=12.0.0-alpha.1 --set clusterName=teleport.example.com --set tls.existingSecretName=my-tls-secret --set tls.existingCASecretName=my-root-ca --set operator.enabled=true
# [...]
Error: INSTALLATION FAILED: Deployment.apps "teleport-repro-auth" is invalid: spec.template.spec.containers[1].volumeMounts[0].name: Not found: "teleport-tls"
```

The operator does not need those certs to work.
2023-01-25 16:11:31 +00:00
Paul Schisa 986c7f0196
Update ssh-approval-email.mdx (#20691)
Fix the step numbers
2023-01-25 15:05:56 +00:00
rosstimothy 8819d9d954
v12 loadtest updates (#20614) 2023-01-25 14:54:21 +00:00
rosstimothy 70c0c87678
Move connection metrics to proxy.Router (#20646)
Migrates metrics counting proxied connections and connection attempts
from `regular/proxy.go` to `proxy.Router` so that connections via
the web UI, tsh ssh via the Proxy ssh and grpc servers are all
accounted for.
2023-01-25 14:36:47 +00:00
Hugo Shaka b23dcd680a
helm: default 2fa to on instead of otp (#20631)
This change adds support for FIDO2/webauthn/hardware tokens by default.
OTP 2fa fill remains functional. This is a major change and should be
part of a major release, even if this should be seamless for most users.

Warning: `webauthn.rp_id` should not change in the cluster life, else
2fa tokens will have to be re-registered.

Users accessing the cluster under a different name than `clusterName`
will have to set rp_id
(`auth.teleportConfig.auth_service.authentication.webauthn.rp_id`) to be
able to register second factors. As we strongly encourage users to have
a resolvable `clusterName` and `publicAddr` support got added recently,
this seems an acceptable edge case.
2023-01-25 13:10:25 +00:00
rosstimothy d6ef2bedc5
Enforce using github.com/google/uuid (#20633) 2023-01-25 12:54:30 +00:00
Edward Dowling 9ac550af2d
Reject access requests with invalid cluster names (#20472) 2023-01-25 12:31:46 +00:00
Krzysztof Skrzętnicki 5cef56d60f
Relax regexp checking Azure identities: allow underscores in two parts. (#20593) 2023-01-25 11:22:42 +00:00
Marco André Dinis 927f52164f
Fix typo in install-node script's usage message (#20664)
* Fix typo in install-node script's usage message

* Update lib/web/scripts/node-join/install.sh

Co-authored-by: Łukasz Kozłowski <lukasz.kozlowski@goteleport.com>
2023-01-25 11:04:39 +00:00
Grzegorz Zdunek f42e5966bd
Send Connect usage events before tshd closes (#20265) 2023-01-25 10:12:37 +00:00
rosstimothy 4cc1c76e4d
Batched dependabot updates (#20624)
* Update rsa requirement in /lib/srv/desktop/rdp/rdpclient

Updates the requirements on [rsa](https://github.com/RustCrypto/RSA) to permit the latest version.
- [Release notes](https://github.com/RustCrypto/RSA/releases)
- [Changelog](https://github.com/RustCrypto/RSA/blob/master/CHANGELOG.md)
- [Commits](https://github.com/RustCrypto/RSA/compare/v0.7.2...v0.8.1)

---
updated-dependencies:
- dependency-name: rsa
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>

* Bump rsa from 0.7.2 to 0.8.1

Bumps [rsa](https://github.com/RustCrypto/RSA) from 0.7.2 to 0.8.1.
- [Release notes](https://github.com/RustCrypto/RSA/releases)
- [Changelog](https://github.com/RustCrypto/RSA/blob/master/CHANGELOG.md)
- [Commits](https://github.com/RustCrypto/RSA/compare/v0.7.2...v0.8.1)

---
updated-dependencies:
- dependency-name: rsa
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* Bump github.com/gravitational/trace from 1.2.0 to 1.2.1 in /api

Bumps [github.com/gravitational/trace](https://github.com/gravitational/trace) from 1.2.0 to 1.2.1.
- [Release notes](https://github.com/gravitational/trace/releases)
- [Commits](https://github.com/gravitational/trace/compare/v1.2.0...v1.2.1)

---
updated-dependencies:
- dependency-name: github.com/gravitational/trace
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* Bump github.com/aws/aws-sdk-go from 1.44.180 to 1.44.184

Bumps [github.com/aws/aws-sdk-go](https://github.com/aws/aws-sdk-go) from 1.44.180 to 1.44.184.
- [Release notes](https://github.com/aws/aws-sdk-go/releases)
- [Commits](https://github.com/aws/aws-sdk-go/compare/v1.44.180...v1.44.184)

---
updated-dependencies:
- dependency-name: github.com/aws/aws-sdk-go
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* Bump github.com/coreos/go-semver from 0.3.0 to 0.3.1

Bumps [github.com/coreos/go-semver](https://github.com/coreos/go-semver) from 0.3.0 to 0.3.1.
- [Release notes](https://github.com/coreos/go-semver/releases)
- [Commits](https://github.com/coreos/go-semver/compare/v0.3.0...v0.3.1)

---
updated-dependencies:
- dependency-name: github.com/coreos/go-semver
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* Bump k8s.io/apimachinery from 0.26.0 to 0.26.1

Bumps [k8s.io/apimachinery](https://github.com/kubernetes/apimachinery) from 0.26.0 to 0.26.1.
- [Release notes](https://github.com/kubernetes/apimachinery/releases)
- [Commits](https://github.com/kubernetes/apimachinery/compare/v0.26.0...v0.26.1)

---
updated-dependencies:
- dependency-name: k8s.io/apimachinery
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* Bump github.com/aws/aws-sdk-go-v2/service/ec2 from 1.78.0 to 1.80.0

Bumps [github.com/aws/aws-sdk-go-v2/service/ec2](https://github.com/aws/aws-sdk-go-v2) from 1.78.0 to 1.80.0.
- [Release notes](https://github.com/aws/aws-sdk-go-v2/releases)
- [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/CHANGELOG.md)
- [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/ec2/v1.78.0...service/ec2/v1.80.0)

---
updated-dependencies:
- dependency-name: github.com/aws/aws-sdk-go-v2/service/ec2
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* Bump k8s.io/api from 0.26.0 to 0.26.1

Bumps [k8s.io/api](https://github.com/kubernetes/api) from 0.26.0 to 0.26.1.
- [Release notes](https://github.com/kubernetes/api/releases)
- [Commits](https://github.com/kubernetes/api/compare/v0.26.0...v0.26.1)

---
updated-dependencies:
- dependency-name: k8s.io/api
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* Bump cloud.google.com/go/storage from 1.28.1 to 1.29.0

Bumps [cloud.google.com/go/storage](https://github.com/googleapis/google-cloud-go) from 1.28.1 to 1.29.0.
- [Release notes](https://github.com/googleapis/google-cloud-go/releases)
- [Changelog](https://github.com/googleapis/google-cloud-go/blob/main/CHANGES.md)
- [Commits](https://github.com/googleapis/google-cloud-go/compare/storage/v1.28.1...spanner/v1.29.0)

---
updated-dependencies:
- dependency-name: cloud.google.com/go/storage
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* Bump k8s.io/cli-runtime from 0.26.0 to 0.26.1

Bumps [k8s.io/cli-runtime](https://github.com/kubernetes/cli-runtime) from 0.26.0 to 0.26.1.
- [Release notes](https://github.com/kubernetes/cli-runtime/releases)
- [Commits](https://github.com/kubernetes/cli-runtime/compare/v0.26.0...v0.26.1)

---
updated-dependencies:
- dependency-name: k8s.io/cli-runtime
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* revert firestore to v1.6.0

* Bump k8s.io/kubectl from 0.26.0 to 0.26.1

Bumps [k8s.io/kubectl](https://github.com/kubernetes/kubectl) from 0.26.0 to 0.26.1.
- [Release notes](https://github.com/kubernetes/kubectl/releases)
- [Commits](https://github.com/kubernetes/kubectl/compare/v0.26.0...v0.26.1)

---
updated-dependencies:
- dependency-name: k8s.io/kubectl
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* Bump k8s.io/client-go from 0.26.0 to 0.26.1

Bumps [k8s.io/client-go](https://github.com/kubernetes/client-go) from 0.26.0 to 0.26.1.
- [Release notes](https://github.com/kubernetes/client-go/releases)
- [Changelog](https://github.com/kubernetes/client-go/blob/master/CHANGELOG.md)
- [Commits](https://github.com/kubernetes/client-go/compare/v0.26.0...v0.26.1)

---
updated-dependencies:
- dependency-name: k8s.io/client-go
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* Bump k8s.io/apiserver from 0.26.0 to 0.26.1

Bumps [k8s.io/apiserver](https://github.com/kubernetes/apiserver) from 0.26.0 to 0.26.1.
- [Release notes](https://github.com/kubernetes/apiserver/releases)
- [Commits](https://github.com/kubernetes/apiserver/compare/v0.26.0...v0.26.1)

---
updated-dependencies:
- dependency-name: k8s.io/apiserver
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* use firestore v1.6.1

* go mod tidy

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot-batcher[bot] <122306277+dependabot-batcher[bot]@users.noreply.github.com>
2023-01-25 00:25:59 +00:00
rosstimothy 362cb46412
Add test that verifies connectivity when Auth is down (#20450)
Ensures that if a user has a valid certificate and Auth is down
that they can still establish a session to nodes.
2023-01-24 21:07:11 +00:00
Nic Klaassen e89b9b8893
feat: add login rule evaluator to auth.Server (#20514)
This enables the enterprise plugin to install the real login rule
evaluator implementation during enterprise process startup.
2023-01-24 18:48:55 +00:00
Vitor Enes 06c313f47f
Show client_idle_timeout_message for windows access (#20576)
This commit sets the `IdleTimeoutMessage` in the windows server
`MonitorConfig`, which ensures that the `client_idle_timeout_message`
will be written to the `MessageWriter` upon a client timeout
(see `Monitor.start`).
2023-01-24 18:26:24 +00:00
Brian Joerger ccff88c282
Fix key attestation error on tsh login (#20314) 2023-01-24 17:57:55 +00:00
Brian Joerger 5b6e2ada79
Test plan additions (#20586) 2023-01-24 17:41:45 +00:00
Ryan Clark 87abbb8e49
Alert ack API + CLI implementation (#19480)
Co-authored-by: Forrest Marshall <forrest@goteleport.com>
2023-01-24 17:30:07 +00:00
Hugo Shaka 9262f95665
helm: add resources to load-test the Helm chart (#19754) 2023-01-24 15:45:44 +00:00
Rafał Cieślak 9b7355cd20
Connect: Add useWorkspaceLoggedInUser (#20552) 2023-01-24 15:31:39 +00:00
Alex McGrath 66985553db
Add agentless installer in the teleport discovery service (#19648)
* Add agentless installer

* Resolve comments

* Resolve comments

* Use GetCertAuthorities locally

* Try to get IMDS hostname

* Try get imds hostname first

This seems to be how its implemented for non-agentless nodes

* Use FIPS cipher suites

* use the openssh ca, resolve comments

* write keys to /etc/teleport/agentless by default

* Resolve comment

* lints

* test fixes
2023-01-24 14:49:06 +00:00
Alex McGrath 2eb418359d
Convert rhel VERSION_IDs to only include the major version (#20403)
* Convert rhel `VERSION_ID`s to only include the major version

* shfmt
2023-01-24 12:32:47 +00:00
Krzysztof Skrzętnicki af5716a9a7
Fix two issues with Oracle MySQL client on Windows. (#20397)
* Add `--defaults-extra-file` as `~/.my.cnf` is not read on Windows.

* Escape `\` as `\\` in paths saved to the config file.
2023-01-24 09:36:47 +00:00
Rafał Cieślak c4897417fe
Add integration test for deamon.Service.AddCluster (#20332)
* Add integration test for daemon.Service.AddCluster

* Call SaveProfile on clusterClient rather than cfg

This way we don't have to explicitly set ClientStore as
client.NewClient(cfg) does that for us.
2023-01-24 08:10:02 +00:00
fheinecke a86f53ca03
Fixed incorrect container image branch version numbers (#20585) 2023-01-24 02:08:36 +00:00
Jakub Nyckowski c1f59a1803
Disconnect moderated session on Ctrl+C (#20580)
* Disconnect moderated session on Ctrl+C

* Add moderated session to the test plan.
2023-01-24 01:37:34 +00:00
Jeff Pihach 0f21a8b8e3
Resolve issues to enable passing CI tests. (#20582)
* Move lint commands to root package.json

* Correctly resolve e-teleport paths.

* Fix prettier issues.

* move eslint configuration files to root.

* resolve lint errors.
2023-01-23 22:06:56 +00:00
Steven Martin dfd3acbc5f
Docker install doc updates (#19783)
* Includes in commericial pre-req to have a enterprise account.  Uses includes on how to get a license file.

* Showed how to use the arm version. Removed comment that only x86_64 are provided.

* includes amd64, arm and arm64 include descriptions

* Updates to GCp to show enterprise installation.
2023-01-23 20:09:37 +00:00
Tiago Silva ddd1055552
fix tctl auth sign --format kubernetes when using remote auth server (#20497)
This PR fixes `tctl auth sign --format kubernetes`  when used with remote auth servers running with multiplex mode.

Fixes #20499
2023-01-23 19:02:42 +00:00
Mike Jensen 261dce259f
dependabot-batcher - Specify environment (#20563)
The environment needs to be specified to have access tot he GitHub App auth.
2023-01-23 18:41:52 +00:00
David Boslee 06ba6ec7b1
Fix kube access proxy peering compatibility (#20561)
The change from kube_service to kube_server in v11
lead to breaking backwards compatibility for v10 agents
connecting to a v11 teleport cluster when proxy peering
is enabled.

The issue was in converting from a kube_service to kube_server
the proxy ids the kube agent is connected to was never copied.

This leads to kube agents being reachable through the proxy
they are connected to but not through peer proxies.
2023-01-23 18:20:22 +00:00
Marco André Dinis 5dcd49cff1
Fix: change var to inner scope's Testing t (#20560) 2023-01-23 18:38:59 +01:00
Krzysztof Skrzętnicki 4a8658ab25
Change Azure and GCP server-side handlers to ensure timeout tests pass. (#20281)
* Change Azure and GCP server-side handlers to ensure timeout tests pass.

Co-authored-by: Edoardo Spadolini <edoardo.spadolini@goteleport.com>
2023-01-23 15:24:10 +00:00
Tiago Silva 10da451dd6
Add support for subResourceName to teleterm (#20541)
Initial support for `subResourceName` when listing resource access requests for `type=pod`.
2023-01-23 15:06:01 +00:00
Tiago Silva 605a7d00f4
Adds tsh kubectl support (#20031)
This PR implements a `kubectl` wrapper inside `tsh` that creates resource access requests, waits for their approval and retries the command when it detects that access to a pod was denied due to missing role or Kubernetes RBAC principals permissions.


Part of #18434
Updates #19573
2023-01-23 14:34:40 +00:00
Mike Jensen 2235827c0e
Update dependabot-batcher to use GitHub app for authentication (#20342) 2023-01-23 13:42:39 +00:00
Rafał Cieślak b94edcf450
Move tsconfig.json to root dir, remove web Makefile and Dockerfile (#20399)
* Move tsconfig.json to root dir

At the moment, it looks like the TS language server has problems with
recognizing imports when editing files inside e/web.

I figured this is probably because tsconfig.json is in web, so the lang
server doesn't recognize it when editing files from e/web.

* Remove web/Dockerfile and web/Makefile

* Misc updates to readme

* Fix links in readme
2023-01-23 11:50:16 +00:00
Zac Bergquist 6a2ed69567
tctl edit: get the original resource name from the file (#20362)
This ensures we correctly detect attempts to rename even when
aliases are used for dynamic resources like `cap`.
2023-01-22 14:45:00 +00:00
Tiago Silva 10045bd349
Increase ReadDeadline to accommodate slow clients (#20468)
Increases deadline until the agent receives the first byte to 10s.
It's required to accommodate setups with high latency and where the time
between the TCP being accepted and the time for the first byte is longer
than the default value -  1s.

Fixes #20442
2023-01-21 10:18:07 +00:00
Roman Tkachenko 6bcad73d69
rm -rf .cloudbuild (#20512) 2023-01-21 01:02:19 +00:00
Alan Parra e8e48a1c55
Add device-specific verbs to RoleAdmin (#20505)
Add device-specific verbs to RoleAdmin, which are not included in the default
`RW()` set. Fixes issues while using `tctl devices add --enroll` and
`tctl devices enroll`.

#514
2023-01-20 19:33:08 -03:00
Michael 7f5e822c18
Update eref (#20498) 2023-01-20 20:38:07 +00:00