mirror of
https://github.com/pomerium/pomerium.git
synced 2025-05-30 09:27:19 +02:00
remove user impersonation and service account cli (#1768)
* remove user impersonation and service account cli * update doc * remove user impersonation url query params * fix flaky test
This commit is contained in:
parent
eadd8c2482
commit
ab4a68f56f
21 changed files with 258 additions and 831 deletions
|
@ -136,37 +136,6 @@
|
|||
</label>
|
||||
{{end}}
|
||||
{{end}}
|
||||
|
||||
{{with .State}}
|
||||
{{with .ImpersonateEmail}}
|
||||
<label>
|
||||
<span>Impersonating Email</span>
|
||||
<input
|
||||
type="text"
|
||||
class="field"
|
||||
value="{{.}}"
|
||||
disabled
|
||||
/>
|
||||
</label>
|
||||
{{end}}
|
||||
{{range $i,$_:= .ImpersonateGroups}}
|
||||
<label>
|
||||
{{if eq $i 0}}
|
||||
<span>Impersonating Group</span>
|
||||
{{else}}
|
||||
<span></span>
|
||||
{{end}}
|
||||
<input
|
||||
type="text"
|
||||
class="field"
|
||||
value="{{.}}"
|
||||
title="{{.}}"
|
||||
disabled
|
||||
/>
|
||||
</label>
|
||||
{{end}}
|
||||
{{end}}
|
||||
|
||||
</fieldset>
|
||||
</section>
|
||||
<div class="flex">
|
||||
|
@ -175,69 +144,6 @@
|
|||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{if .EnableUserImpersonation}}
|
||||
<div id="info-box">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h2>Sign-in-as</h2>
|
||||
<img
|
||||
class="icon"
|
||||
src="{{dataURL "/.pomerium/assets/img/supervised_user_circle-24px.svg"}}"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
/>
|
||||
</div>
|
||||
|
||||
<form method="POST" action="/.pomerium/admin/impersonate">
|
||||
<input type="hidden" value="{{.RedirectURL}}" name="pomerium_redirect_uri">
|
||||
<section>
|
||||
<p class="message">
|
||||
Administrators can temporarily impersonate another user.
|
||||
</p>
|
||||
{{if not .State.ImpersonateEmail}}
|
||||
<fieldset>
|
||||
<label>
|
||||
<span>Email</span>
|
||||
<input
|
||||
name="{{ .ImpersonateEmail }}"
|
||||
type="email"
|
||||
class="field"
|
||||
value=""
|
||||
placeholder="user@example.com"
|
||||
/>
|
||||
</label>
|
||||
<label>
|
||||
<span>Group</span>
|
||||
<input
|
||||
name="{{ .ImpersonateGroups }}"
|
||||
type="text"
|
||||
class="field"
|
||||
value=""
|
||||
placeholder="engineering"
|
||||
/>
|
||||
</label>
|
||||
</fieldset>
|
||||
{{end}}
|
||||
</section>
|
||||
<div class="flex">
|
||||
{{ .csrfField }}
|
||||
<button
|
||||
name="{{ .ImpersonateAction }}"
|
||||
value="set"
|
||||
class="button full"
|
||||
type="submit"
|
||||
>
|
||||
{{if .State.ImpersonateEmail}}
|
||||
Unimpersonate
|
||||
{{else}}
|
||||
Impersonate
|
||||
{{end}}
|
||||
</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
{{end}}
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Add table
Add a link
Reference in a new issue