0

I have a server which hosts Sharepoint 2010. I have another server which hosts a SQL Server 2008 R2. SharePoint is Kerberos/Claims Based.

On my SharePoint, I installed a custom made webpart that connects to the SQL Server machine using standard connection string (Data Source=myServerAddress;Initial Catalog=myDataBase;Integrated Security=SSPI;).

The problem is that when the webpart tries to connect to the sql server, I get the following message :

Login failed for user 'NT AUTHORITY\ANONYMOUS LOGON'

What we've done :

  • Verify all spn/delegation/trusts things - everything seems okay.
  • Tried to connect directly from the sharepoint machine via a UDL file to sql server, and it works.
  • Tried the webpart as standalone ASPX page on a single machine server to prove the code is supposed to work, and it works.
  • Wireshark -> We can see a KDC_ERR_S_PRINCIPAL_UNKNOWN when ANONYMUS LOGON tries to connect to sql server (obvisously).
  • SharePoint Developer Dashboard shows us our current username, which is not ANONYMUS.
  • Traces in the webpart shows two things : The HTTPCONTEXT is set to my current user, so is the Thread.Current.
  • Using SQL Profiler, we can see that the request is from ANONYMUS
  • We tried to access a web service on another server from another custom made webpart, and it failed for the same reason (ANONYMUS).

What are we missing? The problem really seems to be that SharePoint is unable to send the current user credential to another server (sql or not).

1 Answer 1

0

Have you verified that Kerberos is working ?

Download the Troubleshooting Kerberos Delegation

http://www.microsoft.com/DOWNLOADS/details.aspx?familyid=99B0F94F-E28A-4726-BFFE-2F64AE2F59A2&displaylang=en

1
  • Yeah we went through that too. Everything is setup properly. We recently read on a non official source that case could matter in the SPN, so we are checking all of them right now... Commented Aug 30, 2011 at 15:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.