Carlos Quintana
33c418d7c6
chore: allow to define a different DB_URI for event listener ( #2189 )
2024-08-20 14:01:48 +00:00
Carlos Quintana
a72b7bde92
chore: add config for enabling sync for specific users ( #2184 )
...
* chore: add config for enabling sync for users
* chore: error handling
2024-08-19 06:35:39 +00:00
danfate
e71d6264a7
convert POSTFIX_TIMEOUT to int ( #2135 )
2024-07-02 12:24:50 +00:00
Adrià Casajús
8a77a8b251
Create jobs to trigger sending all alias as create events ( #2126 )
...
* Create jobs to trigger sending all alias as create events
* Set events in past tense
* fix test
* Removed debug log
* Log messages
2024-06-07 13:36:18 +00:00
Carlos Quintana
450322fff1
feat: allow to disable event-webhook ( #2118 )
2024-05-23 16:50:54 +02:00
Carlos Quintana
8eccb05e33
feat: implement HTTP event sink ( #2116 )
...
* feat: implement HTTP event sink
* Update events/event_sink.py
---------
Co-authored-by: Adrià Casajús <acasajus@users.noreply.github.com>
2024-05-23 11:32:45 +02:00
Carlos Quintana
3e0b7bb369
Add sync events ( #2113 )
...
* feat: add protocol buffers for events
* chore: add EventDispatcher
* chore: add WebhookEvent class
* chore: emit events
* feat: initial version of event listener
* chore: emit user plan change with new timestamp
* feat: emit metrics + add alias status to create event
* chore: add newrelic decorator to functions
* fix: event emitter fixes
* fix: take null end_time into account
* fix: avoid double-commits
* chore: move UserDeleted event to User.delete method
* db: add index to sync_event created_at and taken_time columns
* chore: add index to model
2024-05-23 10:27:08 +02:00
Adrià Casajús
8f12fabd81
Make hibp rate configurable ( #2105 )
2024-05-10 18:51:16 +02:00
Daniel Mühlbachler-Pietrzykowski
b6004f3336
feat: use oidc well-known url ( #2077 )
2024-05-02 16:17:10 +02:00
Adrià Casajús
0da1811311
Cleanup old data ( #2066 )
...
* Cleanup tasks
* Update
* Added tests
* Create cron job
* Delete old data cron
* Fix import
* import fix
* Added delete + script to disable pgp for proton mboxes
2024-03-18 16:00:21 +01:00
Adrià Casajús
e96de79665
Add missing indexes and mark aliases as created by partner ( #2058 )
...
* Add missing indexes and mark aliases as created by partner
* Configure if we should skip the partner aliases or not
2024-03-13 14:30:17 +01:00
Daniel Mühlbachler-Pietrzykowski
a608503df6
feat: add generic OIDC connect ( #2046 )
2024-03-13 14:30:00 +01:00
Adrià Casajús
76423527dd
Update HIBP async script ( #2043 )
...
* Update HIBP async script
* Fix: continue instead of return
2024-03-04 13:12:38 +01:00
Adrià Casajús
1dada1a4b5
Allow to skip creating transactional emails ( #2042 )
2024-02-27 16:52:45 +01:00
Adrià Casajús
b6f1cecee9
Move rate limit config to configuration ( #2023 )
2024-02-01 14:47:15 +01:00
Adrià Casajús
da09db3864
Do not allow free users to create reverse alias to reduce abuse ( #2013 )
...
* Do not allow free users to create reverse alias to reduce abuse
* Update format
* Move function under user
* Update tests
2024-01-16 14:51:01 +01:00
Adrià Casajús
fe1c66268b
Allow to use another S3 provider ( #1970 )
2023-12-14 15:55:37 +01:00
Carlos Quintana
0e82801512
chore: add upcloud monitoring ( #1835 )
...
* chore: add upcloud monitoring
* Added db_role to new_relic metrics
---------
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2023-08-04 12:19:00 +02:00
Adrià Casajús
d62bff8e46
Add rate limit and maximum amount of api keys ( #1788 )
...
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2023-06-29 17:21:00 +02:00
Adrià Casajús
ed66c7306b
Fix typo ( #1755 )
...
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2023-05-29 17:50:41 +02:00
Adrià Casajús
e43a2dd34d
Have subscription callback whenever a subscription changes ( #1748 )
...
* Have subscription callback whenever a subscription changes
* Fixed tests
---------
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2023-05-26 15:33:55 +02:00
Adrià Casajús
f722cae8d6
Add multiple registration warning message ( #1653 )
...
* Add multiple registration warning message
* Add alert
---------
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2023-03-22 15:35:33 +01:00
Adrià Casajús
48ae859e1b
Fix: Set the smtp default port in config to allow connect to port 25 with TLS ( #1564 )
...
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2023-02-06 16:53:10 +01:00
Adrià Casajús
5e48d86efa
Canonicalize emails from google and proton before registering users ( #1493 )
...
* Revert "Revert "Use canonical email when registering users (#1458 )" (#1474 )"
This reverts commit c8ab1c747e
.
* Only canonicalize gmail and proton
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2022-12-14 11:50:36 +01:00
Adrià Casajús
c8ab1c747e
Revert "Use canonical email when registering users ( #1458 )" ( #1474 )
...
* Revert "Use canonical email when registering users (#1458 )"
This reverts commit f728b0175a
.
* missing chang
* typo
2022-12-08 10:57:46 +01:00
Adrià Casajús
f728b0175a
Use canonical email when registering users ( #1458 )
...
* Use canonical email for registration, check both when checking if user exists
* Fix test
* Set pagesize to 100
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2022-11-30 17:19:55 +01:00
Adrià Casajús
5bbf6a2654
Fix: Only override postfix port when enabling TLS if the port is set to be 25 ( #1401 )
...
* Fix: Only override postfix port when enabling TLS if the port is set to be 25
* Add connection timeout
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2022-11-04 11:13:19 +01:00
Adrià Casajús
3bc976c322
Feature: Add app name to each db connection ( #1393 )
...
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2022-11-02 15:41:48 +01:00
Son Nguyen Kim
1fc75203f2
Improve test: disable rate limit during test and avoid conflicts between tests ( #1349 )
...
* disable rate limit during test, avoid conflict between tests
* fix test
2022-10-14 16:37:49 +02:00
Son Nguyen Kim
7b24cdd98a
Revert "remove deduct_limit as it has no effect ( #1347 )" ( #1348 )
...
This reverts commit 851ba0a99a
.
2022-10-13 22:00:45 +02:00
Son Nguyen Kim
851ba0a99a
remove deduct_limit as it has no effect ( #1347 )
...
* remove deduct_limit as it has no effect
- disable rate limit during test
- randomize data in test
- support non-empty db in test
* fix more test
2022-10-13 18:55:22 +02:00
Son Nguyen Kim
1c5a547cd0
do not quarantine an email if fails DMARC but has a small rspamd score ( #1337 )
...
* do not quarantine an email if fails DMARC but has a small rspamd score
* use 0 when cannot parse rspamd score
* use -1 as default value
2022-10-10 10:13:07 +02:00
Son Nguyen Kim
5088604bb8
Replace reverse alias ( #1335 )
...
* replace any reverse alias by real address for all contacts
* improve logging
* fix comment
* Request contacts in batches of 100 to avoid loading the db
* Fix typo
* Added tests for the contact replacement
* Increase batch size to 1k
* Revert and use only reply_email and website_email
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2022-10-10 10:00:19 +02:00
Adrià Casajús
faeddc365c
Display recovery codes for mfa only once ( #1317 )
...
* Recovery codes can only be shown after adding a 2FA code and cannot be seen afterwards
* Added recovery codes fix
* Updated models and script
* Formatting
* Format
* Added base code
* Updated wording
* Set the config by default
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2022-10-03 12:32:45 +02:00
Son Nguyen Kim
97805173cb
remove envs used for proton beta link ( #1189 )
...
* remove envs used for proton beta link
* remove is_connect_with_proton_enabled()
2022-07-26 12:38:18 +02:00
Adrià Casajús
06c1c7f2f7
Restrict the number of free alias for new free users ( #1155 )
...
* Restrict the number of free alias for new free users
* Fix test
* Make flag reverse
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2022-07-20 11:09:22 +02:00
Adrià Casajús
f3d47a1eaa
Allow users to keep the original unsub behaviour ( #1148 )
...
* Feature: Preserve original unsubscribe request
* Updated tests
* Updated settings
* PR comments
* reduced prefix length
* Include migrate users for new unsub behaviour
* PR comments
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2022-07-19 17:25:21 +02:00
Adrià Casajús
afb2ab3758
Allow to configure mem storage from config ( #1166 )
...
* Allow to configure memory storage from config
* format
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2022-07-19 08:25:59 +02:00
Adrià Casajús
f75bdd006a
Fix: Allow internal link independent of enable log in with proton ( #1151 )
...
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2022-07-11 09:41:20 +02:00
Adrià Casajús
88dd07e48d
Feature: Use new job status to retry killed jobs ( #1130 )
...
* Feature: Use new job status to retry killed jobs
* Set attermpts and time via config
* Update timing condition
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2022-07-01 11:14:53 +02:00
Adrià Casajús
99ce10a1bc
Send email to users with a subscription and a partner plan upgrade ( #1101 )
...
* Send email to users with a subscription and a partner plan upgrade
* Update double-subscription-partner.html
* Update double-subscription-partner.txt.jinja2
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
Co-authored-by: Son Nguyen Kim <nguyenkims@users.noreply.github.com>
2022-06-20 14:34:20 +02:00
Adrià Casajús
fbb59a1531
Send welcome mail to proton created users ( #1099 )
...
* Send welcome mail to proton created users
* Skip import
* Use new logo
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2022-06-20 11:36:16 +02:00
Carlos Quintana
58990ec762
Hide proton integration behind cookie ( #1092 )
...
* Hide proton integration behind cookie
* Make cookie name configurable via config
2022-06-15 15:42:41 +02:00
Carlos Quintana
cf5ff6fa23
Allow extra headers on proton connection ( #1087 )
2022-06-14 10:29:18 +02:00
Adrià Casajús
efa534fd3e
Store transfer tokens hashed in the db and only allow them to be valid for 24 hours ( #1080 )
...
* Store transfer tokens hashed in the db and only allow them to be valid for 30 mins
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2022-06-13 12:41:47 +02:00
Adrià Casajús
e688f04d6b
Send full user report asynchronously on request ( #1029 )
...
* Send full user report asynchronously
* Fix test
* Filter some fields before exporting
* Fix: Domain -> CustomDomain
* format settings html
* not include RefusedEmail as they are not usable by user and are automatically deleted
* send the export to the user email
* change email and setting wording
* fix user can only export data once
* remove alias export section
* remove unused import
* fix flake8
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
Co-authored-by: Son <nguyenkims@users.noreply.github.com>
2022-06-07 10:45:04 +02:00
Carlos Quintana
dba56f0dae
Store hmaced partner api tokens ( #1028 )
...
* Store hmaced partner api tokens
* MR comments
2022-06-02 11:24:04 +02:00
Adrià Casajús
7ba9bcb9e2
Save unsent emails to disk to be resent later ( #1022 )
...
* Initial save to disk
* Store unsent messages to disk so they can be retried later
* Set back not sending emails
* Fixed decorator
* Add general exceptions to the catchall
* Have dummy server just to make sure
* Added several server test cases
* ADded tests for bounced and error status
* Moved dir creation to config parse time
* Set LOG.e
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2022-05-30 11:52:10 +02:00
Adrià Casajús
34ad81c7c0
Merge pull request #921 from simple-login/ac-free-no-reverse-alias
...
Prevent free users from creating reverse-alias
2022-05-13 17:13:48 +02:00
Adrià Casajús
4d07bc9d31
Moved global flag to config
2022-05-12 18:30:46 +02:00