Commit Graph

427 Commits

Author SHA1 Message Date
Marie PUPO JEAMMET
2f1843e0e8 🐛(stats) rename stat for clarity
Public statistics on domains was modified to count only enabled
domains. Modify stat name to reflect change.
2025-04-03 14:58:07 +02:00
Quentin BEY
e23d236614 (pytest) fail on tests external calls
The backend tests must not try to call the real world.
2025-04-03 09:39:15 +02:00
renovate[bot]
61c3b6ac6b ⬆️(dependencies) update django to v5.1.8 [SECURITY] 2025-04-03 07:47:33 +02:00
Quentin BEY
1eb9dffa48 🐛(contacts) add missing select_related
The new DRF version (3.16.0) adds a check on unique together and needs
more fields to be loaded. To prevent an extra query, we select the owner
value in the DB query.
2025-04-01 10:58:49 +02:00
renovate[bot]
d0854851a2 ⬆️(dependencies) update python dependencies 2025-04-01 10:58:49 +02:00
Quentin BEY
dd43483ce6 🔒️(passwords) add validators for production
This enabled various password validators to enforce password complexity.
2025-03-28 15:43:45 +01:00
Sabrina Demagny
e4e9a121a4 (organization) add is_active field
Add flag to indicate whether the organization is active.
Prepare organizations provisioning. The organization
will be created with this flag set to False and will
become active when the first user is associated with it.
2025-03-27 18:34:09 +01:00
Sabrina Demagny
3173e096d9 🐛(dimail) enhance sentry log for dimail error
Remove duplicate sentry log and fix failure if response content
has an unexpected format
2025-03-27 18:25:24 +01:00
Marie PUPO JEAMMET
4420bab073 🐛(demo) fix missing support_email field
"support_email" field was missing for all domains created in demo.
this lead to "make demo" and "setup_dimail_db" commands to fail.
2025-03-27 18:06:36 +01:00
Marie PUPO JEAMMET
8cbedeb76e ♻️(dimail) refacto setup_dimail_db to call dimail client
Management command "setup_dimail_db" called dimail directly, thus
creating duplicated code. It now calls "create_domain" and "create_allow"
methods from DimailAPIClient (create_user is left unchanged to create
special users such as dimail admin or people)
2025-03-27 18:06:36 +01:00
Quentin BEY
28fdee868d ♻️(plugins) rewrite plugin system as django app
This allow more flexibility around the installed plugins, this will
allow to add models in plugins if needed.
2025-03-26 19:56:23 +01:00
Quentin BEY
4ced342062 ♻️(core) move app ready code to functions
For readability, we move the code block from the `ready` method to a
dedicated function.

This will allow to add more things to do in the `ready` with more focus.
2025-03-26 19:56:23 +01:00
Laurent Bossavit
2502ff0c99 🔧(dns) make target zone for communes domains configurable
Add a configuration setting tied to an env var, so we can have
a separate zone for staging/preprod.
2025-03-25 19:48:43 +01:00
Sabrina Demagny
339831f090 🌐(i18n) update translations
Run i18n-download-and-compile to download translations from
Crowdin and compile them
2025-03-25 13:45:24 +01:00
Sabrina Demagny
5178e460c4 (domains) notify support when domain status changes
During the scheduled task to check domains,
send an email notification to domain support if a
status has changed.
2025-03-25 08:44:35 +01:00
Sabrina Demagny
feb5d7154b (domains) define domain check interval as a settings
For now, to avoid overloading dimail, we have defined a
time interval between each check request to dimail.
This interval should be configurable for testing and
different environments.
2025-03-25 08:44:35 +01:00
renovate[bot]
660fc7c291 ⬆️(dependencies) update python dependencies 2025-03-24 09:34:53 +01:00
Quentin BEY
6b2ca88ff2 (oidc) add simple introspection backend
This provides a configurable OIDC introspection backend to be able to
call introspection endpoints which returns JSON data instead of an
encrypted JWT.

