Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Removes some optional cancellation tokens that don't work with all se…

…rver configurations.
  • Loading branch information...
commit 6877b41cb57087bc6ecefcfc5a0f9534a33b2ba8 1 parent c52a9ba
@AArnott AArnott authored
View
6 samples/OAuthAuthorizationServer/Controllers/AccountController.cs
@@ -23,13 +23,13 @@ public class AccountController : Controller {
public async Task<ActionResult> LogOn(LogOnModel model, string returnUrl) {
if (ModelState.IsValid) {
var rp = new OpenIdRelyingParty();
- var request = await rp.CreateRequestAsync(model.UserSuppliedIdentifier, Realm.AutoDetect, new Uri(Request.Url, Url.Action("Authenticate")), Response.ClientDisconnectedToken);
+ var request = await rp.CreateRequestAsync(model.UserSuppliedIdentifier, Realm.AutoDetect, new Uri(Request.Url, Url.Action("Authenticate")));
if (request != null) {
if (returnUrl != null) {
request.AddCallbackArguments("returnUrl", returnUrl);
}
- var response = await request.GetRedirectingResponseAsync(Response.ClientDisconnectedToken);
+ var response = await request.GetRedirectingResponseAsync();
return response.AsActionResult();
} else {
ModelState.AddModelError(string.Empty, "The identifier you supplied is not recognized as a valid OpenID Identifier.");
@@ -42,7 +42,7 @@ public class AccountController : Controller {
public async Task<ActionResult> Authenticate(string returnUrl) {
var rp = new OpenIdRelyingParty();
- var response = await rp.GetResponseAsync(Request, Response.ClientDisconnectedToken);
+ var response = await rp.GetResponseAsync(Request);
if (response != null) {
switch (response.Status) {
case AuthenticationStatus.Authenticated:
Please sign in to comment.
Something went wrong with that request. Please try again.