public inbox for [email protected]  
help / color / mirror / Atom feed
[Patch] - Bug #7059 - pgAdmin throws internal server error for OAuth2 after some random idle time
2+ messages / 2 participants
[nested] [flat]

* [Patch] - Bug #7059 - pgAdmin throws internal server error for OAuth2 after some random idle time
@ 2022-03-15 09:42  Yogesh Mahajan <[email protected]>
  0 siblings, 1 reply; 2+ messages in thread

From: Yogesh Mahajan @ 2022-03-15 09:42 UTC (permalink / raw)
  To: pgadmin-hackers

Hi,

Please find the patch which fixes the error shown on logout when auth
sources include  'oauth2'.

Thanks,
Yogesh Mahajan
EnterpriseDB


Attachments:

  [application/octet-stream] RM_7059_v1.patch (724B, 3-RM_7059_v1.patch)
  download | inline diff:
diff --git a/web/pgadmin/authenticate/__init__.py b/web/pgadmin/authenticate/__init__.py
index c62fbe22b..d637e32dd 100644
--- a/web/pgadmin/authenticate/__init__.py
+++ b/web/pgadmin/authenticate/__init__.py
@@ -43,6 +43,11 @@ def get_logout_url() -> str:
             KERBEROS:
         return _URL_WITH_NEXT_PARAM.format(url_for(
             'kerberos.logout'), url_for(BROWSER_INDEX))
+    elif config.SERVER_MODE and\
+            session['auth_source_manager']['current_source'] == \
+            OAUTH2:
+        return _URL_WITH_NEXT_PARAM.format(url_for(
+            'oauth2.logout'), url_for(BROWSER_INDEX))
 
     return _URL_WITH_NEXT_PARAM.format(
         url_for('security.logout'), url_for(BROWSER_INDEX))


^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* Re: [Patch] - Bug #7059 - pgAdmin throws internal server error for OAuth2 after some random idle time
@ 2022-03-15 11:33  Akshay Joshi <[email protected]>
  parent: Yogesh Mahajan <[email protected]>
  0 siblings, 0 replies; 2+ messages in thread

From: Akshay Joshi @ 2022-03-15 11:33 UTC (permalink / raw)
  To: Yogesh Mahajan <[email protected]>; +Cc: pgadmin-hackers

Thanks, the patch applied.

On Tue, Mar 15, 2022 at 3:13 PM Yogesh Mahajan <
[email protected]> wrote:

> Hi,
>
> Please find the patch which fixes the error shown on logout when auth
> sources include  'oauth2'.
>
> Thanks,
> Yogesh Mahajan
> EnterpriseDB
>


-- 
*Thanks & Regards*
*Akshay Joshi*
*pgAdmin Hacker | Principal Software Architect*
*EDB Postgres <http://edbpostgres.com>*

*Mobile: +91 976-788-8246*


^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2022-03-15 11:33 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2022-03-15 09:42 [Patch] - Bug #7059 - pgAdmin throws internal server error for OAuth2 after some random idle time Yogesh Mahajan <[email protected]>
2022-03-15 11:33 ` Akshay Joshi <[email protected]>

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox