Bifrost/src/Bifrost.Web/Pages/Membership/Status.cshtml
Heimdall 4c9937f881 Bifrost: explicit Google link by fresh Heimdall sign-in, no stored token
The account page's POST starts an ordinary sign-in whose attempt (a purpose, the expected
account id, a pending link id; never a token) is only the proof for a link. Each Heimdall
call that needs a bearer follows its own fresh sign-in; the bearer lives in that request.
Google stays out of AllowedProviders and member access. Authorization is redacted from
HttpClient logging. Outcomes redirect to a fixed closed set of wording.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-12 15:21:40 +00:00

58 lines
1.9 KiB
Text

@page
@model Bifrost.Web.Pages.Membership.StatusModel
@{
ViewData["Title"] = "Membership status";
}
<section class="panel">
<span class="eyebrow">Membership gate</span>
<h1>Current access state</h1>
<p class="panel-intro">
Authentication and participation are separate on purpose. Bifrost only opens the member console
after a GitHub account has cleared the invite and approval gates.
</p>
<div class="status-banner">
<div class="inline-actions">
<span class="pill @Model.StatusTone">@Model.StatusLabel</span>
@if (Model.Actor.IsActiveMember)
{
<span class="pill success">Voting weight @Model.Actor.EffectiveVotingWeight</span>
}
</div>
<strong>@Model.Actor.DisplayName</strong>
<p class="muted">@Model.StatusMessage</p>
</div>
@if (Model.LinkMessage is not null)
{
<div class="callout" role="status">@Model.LinkMessage</div>
}
@if (Model.CanLinkGoogle)
{
<form method="post" asp-page-handler="LinkGoogle" class="panel-actions">
<button class="button secondary" type="submit">Link a Google login</button>
<span class="muted">You will sign in to Heimdall again, then to Google. Google links your account; it does not sign you in.</span>
</form>
}
@if (Model.Invitation is not null)
{
<div class="callout success">
Invitation tracked for <code>@Model.Invitation.GitHubLogin</code>.
Issued @Model.Invitation.IssuedAtUtc.ToString("dd MMM yyyy") UTC.
</div>
}
<div class="panel-actions">
@if (Model.Actor.IsActiveMember)
{
<a class="button" asp-page="/App/Index">Open member console</a>
}
else
{
<a class="button secondary" asp-page="/Index">Back to overview</a>
}
</div>
</section>