Skip to content

Conversation

@rimi-itk
Copy link
Contributor

Description

Suggested fix for #3085.

As mentioned in #3067 (comment) (and in #3068) some cleanups should be done throughout the code handling API requests.

Link to ticket

#3085

Type

  • Fix
  • Feature
  • Cleanup

Screenshot of the result

If your change affects the user interface, you should include a screenshot of the result with the pull request.

];

if (! $this->projectService->isUserAssignedToProject(session('userdata.id'), $values['projectId'])) {
if (! $this->projectService->isUserAssignedToProject($userId, $values['projectId'])) {
Copy link
Contributor

Choose a reason for hiding this comment

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

The problem with this approach is that is completely circumvents the roles, permissions and projects assigned to an API Key. Devs could just set the userId to any administrator and act on behalf of that admin.

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.

2 participants