Blank page displayed when editing a permissions scheme in Jira server
Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.
Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Summary
Problem
When edit a permissions scheme, a blank page is shown. Results in the following exception in atlassian-jira.log :
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
2016-04-22 12:37:01,622 http-nio-8080-exec-2 ERROR xxxx 757x4587x1 1aad55m 172.16.20.65 /rest/internal/2/managedpermissionscheme/10100 [c.a.p.r.c.error.jersey.ThrowableExceptionMapper] Uncaught exception thrown by REST service: null
java.lang.NullPointerException
at com.atlassian.jira.permission.management.ManagedPermissionSchemeHelperImpl.buildGrants(ManagedPermissionSchemeHelperImpl.java:317)
at com.atlassian.jira.permission.management.ManagedPermissionSchemeHelperImpl.lambda$generatePermissionSchemeBean$4(ManagedPermissionSchemeHelperImpl.java:224)
at com.google.common.collect.Iterators$8.transform(Iterators.java:799)
at com.google.common.collect.TransformedIterator.next(TransformedIterator.java:48)
at com.google.common.collect.Iterators.addAll(Iterators.java:362)
at com.google.common.collect.Lists.newArrayList(Lists.java:160)
at com.google.common.collect.Lists.newArrayList(Lists.java:144)
at com.atlassian.jira.permission.management.ManagedPermissionSchemeHelperImpl.generatePermissionSchemeBean(ManagedPermissionSchemeHelperImpl.java:238)
at com.atlassian.jira.permission.management.ManagedPermissionSchemeHelperImpl.getManagedPermissionScheme(ManagedPermissionSchemeHelperImpl.java:104)
... 2 filtered
at java.lang.reflect.Method.invoke(Method.java:498)
at com.atlassian.plugin.util.ContextClassLoaderSettingInvocationHandler.invoke(ContextClassLoaderSettingInvocationHandler.java:26)
at com.sun.proxy.$Proxy264.getManagedPermissionScheme(Unknown Source)
Symptoms
After upgrading to Jira 7
After deactivating Jira Service Management
It can happen in any version of Jira if the permission-types.xml file was modified during automated deployments, causing it to expose new security types such as reportercreate and assigneeassignable which have been since deprecated. The file is located in $JIRA_INSTALL/atlassian-jira/WEB-INF/classes
Solution
Cause 1
There seems to be an old permission type from the old version of Jira that is still present in this permission scheme.
Cause 2
Service Management's role is still being used in the permission scheme.
Resolution
Resolution 1
Option 1 (if you can roll back the Jira upgrade) : While still on Jira 6 (or the version of Jira before upgrading), check the permission scheme on the UI. Notice that there is an 'Unknown Security Type' in there.
This security type is not compatible in the new version. So, it needs to be deleted.
If you can spot the problematic security type then delete that security type from the Jira version prior to the upgrade and then upgrade the Jira instance again.
Option 2 (If you have upgraded already, and cannot roll back) :
Create a new permission scheme from the UI. Make sure it does not give the same error.
Run the following queries in the database :
1
SELECT * FROM schemepermissions WHERE scheme=<old>
1
SELECT * FROM schemepermissions WHERE scheme=<new>
ℹ️ Here 'old' and 'new' are ids of the permissions schemes. To determine the id for the permission scheme, hover over the permission scheme in Administration console. The id will show up in the url.
Comparing the results of the 2 queries should help to identify the perm_type that is causing problems.
Deleting the rows that are causing problems :
1
DELETE FROM schemepermissions WHERE perm_type="reportercreate"
ℹ️ In this case its "reportercreate". It could be different in other cases.
Always back up your data before making any database modifications. If possible, test any alter, insert, update, or delete SQL commands on a staging server first.
Restart Jira. That should help to fix the issue here.
Resolution 2
Option 1
Install Jira Service Management
> Issues > Permission Scheme
Check the permission scheme with the name Jira Service Management Permission Scheme for Project XXX
Remove *Service Management customer - portal access* from the permission schemes
Uninstall Jira Service Management
Option 2
Always back up your data before making any database modifications. If possible, test any alter, insert, update, or delete SQL commands on a staging server first.
Update the database:
1
delete from schemepermissions where perm_type = 'sd.customer.portal.only';
Restart Jira.
Was this helpful?