jakubgarfield / Bonobo-Git-Server

Bonobo Git Server for Windows is a web application you can install on your IIS and easily manage and connect to your git repositories. Go to homepage for release and more info.
http://bonobogitserver.com
MIT License
1.81k stars 603 forks source link

Version 6.3.0 - Redirection After Login #743

Open abald124 opened 7 years ago

abald124 commented 7 years ago

Upgraded to version 6.3.0 and using Active Directory Membership Service . Having issues with the redirect after authentication similar to the issues described in #731 and #733.

On a successful login the URL in address bar changes to /Home/Logon?returnUrl=%2FBonobo.Git.Server%2FHome%2FIndex but still stuck on the login page.

Know login was successful because I can manually put /Account in the address bar and get to the accounts index view.

CatStarwind commented 7 years ago

I'm not sure why, but going to "/Home/WindowsLogin" solves this.

CatStarwind commented 7 years ago

Still looking into this, so far it seems the issue stems from this commit. Thus far I was able to patch it by changing line 44 in RepositoryController.cs to the following:

return RedirectToAction((AuthenticationProvider is WindowsAuthenticationProvider ? "WindowsLogin" : "Logon"), "Home", new { returnUrl = Url.Action("index", "Home") });

But I'm still looking into a more elegant solution/why it doesn't authenticate before hand. It doesn't seem like the CookieAuthenticationOptions that are configured ever get used.

AlmightyCZ commented 5 years ago

Was there any release fixing this issue?