2

We are using MAF to load external plugins and activate them as new processes. The host process is a Windows Service that runs under user account svc-host.

Is there any possibility to activate a plugin in a separate process but running under another user account (svc-mypluginuser)?

Example use case: plugins connect to their own databases. Database security is AD based. We need to ensure each plugin has access to its own database only.

Code we use:

var process = new AddInProcess();
var view = pluginToken.Activate<MyPlugin>(process, AddInSecurityLevel.Host);

The AddInProcess does not seem to have any way to pass in any user credentials.

Olek
  • 676
  • 7
  • 11
  • Where are the credentials going to come from? You could setup an initialize method and pass them in that way. Then anytime you need to run code you need to impersonate the user. You could possibly setup your AddinAdapters to enter the correct context for you, so your plugins don't need to worry about running under the correct context. – John Koerner Dec 11 '14 at 02:39

0 Answers0