puiterwijk / flask-oidc

OpenID Connect support for Flask
BSD 2-Clause "Simplified" License
154 stars 217 forks source link

Two flask apps behind Nginx Proxy using Keycloak #102

Open mabbasi90 opened 4 years ago

mabbasi90 commented 4 years ago

Hi, I configured Apache Superset with flask_oidc and Airflow with fab_oidc(flask_oidc wrapper,https://github.com/ministryofjustice/fab-oidc), and both of them are behind same Nginx proxy using one domain and different paths, e.g. foobar.com/airflow and foobar.com/superset, but when I sign in with one of them, second one gets error like this: File "/somewhere/airflow/venv/lib/python3.6/site-packages/itsdangerous/signer.py", line 169, in unsign raise BadSignature("Signature %r does not match" % sig, payload=value) itsdangerous.exc.BadSignature: Signature b'[some part of oidc_token_id]' does not match it seems oidc_id_token of these two apps have conflict in this situation, is there any workaround for configuring multiple flask_oidc apps behind one Nginx proxy, using one domain? many thanks in advance

mabbasi90 commented 4 years ago

It seems I can configure OIDC_ID_TOKEN_COOKIE_NAME, I'll test this.

mabbasi90 commented 4 years ago

Solved with OIDC_ID_TOKEN_COOKIE_NAME configuration.