Skip to content

Conversation

@wangke19
Copy link
Contributor

@wangke19 wangke19 commented Jan 9, 2026

Summary

Cherry-pick of commits from #30660 to release-4.20 with manual fixes for CI failures.

This PR re-applies the TLS 1.3 / Modern profile tests that were previously reverted, along with fixes to make them work properly in CI.

Commits

Fixes Applied

  • JSON validation error: Added test/extended/util/compat_otp/testdata/opm/render/validate/catalog-error/operator-2/index.json to the excluded files list in hack/verify-jsonformat.sh. This file is intentionally malformed (multiple JSON objects without array wrapper) to test error handling in catalog validation.
  • Generated file mismatch: Ran hack/update-generated.sh to regenerate test/extended/util/annotate/generated/zz_generated.annotations.go with the new TestTLSMinimumVersions test annotation.

References

🤖 Generated with Claude Code

Co-Authored-By: Claude noreply@anthropic.com

This commit refactors TestTLSDefaults to use the same port-forwarding
approach as TestTLSMinimumVersions, which fixes DNS resolution failures
when running in CI as a pod.

Problem:
When the test runs as a pod in the cluster, it attempted to connect
directly to the external API server hostname from the kubeconfig
(e.g., api.cluster5.ocpci.eng.rdu2.redhat.com). However, the pod's
internal DNS cannot resolve this external hostname, resulting in:
  dial tcp: lookup api.cluster5.ocpci.eng.rdu2.redhat.com on 172.30.0.10:53: no such host

Solution:
Use forwardPortAndExecute() to create a port-forward tunnel to the
apiserver service in openshift-kube-apiserver namespace, then test
against localhost:<forwarded-port>. This approach:
- Works both in-cluster (CI) and externally (with kubeconfig)
- Eliminates DNS resolution issues entirely
- Is consistent with TestTLSMinimumVersions pattern
- Includes built-in retry logic (3 attempts)
- Simplifies the code by removing URL parsing and env var detection

Changes:
- Removed net/url and os imports (no longer needed)
- Wrapped TLS version and cipher tests in forwardPortAndExecute callback
- Changed error reporting from t.Errorf() to returning errors for retry support
- Tests now connect to localhost via port-forward tunnel
Remove the IPv4-only restriction from TLS tests to support IPv6 clusters.
The tests use port-forwarding to localhost, which works for both IPv4
and IPv6 environments since localhost resolves appropriately in both cases.

Changes:
- Removed IPv4-only check in BeforeEach that skipped tests on IPv6 clusters
- Removed unused networking import

This allows the TLS configuration tests to run on:
- IPv4-only clusters
- IPv6-only clusters
- Dual-stack (IPv4+IPv6) clusters
Update the comment explaining why cipher suite tests are constrained to
TLS 1.2 to be more technically accurate. The previous comment suggested
this was about "Go 1.23+ behavior", but the real issue is fundamental to
how TLS 1.3 works:

- The intermediate profile allows both TLS 1.2 and TLS 1.3
- Clients negotiate TLS 1.3 when MaxVersion is unspecified and server supports it
- TLS 1.3 spec predefines cipher suites and doesn't support configuration
- Therefore, specifying any cipher suite has no effect with TLS 1.3
- Forcing TLS 1.2 allows actual testing of cipher suite restrictions

This makes the reasoning clearer for future maintainers.
The file test/extended/util/compat_otp/testdata/opm/render/validate/catalog-error/operator-2/index.json
is an intentionally malformed JSON file used to test error handling in the catalog validation code.
It contains multiple JSON objects without being wrapped in an array, which is the expected error case.

Add this file to the excluded_files list in verify-jsonformat.sh to prevent it from failing
JSON validation checks during CI.
Run hack/update-generated.sh to regenerate test annotations after adding
the new TestTLSMinimumVersions test. This adds the test to the annotations
map so it can be properly tagged with [Suite:openshift/conformance/parallel].
@openshift-ci-robot openshift-ci-robot added jira/severity-important Referenced Jira bug's severity is important for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. labels Jan 9, 2026
@openshift-ci-robot
Copy link

@wangke19: This pull request references Jira Issue OCPBUGS-72395, which is invalid:

  • expected dependent Jira Issue OCPBUGS-71229 to be in one of the following states: VERIFIED, RELEASE PENDING, CLOSED (ERRATA), CLOSED (CURRENT RELEASE), CLOSED (DONE), CLOSED (DONE-ERRATA), but it is MODIFIED instead

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

The bug has been updated to refer to the pull request using the external bug tracker.

Details

In response to this:

Summary

Cherry-pick of commits from #30660 to release-4.20 with manual fixes for CI failures.

This PR re-applies the TLS 1.3 / Modern profile tests that were previously reverted, along with fixes to make them work properly in CI.

