Hi All,

I am working on a jira [1] which is related with an exception that is
thrown when trying to add a user/role in tenant mode using EMM console.
This is particularly happens when we call the admin service to get the
secondary user store configurations related to particular tenant [2].
Following is the root cause behind this exception,

*Caused by: java.lang.SecurityException: Illegal access attempt to cache ]
owned by tenant*
*{[test.com <http://test.com>],[1]} by tenant {[test.com

When trying to access the cache, the caller's tenant id has changed to
super-tenant id, although tenant domain is correct. I tried to start the
tenant flow before calling the admin service, but still I got the same
error. While debugging I found, [3] is the point where the tenant domain is
set to correct domain, while the tenant id still set to super-tenant id.
Locally I changed that particular line as per below,


After that I could get the secondary user-store configurations related to
that particular tenant. Is this a bug from carbon-level or is there any
work-around to avoid this? Any comments or suggestions on this regard is
highly appreciated.

[1] https://wso2.org/jira/browse/EMM-1762


Megala Uthayakumar

Software Engineer
Mobile : 0779967122
Dev mailing list

Reply via email to