Hidden datasource access via authorization bypass in application import and fork
Description
An authenticated workspace member who can import or fork applications could cause Appsmith to reuse an existing datasource that the member was not authorized to view. Imported or forked actions could then be associated with that datasource when the member had permission to execute it. The issue affected Appsmith Community and Enterprise editions.
Impact
A member could run actions through a datasource that was otherwise hidden from them, using the datasource's stored connection configuration. Depending on the datasource and the permissions of its credentials, this could disclose data or perform changes in a connected database or API. Exploitation required an authenticated member who could import or fork an application and execute the affected datasource while lacking permission to view it.
Affected and patched versions
Appsmith versions earlier than 2.3 are affected. Upgrade to 2.3 or later.
Workarounds
Until upgrading, restrict application import and fork capabilities to trusted workspace members. Do not grant members execute permission on datasources they are not also authorized to view.
Credits
Thanks to David Carliez (@DavidCarliez) for reporting this issue.