private ActionResult CompleteSignIn(OpenIdentity identity) { if (identity == null || string.IsNullOrEmpty(identity.Username)) { return(ErrorOut("Invalid Identifier")); } _formsService.SignIn(identity.Username, true); return(Redirect()); }
public OpenIdentity Verify() { var oid = new OpenIdentity(); switch (_response.Status) { case AuthenticationStatus.Authenticated: oid.Id = _response.ClaimedIdentifier; var claimsResponse = _response.GetExtension<ClaimsResponse>(); oid.Username = _response.FriendlyIdentifierForDisplay; break; case AuthenticationStatus.Canceled: throw new ApplicationException("Canceled at Provider"); case AuthenticationStatus.Failed: throw new ApplicationException(_response.Exception.Message); } return oid; }
private ActionResult CompleteSignIn(OpenIdentity identity) { if (identity == null || string.IsNullOrEmpty(identity.Username)) { return ErrorOut("Invalid Identifier"); } // Stick in next request or cookie!!!!!!!!! Debugger.Break(); var cookie = Request.Cookies["returnUrl"]; if (cookie != null) { return Redirect(cookie.Value); } else { return RedirectToAction("Index", "Home"); } }