Taylohtio/GeneralSSO/GeneralSSO.Server/Layouts/Taloyhtio/OAuth/Authenticated/Authorize.aspx

48 lines
2.9 KiB
Plaintext

<%@ Assembly Name="$SharePoint.Project.AssemblyFullName$" %>
<%@ Import Namespace="Microsoft.SharePoint.ApplicationPages" %>
<%@ Register Tagprefix="SharePoint" Namespace="Microsoft.SharePoint.WebControls" Assembly="Microsoft.SharePoint, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
<%@ Register Tagprefix="Utilities" Namespace="Microsoft.SharePoint.Utilities" Assembly="Microsoft.SharePoint, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
<%@ Register Tagprefix="asp" Namespace="System.Web.UI" Assembly="System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" %>
<%@ Import Namespace="Microsoft.SharePoint" %>
<%@ Import Namespace="DotNetOpenAuth.OAuth2" %>
<%@ Import Namespace="Taloyhtio.GeneralSSO.Server.Layouts.Taloyhtio.OAuth.Authenticated.App_LocalResources" %>
<%@ Assembly Name="Microsoft.Web.CommandUI, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
<%@ Assembly Name="System.Core, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" %>
<%@ Assembly Name="DotNetOpenAuth, Version=4.3.0.0, Culture=neutral, PublicKeyToken=2780ccd10d57b246" %>
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Authorize.aspx.cs" Inherits="Taloyhtio.GeneralSSO.Server.Authorize"%>
<html>
<head>
<title>
<asp:Literal ID="Literal1" runat="server" Text="<%$Resources:Title %>" />
</title>
<link rel="stylesheet" type="text/css" href="css/styles.css" />
</head>
<body>
<p>
<%= Authorize_aspx.Warning %>
</p>
<p>
<%= string.Format(Authorize_aspx.QuestionTemplate, this.Model.ClientName) %>
</p>
<p>
<b><%= Authorize_aspx.RequestedAccess %></b> <%= string.Join(" ", this.Model.ScopeAsArray) %>
</p>
<p>
<form id="Form1" runat="server">
<input type="hidden" id="IsApproved" name="IsApproved"/>
<input type="hidden" id="client_id" name="client_id" value="<%= this.Model.AuthorizationRequest.ClientIdentifier %>"/>
<input type="hidden" id="redirect_uri" name="redirect_uri" value="<%= this.Model.AuthorizationRequest.Callback %>"/>
<input type="hidden" id="state" name="state" value="<%= this.Model.AuthorizationRequest.ClientState %>"/>
<input type="hidden" id="scope" name="scope" value="<%= OAuthUtilities.JoinScopes(Model.AuthorizationRequest.Scope) %>"/>
<input type="hidden" id="response_type" name="response_type" value='<%= this.Model.AuthorizationRequest.ResponseType == DotNetOpenAuth.OAuth2.Messages.EndUserAuthorizationResponseType.AccessToken ? "token" : "code" %>'/>
<div>
<input type="submit" value="<%= Authorize_aspx.Yes %>"
onclick="document.getElementsByName('IsApproved')[0].value = true; return true;" class="button"/>&nbsp;&nbsp;
<input type="submit" value="<%= Authorize_aspx.No %>"
onclick="document.getElementsByName('IsApproved')[0].value = false; return true;" class="button"/>
</div>
</form>
</p>
</body>
</html>