-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(user): basculer l'authentification vers ProConnect (#731)
## Description 🎸 Inclusion Connect est remplacé par Pro Connect (https://moncomptepro.beta.gouv.fr/) en tant que fournisseur d'identité 🎸 La migration des comptes est réalisée au fil de l'eau, lors de chaque première connection d'un utilisateur précédemment inscrit via Inclusion Connect. ## Type de changement 🚧 technique ### Points d'attention 🦺 renommage de l'app django 🦺 mise à jour des urls 🦺 ajout du paramètre `"acr_values": "eidas1"` lors de l'appel au end-point `authorize` 🦺 remplacement de `family_name` par `usual_name` lors de l'appel au end-point `user-info` 🦺 decoder `user_data` à l'aide de la lib `PyJWT`
- Loading branch information
1 parent
7c34605
commit 5429fce
Showing
38 changed files
with
395 additions
and
342 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import datetime | ||
|
||
from django.conf import settings | ||
|
||
|
||
OPENID_CONNECT_SCOPES = "openid email given_name usual_name" | ||
|
||
OPENID_CONNECT_CLIENT_ID = settings.OPENID_CONNECT_CLIENT_ID | ||
OPENID_CONNECT_CLIENT_SECRET = settings.OPENID_CONNECT_CLIENT_SECRET | ||
|
||
OPENID_CONNECT_ENDPOINT = "{base_url}".format( | ||
base_url=settings.OPENID_CONNECT_BASE_URL, | ||
) | ||
OPENID_CONNECT_ENDPOINT_AUTHORIZE = f"{OPENID_CONNECT_ENDPOINT}/authorize" | ||
OPENID_CONNECT_ENDPOINT_REGISTRATIONS = f"{OPENID_CONNECT_ENDPOINT}/register" | ||
OPENID_CONNECT_ENDPOINT_TOKEN = f"{OPENID_CONNECT_ENDPOINT}/token" | ||
OPENID_CONNECT_ENDPOINT_USERINFO = f"{OPENID_CONNECT_ENDPOINT}/userinfo" | ||
OPENID_CONNECT_ENDPOINT_LOGOUT = f"{OPENID_CONNECT_ENDPOINT}/session/end" | ||
|
||
# These expiration times have been chosen arbitrarily. | ||
OPENID_CONNECT_TIMEOUT = 60 | ||
|
||
OPENID_CONNECT_SESSION_KEY = "pro_connect" | ||
|
||
# This expiration time has been chosen arbitrarily. | ||
OIDC_STATE_EXPIRATION = datetime.timedelta(hours=1) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# Generated by Django 5.0.7 on 2024-07-31 13:05 | ||
|
||
from django.db import migrations, models | ||
|
||
|
||
class Migration(migrations.Migration): | ||
initial = True | ||
|
||
dependencies = [] | ||
|
||
operations = [ | ||
migrations.CreateModel( | ||
name="OpenID_State", | ||
fields=[ | ||
("id", models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name="ID")), | ||
("created_at", models.DateTimeField(auto_now_add=True)), | ||
("csrf", models.CharField(max_length=12, unique=True)), | ||
], | ||
), | ||
] |
File renamed without changes.
Oops, something went wrong.