Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
0bb4dbd
:seedling: Bump click from 8.1.8 to 8.3.0 (#2250)
dependabot[bot] Oct 6, 2025
ce3551a
:seedling: Bump certifi from 2025.8.3 to 2025.10.5 (#2249)
dependabot[bot] Oct 6, 2025
759fd72
:seedling: Bump github.com/operator-framework/operator-registry (#2248)
dependabot[bot] Oct 6, 2025
029484d
Add support for TLS profiles (#2246)
tmshort Oct 6, 2025
2571a5b
:seedling: Bump github.com/prometheus/common from 0.66.1 to 0.67.1 (#…
dependabot[bot] Oct 7, 2025
6604f2a
fix: make hack/tools/update-tls-profiles.sh work on macOS (#2256)
joelanford Oct 7, 2025
d3c4faf
Merge branch 'main' into synchronize
Oct 8, 2025
2f1b787
UPSTREAM: <carry>: Add OpenShift specific files
dtfranz Oct 26, 2023
e28c94a
UPSTREAM: <carry>: Add pedjak and trgeiger as reviewers
oceanc80 Sep 5, 2025
6373e63
UPSTREAM: <carry>: Fix cp-manifests copying of helm charts
tmshort Sep 23, 2025
60da94e
UPSTREAM: <carry>: migrate more cases from tests-private and enhance …
kuiwang02 Sep 22, 2025
d77f567
UPSTREAM: <carry>: Updating ose-olm-operator-controller-container ima…
Sep 29, 2025
e5b123b
UPSTREAM: <carry>: Updating ose-olm-catalogd-container image to be co…
Sep 29, 2025
6b0d5a3
UPSTREAM: <carry>: Remove kustomize manifests from images and repo
tmshort Oct 1, 2025
a3ccd08
UPSTREAM: <carry>: OTE: Enable disconnected environment and build tes…
Sep 24, 2025
d58a26b
UPSTREAM: <carry>: for incompatible test add func to wait builder and…
camilamacedo86 Oct 7, 2025
b0cc7a0
UPSTREAM: <drop>: go mod vendor
Oct 8, 2025
6888d54
UPSTREAM: <drop>: remove upstream GitHub configuration
Oct 8, 2025
166bae2
UPSTREAM: <drop>: configure the commit-checker
Oct 8, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .bingo/Variables.mk
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,12 @@ $(CRD_REF_DOCS): $(BINGO_DIR)/crd-ref-docs.mod
@echo "(re)installing $(GOBIN)/crd-ref-docs-v0.1.0"
@cd $(BINGO_DIR) && GOWORK=off $(GO) build -mod=mod -modfile=crd-ref-docs.mod -o=$(GOBIN)/crd-ref-docs-v0.1.0 "github.com/elastic/crd-ref-docs"

GOJQ := $(GOBIN)/gojq-v0.12.17
$(GOJQ): $(BINGO_DIR)/gojq.mod
@# Install binary/ries using Go 1.14+ build command. This is using bwplotka/bingo-controlled, separate go module with pinned dependencies.
@echo "(re)installing $(GOBIN)/gojq-v0.12.17"
@cd $(BINGO_DIR) && GOWORK=off $(GO) build -mod=mod -modfile=gojq.mod -o=$(GOBIN)/gojq-v0.12.17 "github.com/itchyny/gojq/cmd/gojq"

GOLANGCI_LINT := $(GOBIN)/golangci-lint-v2.1.6
$(GOLANGCI_LINT): $(BINGO_DIR)/golangci-lint.mod
@# Install binary/ries using Go 1.14+ build command. This is using bwplotka/bingo-controlled, separate go module with pinned dependencies.
Expand Down
5 changes: 5 additions & 0 deletions .bingo/gojq.mod
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
module _ // Auto generated by https://github.com/bwplotka/bingo. DO NOT EDIT

go 1.24.4

require github.com/itchyny/gojq v0.12.17 // cmd/gojq
17 changes: 17 additions & 0 deletions .bingo/gojq.sum
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
github.com/itchyny/gojq v0.12.17 h1:8av8eGduDb5+rvEdaOO+zQUjA04MS0m3Ps8HiD+fceg=
github.com/itchyny/gojq v0.12.17/go.mod h1:WBrEMkgAfAGO1LUcGOckBl5O726KPp+OlkKug0I/FEY=
github.com/itchyny/timefmt-go v0.1.6 h1:ia3s54iciXDdzWzwaVKXZPbiXzxxnv1SPGFfM/myJ5Q=
github.com/itchyny/timefmt-go v0.1.6/go.mod h1:RRDZYC5s9ErkjQvTvvU7keJjxUYzIISJGxm9/mAERQg=
github.com/mattn/go-isatty v0.0.20 h1:xfD0iDuEKnDkl03q4limB+vH+GxLEtL/jb4xVJSWWEY=
github.com/mattn/go-isatty v0.0.20/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y=
github.com/mattn/go-runewidth v0.0.15 h1:UNAjwbU9l54TA3KzvqLGxwWjHmMgBUVhBiTjelZgg3U=
github.com/mattn/go-runewidth v0.0.15/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w=
github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc=
github.com/rivo/uniseg v0.4.7 h1:WUdvkW8uEhrYfLC4ZzdpI2ztxP1I582+49Oc5Mq64VQ=
github.com/rivo/uniseg v0.4.7/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88=
golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.20.0 h1:Od9JTbYCk261bKm4M/mw7AklTlFYIa0bIp9BgSm1S8Y=
golang.org/x/sys v0.20.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
2 changes: 2 additions & 0 deletions .bingo/variables.env
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ CRD_DIFF="${GOBIN}/crd-diff-v0.2.0"

CRD_REF_DOCS="${GOBIN}/crd-ref-docs-v0.1.0"

GOJQ="${GOBIN}/gojq-v0.12.17"

GOLANGCI_LINT="${GOBIN}/golangci-lint-v2.1.6"

GORELEASER="${GOBIN}/goreleaser-v1.26.2"
Expand Down
6 changes: 5 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ generate: $(CONTROLLER_GEN) #EXHELP Generate code containing DeepCopy, DeepCopyI
$(CONTROLLER_GEN) --load-build-tags=$(GO_BUILD_TAGS) object:headerFile="hack/boilerplate.go.txt" paths="./..."

.PHONY: verify
verify: k8s-pin kind-verify-versions fmt generate manifests crd-ref-docs #HELP Verify all generated code is up-to-date. Runs k8s-pin instead of just tidy.
verify: k8s-pin kind-verify-versions fmt generate manifests update-tls-profiles crd-ref-docs #HELP Verify all generated code is up-to-date. Runs k8s-pin instead of just tidy.
git diff --exit-code

.PHONY: fix-lint
Expand All @@ -189,6 +189,10 @@ fix-lint: $(GOLANGCI_LINT) #EXHELP Fix lint issues
fmt: #EXHELP Formats code
go fmt ./...

.PHONY: update-tls-profiles
update-tls-profiles: $(GOJQ) #EXHELP Update TLS profiles from the Mozilla wiki
env JQ=$(GOJQ) hack/tools/update-tls-profiles.sh

.PHONY: verify-crd-compatibility
CRD_DIFF_ORIGINAL_REF := git://main?path=
CRD_DIFF_UPDATED_REF := file://
Expand Down
10 changes: 9 additions & 1 deletion cmd/catalogd/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ import (
imageutil "github.com/operator-framework/operator-controller/internal/shared/util/image"
"github.com/operator-framework/operator-controller/internal/shared/util/pullsecretcache"
sautil "github.com/operator-framework/operator-controller/internal/shared/util/sa"
"github.com/operator-framework/operator-controller/internal/shared/util/tlsprofiles"
"github.com/operator-framework/operator-controller/internal/shared/version"
)

Expand Down Expand Up @@ -142,6 +143,7 @@ func init() {
klog.InitFlags(flag.CommandLine)
flags.AddGoFlagSet(flag.CommandLine)
features.CatalogdFeatureGate.AddFlag(flags)
tlsprofiles.AddFlags(flags)

utilruntime.Must(clientgoscheme.AddToScheme(scheme))
utilruntime.Must(ocv1.AddToScheme(scheme))
Expand Down Expand Up @@ -216,12 +218,18 @@ func run(ctx context.Context) error {
// For details, see: https://github.com/kubernetes/kubernetes/issues/121197
config.NextProtos = []string{"http/1.1"}
}
tlsProfile, err := tlsprofiles.GetTLSConfigFunc()
if err != nil {
setupLog.Error(err, "failed to get TLS profile")
return err
}

// Create webhook server and configure TLS
webhookServer := crwebhook.NewServer(crwebhook.Options{
Port: cfg.webhookPort,
TLSOpts: []func(*tls.Config){
tlsOpts,
tlsProfile,
},
})

Expand All @@ -233,7 +241,7 @@ func run(ctx context.Context) error {
metricsServerOptions.SecureServing = true
metricsServerOptions.FilterProvider = filters.WithAuthenticationAndAuthorization

metricsServerOptions.TLSOpts = append(metricsServerOptions.TLSOpts, tlsOpts)
metricsServerOptions.TLSOpts = append(metricsServerOptions.TLSOpts, tlsOpts, tlsProfile)
} else {
// Note that the metrics server is not serving if the BindAddress is set to "0".
// Therefore, the metrics server is disabled by default. It is only enabled
Expand Down
10 changes: 10 additions & 0 deletions cmd/operator-controller/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ import (
imageutil "github.com/operator-framework/operator-controller/internal/shared/util/image"
"github.com/operator-framework/operator-controller/internal/shared/util/pullsecretcache"
sautil "github.com/operator-framework/operator-controller/internal/shared/util/sa"
"github.com/operator-framework/operator-controller/internal/shared/util/tlsprofiles"
"github.com/operator-framework/operator-controller/internal/shared/version"
)

Expand Down Expand Up @@ -166,6 +167,9 @@ func init() {
//add feature gate flags to flagset
features.OperatorControllerFeatureGate.AddFlag(flags)

//add TLS flags
tlsprofiles.AddFlags(flags)

ctrl.SetLogger(klog.NewKlogr())
}
func validateMetricsFlags() error {
Expand Down Expand Up @@ -274,6 +278,12 @@ func run() error {
// the risks. More info https://github.com/golang/go/issues/63417
config.NextProtos = []string{"http/1.1"}
})
tlsProfile, err := tlsprofiles.GetTLSConfigFunc()
if err != nil {
setupLog.Error(err, "failed to get TLS profile")
return err
}
metricsServerOptions.TLSOpts = append(metricsServerOptions.TLSOpts, tlsProfile)
} else {
// Note that the metrics server is not serving if the BindAddress is set to "0".
// Therefore, the metrics server is disabled by default. It is only enabled
Expand Down
2 changes: 1 addition & 1 deletion commitchecker.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
expectedMergeBase: 35da385077935545a4eaadc338015e249a6df211
expectedMergeBase: 6604f2a4e24ca0c4abce99389b1e5dbbe8d8dbfa
upstreamBranch: main
upstreamOrg: operator-framework
upstreamRepo: operator-controller
8 changes: 4 additions & 4 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,11 @@ require (
github.com/opencontainers/image-spec v1.1.1
github.com/operator-framework/api v0.35.0
github.com/operator-framework/helm-operator-plugins v0.8.0
github.com/operator-framework/operator-registry v1.59.0
github.com/operator-framework/operator-registry v1.60.0
github.com/prometheus/client_golang v1.23.2
github.com/prometheus/common v0.66.1
github.com/prometheus/common v0.67.1
github.com/spf13/cobra v1.10.1
github.com/spf13/pflag v1.0.10
github.com/stretchr/testify v1.11.1
go.podman.io/image/v5 v5.37.0
golang.org/x/exp v0.0.0-20250620022241-b7579e27df2b
Expand Down Expand Up @@ -199,7 +200,6 @@ require (
github.com/sirupsen/logrus v1.9.3 // indirect
github.com/smallstep/pkcs7 v0.2.1 // indirect
github.com/spf13/cast v1.7.1 // indirect
github.com/spf13/pflag v1.0.10 // indirect
github.com/stefanberger/go-pkcs11uri v0.0.0-20230803200340-78284954bff6 // indirect
github.com/stoewer/go-strcase v1.3.1 // indirect
github.com/stretchr/objx v0.5.2 // indirect
Expand Down Expand Up @@ -236,7 +236,7 @@ require (
google.golang.org/genproto/googleapis/api v0.0.0-20250707201910-8d1bb00bc6a7 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20250707201910-8d1bb00bc6a7 // indirect
google.golang.org/grpc v1.75.1 // indirect
google.golang.org/protobuf v1.36.9 // indirect
google.golang.org/protobuf v1.36.10 // indirect
gopkg.in/evanphx/json-patch.v4 v4.13.0 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/warnings.v0 v0.1.2 // indirect
Expand Down
12 changes: 6 additions & 6 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -394,8 +394,8 @@ github.com/operator-framework/helm-operator-plugins v0.8.0 h1:0f6HOQC5likkf0b/Ov
github.com/operator-framework/helm-operator-plugins v0.8.0/go.mod h1:Sc+8bE38xTCgCChBUvtq/PxatEg9fAypr7S5iAw8nlA=
github.com/operator-framework/operator-lib v0.17.0 h1:cbz51wZ9+GpWR1ZYP4CSKSSBxDlWxmmnseaHVZZjZt4=
github.com/operator-framework/operator-lib v0.17.0/go.mod h1:TGopBxIE8L6E/Cojzo26R3NFp1eNlqhQNmzqhOblaLw=
github.com/operator-framework/operator-registry v1.59.0 h1:SQhT0qMTYJXqStNhBOYXmLAMpS3eszzbcXAg5NLgJu8=
github.com/operator-framework/operator-registry v1.59.0/go.mod h1:QE1RRQGe+iau8sfY10DbP3+eoahH0G0l+coYrnEzJgI=
github.com/operator-framework/operator-registry v1.60.0 h1:eUP14WThVTNx+/5hQR9Jyg0nxbf5cOg7hK/GgaOA5Tg=
github.com/operator-framework/operator-registry v1.60.0/go.mod h1:PojPivJbKZgD9RG77JWxFpQRo3iCoUn6WR3aTiS6HBI=
github.com/otiai10/copy v1.14.1 h1:5/7E6qsUMBaH5AnQ0sSLzzTg1oTECmcCmT6lvF45Na8=
github.com/otiai10/copy v1.14.1/go.mod h1:oQwrEDDOci3IM8dJF0d8+jnbfPDllW6vUjNc3DoZm9I=
github.com/otiai10/mint v1.6.3 h1:87qsV/aw1F5as1eH1zS/yqHY85ANKVMgkDrf9rcxbQs=
Expand All @@ -418,8 +418,8 @@ github.com/prometheus/client_golang v1.23.2/go.mod h1:Tb1a6LWHB3/SPIzCoaDXI4I8UH
github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
github.com/prometheus/client_model v0.6.2 h1:oBsgwpGs7iVziMvrGhE53c/GrLUsZdHnqNwqPLxwZyk=
github.com/prometheus/client_model v0.6.2/go.mod h1:y3m2F6Gdpfy6Ut/GBsUqTWZqCUvMVzSfMLjcu6wAwpE=
github.com/prometheus/common v0.66.1 h1:h5E0h5/Y8niHc5DlaLlWLArTQI7tMrsfQjHV+d9ZoGs=
github.com/prometheus/common v0.66.1/go.mod h1:gcaUsgf3KfRSwHY4dIMXLPV0K/Wg1oZ8+SbZk/HH/dA=
github.com/prometheus/common v0.67.1 h1:OTSON1P4DNxzTg4hmKCc37o4ZAZDv0cfXLkOt0oEowI=
github.com/prometheus/common v0.67.1/go.mod h1:RpmT9v35q2Y+lsieQsdOh5sXZ6ajUGC8NjZAmr8vb0Q=
github.com/prometheus/procfs v0.17.0 h1:FuLQ+05u4ZI+SS/w9+BWEM2TXiHKsUQ9TADiRH7DuK0=
github.com/prometheus/procfs v0.17.0/go.mod h1:oPQLaDAMRbA+u8H5Pbfq+dl3VDAvHxMUOVhe0wYB2zw=
github.com/redis/go-redis/extra/rediscmd/v9 v9.10.0 h1:uTiEyEyfLhkw678n6EulHVto8AkcXVr8zUcBJNZ0ark=
Expand Down Expand Up @@ -727,8 +727,8 @@ google.golang.org/protobuf v1.22.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2
google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU=
google.golang.org/protobuf v1.23.1-0.20200526195155-81db48ad09cc/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU=
google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlbajtzgsN7c=
google.golang.org/protobuf v1.36.9 h1:w2gp2mA27hUeUzj9Ex9FBjsBm40zfaDtEWow293U7Iw=
google.golang.org/protobuf v1.36.9/go.mod h1:fuxRtAxBytpl4zzqUh6/eyUujkJdNiuEkXntxiD/uRU=
google.golang.org/protobuf v1.36.10 h1:AYd7cD/uASjIL6Q9LiTjz8JLcrh/88q5UObnmY3aOOE=
google.golang.org/protobuf v1.36.10/go.mod h1:HTf+CrKn2C3g5S8VImy6tdcUvCska2kB7j23XfzDpco=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk=
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q=
Expand Down
69 changes: 69 additions & 0 deletions hack/tools/update-tls-profiles.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
#!/usr/bin/env bash

set -e

if [ -z "${JQ}" ]; then
echo "JQ not defined"
exit 1
fi

OUTPUT=internal/shared/util/tlsprofiles/mozilla_data.go
INPUT=https://ssl-config.mozilla.org/guidelines/latest.json

TMPFILE="$(mktemp)"
trap 'rm -rf "$TMPFILE"' EXIT

curl -L -s ${INPUT} > ${TMPFILE}

version=$(${JQ} -r '.version' ${TMPFILE})

cat > ${OUTPUT} <<EOF
package tlsprofiles

// DO NOT EDIT, GENERATED BY ${0}
// DATA SOURCE: ${INPUT}
// DATA VERSION: ${version}

import (
"crypto/tls"
)
EOF

function generate_profile {
cat >> ${OUTPUT} <<EOF

var ${1}TLSProfile = tlsProfile{
ciphers: cipherSlice{
cipherNums: []uint16{
EOF

${JQ} -r ".configurations.$1.ciphersuites.[] | . |= \"tls.\" + . + \",\"" ${TMPFILE} >> ${OUTPUT}
${JQ} -r ".configurations.$1.ciphers.go[] | . |= \"tls.\" + . + \",\"" ${TMPFILE} >> ${OUTPUT}

cat >> ${OUTPUT} <<EOF
},
},
curves: curveSlice{
curveNums: []tls.CurveID{
EOF

${JQ} -r ".configurations.$1.tls_curves[] | . |= . + \",\"" ${TMPFILE} >> ${OUTPUT}

version=$(${JQ} -r ".configurations.$1.tls_versions[0]" ${TMPFILE})
version=${version/TLSv1./tls.VersionTLS1}
version=${version/TLSv1/tls.VersionTLS10}

cat >> ${OUTPUT} <<EOF
},
},
minTLSVersion: ${version},
}
EOF
}

generate_profile "modern"
generate_profile "intermediate"
generate_profile "old"

# Make go happy
go fmt ${OUTPUT}
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,13 @@ spec:
- --v=${LOG_VERBOSITY}
- --global-pull-secret=openshift-config/pull-secret
{{- end }}
{{- if .Values.options.e2e.enabled }}
{{- /* This is effectively modern with the CHACHA cipher and secp384r1 curve removed */}}
- --tls-profile=custom
- --tls-custom-version=TLSv1.3
- --tls-custom-curves=X25519,prime256v1
- --tls-custom-ciphers=TLS_AES_128_GCM_SHA256,TLS_AES_256_GCM_SHA384
{{- end }}
command:
- ./catalogd
{{- if or .Values.options.e2e.enabled .Values.options.openshift.enabled }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,9 @@ spec:
- --v=${LOG_VERBOSITY}
- --global-pull-secret=openshift-config/pull-secret
{{- end }}
{{- if .Values.options.e2e.enabled }}
- --tls-profile=modern
{{- end }}
command:
- /operator-controller
{{- if or .Values.options.e2e.enabled .Values.options.openshift.enabled }}
Expand Down
Loading