Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

no-jira: Validate AWS resource tag keys with aws: prefix #2183

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

patrickdillon
Copy link
Contributor

AWS docs indicate that tag keys cannot be prefix with aws:. See:
https://docs.aws.amazon.com/directoryservice/latest/devguide/API_Tag.html

Using this key prefix leads to an AWS API error indicating the prefix
is reserved for AWS system usage. This commit adds API validation
and ratecheting tests, as the key was previously allowed.

This was originally included in #2124 but cannot land due to a bug addressed by openshift/kubernetes#2167, so

Depends on #2124
Depends on openshift/kubernetes#2167

An incorrect regex validation prevents users from specifying AWS tag keys or
values that include spaces, which are allowed by AWS's official regex:

https://docs.aws.amazon.com/directoryservice/latest/devguide/API_Tag.html

Also includes some API cleanup.
AWS docs indicate that tag keys cannot be prefix with aws:. See:
https://docs.aws.amazon.com/directoryservice/latest/devguide/API_Tag.html

Using this key prefix leads to an AWS API error indicating the prefix
is reserved for AWS system usage. This commit adds API validation
and ratecheting tests, as the key was previously allowed.
@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label Jan 30, 2025
@openshift-ci-robot
Copy link

@patrickdillon: This pull request explicitly references no jira issue.

In response to this:

AWS docs indicate that tag keys cannot be prefix with aws:. See:
https://docs.aws.amazon.com/directoryservice/latest/devguide/API_Tag.html

Using this key prefix leads to an AWS API error indicating the prefix
is reserved for AWS system usage. This commit adds API validation
and ratecheting tests, as the key was previously allowed.

This was originally included in #2124 but cannot land due to a bug addressed by openshift/kubernetes#2167, so

Depends on #2124
Depends on openshift/kubernetes#2167

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.

@patrickdillon
Copy link
Contributor Author

/hold
for dependencies

Copy link
Contributor

openshift-ci bot commented Jan 30, 2025

Hello @patrickdillon! Some important instructions when contributing to openshift/api:
API design plays an important part in the user experience of OpenShift and as such API PRs are subject to a high level of scrutiny to ensure they follow our best practices. If you haven't already done so, please review the OpenShift API Conventions and ensure that your proposed changes are compliant. Following these conventions will help expedite the api review process for your PR.

@openshift-ci openshift-ci bot added do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Jan 30, 2025
Copy link
Contributor

openshift-ci bot commented Jan 30, 2025

[APPROVALNOTIFIER] This PR is NOT APPROVED

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

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

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

Copy link
Contributor

openshift-ci bot commented Jan 31, 2025

@patrickdillon: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/e2e-aws-serial 9ae0e4a link true /test e2e-aws-serial
ci/prow/minor-e2e-upgrade-minor 9ae0e4a link true /test minor-e2e-upgrade-minor
ci/prow/e2e-aws-ovn-hypershift 9ae0e4a link true /test e2e-aws-ovn-hypershift
ci/prow/e2e-aws-serial-techpreview 9ae0e4a link true /test e2e-aws-serial-techpreview
ci/prow/e2e-aws-ovn-techpreview 9ae0e4a link true /test e2e-aws-ovn-techpreview
ci/prow/e2e-aws-ovn 9ae0e4a link true /test e2e-aws-ovn
ci/prow/e2e-upgrade 9ae0e4a link true /test e2e-upgrade
ci/prow/okd-scos-e2e-aws-ovn 9ae0e4a link false /test okd-scos-e2e-aws-ovn
ci/prow/e2e-gcp 9ae0e4a link false /test e2e-gcp

Full PR test history. Your PR dashboard.

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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants