summaryrefslogtreecommitdiffstats
path: root/samples/OAuthServiceProvider/Code/Global.cs
diff options
context:
space:
mode:
Diffstat (limited to 'samples/OAuthServiceProvider/Code/Global.cs')
-rw-r--r--samples/OAuthServiceProvider/Code/Global.cs10
1 files changed, 10 insertions, 0 deletions
diff --git a/samples/OAuthServiceProvider/Code/Global.cs b/samples/OAuthServiceProvider/Code/Global.cs
index ceaeac8..7c2e9f7 100644
--- a/samples/OAuthServiceProvider/Code/Global.cs
+++ b/samples/OAuthServiceProvider/Code/Global.cs
@@ -5,6 +5,8 @@
using System.Text;
using System.Web;
using DotNetOpenAuth.OAuth.Messages;
+ using DotNetOpenAuth.OAuth2;
+ using DotNetOpenAuth.OAuth2.Messages;
/// <summary>
/// The web application global events and properties.
@@ -20,6 +22,8 @@
/// </summary>
public static log4net.ILog Logger = log4net.LogManager.GetLogger("DotNetOpenAuth.OAuthServiceProvider");
+ public static AuthorizationServer AuthorizationServer = new AuthorizationServer(new OAuth2AuthorizationServer());
+
/// <summary>
/// Gets the transaction-protected database connection for the current request.
/// </summary>
@@ -50,6 +54,12 @@
set { HttpContext.Current.Session["authrequest"] = value; }
}
+ public static EndUserAuthorizationRequest PendingOAuth2Authorization
+ {
+ get { return HttpContext.Current.Session["authrequest"] as EndUserAuthorizationRequest; }
+ set { HttpContext.Current.Session["authrequest"] = value; }
+ }
+
private static DataClassesDataContext dataContextSimple {
get {
if (HttpContext.Current != null) {