Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

I am planning to use the share-point client object model to get the data(Lists etc) from share-point site ( Sharepoint site and mobile sites are hosted on two different machines/IIS servers).

I do have STS SAML 1.0 running on the another machine. All sharepoint site and mobile sites are federated with STS site and Single sign on (SSO FedAuth) is working fine when you browse through browsers. My question is can I call sharepoint resources sitting in mobile site server side using client object model (getting the SAML token from the STS directly (SSO & realm) and using(adding to web request) in each and every service call ? will it work.. or any suggestion is appreciated. Thank you in advance

Shashi

share|improve this question
add comment

2 Answers

What you want to do is get the FedAuth cookie from you SharePoint site and pass it with each web request.

You will get that cookie when you pass the SAML token's encrypted data to your site's login page - login to your site with a browser and fiddler running to see what happens.

share|improve this answer
add comment

Yes, this should work if you attach all the needed cookies (should be FedAuth ... but there might be others).

This is the same scenario as calling SharePoint online. It uses federated auth too. I blogged about how to authenticate with 365 here:

http://blogs.msdn.com/b/cjohnson/archive/2011/05/14/part-2-headless-authentication-with-sharepoint-online-and-the-client-side-object-model.aspx

You should be able to take a look at the sample code and see how it gets the FedAuth cookie and reattaches it to the CSOM calls for subsequent calls.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.