Frequently we have to execute plugins as Service Accounts so they have the right privileges to execute the business logic we want. Although you can set a user in the "Run In User Context" field of the plugin step, sometimes our organizations doesn't actually have service accounts to be used there. To programatically run a plugin … Continue reading Impersonating plugin as SYSTEM programatically
Find below a C# method to check if an specified user(Sent as parameter) has System Admin role. The method will return true if so. Otherwise, it will return false. Hope it helps.