nguyentientoan / socialauth-net

Automatically exported from code.google.com/p/socialauth-net
0 stars 0 forks source link

Custom authentication has no way to know loginUrl when it initializes and tries to auto disconnect. #210

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Custom Authentication

When I start up my application using custom authentication, the 
context_PreRequestHandlerExecute function attempts to run 
SocialAuthUser.Disconnect in an effort to eliminate persisting forms and 
cookies. This is an automatic process that I don't have the ability to control. 
However, because it doesn't call SocialAuthUSer.Disconnect() with a loginURL 
parameter, it is always "" -- which means that when it gets to the 
RedirectToLoginPage function it ALWAYS fails with the exception "Pleas specify 
loginUrl".

Someone else raised this point a little earlier, and the recommendation was to 
always be sure to include a loginUrl if you are calling RedirectToLoginPage() 
from a custom installation. However, in this case there is no opportunity to do 
so (because it is completely automatic). And as far as I can tell there is not 
configuration option that allows me to store this URL as a default.

What is the expected output? What do you see instead?

A configuration option should be provided which the system can refer to if it 
attempts to redirect to the loginUrl and one isn't passed by the user. 

With that said, I'm a little confused by the system is automatically calling 
SocialAuthUser.Disconnect() in context_PreRequestHandlerExecute() if I am 
supposedly supposed to be completely in control of authentication? But that is 
a separate question. 

What version of the product are you using? On what operating system?

Looks like 2.5 from the repository. Although I also had this issue with 2.4.

Please provide any additional information below.

Love the program! It has made things so much easier!

Mark

Original issue reported on code.google.com by mark.kup...@gmail.com on 14 Jan 2015 at 4:40