Two backends are currently defined:

 - ResourceServerBackend` which expect a JSON response
 - JWTResourceServerBackend which implements RFC 9701 and expects
   JWE reponse.

There might be other cases (eg: ResourceServerBackend with JWT, JWS or
JWE, etc. but for now we don't use it, so we follow YAGNI).

This also allow to configure the claim to determine the "audience":

 - client_id: for our Keycloak implementation
 - aud: used by ProConnect
2025-03-20 09:30:18 +01:00
Marie PUPO JEAMMET
889a495ea3 🧐(stats) restrict domains count to active domains
Stats are currently counting all domains, including users tests.
Counting enabled domains is more relevant to reflect actual use.
2025-03-19 16:52:11 +01:00
Sabrina Demagny
666cafe220 📝(dimail) add some info about data required to create mailbox
Prepare generic mailbox implementation
2025-03-18 18:29:02 +01:00
Quentin BEY
1ec98f0948 🧑‍💻(tasks) run management commands
This allows to run management commands from a celery task.
2025-03-18 18:02:53 +01:00
renovate[bot]
f0258bbde7 ⬆️(dependencies) update python dependencies 2025-03-17 12:02:44 +01:00
sdemagny
4003f66243 🌐(i18n) update translated strings
Update translated files with new translations
2025-03-17 11:26:13 +01:00
Sabrina Demagny
5cd8f79f1e 🔖(patch) release version 1.14.1
Update all version files and changelog for patch release.
2025-03-17 11:26:13 +01:00
Sabrina Demagny
9c451e74a6 🔖(minor) release version 1.14.0
Update all version files and changelog for minor release.
2025-03-17 11:06:14 +01:00
Sabrina Demagny
4c033d7262 🌐(i18n) update translations
Run i18n-download-and-compile to download translations from
Crowdin and compile them
2025-03-14 13:48:33 +01:00
Sabrina Demagny
74655ba378 🐛(domains) fix admin information messages not translated
Using format or f-string breaks translations
2025-03-14 12:26:52 +01:00
Sabrina Demagny
859efa26dc 🐛(mail) fix team invitation subject not translated
Using format or f-string breaks translations
2025-03-14 12:26:52 +01:00
Sabrina Demagny
d31b79aaad 🌐(i18n) fix bad translated sentence on crowdin
A special character was inserted by mistake.
2025-03-14 12:26:52 +01:00
Sabrina Demagny
495245a752 🐛(domain) fix flaky test with translated email content
Do not test the content of emails sent with
a random user language
2025-03-14 12:26:52 +01:00
Sabrina Demagny
d5eb736343 🌐(i18n) update translations from crowdin
Download and compile translation from Crowdin before release
2025-03-13 17:40:21 +01:00
Quentin BEY
803b2c1930 🐛(oauth2) remove ProConnect unknown claims
When we don't have information about the requested claims, they must be
ignored.
2025-03-13 14:52:00 +01:00
Quentin BEY
c4dd4ae3fd 🐛(oauth2) force JWT signed for /userinfo
ProConnect requires the userinfo endpoint to return a signed JWT.
2025-03-13 14:27:26 +01:00
Quentin BEY
34783d0557 🐛(oauth2) add ProConnect scopes
Add missing scopes required by ProConnect evenif we don't fill them.
2025-03-13 11:33:07 +01:00
Quentin BEY
5cc8108e7b 🐛(oauth2) disable PKCE for Proconnect
The PKCE is not available for Proconnect, security is made otherwise.
2025-03-13 10:23:43 +01:00
Sabrina Demagny
0b290d9a5e 🧑‍💻(docker) add flower for dev env
Allow to manage and monitor celery tasks
2025-03-12 17:08:45 +01:00
Sabrina Demagny
68ed5e4d55 (domains) add periodic task to fetch domains status
Add celery crontab to check and update domains status.
This task calls dimail API.
2025-03-12 17:08:45 +01:00
Quentin BEY
e3bf1d76fa (json) add a test for declared schema
This checks all the defined schema are properly defined.
2025-03-12 15:45:47 +01:00
Quentin BEY
f64a592648 (organization) add metadata update command
This allows to update the Organization metadata with default values.
2025-03-12 15:45:47 +01:00
Quentin BEY
7ce5b28af4 (organization) add metadata field
This allows to store custom values which can be reused along the
organization lifetime.
2025-03-12 15:45:47 +01:00
Quentin BEY
403fea94bb (teams) allow broadly available teams
This adds `is_visible_all_services` field to `Teams` to make them
visible to all service providers
2025-03-11 19:15:03 +01:00
Sabrina Demagny
5730b9ea5e (teams) update and enhance team invitation email
- replace logo
- modify wording
- enhance template
2025-03-11 14:09:18 +01:00
renovate[bot]
305e2438c5 ⬆️(dependencies) update python dependencies 2025-03-11 12:01:50 +01:00
Sabrina Demagny
ebc2b02d22 🐛(domains) use a dedicated mail to invite user to manage domain
- modify models to allow to specify path to mail template
- rename team invitation template
- fix logo and text used for domain invitation email
2025-03-11 11:48:38 +01:00
Sabrina Demagny
701aeca763 🐛(mailbox) fix mailbox creation email language
Don't forget to translate mail content before sending.
2025-03-10 15:14:05 +01:00
Sabrina Demagny
7a128393f6 (api) define dimail timeout as a setting
Allow to param dimail timeout for each env
2025-03-10 10:18:14 +01:00
renovate[bot]
ea1f06f6cc ⬆️(dependencies) update django to v5.1.7 [SECURITY] 2025-03-07 10:49:16 +01:00
Quentin BEY
b063f690f6 (resource-server) add team invitation endpoint
This allows a service provider to add new members to a team.
2025-03-06 15:17:33 +01:00
Laurent Bossavit
ae92ab5dd8 🐛(tests) change domain name factory to be more boring but reliable
MailDomain fixtures now use a boring non-repeating sequence. No
longer will the occasional random CI failure inject excitement
into our workdays; but fear not, there will remain other occasions
to enjoy the art of debugging.
2025-03-06 14:34:41 +01:00
Sabrina Demagny
91389181f0 🧑‍💻(admin) add admin for mail domain invitation
Allow to access to mail domain invitation table
on Django admin interface.
2025-03-06 13:28:52 +01:00