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

feat(doctrine): check property security during search filter #6433

Conversation

emmanuel-averty
Copy link
Contributor

Q A
Branch? main
License MIT

TODO

  • tests
  • add a parameter (where ?) to enable this feature (BC)
  • manage security for nested properties
  • reproduce code in ODM

SearchFilter should check property security before adding where condition to the query. In other words : a user should not be able to filter resources by a property he is not allowed to see.

Use case
Considering a Student resource with following properties :

  • name
  • anonymizationCode

Users with «corrector» role don't see name property.
A SearchFilter can be applied on name.

As a corrector I can try to find which student matches each anonymization code by trying :
GET /api/students?name=John+Doe

@emmanuel-averty
Copy link
Contributor Author

This PR is replaced by #6435

@emmanuel-averty emmanuel-averty deleted the feat/search-filter-property-security branch June 25, 2024 13:34
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.

1 participant