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 following the article and sample that can be found in this address: http://msdn.microsoft.com/en-us/library/hh147177.aspx

Everything works fine but I need a more automated solution. The user shouldn't see the login popup, and my app must be able to login on behalf of the user without waiting for the popup.

I have two questions in this context:

  1. Can I fill the username and password input boxes in the web browser control automatically? And what do you think of using this system in a service architecture where a service logs in for the users? Using WebBrowser control in a WCF service method makes me nervous.

  2. Can I give up using WebBrowser control completely and code the login process with pure TCP Sockets? I know it's not possible with WebRequest classes because AFAIK HTTPOnly cookies cannot be retrieved with them.

Thanks in advance.

share|improve this question
    
So here are my comments on my own question: 1-This is possible but I have to wait a few more seconds after DocumentCompleted event because Windows Live Services scripts run after the document is loaded and creates thousands of HtmlElements. 2-This is not possible. Answer lies in my first comment. Windows Live Services scripts creates thousands of elements and the worst of all it also creates login cookies dynamically. Not being able to log on to SharePoint online programmatically is a real pain for me right now. –  Élodie Petit Jul 21 '11 at 7:51
    
Start working on the similar problem (LiveID auth via SP2010). 2) If it's a desktop app it seems that your comments are right. I'm looking at WS-Federation specs now. Maybe it's possible to work around it. The second variant is to dig into OAuth 2.0 for Windows Live –  AlexSSE Jul 29 '11 at 8:17
    
If you come up with a solution, it will be greatly appreciated. –  Élodie Petit Jul 29 '11 at 8:19
add comment

1 Answer

up vote 2 down vote accepted

What you are after is "Headless" authentication. Check out this blog post from CJ

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.