Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(Admin): Ajout d'une contrainte de longueur à 64 caractères sur les jetons d'API #1479

Merged
merged 2 commits into from
Feb 7, 2025

Conversation

SebastienReuiller
Copy link
Contributor

Quoi ?

Ajout d'une contrainte de longueur à 64 caractères sur les jetons d'API

Pourquoi ?

Pour éviter d'avoir des jetons trop court et facile à brut force.

Comment ?

En ajoutant un validateur sur le modèle.

Captures d'écran

image

@SebastienReuiller
Copy link
Contributor Author

Attention, les jetons devront être mise à jour en prod par @madjid-asa avant de passer cette PR.

@SebastienReuiller
Copy link
Contributor Author

@madjid-asa , j'ai testé, la migration passe même si il y a des api_key trop court.
On peut donc passer la PR en prod quand on veut avec la seule contrainte que les utilisateurs avec ces api_key trop court ne sont plus éditables sans corriger leur jeton.

@madjid-asa madjid-asa force-pushed the sreuiller/add-min-length-on-api-key branch from 548469e to 86430eb Compare February 4, 2025 21:25
Copy link

gitguardian bot commented Feb 4, 2025

️✅ There are no secrets present in this pull request anymore.

If these secrets were true positive and are still valid, we highly recommend you to revoke them.
While these secrets were previously flagged, we no longer have a reference to the
specific commits where they were detected. Once a secret has been leaked into a git
repository, you should consider it compromised, even if it was deleted immediately.
Find here more information about risks.


🦉 GitGuardian detects secrets in your source code to help developers and security teams secure the modern development process. You are seeing this because you or someone else with access to this repository has authorized GitGuardian to scan your pull request.

lemarche/static/js/favorite_item.js Dismissed Show dismissed Hide dismissed
lemarche/siaes/management/commands/import_esat_from_asp.py Dismissed Show dismissed Hide dismissed
lemarche/siaes/management/commands/import_esat_from_asp.py Dismissed Show dismissed Hide dismissed
lemarche/siaes/management/commands/import_esat_from_csv.py Dismissed Show dismissed Hide dismissed
lemarche/siaes/management/commands/import_esat_gesat.py Dismissed Show dismissed Hide dismissed
lemarche/siaes/management/commands/import_esat_handeco.py Dismissed Show dismissed Hide dismissed
lemarche/siaes/management/commands/import_sep.py Dismissed Show dismissed Hide dismissed
lemarche/www/auth/views.py Dismissed Show dismissed Hide dismissed
lemarche/www/pages/views.py Fixed Show fixed Hide fixed
lemarche/www/siaes/views.py Dismissed Show dismissed Hide dismissed
lemarche/www/siaes/views.py Dismissed Show dismissed Hide dismissed
@SebastienReuiller SebastienReuiller force-pushed the sreuiller/add-min-length-on-api-key branch from 86430eb to 548469e Compare February 7, 2025 08:22
@SebastienReuiller SebastienReuiller force-pushed the sreuiller/add-min-length-on-api-key branch from 548469e to 141c527 Compare February 7, 2025 08:27
@SebastienReuiller SebastienReuiller merged commit 3cd84a4 into master Feb 7, 2025
8 checks passed
@SebastienReuiller SebastienReuiller deleted the sreuiller/add-min-length-on-api-key branch February 7, 2025 09:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants