Prevent switching auth type for Platform Admins

This closes a security loophole, where the auth type of a Platform
Admin could be unwittingly changed when they accept an invite, or
by an admin of a service they are a member of.
This commit is contained in:
Ben Thorner
2021-05-25 15:58:33 +01:00
parent a10304d9c6
commit 6d0d9d46f7
5 changed files with 92 additions and 11 deletions

View File

@@ -11,7 +11,11 @@
{% endif %}
{% if service_has_email_auth %}
{% if not mobile_number %}
{% if user.platform_admin %}
<p class="bottom-gutter">
Platform admin users will login with a security key.
</p>
{% elif not mobile_number %}
{{ radios(
form.login_authentication,
disable=['sms_auth'],