Cockpit-HQ / Cockpit

Cockpit Core - Content Platform
https://getcockpit.com
Other
388 stars 47 forks source link

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

Closed raffaelj closed 1 year ago

raffaelj commented 1 year ago

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:

__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 commented 1 year ago

Should be fixed in dev. Thanks!