Commits

Fixes Applied

  • JSON validation error: Added test/extended/util/compat_otp/testdata/opm/render/validate/catalog-error/operator-2/index.json to the excluded files list in hack/verify-jsonformat.sh. This file is intentionally malformed (multiple JSON objects without array wrapper) to test error handling in catalog validation.
  • Generated file mismatch: Ran hack/update-generated.sh to regenerate test/extended/util/annotate/generated/zz_generated.annotations.go with the new TestTLSMinimumVersions test annotation.

References

🤖 Generated with Claude Code

Co-Authored-By: Claude noreply@anthropic.com

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci openshift-ci bot requested review from knobunc and p0lyn0mial January 9, 2026 05:55
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jan 9, 2026

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: wangke19
Once this PR has been reviewed and has the lgtm label, please assign xueqzhan for approval. For more information see the Code Review Process.

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

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jan 9, 2026

@wangke19: all tests passed!

Full PR test history. Your PR dashboard.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

@wangke19
Copy link
Contributor Author

wangke19 commented Jan 9, 2026

/payload 4.21 nightly blocking

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jan 9, 2026

@wangke19: trigger 13 job(s) of type blocking for the nightly release of OCP 4.21

  • periodic-ci-openshift-release-master-ci-4.21-e2e-aws-upgrade-ovn-single-node
  • periodic-ci-openshift-release-master-nightly-4.21-e2e-aws-ovn-upgrade-fips
  • periodic-ci-openshift-release-master-ci-4.21-e2e-azure-ovn-upgrade
  • periodic-ci-openshift-release-master-ci-4.21-upgrade-from-stable-4.20-e2e-gcp-ovn-rt-upgrade
  • periodic-ci-openshift-hypershift-release-4.21-periodics-e2e-aws-ovn-conformance
  • periodic-ci-openshift-release-master-nightly-4.21-e2e-aws-ovn-serial-1of2
  • periodic-ci-openshift-release-master-nightly-4.21-e2e-aws-ovn-serial-2of2
  • periodic-ci-openshift-release-master-ci-4.21-e2e-aws-ovn-techpreview
  • periodic-ci-openshift-release-master-ci-4.21-e2e-aws-ovn-techpreview-serial-1of3
  • periodic-ci-openshift-release-master-ci-4.21-e2e-aws-ovn-techpreview-serial-2of3
  • periodic-ci-openshift-release-master-ci-4.21-e2e-aws-ovn-techpreview-serial-3of3
  • periodic-ci-openshift-release-master-nightly-4.21-e2e-metal-ipi-ovn-bm
  • periodic-ci-openshift-release-master-nightly-4.21-e2e-metal-ipi-ovn-ipv6

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/4b3df6c0-ed3f-11f0-813a-7af3f9200b0a-0

@wangke19
Copy link
Contributor Author

wangke19 commented Jan 9, 2026

/test periodic-ci-openshift-release-master-ci-4.21-e2e-aws-upgrade-ovn-single-node

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jan 9, 2026

@wangke19: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

/test e2e-aws-jenkins
/test e2e-aws-ovn-fips
/test e2e-aws-ovn-image-registry
/test e2e-aws-ovn-microshift
/test e2e-aws-ovn-microshift-serial
/test e2e-aws-ovn-serial-1of2
/test e2e-aws-ovn-serial-2of2
/test e2e-gcp-ovn
/test e2e-gcp-ovn-builds
/test e2e-gcp-ovn-image-ecosystem
/test e2e-gcp-ovn-upgrade
/test e2e-metal-ipi-ovn-ipv6
/test e2e-vsphere-ovn
/test e2e-vsphere-ovn-upi
/test images
/test lint
/test okd-scos-images
/test unit
/test verify
/test verify-deps

The following commands are available to trigger optional jobs:

