Skip to content

Refactor TLS Configuration #1112

@mbrandenburger

Description

@mbrandenburger

The current core.yaml for an FSC node contains incomplete and inconsistent TLS configuration options across services. This issue proposes a systematic refactor of TLS and mTLS configuration for every client and server exposed or used by an FSC node, with the goal of achieving a consistent, explicit, and extensible TLS model.

Problem

An FSC node exposes and consumes multiple services (gRPC, web, P2P, Fabric services, metrics, tracing, etc.). Today:

  • TLS settings differ across services
  • Client vs server TLS options are inconsistent
  • mTLS is configured differently (or implicitly) depending on the component
  • Metrics are coupled to the web service
  • Tooling (e.g. FSCCLI) requires special-case configuration

This makes the system harder to reason about, configure, and secure.

FSC Services Overview

An FSC node may provide or consume the following services:

Node services:

  • View service
    • gRPC (server)
    • Web (server)
  • Node P2P
    • (Client / Server)
  • Metrics
    • Server (currently attached to web)
  • Tracing
    • Client

Fabric (x) integrations:

  • Ordering service (from config block) — client
  • Peers (sidecar) — client
  • Notification service — client
  • Query service — client

Tooling:

  • FSCCLI
    • View service gRPC (client)
    • View service Web (server)

Proposed TLS Configuration Model

Each client and server configuration should follow a uniform and explicit structure.

Server configuration

server:
  # TLS
  enabled: bool
  serverCert: string
  serverKey: string

  # mTLS
  clientAuthRequired: bool
  clientRootCAs: []string

Client configuration

client:
  # TLS
  enabled: bool
  serverRootCAs: []string

  # mTLS
  clientAuthEnabled: bool
  clientCert: string
  clientKey: string

This structure should be reused consistently across all services.

Ordering service

The TLS configuration of the ordering service might differ a bit as the endpoint details are extracted from config transactions received from the network. In that case the client.serverRootCAs provided via the config file will be ignored and set via the config transactions and if client.clientAuthEnabled is true, client.clientCert and client.clientKey is used for all orderer connections.

Tasks

  • Align TLS configuration across all services (client & server)
  • Restructure core.yaml to reflect the new TLS model
  • Update NWO configuration generation
  • Update each component to consume the new configuration
  • Run Metrics via an independent web server
  • Update configuration documentation

Metadata

Metadata

Assignees

No one assigned

    Labels

    cleanupSomething needs some cleanupenhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions