mozilla-django-oidc | A django OpenID Connect library | Authentication library
kandi X-RAY | mozilla-django-oidc Summary
kandi X-RAY | mozilla-django-oidc Summary
A django OpenID Connect library
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Authenticate the request
- Create a new user
- Get or create a user
- Return the username based on the given claims
- Returns the redirect URL
- Handles GET requests
- Redirect to the user s id_token
- Handles OIDC authentication
- Add a state and nonce to the session
- Returns the next URL for the redirect field
- Authenticate the given access token
- Parse a www - authentication header
- Extract the access token from the request
- Handle POST request
- Handler for logout
- Get the configured OIDC backend
mozilla-django-oidc Key Features
mozilla-django-oidc Examples and Code Snippets
Community Discussions
Trending Discussions on mozilla-django-oidc
QUESTION
I'm attempting to set up OIDC with Keycloak as my IdP and Django (using Django Rest Framework and mozilla-django-oidc) as my client server. I have got keycloak installed and a rough Django application stood up that successfully redirects to keycloak where I can then successfully authenticate (to keycloak), but when I'm redirected back to django I'm missing information, specifically oidc_states
.
The redirect to django triggers this log entry:
...ANSWER
Answered 2021-Oct-12 at 14:52To any wayward travelers, I wish you luck. Ultimately, I solved my problem by re-configuring my mozilla-django-oidc settings. Specifically, I was missing:
QUESTION
I am trying to configure the "mozilla-django-oidc" package in Django. To authenticate I use Azure Active Directory B2C policy, so this is my federation server.
When I click in the login button I got this URL which looks wrong to me, I will split it, just for convenience:
and the URL I need has this format: https://TENANTID.b2clogin.com/TENANTID.onmicrosoft.com/oauth2/v2.0/authorize?p=B2C_1_TENANTID_SIGNIN&client_id=XXXXXXXXXXXXX&nonce=defaultNonce&redirect_uri=http%3A%2F%2Flocalhost%3A8000%2Foidc%2Fcallback%2F&scope=openid&response_type=id_token&prompt=login
In the home page I have this code:
...ANSWER
Answered 2020-Mar-31 at 18:42I had to update the views.py file from the library in order to get the URL I needed. The documentation was very poor, but at least it is working.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install mozilla-django-oidc
You can use mozilla-django-oidc like any standard Python library. You will need to make sure that you have a development environment consisting of a Python distribution including header files, a compiler, pip, and git installed. Make sure that your pip, setuptools, and wheel are up to date. When using pip it is generally recommended to install packages in a virtual environment to avoid changes to the system.
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page