Jenkins - Impersonation
About
See https://issues.jenkins-ci.org/browse/JENKINS-18453
In a secure environment you should configure the master computer to have no executors, so all builds are run on slaves, which may have their own user ID. Then you can configure which jobs can use certain slaves, e.g. http://jenkins-enterprise.cloudbees.com/docs/user-guide-bundle/foldersplus-sect-controlledslaves.html