/test e2e-agnostic-ovn-cmd
/test e2e-aws-csi
/test e2e-aws-disruptive
/test e2e-aws-etcd-certrotation
/test e2e-aws-etcd-recovery
/test e2e-aws-ovn
/test e2e-aws-ovn-cgroupsv2
/test e2e-aws-ovn-edge-zones
/test e2e-aws-ovn-etcd-scaling
/test e2e-aws-ovn-kube-apiserver-rollout
/test e2e-aws-ovn-kubevirt
/test e2e-aws-ovn-serial-ipsec
/test e2e-aws-ovn-serial-publicnet-1of2
/test e2e-aws-ovn-serial-publicnet-2of2
/test e2e-aws-ovn-single-node
/test e2e-aws-ovn-single-node-serial
/test e2e-aws-ovn-single-node-techpreview
/test e2e-aws-ovn-single-node-techpreview-serial
/test e2e-aws-ovn-single-node-upgrade
/test e2e-aws-ovn-upgrade
/test e2e-aws-ovn-upgrade-rollback
/test e2e-aws-ovn-upi
/test e2e-aws-proxy
/test e2e-azure
/test e2e-azure-ovn-etcd-scaling
/test e2e-azure-ovn-upgrade
/test e2e-baremetalds-kubevirt
/test e2e-external-aws
/test e2e-external-aws-ccm
/test e2e-external-vsphere-ccm
/test e2e-gcp-csi
/test e2e-gcp-disruptive
/test e2e-gcp-fips-serial-1of2
/test e2e-gcp-fips-serial-2of2
/test e2e-gcp-ovn-etcd-scaling
/test e2e-gcp-ovn-rt-upgrade
/test e2e-gcp-ovn-techpreview
/test e2e-gcp-ovn-techpreview-serial-1of2
/test e2e-gcp-ovn-techpreview-serial-2of2
/test e2e-gcp-ovn-usernamespace
/test e2e-hypershift-conformance
/test e2e-metal-ipi-ovn
/test e2e-metal-ipi-ovn-bgp-virt-dualstack
/test e2e-metal-ipi-ovn-bgp-virt-dualstack-techpreview
/test e2e-metal-ipi-ovn-dualstack
/test e2e-metal-ipi-ovn-dualstack-bgp
/test e2e-metal-ipi-ovn-dualstack-bgp-local-gw
/test e2e-metal-ipi-ovn-dualstack-local-gateway
/test e2e-metal-ipi-ovn-kube-apiserver-rollout
/test e2e-metal-ipi-serial-1of2
/test e2e-metal-ipi-serial-2of2
/test e2e-metal-ipi-serial-ovn-ipv6-1of2
/test e2e-metal-ipi-serial-ovn-ipv6-2of2
/test e2e-metal-ipi-virtualmedia
/test e2e-metal-ovn-single-node-live-iso
/test e2e-metal-ovn-single-node-with-worker-live-iso
/test e2e-metal-ovn-two-node-arbiter
/test e2e-metal-ovn-two-node-fencing
/test e2e-openstack-ovn
/test e2e-openstack-serial
/test e2e-vsphere-ovn-dualstack-primaryv6
/test e2e-vsphere-ovn-etcd-scaling
/test okd-scos-e2e-aws-ovn

Use /test all to run the following jobs that were automatically triggered:

pull-ci-openshift-origin-release-4.20-e2e-aws-ovn-fips
pull-ci-openshift-origin-release-4.20-e2e-aws-ovn-microshift
pull-ci-openshift-origin-release-4.20-e2e-aws-ovn-microshift-serial
pull-ci-openshift-origin-release-4.20-e2e-aws-ovn-serial-1of2
pull-ci-openshift-origin-release-4.20-e2e-aws-ovn-serial-2of2
pull-ci-openshift-origin-release-4.20-e2e-gcp-ovn
pull-ci-openshift-origin-release-4.20-e2e-gcp-ovn-upgrade
pull-ci-openshift-origin-release-4.20-e2e-metal-ipi-ovn-ipv6
pull-ci-openshift-origin-release-4.20-e2e-vsphere-ovn
pull-ci-openshift-origin-release-4.20-e2e-vsphere-ovn-upi
pull-ci-openshift-origin-release-4.20-images
pull-ci-openshift-origin-release-4.20-lint
pull-ci-openshift-origin-release-4.20-okd-scos-images
pull-ci-openshift-origin-release-4.20-unit
pull-ci-openshift-origin-release-4.20-verify
pull-ci-openshift-origin-release-4.20-verify-deps
Details

In response to this:

/test periodic-ci-openshift-release-master-ci-4.21-e2e-aws-upgrade-ovn-single-node

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@wangke19
Copy link
Contributor Author

wangke19 commented Jan 9, 2026

/test periodic-ci-openshift-release-master-nightly-4.21-e2e-aws-ovn-upgrade-fips

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jan 9, 2026

@wangke19: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

/test e2e-aws-jenkins
/test e2e-aws-ovn-fips
/test e2e-aws-ovn-image-registry
/test e2e-aws-ovn-microshift
/test e2e-aws-ovn-microshift-serial
/test e2e-aws-ovn-serial-1of2
/test e2e-aws-ovn-serial-2of2
/test e2e-gcp-ovn
/test e2e-gcp-ovn-builds
/test e2e-gcp-ovn-image-ecosystem
/test e2e-gcp-ovn-upgrade
/test e2e-metal-ipi-ovn-ipv6
/test e2e-vsphere-ovn
/test e2e-vsphere-ovn-upi
/test images
/test lint
/test okd-scos-images
/test unit
/test verify
/test verify-deps

The following commands are available to trigger optional jobs:

