How can I temporarily "sudo" to another user in a
In a follow-up plugin I need the user who performed the save on the WI to temporarily gain more permissions and perform actions in the plugin; reverting back to normal permissions on plugin termination.
|
2 answers
Hi,
I think you can try to use com.ibm.team.repository.service.IImpersonationService to run some code under a different user. Michele. |
You can use the "com.ibm.team.repository.service.IImpersonationService" service:
IContributorHandle contributorH = ...
Be aware of the logged-in contributor must have administrator permissions.
|
Your answer
Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.