39 lines
1.5 KiB
Text
39 lines
1.5 KiB
Text
|
|
@model Client
|
||
|
|
|
||
|
|
<h2>@Localizer["Regenerate client secret"]</h2>
|
||
|
|
|
||
|
|
<div class="alert alert-warning" role="alert">
|
||
|
|
<strong>@Localizer["Warning."]</strong>
|
||
|
|
@Localizer["Regenerating the secret will immediately invalidate the current one. Any client using the existing secret will be unable to authenticate until it is updated with the new value. The new secret will be displayed exactly once and cannot be recovered afterwards."]
|
||
|
|
</div>
|
||
|
|
|
||
|
|
<div>
|
||
|
|
<h4>@Model.ClientName</h4>
|
||
|
|
<hr />
|
||
|
|
<dl class="dl-horizontal">
|
||
|
|
<dt>@Html.DisplayNameFor(model => model.ClientId)</dt>
|
||
|
|
<dd>@Html.DisplayFor(model => model.ClientId)</dd>
|
||
|
|
<dt>@Localizer["Current secrets"]</dt>
|
||
|
|
<dd>
|
||
|
|
@if (Model.ClientSecrets != null && Model.ClientSecrets.Count > 0)
|
||
|
|
{
|
||
|
|
<ul>
|
||
|
|
@foreach (var secret in Model.ClientSecrets)
|
||
|
|
{
|
||
|
|
<li>@secret.Description <small class="text-muted">(created @secret.Created.ToString("u"))</small></li>
|
||
|
|
}
|
||
|
|
</ul>
|
||
|
|
}
|
||
|
|
else
|
||
|
|
{
|
||
|
|
<em>@Localizer["No secret currently set."]</em>
|
||
|
|
}
|
||
|
|
</dd>
|
||
|
|
</dl>
|
||
|
|
</div>
|
||
|
|
|
||
|
|
<form asp-action="RegenerateSecret" asp-route-id="@Model.Id" method="post">
|
||
|
|
@Html.AntiForgeryToken()
|
||
|
|
<button type="submit" class="btn btn-danger">@Localizer["Regenerate now"]</button>
|
||
|
|
<a asp-action="Details" asp-route-id="@Model.Id" class="btn btn-default">@Localizer["Cancel"]</a>
|
||
|
|
</form>
|