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

A role without a tag should not have its permissions restricted. #4288

Open
2 of 4 tasks
novakzaballa opened this issue Jul 5, 2024 · 6 comments
Open
2 of 4 tasks
Labels
bug Something isn't working

Comments

@novakzaballa
Copy link
Contributor

novakzaballa commented Jul 5, 2024

How are you running Flagsmith

  • Self Hosted with Docker
  • Self Hosted with Kubernetes
  • SaaS at flagsmith.com
  • Some other way (add details in description below)

Describe the bug

If a role without a tag should not have its permissions(UPDATE_FEATURE_STATE and/or DELETE_FEATURE) restricted.

Steps To Reproduce

  1. Create a role with View Project, View environment, and delete feature, and assign it to test user
  2. Log in with the test user
  3. Go to the project -> environment that you have permission to access.
  4. Try to delete a feature
  5. Error 403

Expected behavior

If there is no tag restricting the permissions, the feature should be deleted successfully.

Screenshots

No response

CC @matthewelwell @gagantrivedi @kyle-ssg

@matthewelwell
Copy link
Contributor

@novakzaballa the example you have given in the description is not valid. The permission for deleting features is the DELETE_FEATURE at the project level. I'm going to close this issue but please re-open it if there is another valid reproduction scenario.

@novakzaballa
Copy link
Contributor Author

@matthewelwell I'm sorry, there was confusion in the PR description. I will correct this with the correct permission and reopen this issue

@novakzaballa novakzaballa reopened this Jul 9, 2024
@novakzaballa novakzaballa self-assigned this Jul 30, 2024
@novakzaballa
Copy link
Contributor Author

Related with #1535

@gagantrivedi
Copy link
Member

gagantrivedi commented Aug 26, 2024

@novakzaballa I think this is a duplicate of #4506 and was fixed here: https://github.com/Flagsmith/flagsmith-rbac/pull/24? Is that correct? I am not able to reproduce this

@gagantrivedi
Copy link
Member

@novakzaballa I think this is a duplicate of #4506 and was fixed here: Flagsmith/flagsmith-rbac#24? Is that correct? I am not able to reproduce this

Ah, I am able to reproduce this if I tag the feature?

@novakzaballa
Copy link
Contributor Author

Hey @gagantrivedi, you’re right. The PR also resolved part of the issue with the roles in the same way. I’ll merge it along with my PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants