Commit graph

24 commits

Author SHA1 Message Date
Adrià Casajús
25fde11a86
Refactor alias suffix (#1194)
* Extract suffix generation and validation to a module

* Updated tests

* Make custom alias use signed suffixes

* Added the signature check to the module

* Fix invalid route

* Move more suffix related stuff

* Fix tests

Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2022-07-27 17:40:22 +02:00
Son Nguyen Kim
09cec0cdec
allow to hide some public domains and set their order (#1107) 2022-06-22 18:21:19 +02:00
Adrià Casajús
220f21bb2a
Fix tests to allow re-running them locally without colliding with previous runs 2022-05-20 14:39:07 +02:00
Son
becde6458b fix test 2022-04-18 11:55:14 +02:00
Son
80b0af91e5 allow user to create alias with domain that has ownership verified (and might not have MX verified) 2021-12-29 10:24:22 +01:00
Son
372466ab06 do not use flask-sqlalchemy
- add __tablename__ for all models
- use sa and orm instead of db
- rollback all changes in tests
- remove session in @app.teardown_appcontext
2021-10-12 14:36:47 +02:00
Son Nguyen Kim
d181cd49dd Sign the whole Alias Suffix Info instead of just the suffix 2021-07-19 20:14:59 +02:00
Son NK
71389b7e09 add limiter on custom alias page 2021-03-24 16:52:05 +01:00
Son NK
2b4dc3cdcc when a custom domain is default and has random_prefix_generation enabled, use the random_prefix as the first choice 2021-01-02 18:17:53 +01:00
Son NK
33dd6083c7 rename available_suffixes_more_info -> get_available_suffixes 2020-12-31 14:27:04 +01:00
Son NK
5a3b79b4cf replace available_suffixes by available_suffixes_more_info 2020-12-31 14:25:44 +01:00
Son NK
75d1b090cd rename default_random_alias_public_domain_id -> default_alias_public_domain_id 2020-12-31 14:14:56 +01:00
Son NK
b9d8f11f2d put the default domain to top 2020-12-31 13:59:03 +01:00
Renaud Boyer
0f48121fd5 linting 2020-12-06 17:46:10 +01:00
Son NK
8dbd3c1c68 more detailed error message when an alias can't be created 2020-10-09 11:48:52 +02:00
Son NK
859bc7976e create create-alias tests when alias is already existed 2020-10-09 11:37:56 +02:00
Son NK
e52f2ca6de Support multiple mailboxes in custom alias page 2020-05-10 20:09:54 +02:00
Son NK
9874422700 refactor custom_alias: create available_suffixes() 2020-05-02 12:34:11 +02:00
Son NK
0edcc25289 refactor verify_prefix_suffix: remove user_custom_domains param 2020-05-02 12:27:54 +02:00
Son NK
db92003e5f Anti tamper: avoid submitting any suffix 2020-05-02 12:15:03 +02:00
Son NK
ca70d26285 black format 2020-03-05 11:00:58 +01:00
Son NK
a9a5f145aa fix showing unverified mailbox when creating new alias 2020-02-21 21:59:13 +07:00
Son NK
991a76dabd fix test 2020-02-10 23:30:38 +07:00
Son NK
d8229102a6 add test for custom alias page 2020-02-05 17:35:38 +07:00