Skip to content

fftls: added ClientTLSConfigMergingSystemCAs for HTTP clients that ne… - #238

Merged
EnriqueL8 merged 3 commits into
hyperledger-firefly:mainfrom
kaleido-io:fftls-client-merging-cas
Jul 27, 2026
Merged

fftls: added ClientTLSConfigMergingSystemCAs for HTTP clients that ne…#238
EnriqueL8 merged 3 commits into
hyperledger-firefly:mainfrom
kaleido-io:fftls-client-merging-cas

Conversation

@IvanNik

@IvanNik IvanNik commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Add TLS config option includeSystemCAs (default false).
  • When a custom CA (caFile / ca) is set and includeSystemCAs: true, merge that CA into the system cert pool instead of replacing RootCAs.
  • Existing replace-only behavior is unchanged when the flag is unset/false.

Config

Key Default Effect when caFile/ca set
includeSystemCAs false false: custom CA only (existing). true: system pool + custom CA.

Example:

tls:
  enabled: true
  caFile: /path/to/private-ca.pem
  certFile: /path/to/client.pem
  keyFile: /path/to/client-key.pem
  includeSystemCAs: true

Security

  • Opt-in only; default preserves CA pinning.
  • Does not skip hostname verification.
  • Prefer for outbound clients that may hit public HTTPS redirects; avoid widening inbound ClientCAs trust unless intentional.

@IvanNik
IvanNik force-pushed the fftls-client-merging-cas branch from 98dd301 to cd8699f Compare July 24, 2026 20:32
… public CAs

Signed-off-by: IvanNik <ivan.nikulin@kaleido.io>
@IvanNik
IvanNik force-pushed the fftls-client-merging-cas branch from cd8699f to 803d465 Compare July 24, 2026 20:55
@IvanNik
IvanNik marked this pull request as ready for review July 24, 2026 21:09
@IvanNik
IvanNik requested a review from a team as a code owner July 24, 2026 21:09

@onelapahead onelapahead left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! Thanks Ivan

@EnriqueL8 EnriqueL8 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @IvanNik - build failing

Error: pkg/fftls/fftls.go:208:81: newRootCAPool - result 1 (error) is always nil (unparam)
func newRootCAPool(ctx context.Context, includeSystemCAs bool) (*x509.CertPool, error) {

… public CAs

Signed-off-by: IvanNik <ivan.nikulin@kaleido.io>
@IvanNik
IvanNik force-pushed the fftls-client-merging-cas branch from 44119f0 to f6ae832 Compare July 27, 2026 14:48
… public CAs

Signed-off-by: IvanNik <ivan.nikulin@kaleido.io>
@IvanNik
IvanNik requested a review from EnriqueL8 July 27, 2026 15:55

@EnriqueL8 EnriqueL8 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @IvanNik for the changes

@EnriqueL8
EnriqueL8 merged commit 37f809c into hyperledger-firefly:main Jul 27, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants