mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
Ensure that the login form is hidden if the authentication source is OAuth2 or Kerberos. #5386
This commit is contained in:
parent
e3a172e0e8
commit
2d0f09144d
@ -47,5 +47,6 @@ Bug fixes
|
||||
| `Issue #5352 <https://github.com/pgadmin-org/pgadmin4/issues/5352>`_ - Fixed error occurring while LDAP authentication for a user with multiple email attributes.
|
||||
| `Issue #5367 <https://github.com/pgadmin-org/pgadmin4/issues/5367>`_ - Ensure that the correct value should be returned if an exception occurs while decoding the password.
|
||||
| `Issue #5368 <https://github.com/pgadmin-org/pgadmin4/issues/5368>`_ - Fixed the issue while downloading the file from the file manager.
|
||||
| `Issue #5386 <https://github.com/pgadmin-org/pgadmin4/issues/5386>`_ - Ensure that the login form is hidden if the authentication source is OAuth2 or Kerberos.
|
||||
| `Issue #5402 <https://github.com/pgadmin-org/pgadmin4/issues/5402>`_ - Ensure that scroll bar on browser tree should be visible on windows resize.
|
||||
| `Issue #5405 <https://github.com/pgadmin-org/pgadmin4/issues/5405>`_ - Fixed the cross-site scripting vulnerability.
|
||||
|
@ -10,11 +10,14 @@
|
||||
<form action="{{ url_for('authenticate.login') }}" method="POST" name="login_user_form">
|
||||
{{ login_user_form.hidden_tag() }}
|
||||
{% set user_language = request.cookies.get('PGADMIN_LANGUAGE') or 'en' %}
|
||||
{{ render_username_with_errors(login_user_form.email, "text") }}
|
||||
{{ render_field_with_errors(login_user_form.password, "password") }}
|
||||
<button name="internal_button" {% if (config.OAUTH2 in config.AUTHENTICATION_SOURCES or config.KERBEROS in config.AUTHENTICATION_SOURCES) and config.AUTHENTICATION_SOURCES | length == 1 %} disabled {% endif %} class="btn btn-primary btn-block btn-login" type="submit" value="{{ _('Login') }}">{{ _('Login') }}</button>
|
||||
<div class="form-group row mb-3 c user-language">
|
||||
{% if not ((config.OAUTH2 in config.AUTHENTICATION_SOURCES or config.KERBEROS in config.AUTHENTICATION_SOURCES) and config.AUTHENTICATION_SOURCES | length == 1
|
||||
or (config.OAUTH2 in config.AUTHENTICATION_SOURCES and config.KERBEROS in config.AUTHENTICATION_SOURCES) and config.AUTHENTICATION_SOURCES | length == 2) %}
|
||||
{{ render_username_with_errors(login_user_form.email, "text") }}
|
||||
{{ render_field_with_errors(login_user_form.password, "password") }}
|
||||
<button name="internal_button" class="btn btn-primary btn-block btn-login" type="submit" value="{{ _('Login') }}">{{ _('Login') }}</button>
|
||||
<div class="col-7"><span class="help-block">{{ _('<a href="%(url)s" class="text-white">Forgotten your password</a>?', url=url_for('browser.forgot_password')) }}</span></div>
|
||||
{% endif %}
|
||||
<div class="form-group row mb-3 c user-language">
|
||||
<div class="col-5">
|
||||
<select class="form-control" name="language" value="{{user_language}}">
|
||||
{% for key, lang in config.LANGUAGES.items() %}
|
||||
|
Loading…
Reference in New Issue
Block a user