summaryrefslogtreecommitdiff
path: root/migrations/20240929013644_token_id.sql
Commit message (Collapse)AuthorAge
* Start fresh with database migrations.Owen Jacobson2024-10-04
| | | | | | The migration path from the original project inception to now was complicated and buggy, and stranded _both_ Kit and I with broken databases due to oversights and incomplete migrations. We've agreed to start fresh, once. If this is mistakenly started with an original-schema-flavour DB, startup will be aborted.
* Shut down the `/api/events` stream when the user logs out or their token ↵Owen Jacobson2024-09-29
expires. When tokens are revoked (logout or expiry), the server now publishes an internal event via the new `logins` event broadcaster. These events are used to guard the `/api/events` stream. When a token revocation event arrives for the token used to subscribe to the stream, the stream is cut short, disconnecting the client. In service of this, tokens now have IDs, which are non-confidential values that can be used to discuss tokens without their secrets being passed around unnecessarily. These IDs are not (at this time) exposed to clients, but they could be.