The Atlassian Community Forums are currently in read-only mode. We will be relaunching on a new platform on September 22 (read more here). We apologize for the extended downtime. For concerns or questions, please email communitymanagers@atlassian.com. See you on the other side, on the new Atlassian Community Forums! :)

×

Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Adaptavist Scriptrunner : Switch User functionality not working as expected

bhimashankar_poddar
Contributor
April 7, 2025

Hi Team,

I'm encountering an issue with the built-in 'Switch User' function provided by the Adaptavist ScriptRunner plugin.

Jira Environment:

  • Jira Data Center version: 10.3.4 (recently upgraded from 9.4)

  • ScriptRunner plugin version: 9.10.0

  • Manage Inactive User version: 1.5.7

The 'Switch User' feature is particularly useful for testing user permissions and access by impersonating other users.

In our setup, Jira allows access to users who are members of jira-software-users, jira-users groups.

Our license supports up to 500 users.To manage users beyond this limit, we're using the 'Manage Inactive Users' plugin.

This plugin automatically moves users to a jira-away-users group if they have been inactive (not logged in) for a day. When these users log back in, they are re-added to the original jira-software-users and jira-users groups.

The Issue:

When I attempt to use 'Switch User' for a user who is currently in the jira-away-users group (i.e., not in the active access groups), I receive a 403 Forbidden error as attached in screenshot.

Screenshot 2025-04-07 122148.pngScreenshot 2025-04-03 155823.png


However, this functionality works as expected in Jira 9.4 without any errors.

Could you please help identify what might be causing this issue in the upgraded Jira version?

Has there been a change in how user permissions or group access is handled in version 10.3.4?

Appreciate your time and assistance on this.

2 answers

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

0 votes
Rilwan Ahmed
Community Champion
September 29, 2025

Hi @bhimashankar_poddar ,

This could be the issue (https://docs.adaptavist.com/sr4js/latest/features/built-in-scripts/switch-user#results)

If you are on Jira 10.x.x without JSM installed, please be aware of the following issue:

When switching to a user with insufficient permissions, you may encounter a Forbidden (403) error. This error prevents you from reverting to the admin session within the same page. To resolve this issue:

  1. Close the current page.
  2. Open a new browser tab or window.
  3. Log in again with your admin credentials.

 

0 votes
Ram Kumar Aravindakshan _Adaptavist_
Community Champion
June 26, 2025

Hi @bhimashankar_poddar

Looks like you haven't received any feedback from the community.

Are you still encountering this problem?

I am looking forward to your feedback.

Thank you and Kind regards,
Ram