Skip to content

server: integrate the TLS auto-negotiation inside the crdb code #60632

@knz

Description

@knz

Fixes #32448.
Epic: CRDB-6663
Jira issue: CRDB-3167

Meta-issue to track the implementation for #51991

A couple of new components:

Follow-up work:

Clean-up work:

CLI commands:

  • cockroach connect - new, only responsible for TLS handshake and writing the certs to disk
    This will leverage the first 3 components identified above: cert gen primitives + HTTP client/server for handshake.
  • cockroach start - when provided an init token, must check if the host cert is known already and if not start the TLS handshake before the remainder of the start code server: integrate the TLS auto-negotiation in the start commands #63850
  • cockroach start-single-node - new flag --self-secure-init that auto-generates an init token and proceeds as per the start logic
  • cockroach demo - will be modified to leverage the self secure init code added to start-single-node
  • Add --init-token-file flag to protect the init handshake shared secret cli: --init-token exposes the init token to the ps command #61231

Bugs:

Technical question where the answer is needed as prereq to a number of points above:

  • how are the CN and OU fields populated
  • how is the SAN field populated
    • current assumption for prototype/MVP: the addresses provided on --join go into the SAN? or maybe --listen-addr? (Unsure, this is under-specified)
    • need a practical test with a multi-server experiment, to understand the design constraint
    • there may be some flags / extra logic needed to pick up reasonable + valid addresses to populate SAN

Possible action item: perform that experiment

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-authenticationPertains to authn subsystemsA-securityA-server-start-drainPertains to server startup and shutdown sequencesC-enhancementSolution expected to add code/behavior + preserve backward-compat (pg compat issues are exception)T-server-and-securityDB Server & Security

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions