Skip to content

[18.0-fr6] Fix shell injection in trust_flush CronJob#717

Open
openshift-cherrypick-robot wants to merge 1 commit into
openstack-k8s-operators:18.0-fr6from
openshift-cherrypick-robot:cherry-pick-715-to-18.0-fr6
Open

[18.0-fr6] Fix shell injection in trust_flush CronJob#717
openshift-cherrypick-robot wants to merge 1 commit into
openstack-k8s-operators:18.0-fr6from
openshift-cherrypick-robot:cherry-pick-715-to-18.0-fr6

Conversation

@openshift-cherrypick-robot

@openshift-cherrypick-robot openshift-cherrypick-robot commented Jun 24, 2026

Copy link
Copy Markdown

This is an automated cherry-pick of #715

/assign stuggi

Jira: OSPRH-31632

Replace the bash -c string concatenation of TrustFlushArgs with a
direct argv array, preventing shell metacharacter injection. The
CronJob now executes keystone-manage as Command: ["keystone-manage",
"trust_flush", ...args] instead of Command: ["/bin/bash"] Args:
["-c", "keystone-manage trust_flush" + args].

Additionally add kubebuilder:validation:Pattern on the TrustFlushArgs
CRD field to reject shell metacharacters at the API level.

Jira: OSPRH-31632

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Martin Schuppert <mschuppert@redhat.com>
@openshift-ci

openshift-ci Bot commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: openshift-cherrypick-robot
Once this PR has been reviewed and has the lgtm label, please assign dprince 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

@stuggi

stuggi commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

/hold

@stuggi stuggi self-requested a review June 24, 2026 09:46
@stuggi

stuggi commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

/retest

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants