Limit a user to execute specific custom Jaspersoft reports
book
Article ID: 124482
calendar_today
Updated On:
Products
Clarity PPM SaaSClarity PPM On Premise
Issue/Introduction
How can you restrict a user to be able to only see and execute only specific custom Jaspersoft reports?
Environment
Release: Any
Resolution
A possible way to achieve this is by placing the reports in a custom folder and configuring the user accordingly.
Add a custom role under Home - Advanced Reporting - Manage - Roles.
Add a custom folder under Home - Advanced Reporting - View - Repository, i.e. under the Organization.
Right-click on the custom folder and select Permissions to assign "Read Only" permission to the custom role.
The user to execute the reports needs to have assigned both the ROLE_USER and the Custom Role roles.
ROLE_USER:
In Clarity, go to Administration -> Organization and Access -> Resources
Select the resource
In Resource's Access Rights - Global add: "Advanced Reporting - Navigate"
Custom Role
In Clarity, go to Home -> Advanced Reporting -> Manage -> Users
Edit the User.
Add the Custom Role
Click on Save.
Run the "Create and Update Jaspersoft Users"
In the custom folder, right-click on the report - Permission and assign "Read Only" permission to both the Custom Role and the ROLE_USER roles
The user can now correctly see only the custom folder and the reports in there, but note that on executing a report an error may show up:
org.springframework.security.access.AccessDeniedException: Access is denied To execute a report you need access to the Data Sources and not having this is causing the "Access is denied" message. The data sources can be found in the Repository under the default "CA PPM" folder in the "Data Sources" subfolder. To resolve this error, grant the "Execute Only" access to the "CA PPM" folder for the custom role