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

Authorize on trigger service stop endpoint #7750

Merged
merged 1 commit into from
Oct 20, 2020
Merged

Conversation

aherrmann-da
Copy link
Contributor

Adds authorization to the stop endpoint of the trigger service, if authorization via the auth middleware is enabled.

Stopping the trigger will require the same claims as starting the trigger, i.e. actAs the trigger party. In order to determine the trigger party we first need to query for the running trigger before we can authorize the request.

Part of #7723

Pull Request Checklist

  • Read and understand the contribution guidelines
  • Include appropriate tests
  • Set a descriptive title and thorough description
  • Add a reference to the issue this PR will solve, if appropriate
  • Include changelog additions in one or more commit message bodies between the CHANGELOG_BEGIN and CHANGELOG_END tags
  • Normal production system change, include purpose of change in description

NOTE: CI is not automatically run on non-members pull-requests for security
reasons. The reviewer will have to comment with /AzurePipelines run to
trigger the build.

changelog_begin
changelog_end
Comment on lines +197 to +198
override def getRunningTrigger(triggerInstance: UUID): Either[String, Option[RunningTrigger]] =
run(queryRunningTrigger(triggerInstance))
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Note, this part is not tested, yet. This depends on #7720.

Copy link
Contributor

@cocreature cocreature left a comment

Choose a reason for hiding this comment

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

Nice, thank you!

@aherrmann-da aherrmann-da merged commit 48527e2 into master Oct 20, 2020
@aherrmann-da aherrmann-da deleted the trigger-auth branch October 20, 2020 15:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants