Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

configurable key algorithms for proxy to database agent certs #43329

Merged
merged 5 commits into from
Jun 26, 2024

Conversation

nklaassen
Copy link
Contributor

@nklaassen nklaassen commented Jun 21, 2024

This PR continues the implementation of RFD 136 - Modern Signature Algorithms.

The proxy currently generates a new keypair on each incoming connection from a user database client, and has the auth server sign a TLS certificate that it then uses to dial the db agent through the reverse tunnel that the database agent has already established to the proxy. These certs carry routing information for the database. These certs are signed by the Database CA and only need to be trusted by database agents. This PR updates these generated keys to use a signature algorithm matching the signature algorithm suite currently configured in the cluster.

This has the potential to boost proxy performance since it's so much faster to generate ECDSA keys than RSA keys. If I disable pre-generated RSA key generation, go test ./lib/srv/db speeds up from 4m4s to 3m14s with this change (there are still plenty of other RSA keys being generated).

@github-actions github-actions bot added database-access Database access related issues and PRs rfd Request for Discussion size/sm labels Jun 21, 2024
@nklaassen nklaassen force-pushed the nklaassen/proxy-db-key-algo branch from 054294a to 768904d Compare June 24, 2024 17:06
@nklaassen nklaassen added the no-changelog Indicates that a PR does not require a changelog entry label Jun 24, 2024
@gravitational gravitational deleted a comment from github-actions bot Jun 24, 2024
@gravitational gravitational deleted a comment from github-actions bot Jun 24, 2024
@kimlisa kimlisa removed their request for review June 24, 2024 18:43
@nklaassen nklaassen force-pushed the nklaassen/proxy-db-key-algo branch from 050490c to 96466ed Compare June 24, 2024 22:10
@nklaassen nklaassen force-pushed the nklaassen/proxy-db-key-algo branch from 6b3e2a3 to f44ee97 Compare June 25, 2024 23:43
@nklaassen nklaassen changed the base branch from nklaassen/algs1 to nklaassen/algs0 June 25, 2024 23:43
Base automatically changed from nklaassen/algs0 to master June 26, 2024 16:32
@nklaassen nklaassen force-pushed the nklaassen/proxy-db-key-algo branch from f44ee97 to a07297f Compare June 26, 2024 18:18
@nklaassen nklaassen enabled auto-merge June 26, 2024 18:29
@nklaassen nklaassen force-pushed the nklaassen/proxy-db-key-algo branch from 964c72a to 47280c8 Compare June 26, 2024 19:07
@nklaassen nklaassen disabled auto-merge June 26, 2024 19:07
@nklaassen nklaassen force-pushed the nklaassen/proxy-db-key-algo branch from 47280c8 to 5af9eff Compare June 26, 2024 19:57
@nklaassen nklaassen enabled auto-merge June 26, 2024 19:57
@nklaassen nklaassen added this pull request to the merge queue Jun 26, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jun 26, 2024
@nklaassen nklaassen added this pull request to the merge queue Jun 26, 2024
Merged via the queue into master with commit a48c4f7 Jun 26, 2024
40 checks passed
@nklaassen nklaassen deleted the nklaassen/proxy-db-key-algo branch June 26, 2024 23:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
database-access Database access related issues and PRs no-changelog Indicates that a PR does not require a changelog entry rfd Request for Discussion size/sm
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants