Son Nguyen Kim
6276ad4419
Stats endpoint ( #1716 )
...
* update some dependencies: newrelic, gevent
that isn't compatible with python 3.11 on mac
* update package-lock using npm 9.6.4 and node 20.0
* Add GET /api/stats
* update pytest
---------
Co-authored-by: Son Nguyen Kim <son@Sons-MacBook-Air-2.local>
2023-05-03 10:15:47 +02: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
Spitfireap
b849d1cfa7
Simpler csv export ( #1383 )
...
* Export alias in csv
* reformating
* template
* Improved contributing script and doc
* Updated test
* removed csv export from GDPR export archive
* added test for new route
* fix trailing space
* moved test to new utils file
2022-11-23 13:51:08 +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
f69c9583fb
fix proton partner error when self host ( #1255 )
...
* fix proton partner error when self host
* fix test
* fix test
* remove a@b.c
2022-09-01 14:59:16 +02:00
Carlos Quintana
7eb44a5947
Fixes for connect with proton on mobile ( #1230 )
...
* Fixes for connect with proton on mobile
* Added a test
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2022-08-12 13:17:21 +02:00
Adrià Casajús
3a75686898
Generate a web session from an api key ( #1224 )
...
* Create a token to exchange for a cookie
* Added Route to exchange token for cookie
* add missing migration
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2022-08-10 18:48:32 +02:00
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
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
aabcc8e72a
Feature: Add delete account route for the api ( #1132 )
...
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2022-07-02 16:45:58 +02:00
Adrià Casajús
de31e6d072
Allow to set sudo mode for api requests ( #1108 )
...
* Allow to set sudo mode for api requests
* Rebase migration on top of master
* PR comments
* Added missing migration
* Removed unused import
* Apply suggestions from code review
Co-authored-by: Adrià Casajús <adria.casajus@proton.ch>
2022-06-23 14:26:36 +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
Adrià Casajús
9066116b7e
Simplified method
2022-05-12 18:33:13 +02:00
Adrià Casajús
4d07bc9d31
Moved global flag to config
2022-05-12 18:30:46 +02:00
Adrià Casajús
caff70ea38
Set global config to enable/disable feature
2022-05-12 16:35:51 +02:00
Adrià Casajús
5dde39eb37
Prevent free users from creating reverse-alias
2022-05-12 13:20:05 +02:00
Son
a2c477a816
support "enabled" param in /api/v2/aliases
2022-04-28 17:24:35 +02:00
Son
7b7cb0b571
prevent disabled user from using the api
2022-04-27 16:24:38 +02:00
Son
58b332b7bc
add new parameter disabled in /GET /api/v2/aliases
2022-04-25 09:22:29 +02:00
Son
becde6458b
fix test
2022-04-18 11:55:14 +02:00
Son
9a994ec98b
fix test
2022-04-18 11:17:10 +02:00
Son
a966665478
refactor test: no hardcode a@b.c, make sure each test has a different user
2022-04-15 16:59:44 +02:00
Son
7edbc3a5d5
black
2022-04-14 18:53:27 +02:00
Son
217518c00e
refactor
2022-04-14 18:37:55 +02:00
Son
debed67c68
return whether a domain is custom or primary in GET /api/v5/alias/options
2022-04-14 17:28:40 +02:00
Adrià Casajús
44dd06fabf
Added spoofed email test
2022-03-21 10:43:18 +01:00
Son
7da06ba424
return 422 if account not activated
2022-02-22 22:12:36 +01:00
Son Nguyen Kim
e9d134fe8f
Merge pull request #784 from FozzieHi/fix-testing-warnings
...
Fix deprecation warnings.
2022-02-21 17:12:36 +01:00
george
c415324932
Add flake8-bugbear
2022-02-06 20:37:43 +00:00
george
936d90a5f5
Fix deprecation warnings.
2022-02-04 13:49:38 +00:00
Son
4d1c4cfdff
support pinned parameter in /api/v2/aliases
2022-02-03 11:16:49 +01:00
Son
70cb0609d8
refactor
2022-02-03 11:16:49 +01:00
Son
5b7949f346
return title in /api/notifications
2022-01-24 15:20:59 +01:00
Son
0806f9243e
return custom domain json in patch
2022-01-16 17:26:11 +01:00
Son
9ff323c746
make sure to set custom_domain_id when creating a new alias
2022-01-06 15:29:37 +01:00
Son
4d8c89105f
GET /api/phone/reservations/:reservation_id
2022-01-04 16:22:41 +01: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
a270c72d60
add random_alias_suffix to settings api
2021-12-28 15:24:58 +01:00
Son
226ce9333c
return error if invalid alias address
2021-12-02 16:17:41 +01:00
Son
abc074ea9b
make sure password can't be longer than 100 chars
2021-11-16 19:41:05 +01:00
Son
6012b6ff54
rename file
2021-11-16 19:39:51 +01:00
Son
416eafaeb9
use the first alias suffix when creating a new random alias
2021-11-12 11:04:00 +01:00
Son
bb5259ac3f
fix test
2021-11-12 10:00:01 +01:00
Son
611fb8a20c
take into account user.include_website_in_one_click_alias in /api/alias/random/new
2021-11-12 09:45:31 +01:00
Son
4c87e4ce68
improve test
2021-11-08 12:57:03 +01:00
Son
31e39314d5
return "block_forward" for /api/aliases/{alias.id}/contacts
2021-11-02 15:55:16 +01:00