You are viewing limited content. For full access, please sign in.

Question

Question

Invalid Object Name - ConnectToDatabase

asked on September 5, 2018

I have an integration that is throwing an "Invalid Object Name" error when connecting to a repository using Windows Authentication. If I use a Laserfiche user, instead of a Windows account, the connection is successful

 

ERROR: -1073470661 Invalid object name.
Code Area: Laserfiche Connection    STACK TRACE:    at LFSO102Lib.LFApplicationClass.ConnectToDatabase(String DatabaseName, String ServerName, String UserName, String Password)
   at LFIntegrator_WebService.LFIWebService.GetLFConnection(String iniServer, String iniRep, String iniUsername, String iniPW)

0 0

Replies

replied on September 6, 2018

I'm not sure what that error would be referring to, but are you sure you're attempting the Windows authentication correctly?  You would be passing in null as the username and password, while impersonating the account you want to use.  In a web context, this might require Kerberos to be configured.

0 0
replied on September 7, 2018

Can you confirm that in order to log into a repository via the web using the SDK with a domain user\windows authentication, Kerberos needs to be configured? I think it's odd that if I log in directly to Web Access using the same domain\user, but not through the SDK

0 0
replied on September 12, 2018

It doesn't always require Kerberos, it depends on how exactly you are using the credentials.  You do need to have the impersonation context set up prior to calling ConnectToDatabase (with null for username and password).  It sounds like you are in the situation where you need to call LogonUser for this, see this thread.

0 0
replied on September 13, 2018

To clarify about the Kerberos bit, I originally said "might require" because there are two very different ways to use Windows domain identities in a web application (and indeed in Web Access), and I wasn't sure from your question which situation you were in.

When you log in to a repository through Web Access and give it domain credentials, it does call LogonUser to get a WindowsIdentity that it can impersonate while authenticating to the Laserfiche server.

0 0
replied on September 14, 2018

The suggestion you gave me previously about impersonation seems to be working for me at this time. Thank you for all of your help!

0 0
replied on September 12, 2018

Anyone else run into this before? Any suggestions?

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.