Skip to content

feat(tls): make central TLS opt-out by default#3416

Open
jkhelil wants to merge 1 commit into
tektoncd:mainfrom
jkhelil:SRVKP-11957
Open

feat(tls): make central TLS opt-out by default#3416
jkhelil wants to merge 1 commit into
tektoncd:mainfrom
jkhelil:SRVKP-11957

Conversation

@jkhelil
Copy link
Copy Markdown
Member

@jkhelil jkhelil commented May 11, 2026

Changes

Make EnableCentralTLSConfig opt-out (default: enabled)

EnableCentralTLSConfig was a plain bool (opt-in, default false), meaning every
OpenShift cluster had to explicitly set it to true before any TLS profile injection
kicked in — defeating the point of a cluster-wide security policy.

This PR changes the field type to *bool and defaults it to true via SetDefaults:

  • New installs: central TLS active out of the box.
  • Upgrades: existing CRs that omit the field deserialize to nil; SetDefaults
    sets nil → true on the next reconcile, so TLS injection is transparently enabled.
  • Opt-out: operators who need to manage TLS manually can set
    enableCentralTLSConfig: false in their TektonConfig CR.

ResolveCentralTLSToEnvVars and GetPlatformData are updated to treat nil as
enabled; only an explicit false suppresses injection.

Submitter Checklist

  • Run make test lint before submitting a PR
  • Includes tests (if functionality changed/added)
  • Includes docs (if user facing)
  • Commit messages follow commit message best practices

Release Notes

Central TLS configuration is now enabled by default on OpenShift. The `enableCentralTLSConfig`
field in `TektonConfig` has changed from an opt-in bool to an opt-out *bool: existing clusters
will automatically inherit the cluster APIServer TLS profile (minimum version, cipher suites)
on the next reconcile after upgrade. Set `enableCentralTLSConfig: false` to opt out.

Made with Cursor

Change EnableCentralTLSConfig from an opt-in bool to an opt-out *bool
so central TLS configuration is active by default on all OpenShift
clusters (SRVKP-9615).

SetDefaults now sets EnableCentralTLSConfig = true when the field is nil
(e.g. existing CRs on upgrade). Users who need to manage TLS manually
can set enableCentralTLSConfig: false to opt out.

ResolveCentralTLSToEnvVars and GetPlatformData are updated to treat nil
as enabled; only an explicit false suppresses TLS injection.

Also add ssl_conf_command Groups X25519MLKEM768:X25519 to the nginx TLS
directive builder for the console plugin. This enables the ML-KEM hybrid
key exchange group required for PQC readiness whenever TLS 1.3 is in
scope (which is always the case, since convertTLSVersionToNginx always
includes TLSv1.3). Fixes the PQC TLS scan failure:
  PQC: ML-KEM not supported (no x25519mlkem768 or mlkem768)

Signed-off-by: Jawed khelil <jkhelil@redhat.com>
Assisted-by: Claude Sonnet 4.6 (via Cursor)
Co-authored-by: Cursor <cursoragent@cursor.com>
@tekton-robot tekton-robot added the release-note Denotes a PR that will be considered when it comes time to generate release notes. label May 11, 2026
@tekton-robot
Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
To complete the pull request process, please ask for approval from jkhelil after the PR has been reviewed.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@tekton-robot tekton-robot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label May 11, 2026
@jkhelil jkhelil changed the title feat(tls): make central TLS opt-out by default and enable ML-KEM for console plugin nginx feat(tls): make central TLS opt-out by default May 11, 2026
@jkhelil
Copy link
Copy Markdown
Member Author

jkhelil commented May 12, 2026

/retest

@jkhelil
Copy link
Copy Markdown
Member Author

jkhelil commented May 12, 2026

/kind feature

@tekton-robot tekton-robot added the kind/feature Categorizes issue or PR as related to a new feature. label May 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind/feature Categorizes issue or PR as related to a new feature. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants