Skip to main content

Hey guys,


I'm trying to implement my first custom-made ASP.net page to handle a user viewing some info about his worklist item and then completing an action.


The page works locally, but when I deploy it to the web server and attempt to use it from the worklist, I get an ASP.net error saying that "DOMAINaccountname is not allowed to open worklist item with SN...."



The domain and accountname in the error is the service account that the site's app pool runs under...


Meaning it's trying to actually use the web site's service account to login to the K2 server rather than the person who's logging into the site.


I think I have security set up correctly (the site is even running correctly using Kerberos I think), so I think it might be a problem with my code and the way I've built my connection string or something.


What connection string should I use to make sure I pass the credentials of the signed in user, as opposed to the credentials of the site itself, assuming Kerberos is working correctly?


Thanks...

As previously stated, you can certainly set impersonation in the web.config file.  However, when doing this ALL code that is executing in the code behind is under the context of the currently logged in user.  This isn't always wanted.  A more granular approach is to call the Impersonate method on the work list Connection object prior to loading the work list item.  Just pass in the currently logged in user's credentials and you'll load his/her items.


Reply