@page "/auth" @model VPNAuth.Server.Pages.Auth @{ Layout = null; } <!DOCTYPE html> <html> <head> <title>VPNAuth - Auth</title> <link rel="stylesheet" href="/static/style.css"> </head> <body> <h1>Authorization</h1> @if (Model.ValidRequest) { <div> <p>Do you want to log into <i>@Request.Query["client_id"]</i> as user <i>@Model.User?.Username</i>?</p> <p>Requested scopes:</p> <ul> @foreach (var scope in Model.RequestEntry!.Entity.Scopes) { <li>@scope</li> } </ul> <button class="button primary" onclick="window.location = '/accept-auth/@Model.RequestEntry?.Entity.Id'">Yes </button> <button class="button error" onclick="window.location = '@(Model.Config.FindApp(Request.Query["client_id"]!)!.RedirectUri + "?error=access_denied")'">No</button> <br/> </div> } else { <b>Invalid request.</b> } <footer> <p style="margin-top: 5em;"><a target="_blank" href="https://bytim.eu/projects/VPNAuth/">VPNAuth</a> by Tim</p> </footer> </body> </html>