Skip to content
This repository has been archived by the owner on Jan 8, 2024. It is now read-only.

server: Ensure trigger names are valid paths #4660

Merged
merged 3 commits into from
May 3, 2023

Conversation

briancain
Copy link
Member

Prior to this commit, a user could create a bad HTTP path with a trigger name like ../bad. This commit fixes that behavior by validating the given trigger name matches our expected valid path tokens.

With this fix:

brian@ubuntu:waypoint-tetris λ waypoint trigger create -name=../hello -op=build                                                                        ±[main]
! trigger: (name: name cannot contain '../'.).

Prior to this commit, a user could create a bad HTTP path with a trigger
name like `../bad`. This commit fixes that behavior by validating the
given trigger name matches our expected valid path tokens.
@briancain briancain added pr/no-changelog No automatic changelog entry required for this pull request backport/0.11.x labels May 3, 2023
@briancain briancain requested a review from a team as a code owner May 3, 2023 20:25
@briancain briancain removed the pr/no-changelog No automatic changelog entry required for this pull request label May 3, 2023
Copy link
Contributor

@jgwhite jgwhite left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

NICE

@briancain briancain merged commit da5b54d into main May 3, 2023
38 checks passed
@briancain briancain deleted the maint/trigger/ensure-names-are-valid-paths branch May 3, 2023 21:19
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants