{ "info": { "author": "ministryofjustice", "author_email": "dev@digital.justice.gov.uk", "bugtrack_url": null, "classifiers": [ "Development Status :: 3 - Alpha", "Environment :: Web Environment", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 3", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": "# Flask-AppBuilder SecurityManager for OpenIDConnect\n\nWrapper for [flask_oidc] that exposes a `SecurityManager` for use with any Flask-AppBuilder app.\n\nIt will allow your users to login with OpenIDConnect providers such as Auth0, Okta or Google Apps.\n\nThis is roughly inspired by the code in this [stackoverflow](https://stackoverflow.com/a/47787279/44252) answer. (MIT Licenced \u00a9 [thijsfranck](https://stackoverflow.com/users/8905583/thijsfranck))\n\n## Usage\n\n### Generic\n\nJust override the default security manager in your Flask Appbuilder app.\n\n```python\nfrom fab_oidc.security import OIDCSecurityManager\n\nappbuilder = AppBuilder(app, db.session, security_manager_class=OIDCSecurityManager)\n```\n\n### [Airflow]\nAirflow provides a hook in the `webserver_config.py` file where you can specify a security manager class.\nIn `webserver_config.py` import the OIDCSecurityManager and set\n```python\nfrom fab_oidc.security import AirflowOIDCSecurityManager\n...\nSECURITY_MANAGER_CLASS = AirflowOIDCSecurityManager\n```\n\nAirflow now requires that your `SECURITY_MANAGER_CLASS` is a subclass of `AirflowSecurityManager`.\nUse the special `AirflowOIDCSecurityManager` that is only defined if you're using this library alongside Airflow.\n\n### [Superset]\nSuperset works in a a similar way. Just as in Airflow,\n`SECURITY_MANAGER_CLASS` needs to be a subclass of `SupersetSecurityManager`\nthe config is in a file called `superset_config.py` and the hook is called\n`CUSTOM_SECURITY_MANAGER`. There now exists a special\n`SupersetOIDCSecurityManager` that is only defined if you are using this\nlibrary alongside Superset.\n\n```python\nfrom fab_oidc.security import SupersetOIDCSecurityManager\n...\nCUSTOM_SECURITY_MANAGER = SupersetOIDCSecurityManager\n```\n\n\n## Settings\nThe settings are the same as the [flask_oidc settings][flask_oidc_settings], so look there for a reference.\n\nif you're happy with [flask_oidc]'s defaults the only thing you'll really need is something like:\n\n```python\nOIDC_CLIENT_SECRETS = '/path/to/client_secret.json'\n```\n\nsee the [flask_oidc manual client registration][flask_oidc_manual_config] docs for how to generate or write one.\n\n### OIDC Field configuration\n\nIf you like to change the default OIDC field that will be used as a username,\nfirst name and last name you can set the following env var in the shell you run\nyour process:\n\n```bash\nexport USERNAME_OIDC_FIELD='preferred_username'\nexport FIRST_NAME_OIDC_FIELD='given_name'\nexport LAST_NAME_OIDC_FIELD='family_name'\n```\n\nCopyright \u00a9 2018 HM Government (Ministry of Justice Digital Services). See LICENSE.txt for further details.\n\n\n[flask_oidc]: http://flask-oidc.readthedocs.io/en/latest/\n[flask_oidc_settings]: http://flask-oidc.readthedocs.io/en/latest/#settings-reference\n[flask_oidc_manual_config]: http://flask-oidc.readthedocs.io/en/latest/#manual-client-registration\n[Airflow]: https://airflow.apache.org/\n [Superset]: https://superset.incubator.apache.org/\n\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/ministryofjustice/fab-oidc/", "keywords": "", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "fab-oidc", "package_url": "https://pypi.org/project/fab-oidc/", "platform": "any", "project_url": "https://pypi.org/project/fab-oidc/", "project_urls": { "Homepage": "https://github.com/ministryofjustice/fab-oidc/" }, "release_url": "https://pypi.org/project/fab-oidc/0.0.9/", "requires_dist": [ "Flask-AppBuilder (>=1.5.0)", "Flask-OIDC (>=1.2.0)", "Flask-Admin (>=1.4.1)" ], "requires_python": "", "summary": "Flask-AppBuilder SecurityManager for OpenIDConnect", "version": "0.0.9" }, "last_serial": 5880455, "releases": { "0.0.2": [ { "comment_text": "", "digests": { "md5": "8a1dfc5fcdaeed12208ac5f50103accd", "sha256": "0d60e4658fa846a3bde476089723d73a86119008a8495d653d8372128ce5c861" }, "downloads": -1, "filename": "fab_oidc-0.0.2-py3-none-any.whl", "has_sig": false, "md5_digest": "8a1dfc5fcdaeed12208ac5f50103accd", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 3499, "upload_time": "2018-07-06T10:19:54", "url": "https://files.pythonhosted.org/packages/b9/a0/e66c0f3840badc98ed3d1e16dec9b52e9273549d5e387422422e84ff6e59/fab_oidc-0.0.2-py3-none-any.whl" } ], "0.0.3": [ { "comment_text": "", "digests": { "md5": "cdb415413e676be9ec227ae57f499b84", "sha256": "f3edbcdfe785e247d8ff13fd3d9d32048924423f5c600fed87024e6ce9632a58" }, "downloads": -1, "filename": "fab_oidc-0.0.3-py3-none-any.whl", "has_sig": false, "md5_digest": "cdb415413e676be9ec227ae57f499b84", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 3702, "upload_time": "2018-07-17T13:41:38", "url": "https://files.pythonhosted.org/packages/13/45/827d97daa6bb9cce3267082338657512c12183acc0a8531f84032e41e834/fab_oidc-0.0.3-py3-none-any.whl" } ], "0.0.4": [ { "comment_text": "", "digests": { "md5": "08a26fd1a30d9ae08347b2f27399caa4", "sha256": "e8396c9e980c090244d2f31d18bd0ed40c9a085dd112ed9d988db5405c9896d9" }, "downloads": -1, "filename": "fab_oidc-0.0.4-py3-none-any.whl", "has_sig": false, "md5_digest": "08a26fd1a30d9ae08347b2f27399caa4", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 4054, "upload_time": "2018-07-18T15:28:56", "url": "https://files.pythonhosted.org/packages/52/05/208302b86eb6584c71352c95bb8e786d91e1ff3954c50ea65d171817d7c0/fab_oidc-0.0.4-py3-none-any.whl" } ], "0.0.5": [ { "comment_text": "", "digests": { "md5": "3ff72eb1b6a4d635a44854c730fcef58", "sha256": "47425c0e83916486e4d5d90f4ba0fb00b34f12cc7828bbef6320bc6f7c723631" }, "downloads": -1, "filename": "fab_oidc-0.0.5-py3-none-any.whl", "has_sig": false, "md5_digest": "3ff72eb1b6a4d635a44854c730fcef58", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 4087, "upload_time": "2018-07-19T10:12:54", "url": "https://files.pythonhosted.org/packages/42/ec/2fe8fe6f95074bd2d2045d89c96ee1f0c914b2c86f75df949d9407b1165c/fab_oidc-0.0.5-py3-none-any.whl" } ], "0.0.6": [ { "comment_text": "", "digests": { "md5": "81a33edb3f047d061745f6c4c0f6b537", "sha256": "f462c32c60edd58a861c45d2d89deb46b2b8fa2029011549498be4b47330cccb" }, "downloads": -1, "filename": "fab_oidc-0.0.6.tar.gz", "has_sig": false, "md5_digest": "81a33edb3f047d061745f6c4c0f6b537", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3962, "upload_time": "2018-10-15T09:21:45", "url": "https://files.pythonhosted.org/packages/0f/6b/93f573575506f8854bf5d9cb4fe9ef7dcf09eae2bf18d36728f0b5f6bcb3/fab_oidc-0.0.6.tar.gz" } ], "0.0.7": [ { "comment_text": "", "digests": { "md5": "1890b2c141f3602304576e34a7585f62", "sha256": "85a8ac302bdd0fc627d989846e888e71a98f44c568d5ad40e566624781e40e34" }, "downloads": -1, "filename": "fab_oidc-0.0.7.tar.gz", "has_sig": false, "md5_digest": "1890b2c141f3602304576e34a7585f62", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4159, "upload_time": "2019-03-08T10:38:11", "url": "https://files.pythonhosted.org/packages/e3/6e/2891c91ebe2f4889bb68b922dad865accd8283b52a6918a041c1d3bf4b64/fab_oidc-0.0.7.tar.gz" } ], "0.0.8": [ { "comment_text": "", "digests": { "md5": "80feac7b4e8a6d3149eee59ca2d8206a", "sha256": "169b54267ae40f1f3a9cabb6097991cbc209d661a8d19466287e76fba21ec7cf" }, "downloads": -1, "filename": "fab_oidc-0.0.8.tar.gz", "has_sig": false, "md5_digest": "80feac7b4e8a6d3149eee59ca2d8206a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4046, "upload_time": "2019-04-10T11:35:37", "url": "https://files.pythonhosted.org/packages/2a/5d/0b111a95168f25d9c5973e780cee0f3ecb05cbba79c93b73abe7dd25ce71/fab_oidc-0.0.8.tar.gz" } ], "0.0.9": [ { "comment_text": "", "digests": { "md5": "f440797c02a7d5c1d4c124fa5694f113", "sha256": "46617f58d08ff79ac2a85e5ad96c85b57cb05ed2b22fe75d4ab81f29cfbfadf9" }, "downloads": -1, "filename": "fab_oidc-0.0.9-py3-none-any.whl", "has_sig": false, "md5_digest": "f440797c02a7d5c1d4c124fa5694f113", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 4458, "upload_time": "2019-09-24T15:14:56", "url": "https://files.pythonhosted.org/packages/fd/28/b7ef08bc8d75ea2fa53cd894ae4f698aab90d9de49bd98517a55e5ed281b/fab_oidc-0.0.9-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "0c938353b745b672beb16ccbf2a4ac6f", "sha256": "3e49b666dc15f6526c9fe0726aabed254d67e49f7e1ddbe52fa0336c4242a5f7" }, "downloads": -1, "filename": "fab_oidc-0.0.9.tar.gz", "has_sig": false, "md5_digest": "0c938353b745b672beb16ccbf2a4ac6f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4027, "upload_time": "2019-09-24T15:15:04", "url": "https://files.pythonhosted.org/packages/a4/19/0ff0bb46a69fcc0773be2d370dee459bf5c880929236e2c6eb23e6dc1966/fab_oidc-0.0.9.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "f440797c02a7d5c1d4c124fa5694f113", "sha256": "46617f58d08ff79ac2a85e5ad96c85b57cb05ed2b22fe75d4ab81f29cfbfadf9" }, "downloads": -1, "filename": "fab_oidc-0.0.9-py3-none-any.whl", "has_sig": false, "md5_digest": "f440797c02a7d5c1d4c124fa5694f113", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 4458, "upload_time": "2019-09-24T15:14:56", "url": "https://files.pythonhosted.org/packages/fd/28/b7ef08bc8d75ea2fa53cd894ae4f698aab90d9de49bd98517a55e5ed281b/fab_oidc-0.0.9-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "0c938353b745b672beb16ccbf2a4ac6f", "sha256": "3e49b666dc15f6526c9fe0726aabed254d67e49f7e1ddbe52fa0336c4242a5f7" }, "downloads": -1, "filename": "fab_oidc-0.0.9.tar.gz", "has_sig": false, "md5_digest": "0c938353b745b672beb16ccbf2a4ac6f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4027, "upload_time": "2019-09-24T15:15:04", "url": "https://files.pythonhosted.org/packages/a4/19/0ff0bb46a69fcc0773be2d370dee459bf5c880929236e2c6eb23e6dc1966/fab_oidc-0.0.9.tar.gz" } ] }