Closed openshift-cherrypick-robot closed 5 months ago
@openshift-cherrypick-robot: Jira Issue OCPBUGS-32634 has been cloned as Jira Issue OCPBUGS-34673. Will retitle bug to link to clone. /retitle [release-4.13] OCPBUGS-34673: Properly handle rewrite-target annotation
@openshift-cherrypick-robot: This pull request references Jira Issue OCPBUGS-34673, which is invalid:
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.
/jira refresh
@gcs278: This pull request references Jira Issue OCPBUGS-34673, which is valid. The bug has been moved to the POST state.
Requesting review from QA contact: /cc @lihongan
@openshift-cherrypick-robot: all tests passed!
Full PR test history. Your PR dashboard.
/jira refresh
@lihongan: This pull request references Jira Issue OCPBUGS-34673, which is valid.
Requesting review from QA contact: /cc @ShudiLi
/label qe-approved tested it with 4.13.0-0.ci.test-2024-06-03-020738-ci-ln-605fzqk-latest
1.
% oc get clusterversion
NAME VERSION AVAILABLE PROGRESSING SINCE STATUS
version 4.13.0-0.ci.test-2024-06-03-020738-ci-ln-605fzqk-latest True False 3m47s Cluster version is 4.13.0-0.ci.test-2024-06-03-020738-ci-ln-605fzqk-latest
2.
% oc -n openshift-ingress rsh router-default-78794fdd95-cnrst
sh-4.4$ grep "http-request replace-path" haproxy-config.template
http-request replace-path ^{{ $cfg.Path }}/?(.*)$ '{{ processRewriteTarget $pathRewriteTarget }}'
http-request replace-path ^{{ $cfg.Path }}(.*)$ '{{ processRewriteTarget $pathRewriteTarget }}'
sh-4.4$
3.
% oc annotate route/unsec-server3 haproxy.router.openshift.io/rewrite-target="/t t$%&*(){}[].,z#:\`_-|" --overwrite
route.route.openshift.io/unsec-server3 annotate
4.
% oc get route unsec-server3 -o=jsonpath="{.metadata.annotations.haproxy\.router\.openshift\.io/rewrite-target}"
/t t$%&*(){}[].,z#:`_-|%
/label cherry-pick-approved
/lgtm /approve
[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: alebedev87
The full list of commands accepted by this bot can be found here.
The pull request process is described here
The backport introduces a change that prevents the router from crashing due to invalid rewrite-target annotations, so any risk is weighed against this benefit. Any remaining risk is eliminated because there is no change to valid rewrite-target annotations, only invalid rewrite-target annotations.
/label backport-risk-assessed
@openshift-cherrypick-robot: Jira Issue OCPBUGS-34673: All pull requests linked via external trackers have merged:
Jira Issue OCPBUGS-34673 has been moved to the MODIFIED state.
/cherry-pick release-4.12
[ART PR BUILD NOTIFIER]
This PR has been included in build ose-haproxy-router-base-container-v4.13.0-202406100906.p0.g2012a1d.assembly.stream.el8 for distgit ose-haproxy-router-base. All builds following this will include this PR.
Fix included in accepted release 4.13.0-0.nightly-2024-06-10-103644
/cherry-pick release-4.12
@gcs278: new pull request created: #610
This is an automated cherry-pick of #583
/assign gcs278