Hi,
We want to implement the following scenario using livelink 9.7.1 les-services:
We have a .NET webapplication that uses windows authentication (IWA) to authenticate the end users. The .NET application needs to call the livelink webservices using the end user's credentials. Also for livelink we're using directory services and IWA.
We don't want to pass clear text passwords over the wire (including the one of an admin account), so we want to use IWA between the .NET app and the les-services. We've managed to get this working. The system account that runs the .NET app is passed to livelink, and this works fine.
Now we want to use the ImpersonateUser method to execute the webservices with the credentials of the end user instead of using the .NET system account. When debugging the .NET app we notice that the impersonate works (it returns a token). When we try to call a method on the DocumentManagementServer using this token, we get an error: "Could not login with cookie".
Any suggestions on how to get passed this error and get this working?
Is it possible to use ImpersonateUser when using IWA on the les-services?
If not, is there another way to achieve are goal: call a LL webservice from a .NET webapp using credentials of the enduser of the webapp, without sending a hardcoded cleartext admin username/password to authenticate.
Here's a piece of code we used for testing:
public Byte[] GetDocumentByID(int id)
{using (var authenticationSrvc = new LLAuthenticationService.AuthenticationClient())
{
var impersonatedUser = authenticationSrvc.ImpersonateUser(new LLAuthenticationService.OTAuthentication { AuthenticationToken = "" }, "GJI760");
var documentAuthentication = new OTAuthentication { AuthenticationToken = impersonatedUser};
using (var documentSrvc = new DocumentManagementClient())
{
return documentSrvc.GetVersionContents(documentAuthentication, id, 0).Contents;
}
}
}