Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Switching to project view not working when user is assigned custom Project Role

Open
#14,014 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
55/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Active
Tech stack
java
Domain
api, authorization

Research direction

Reproduce the failure with a custom Project Role granting "allow *", then inspect the project-view requests for listApis, listZones, and listCapabilities and compare them with Admin or Regular project membership. Check the behavior across API/UI versions 4.22.1.1 and 4.22.1.0. Done means a custom-role user can switch to project view without authorization errors and the listed requests succeed.

Written by the indexing model from the issue text.

Description

component:projects component:UI type:regression
problem

If account/user is added to the project with custom role (even if role permisions are "allow *") user can login to CS successfully but switching to project view will fail and generate multiple errors: "

The given command 'listApis' either does not exist, is not available for user. Unable to proceed. Please contact your administrator." 
The given command 'listZones' either does not exist, is not available for user. Unable to proceed. Please contact your administrator.
The given command 'listCapabilities' either does not exist, is not available for user. Unable to proceed. Please contact your administrator.
...
Image

On browser console indeed you can see that request:
/client/api/?command=listApis&response=json&sessionkey=xxx&projectid=xxx
returns:
{"listapisresponse":{"uuidList":[],"errorcode":401,"cserrorcode":9999,"errortext":"The given command 'listApis' either does not exist, is not available for user."}}
If user is added to the project with Admin or Regular Type without any project role, switching to project view works correctly.

Switching to project view using custom Project Roles in 4.22.1.0 works correctly.
Also using UI ver. 4.22.1.1 and Api ver: 4.22.1.0 works correctly.

No additional logs available in:

cloudstack/management/apilog.log
cloudstack/management/management-server.log
versions

ACS: 4.22.1.1

The steps to reproduce the bug
  1. Create new project "Test"
  2. Create Project Role with "allow *" permission
  3. Add non-admin user to project with that Project Role
  4. Switch to Project View of "Test" project
What to do about it?

Please track the root cause and fix the bug

Dominant language
Java
Stars
3.1k
Forks
1.4k
Avg merge
6d 20h
Merged PRs (30d)
27

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from apache/cloudstack

All issues in apache/cloudstack

Similar issues

More Java issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.