SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is it possible to log a user programmatically with Windows Identity Foundation regardless of the authentication scheme used on SharePoint (claims / forms)?


share|improve this question
Please elaborate a bit more; do you want to do a client authn or do you need to do it actively from an application or impersonate a user inside SharePoint? – Wictor Wilen MCA MCM MVP Aug 3 '11 at 13:24
I am trying to implement a single solution for both our internal server and SharePoint Online. SharePoint Online uses WIF so I wonder if same is possible with SharePoint Server. – Élodie Petit Aug 4 '11 at 8:11
Élodie, were you able to throw together a sample that programmatically logs in to SPO in an ADFS scenario? – cs31415 Apr 4 '12 at 22:36
up vote 0 down vote accepted

SharePoint (365 and on-premise) both uses WIF for claims based authn, even though 365 has implemented some non standard quirks to handle the federated logout scenarios. So if you question is if you can use WIF with SharePoint the answer is Yes.

share|improve this answer
Thanks for the answer. What do you think of my solution then, is it a good way to implement a uniform login system? – Élodie Petit Aug 5 '11 at 9:20
You should definatley take a look at ADFS if you'd like to have SSO to SP on-prem and SP online. There's no need to build a custome fed authn solution. – Wictor Wilen MCA MCM MVP Aug 5 '11 at 10:38

Your Answer


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.