summaryrefslogtreecommitdiffstats
path: root/samples/OAuth2ProtectedWebApi/Code/AuthorizationServerHost.cs
diff options
context:
space:
mode:
Diffstat (limited to 'samples/OAuth2ProtectedWebApi/Code/AuthorizationServerHost.cs')
-rw-r--r--samples/OAuth2ProtectedWebApi/Code/AuthorizationServerHost.cs8
1 files changed, 7 insertions, 1 deletions
diff --git a/samples/OAuth2ProtectedWebApi/Code/AuthorizationServerHost.cs b/samples/OAuth2ProtectedWebApi/Code/AuthorizationServerHost.cs
index eb7f3f3..843280b 100644
--- a/samples/OAuth2ProtectedWebApi/Code/AuthorizationServerHost.cs
+++ b/samples/OAuth2ProtectedWebApi/Code/AuthorizationServerHost.cs
@@ -85,7 +85,7 @@
// TODO: Consider adding a clients table in your database to track actual client accounts
// with authenticating secrets.
// For now, just allow all clients regardless of ID, and consider them "Public" clients.
- return new ClientDescription();
+ return new AnyCallbackClient();
}
/// <summary>
@@ -171,5 +171,11 @@
return new AutomatedAuthorizationCheckResponse(accessRequest, false);
}
}
+
+ private class AnyCallbackClient : ClientDescription {
+ public override bool IsCallbackAllowed(Uri callback) {
+ return true;
+ }
+ }
}
} \ No newline at end of file