/test e2e-agnostic-ovn-cmd
/test e2e-aws-csi
/test e2e-aws-disruptive
/test e2e-aws-etcd-certrotation
/test e2e-aws-etcd-recovery
/test e2e-aws-ovn
/test e2e-aws-ovn-cgroupsv2
/test e2e-aws-ovn-edge-zones
/test e2e-aws-ovn-etcd-scaling
/test e2e-aws-ovn-kube-apiserver-rollout
/test e2e-aws-ovn-kubevirt
/test e2e-aws-ovn-serial-ipsec
/test e2e-aws-ovn-serial-publicnet-1of2
/test e2e-aws-ovn-serial-publicnet-2of2
/test e2e-aws-ovn-single-node
/test e2e-aws-ovn-single-node-serial
/test e2e-aws-ovn-single-node-techpreview
/test e2e-aws-ovn-single-node-techpreview-serial
/test e2e-aws-ovn-single-node-upgrade
/test e2e-aws-ovn-upgrade
/test e2e-aws-ovn-upgrade-rollback
/test e2e-aws-ovn-upi
/test e2e-aws-proxy
/test e2e-azure
/test e2e-azure-ovn-etcd-scaling
/test e2e-azure-ovn-upgrade
/test e2e-baremetalds-kubevirt
/test e2e-external-aws
/test e2e-external-aws-ccm
/test e2e-external-vsphere-ccm
/test e2e-gcp-csi
/test e2e-gcp-disruptive
/test e2e-gcp-fips-serial-1of2
/test e2e-gcp-fips-serial-2of2
/test e2e-gcp-ovn-etcd-scaling
/test e2e-gcp-ovn-rt-upgrade
/test e2e-gcp-ovn-techpreview
/test e2e-gcp-ovn-techpreview-serial-1of2
/test e2e-gcp-ovn-techpreview-serial-2of2
/test e2e-gcp-ovn-usernamespace
/test e2e-hypershift-conformance
/test e2e-metal-ipi-ovn
/test e2e-metal-ipi-ovn-bgp-virt-dualstack
/test e2e-metal-ipi-ovn-bgp-virt-dualstack-techpreview
/test e2e-metal-ipi-ovn-dualstack
/test e2e-metal-ipi-ovn-dualstack-bgp
/test e2e-metal-ipi-ovn-dualstack-bgp-local-gw
/test e2e-metal-ipi-ovn-dualstack-local-gateway
/test e2e-metal-ipi-ovn-kube-apiserver-rollout
/test e2e-metal-ipi-serial-1of2
/test e2e-metal-ipi-serial-2of2
/test e2e-metal-ipi-serial-ovn-ipv6-1of2
/test e2e-metal-ipi-serial-ovn-ipv6-2of2
/test e2e-metal-ipi-virtualmedia
/test e2e-metal-ovn-single-node-live-iso
/test e2e-metal-ovn-single-node-with-worker-live-iso
/test e2e-metal-ovn-two-node-arbiter
/test e2e-metal-ovn-two-node-fencing
/test e2e-openstack-ovn
/test e2e-openstack-serial
/test e2e-vsphere-ovn-dualstack-primaryv6
/test e2e-vsphere-ovn-etcd-scaling
/test okd-scos-e2e-aws-ovn

Use /test all to run the following jobs that were automatically triggered:

pull-ci-openshift-origin-release-4.20-e2e-aws-ovn-fips
pull-ci-openshift-origin-release-4.20-e2e-aws-ovn-microshift
pull-ci-openshift-origin-release-4.20-e2e-aws-ovn-microshift-serial
pull-ci-openshift-origin-release-4.20-e2e-aws-ovn-serial-1of2
pull-ci-openshift-origin-release-4.20-e2e-aws-ovn-serial-2of2
pull-ci-openshift-origin-release-4.20-e2e-gcp-ovn
pull-ci-openshift-origin-release-4.20-e2e-gcp-ovn-upgrade
pull-ci-openshift-origin-release-4.20-e2e-metal-ipi-ovn-ipv6
pull-ci-openshift-origin-release-4.20-e2e-vsphere-ovn
pull-ci-openshift-origin-release-4.20-e2e-vsphere-ovn-upi
pull-ci-openshift-origin-release-4.20-images
pull-ci-openshift-origin-release-4.20-lint
pull-ci-openshift-origin-release-4.20-okd-scos-images
pull-ci-openshift-origin-release-4.20-unit
pull-ci-openshift-origin-release-4.20-verify
pull-ci-openshift-origin-release-4.20-verify-deps
Details

In response to this:

/test periodic-ci-openshift-release-master-nightly-4.21-e2e-aws-ovn-upgrade-fips

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. jira/severity-important Referenced Jira bug's severity is important for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants