[ZBX-19443] Exporting template with host prototype that has inaccessible group leads to error Created: 2021 May 24  Updated: 2024 Apr 10

Status: Open
Project: ZABBIX BUGS AND ISSUES
Component/s: API (A)
Affects Version/s: 4.0.30, 5.2.6, 5.4.0, 6.0.0alpha1
Fix Version/s: None

Type: Problem report Priority: Trivial
Reporter: Ivo Kurzemnieks Assignee: Zabbix Development Team
Resolution: Unresolved Votes: 0
Labels: export, permissions
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Team: Team B

 Description   

The set-up:
1. Create a host group "A";
2. Create a template "T";
3. Assign template "T" to host group "A";
4. Create a host group "B";
5. Create a host "H";
6. Assign host "H" to host group "B";
7. Link template "T" to host "H";
8. Create a user group "G";
9. Set "Read-write" permissions to host group "A";
10. Set "Deny" permissions to host group "B";
11. Create a user "U";
12. Assign user "U" to group "G";
13a. Set "User type" to "Zabbix Admin" (for 4.0);
13b1. Create user role "R" and set "User type" to "Admin" (for 5.2 and higher);
13b2. Assign role "R" to user "U" (for 5.2 and higher);
14. Create host prototype on template "T";

The execution:
1. Log in with user "U" (regular admin);
2. Export template "T";

Result:
a) Observe ambiguous error "No permissions to referred object or it does not exist!" (for 4.0);
b) Observe the page reloads, but nothing happens (for 5.2 and higher).

Expected:
If user is not allowed to access the group, then perhaps some better error message is expected. For example "Cannot exported template because it contains an inaccessible group."


Generated at Sun Mar 16 22:10:37 EET 2025 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.