public inbox for [email protected]
help / color / mirror / Atom feedFrom: Khushboo Vashi <[email protected]>
To: pgadmin-hackers <[email protected]>
Subject: [pgAdmin4][Patch] - Fix for RM #6928
Date: Mon, 18 Oct 2021 19:06:44 +0530
Message-ID: <CAFOhELen9x_=mNX6J+aGqa_3xAFDMdzqt6_JahG5j=zYf7HKdA@mail.gmail.com> (raw)
Hi,
Please find the attached patch for the RM #6928 - Master password is not
asked when On MASTER_PASSWORD_REQUIRED=True &
AUTHENTICATION_SOURCES=['webserver']
Thanks,
Khushboo
Attachments:
[application/octet-stream] RM_6928.patch (1.0K, 3-RM_6928.patch)
download | inline diff:
diff --git a/web/pgadmin/browser/__init__.py b/web/pgadmin/browser/__init__.py
index 79d08fac9..4eaef9bdb 100644
--- a/web/pgadmin/browser/__init__.py
+++ b/web/pgadmin/browser/__init__.py
@@ -51,7 +51,7 @@ from pgadmin.utils.master_password import validate_master_password, \
set_crypt_key, process_masterpass_disabled
from pgadmin.model import User
from pgadmin.utils.constants import MIMETYPE_APP_JS, PGADMIN_NODE,\
- INTERNAL, KERBEROS, LDAP, QT_DEFAULT_PLACEHOLDER, OAUTH2
+ INTERNAL, KERBEROS, LDAP, QT_DEFAULT_PLACEHOLDER, OAUTH2, WEBSERVER
from pgadmin.authenticate import AuthSourceManager
try:
@@ -1000,6 +1000,7 @@ def set_master_password():
# Enable master password if oauth is used
if not config.SERVER_MODE or OAUTH2 in config.AUTHENTICATION_SOURCES \
or KERBEROS in config.AUTHENTICATION_SOURCES \
+ or WEBSERVER in config.AUTHENTICATION_SOURCES \
and config.MASTER_PASSWORD_REQUIRED:
# if master pass is set previously
if current_user.masterpass_check is not None and \
view thread (2+ messages) latest in thread
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected]
Subject: Re: [pgAdmin4][Patch] - Fix for RM #6928
In-Reply-To: <CAFOhELen9x_=mNX6J+aGqa_3xAFDMdzqt6_JahG5j=zYf7HKdA@mail.gmail.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox