28 Commits

Author SHA1 Message Date
Tom Moor
190f0b6dc5
fix: Improve handling of suspended users signing in with email (#2012)
* chore: Separate signin/auth middleware
fix: Email signin token parsed by JWT middleware
fix: Email signin marked as active when logging in as suspended
fix: Suspended email signin correctly redirected to login screen
closes #1740

* refactor middleware -> lib

* lint
2021-04-08 20:40:04 -07:00
Tom Moor
ed2a42ac27
chore: Migrate authentication to new tables (#1929)
This work provides a foundation for a more pluggable authentication system such as the one outlined in #1317.

closes #1317
2021-03-09 12:22:08 -08:00
Tom Moor
19ab32f551
chore: Add additional missing events (#1639)
* chore: Add additional missing events
signed in
profile updated
team setting updated

* Minor refactor to DRY existing code

* Add events

* lint

* flow: Add missing ip to event types
2020-11-14 20:44:18 -08:00
Tom Moor
1b6a986986
chore: Refactor authentication pass between subdomains (#1619)
* fix: Use get request instead of cookie to transfer token between domains

* Add domain to database
Add redirects to team domain when present

* 30s -> 1m

* fix: Avoid redirect loop if subdomain and domain set

* fix: Create a transfer specific token to prevent replay requests

* refactor: Move isCustomDomain out of shared as it won't work on the client
2020-11-04 19:54:04 -08:00
Tom Moor
0fa8a6ed2e
feat: Add ctx.state.authType for tracking (#1567) 2020-09-21 22:02:37 -07:00
Tom Moor
449dc55aaa
chore: Upgrade Babel, Jest, Eslint (#1437)
* chore: Upgrade Prettier 1.8 -> 2.0

* chore: Upgrade Babel 6 -> 7

* chore: Upgrade eslint plugins

* chore: Add eslint import/order rules

* chore: Update flow-typed deps
2020-08-08 22:53:59 -07:00
Tom Moor
e312b264a6
chore: Upgrade Prettier 1.8 -> 2.0 (#1436) 2020-08-08 18:53:11 -07:00
Tom Moor
c6d2467fae chore: Upgrade Flow to v0.104.0 2020-08-08 16:26:20 -07:00
Tom Moor
67981a351e
chore: Remove env variables in webpack bundle (#1353)
* chore: Remove env variables in webpack bundle

* remove unused globals

* refactor: consolidate window.env calls to single file

* fix: Slack client side integration auth

* fix: developers url
2020-07-18 11:02:40 -07:00
Tom Moor
f43deb7940
chore: Move to prettier standard double quotes (#1309) 2020-06-20 13:59:15 -07:00
Tom Moor
092d9dce18
fix: Don't set cookie domain when not using multiple subdomains (#1145)
* fix: Don't set cookie domain when not using multiple subdomains

* wip logging domain

* wip logging domain

* wip logging domain

* wip logging domain

* Revert "wip logging domain"

This reverts commit 325907e74962179e02cee0b1df364a3aedbe62e3.

* Revert "wip logging domain"

This reverts commit 6ee095a49e9c18999a20d5379234323d49d5e6c8.

* Revert "wip logging domain"

This reverts commit 813d8eb960cdf4dd6db4795739df3adf895600e2.

* Revert "wip logging domain"

This reverts commit f1ca81927626bbd0d46c1963510d115a003176d8.

* Remove SUBDOMAINS_ENABLED from documented env variables, no-one self hosting should need this – it just adds confusion to those looking to host on a single subdomain
fix: Account for server/client process.env parsing

Co-authored-by: Nan Yu <nanyu@Nans-MBP-2.lan>
Co-authored-by: Nan Yu <nan@getoutline.com>
2020-05-19 21:05:57 -07:00
Tom Moor
dac2d43f55
dashboard -> home (#1194) 2020-02-26 21:10:20 -08:00
Tom Moor
ec4d4fb20f fix: Show error message when signing in to suspended account
closes #1056
2019-10-12 19:16:17 -07:00
Tom Moor
32f83311f6
chore: upgrade sequelize (#965)
* 0.18.0

* chore: Upgrade sequelize 4 -> 5

* fix: migrations v5 support

* fix: Majority of test failures

* fix: the rest of v5 tests
2019-06-23 15:49:45 -07:00
Tom Moor
07a941a65d
Websocket Support (#937)
* Atom / RSS meta link

* Spike

* Feeling good about this spike now

* Remove document.collection

* Remove koa.ctx from all presenters to make them portable outside requests

* Remove full serialized model from events
Move events.add to controllers for now, will eventually be in commands

* collections.create event
parentDocument -> parentDocumentId

* Fix up deprecated tests

* Fixed: Doc creation

* documents.move

* Handle collection deleted

* 💚

* Authorize room join requests

* Move starred data structure
Account for documents with no context on sockets

* Add socket.io-redis

* Add WEBSOCKETS_ENABLED env variable to disable websockets entirely for self hosted
New installations will default to true, existing installations to false

* 💚 No need for promise response here

* Reload notice
2019-04-17 19:11:23 -07:00
Tom Moor
fa38ab60eb
Fixes: Unexpected token parsing sessions cookie (#905) 2019-03-02 14:58:56 -08:00
Tom Moor
346ea4df89 Fixes: Error when user is suspended by deleted user
Fixes: Suspended user interface never displayed
2019-02-15 21:49:48 -08:00
Tom Moor
836f9a88a2 Fixes: Teams with non-latin characters annot signin 2018-12-12 10:31:08 -08:00
Tom Moor
b068ba9f02 Customize route for first signin for tracking 2018-12-08 08:57:34 -08:00
Tom Moor
26036ad92c Fixes: handling of www subdomain in production
Hanging sessions when subdomain changes
2018-11-13 23:08:27 -08:00
Tom Moor
b3a8d34af3 Add support for SUBDOMAINS_ENABLED=false 2018-11-11 22:06:50 -08:00
Tom Moor
61138ff4fa Cleanup 2018-11-11 21:17:03 -08:00
Tom Moor
cc9f32cdc9 Team switcher 2018-11-11 16:24:05 -08:00
Tom Moor
10e1f0231c Iterate, iterate 2018-11-11 14:23:31 -08:00
Tom Moor
e24a187699 accessToken per subdomain 2018-11-09 23:40:33 -08:00
Tom Moor
662f908c76 Allow Slack integration setup for Google Auth accounts 2018-08-02 23:26:44 -07:00
Tom Moor
53a0f423c3
Track recently active and signin times (#663)
* Track recently active and signin times

* Trust proxy headers in production
2018-06-04 19:07:56 -07:00
Tom Moor
ddd2b82d20 WIP: Successful Google Auth, broke pretty much everything else in the process 2018-05-28 11:36:37 -07:00