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

users without read permission can access all items via internal api (backend) #112

Closed
raffaelj opened this issue Jun 5, 2023 · 1 comment

Comments

@raffaelj
Copy link
Collaborator

raffaelj commented Jun 5, 2023

Users with backend access, but without read permission for collections can access all entries of all collections via internal api. This enables the content link functionality, but makes the CMS useless for multi user setups.

Steps to reproduce:

  • create collection "sensitive_data" with at least one entry
  • create role "restricted" and keep all permissions disabled
  • assign role "restricted" to a user
  • login as that user
  • open url in browser to access internal api directly

Display all entries of "sensitive_data" via /content/collection/find:

https://domain.tld/content/collection/find/sensitive_data?options[]=

Without the ?options[]= parameter, an error is thrown.

Display a single entry of "sensitive_data" via /content/populate (if _id parameter is known):

https://domain.tld/content/populate?data[0][_model]=sensitive_data&data[0][_id]=779af80a3132308ce20003bf

In v1 I disabled these open routes by default with my rljUtils addon and I never used collection links again.

@aheinze
Copy link
Collaborator

aheinze commented Jun 5, 2023

Should be fixed in dev. Thanks!

@aheinze aheinze closed this as completed Jun 5, 2023
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

No branches or pull requests

2 participants