Commit Graph

266 Commits

Author SHA1 Message Date
Renaud Boyer
b6c311a02e linting 2020-12-06 14:02:37 +01:00
Son NK
083398522c sentry init with release 2020-11-26 10:30:03 +01:00
Son NK
2c46d1db8e Add PGP_SIGNER and display if it's set 2020-11-14 13:00:14 +01:00
Son NK
15466903d1 Support OTHER_PADDLE_MONTHLY_PRODUCT_IDS, OTHER_PADDLE_YEARLY_PRODUCT_IDS config 2020-11-09 16:56:17 +01:00
Son NK
606f9dfbae use valid PGP key for fake data 2020-11-07 13:00:26 +01:00
Son NK
dec956c84d handle case user is None 2020-10-26 12:01:59 +01:00
Son NK
886d3a761c delete /alias/options v1,v2,v3 2020-10-19 12:08:47 +02:00
Son NK
4a32db5b5d rename PublicDomain -> SLDomain 2020-10-15 16:51:07 +02:00
Son NK
2d73d52127 log disabled user out immediately 2020-10-04 19:17:19 +02:00
Son NK
b99085419e remove AioHttpIntegration sentry, remove aiocontextvars dependency 2020-10-01 12:48:08 +02:00
Son NK
b690e903fa small refactoring 2020-10-01 12:24:37 +02:00
Son NK
73f56818fb fix ProxyFix 2020-10-01 12:21:16 +02:00
Son NK
f2eedfd3d1 enable sentry AioHttpIntegration 2020-09-30 10:22:10 +02:00
Son NK
2fba4c9a53 send email to ask for user feedback when user cancels 2020-09-12 11:12:34 +02:00
Son NK
fdedc24358 black new version 2020-08-27 10:20:48 +02:00
Son Nguyen Kim
637bc569eb
Merge pull request #260 from FabioWidmer/improvements-1
Improvements for Self Hosting & More
2020-08-24 20:16:59 +02:00
Fabio Widmer
6a45010740
Remove secret variables from Jinja 2020-08-22 18:38:44 +02:00
Son NK
b8e0ee424c pass userId to Paddle 2020-08-20 09:44:45 +02:00
Fabio Widmer
aa18b7ecd1
Add variables to Jinja 2020-08-18 08:47:41 +02:00
Son NK
5636b7ba32 do not use DomainDeletedAlias.create 2020-08-14 12:03:59 +02:00
Son NK
00411cef61 reduce further 2020-08-11 16:31:08 +02:00
Son NK
dc206b41c7 lighten mail handler 2020-08-11 16:31:08 +02:00
Son NK
184397dc92 remove sentry AioHttpIntegration 2020-08-11 08:45:06 +02:00
Son NK
8a11e42da9 notify admin when user cancels 2020-08-07 10:01:11 +02:00
Son NK
5dc631a6b5 black 2020-08-05 12:31:08 +02:00
Son NK
f17608df50 add link back to home page in recovery page 2020-08-05 12:28:20 +02:00
Son NK
3d2a325e55 enable debug toolbar when running locally 2020-08-04 11:37:59 +02:00
Son NK
6437ee46e0 use LOG.exception instead of LOG.error to provide stacktrace 2020-07-17 12:59:07 +02:00
Son NK
bb343a5cde use warning level for hit rate limit error 2020-07-11 19:28:54 +02:00
Son NK
74498146d8 add public domain in fake_data 2020-07-04 23:29:15 +02:00
Son NK
e3569ee7ad create less aliases in fake_data 2020-06-30 20:09:48 +02:00
Son NK
c22af6d1f0 no need to bind to 0.0.0.0 2020-06-28 21:58:08 +02:00
Son NK
c41bffbbae refactor: use SESSION_COOKIE_NAME instead of hardcoding "slapp" 2020-06-28 21:17:18 +02:00
Son NK
8e068eea30 fix user has to login again after quitting the browser 2020-06-28 21:14:30 +02:00
Son NK
774ffcae3b enable CORS on /api endpoints 2020-06-24 10:30:01 +02:00
Son NK
683b3e54d8 remove User.can_use_fido column: anyone can setup FIDO 2020-05-28 20:38:29 +02:00
Sibren Vasse
31a1f94a5f Implement rate limiting 2020-05-25 11:39:33 +02:00
Son Nguyen Kim
eb60028b1f
Merge pull request #199 from developStorm/webauthn-multiple-keys
Support Multiple Keys for WebAuthn
2020-05-24 18:56:42 +02:00
Son NK
a2e7de0bab Add Notification model 2020-05-23 19:54:06 +02:00
Son NK
1beb7c004b improve fake_data 2020-05-22 14:13:17 +02:00
Son NK
516485d4d6 warning log for "cancel subscription" 2020-05-21 20:07:41 +02:00
devStorm
ea914e0378
Rename FIDO->Fido 2020-05-18 13:54:05 -07:00
devStorm
e892535287
Black 2020-05-18 05:28:18 -07:00
devStorm
d91fbb563a
Remove debug keys 2020-05-18 05:11:54 -07:00
devStorm
6509053fa8
named key 2020-05-18 02:55:41 -07:00
devStorm
419aa95f1f
more verify 2020-05-18 01:02:58 -07:00
devStorm
2b8febe0b9
black 2020-05-18 00:06:24 -07:00
devStorm
9fb91c83e7
more setup 2020-05-18 00:01:27 -07:00
devStorm
f2f6e13af7
DB & Setup ready for multi-keys 2020-05-17 22:05:37 -07:00
Son Nguyen Kim
1997c207ed
Merge pull request #196 from SibrenVasse/error_handling
Move api error handling to global error handler
2020-05-17 18:02:23 +02:00
Sibren Vasse
2d7bd225e9 Move api error handling to global error handler 2020-05-17 15:27:24 +02:00
Son NK
13bb9810b6 use can disable PGP on an alias 2020-05-16 20:51:07 +02:00
Son NK
083a857f1b disable intro_shown in fake data 2020-05-16 20:50:57 +02:00
Son NK
362d101bab Merge branch 'master' into multiple-mailboxes
# Conflicts:
#	app/dashboard/templates/dashboard/custom_alias.html
#	email_handler.py
#	templates/emails/com/newsletter/mobile-darkmode.html
2020-05-16 11:28:25 +02:00
Son NK
6fb85c81fc fix format 2020-05-15 16:50:14 +02:00
Son NK
f04caa3c35 move SQLALCHEMY_ECHO option to create_app(): useful when profiling 2020-05-15 16:48:42 +02:00
Son NK
0b652cf3f8 remove AliasMailbox.user_id column 2020-05-15 16:35:57 +02:00
Son NK
5c8c741a6a API Error handling for 404 and 500 2020-05-13 22:02:38 +02:00
Son NK
dafa23c5bf Add fake aliases with multiple mailboxes 2020-05-10 20:09:54 +02:00
Son NK
8fa0927826 Set SESSION_COOKIE_SAMESITE to Lax 2020-05-10 11:34:23 +02:00
Son Nguyen Kim
b95d815e5c
Merge pull request #168 from simple-login/global-trash
Global trash
2020-05-09 18:08:51 +02:00
Sibren Vasse
e7c3a127b8 Set samesite and secure attributes of session cookie. Enable strong session protection. 2020-05-09 14:13:37 +02:00
Son NK
0441e5e2a9 Remove DeletedAlias.user_id column 2020-05-07 22:40:30 +02:00
Son NK
3ce3a05c7b Add referral name 2020-05-02 18:08:05 +02:00
Son NK
fd90811e85 Prettify alias contact manager 2020-04-27 19:58:55 +02:00
Son NK
12714ae601 Add Only enabled alias sorting option 2020-04-26 12:31:10 +02:00
Son NK
182f01f775 More diverse fake data 2020-04-25 23:42:56 +02:00
Son NK
97544ac760 Update mailbox using ajax
refactor: return Mailbox in User.mailboxes()
2020-04-25 13:49:40 +02:00
Son NK
8ee34d9132 add more alias in fake_data 2020-04-25 13:42:53 +02:00
Son NK
746cd2eb66 Use FIRST_ALIAS_DOMAIN in directory and custom alias 2020-04-15 22:52:30 +02:00
Son NK
70ce48cd79 Disable trial on fake data 2020-04-12 19:43:55 +02:00
Son NK
b845e2a8eb Handle case where subscription_payment_succeeded arrives BEFORE subscription_created 2020-04-12 19:43:35 +02:00
Son NK
9b91f4a4a4 support changing plan 2020-04-12 19:43:07 +02:00
Son NK
3f84b9e901 no need to set X-Frame-Options header
as already set by Nginx
2020-04-06 22:36:35 +02:00
Son NK
e9208810af Return user to login page in case of 401 2020-04-01 20:32:08 +02:00
Son Nguyen Kim
44e2e175ef
Merge pull request #115 from simple-login/rename
Rename
2020-03-19 10:39:05 +01:00
Son NK
4f281bdbbb rename GenEmail -> Alias, gen_email to alias whenever possible 2020-03-17 11:51:40 +01:00
Son NK
ea43b8f685 Open PGP to everyone 2020-03-17 09:22:29 +01:00
Son NK
69198ff08a delete all unnecessary headers in PGP 2020-03-14 22:24:02 +01:00
Son NK
a240b4af33 fix formatting 2020-03-09 13:38:55 +01:00
Son NK
3be593ed09 prettify mailbox detail page 2020-03-09 13:35:32 +01:00
Son NK
32910b4d77 reformat 2020-03-08 11:40:35 +01:00
Son NK
bada186962 Log more info on cancel event 2020-03-08 11:38:45 +01:00
Son NK
b86937c5c7 Fix next_bill_update update: the event is subscription_payment_succeeded and not subscription_updated 2020-03-08 11:34:39 +01:00
Son NK
3b454b9a80 fix test 2020-03-05 20:32:08 +01:00
Son NK
3492935f95 Canceled user can upgrade again: the payment method is changed immediately though 2020-03-05 09:13:28 +01:00
Son NK
1ebe6558a0 fix paddle logging 2020-03-05 08:11:07 +01:00
Son NK
8099d9841c log next_bill_date 2020-03-04 21:35:39 +01:00
Son NK
930b4cadb9 Fix the case where user cancels and re-subscribes 2020-03-02 23:04:47 +01:00
Son NK
7e4eb9e0db use MAILBOX_SECRET instead of FLASK_SECRET 2020-02-29 18:18:52 +07:00
Son NK
aeed62e95b All users use full-mailbox
- remove can_use_multiple_mailbox col
- remove full_mailbox col
2020-02-29 00:03:35 +07:00
Son NK
2eae0ba4fd set user default mailbox in convert_user_full_mailbox 2020-02-23 15:41:08 +07:00
Son NK
e4bb85ac87 Full-mailbox User can change alias mailbox 2020-02-23 13:58:09 +07:00
Son NK
af8ac99248 use warning for subscription cancel message 2020-02-22 21:50:13 +07:00
Son NK
a9a5f145aa fix showing unverified mailbox when creating new alias 2020-02-21 21:59:13 +07:00
Son NK
9727473b45 Add more fake data 2020-02-19 23:45:48 +07:00
Son NK
8f8857704a Add deleted alias page 2020-02-15 21:47:27 +07:00
Son NK
d1d60f051b remove unnecessary log 2020-02-15 17:03:23 +07:00
Son NK
b41a61165c use mailbox_email when notifying user attempt to send from his alias 2020-02-11 22:46:53 +07:00
Son NK
7407f678ce take into account mailbox in forward phase 2020-02-10 23:23:40 +07:00
Son NK
ec248dcae6 use another sentry project for the front-end using SENTRY_FRONT_END_DSN param 2020-02-05 14:38:29 +07:00
Son NK
b40278f4dc use store instead of localStorage to disable GoatCounter 2020-02-05 14:30:27 +07:00
Son NK
2ca97368f8 Handle trial period
- user can upgrade to lifetime if in trial or free
- free or trial user can buy a subscription
- user has all features when in trial
2020-01-30 10:53:17 +07:00
Son NK
284de7a0a6 fix test 2020-01-16 22:30:00 +01:00
Son NK
13283b6327 Support cancelled premium users in custom domain & directory
- Freemium user can see custom domain and directory but could not add new.
- user who has added custom domain or directory before could delete them
2020-01-16 22:21:19 +01:00
doanguyen
c49bc87bae rollback the debug flag 2020-01-07 22:29:37 +01:00
doanguyen
783aba1275 flask debug must be string, not bool, int. What a joke 2020-01-05 22:58:40 +01:00
doanguyen
4e84815375 let debug configurable 2020-01-05 19:45:29 +01:00
Son NK
35aa8f1438 add GoatCounter analytics 2020-01-03 23:23:29 +01:00
Son NK
0327f755a1 accept both GET and POST for / 2020-01-02 22:10:27 +01:00
Son NK
851eac604b Add Sentry SqlalchemyIntegration and AioHttpIntegration 2020-01-02 22:04:18 +01:00
Son NK
5d25310105 Fix subscription might not exist 2020-01-01 23:51:22 +01:00
Son Nguyen Kim
b8ca2d0158
Merge pull request #16 from simple-login/lifetime
Lifetime coupon
2020-01-01 23:24:15 +01:00
Son NK
6dd7827330 fix formatting 2020-01-01 23:22:34 +01:00
Son NK
064e10771b Ignore /git and /exception in flask-profiler 2020-01-01 23:20:28 +01:00
Son NK
d3f8233844 Enable flask-profiler if FLASK_PROFILER_PATH is set 2020-01-01 23:16:09 +01:00
Son NK
4f980ffd94 add lifetime coupon to fake_data 2020-01-01 20:05:10 +01:00
Son NK
1d4e8368ab Use constant otp_secret in fake_data() 2019-12-27 16:53:07 +00:00
Son NK
a3f547fd22 rename create_custom_alias -> create_new 2019-12-22 16:34:10 +00:00
Son NK
91e38a744b remove GenEmail.custom column 2019-12-22 16:32:55 +00:00
Son NK
a22a635508 create custom domain in fake_data 2019-12-22 16:00:04 +00:00
Son NK
66091b4f9e replace ENABLE_SENTRY by SENTRY_DSN 2019-12-16 19:30:17 +02:00
Son NK
c3b716f644 remove users.can_use_custom_domain flag 2019-12-15 21:52:24 +02:00
Son NK
ec62fad3a0 remove notify_admin, replace by general stats 2019-12-15 18:55:18 +02:00
Son NK
0b982a3f19 comment out flask-toolbar 2019-12-15 18:55:18 +02:00
Son NK
fd5b4f91f9 return 400 in paddle callback if verification fails 2019-12-15 18:55:18 +02:00
Son NK
6ddb8ee5ab fix test 2019-12-15 18:55:17 +02:00
Son NK
2e23a1bf19 add RESET_DB back 2019-12-15 18:55:17 +02:00
Son NK
6e387444f5 do not use RESET_DB to avoid potential error: uncomment fake_date locally if necessary 2019-12-15 18:55:17 +02:00
Son NK
d58ab8c808 fix create random alias: new alias not saved 2019-12-15 18:55:16 +02:00
Son NK
5156ed5eba create constant api_code in local to facilitate test 2019-12-15 18:55:16 +02:00
Son NK
8ed7f2e693 set X-Frame-Options header to deny 2019-12-15 18:55:16 +02:00
Son NK
a827b27215 add custom_domain view 2019-12-15 18:55:16 +02:00
Son NK
b59ffb94b2 Remove Stripe usage 2019-12-15 18:55:16 +02:00
Son NK
6ea43275ed remove user.can_use_api_key 2019-12-15 18:55:16 +02:00
Son NK
7bedd40966 add user.can_use_custom_domain, user.can_use_api_key 2019-12-15 18:55:16 +02:00
Son NK
4f874eec43 Create API Key page 2019-12-15 18:55:16 +02:00
Son NK
6c4a173de5 create /api/alias/new using api-key as authentication 2019-12-15 18:55:16 +02:00
Son NK
c4b9a81c09 fix user re-subscribes 2019-12-15 18:55:14 +02:00
Son NK
47d5b75dc4 remove partner table 2019-12-15 18:55:14 +02:00
Son NK
a084ea880d remove become partner view 2019-12-15 18:55:14 +02:00
Son NK
e8b69014cd fix fake_data 2019-12-15 18:55:14 +02:00
Son NK
3442250bb1 create a subscription in fake_data 2019-12-15 18:55:13 +02:00
Son NK
6c3c37170c Create paddle handler 2019-12-15 18:55:13 +02:00
Son NK
d7d2ea04a9 replace lyra by GA 2019-12-15 18:55:12 +02:00
Son NK
db45b01ddd set a different SESSION_COOKIE_NAME to avoid conflict 2019-12-15 18:55:11 +02:00
Son NK
541cf80b77 add userinfo_endpoint, remove introspection_endpoint and revocation_endpoint in /.well-known/openid-configuration 2019-12-15 18:55:11 +02:00
Son NK
d5a2932a97 use localhost instead of sl-client 2019-12-15 18:55:10 +02:00
Son NK
06f51099a5 all users can have access to developer tab 2019-12-15 18:55:10 +02:00
Son NK
ac8fa33a83 use John Wick email 2019-12-15 18:55:10 +02:00