コミットグラフ

17 コミット

作成者 SHA1 メッセージ 日付
n9k a6c31179b6 Repo changed domains: git.076.ne.jp -> gitler.moe 2023-02-23 22:36:20 +00:00
n9k 9ad069ad08 Allowedness: check (in) websockets 2022-07-03 08:53:02 +00:00
n9k 1ad67fd9cf Basically nothing 2022-06-25 04:00:57 +00:00
n9k 4a76fb023e Access captcha: special case for websocket
There doesn't seem to be a way to catch a 403 Forbidden error opening a
websocket with JavaScript, so this commit changes the behaviour to this:
open the websocket normally, send one "kick" message, close the
websocket.
2022-06-22 08:11:12 +00:00
n9k 46f9b0ec08 Reset websocket aliveness timer on first connecting
This should eliminate the possibilty of the websocket-closing background
task closing a newly opened websocket that hasn't yet ponged our ping
(if we have even sent a ping yet).
2022-06-20 04:15:09 +00:00
n9k 22c84bc230 Give timestamp to route handlers 2022-06-20 04:15:09 +00:00
n9k 1d5b446291 Track the last time users were sent chat messages 2022-06-19 08:21:40 +00:00
n9k 1c7818cc0b Licence headers formatting 2022-06-16 01:31:10 +00:00
n9k c0de94bc5d Remove redundant failsafe `websocket.close()`
Ping timeouts should do the same thing.
2022-06-11 23:14:16 +00:00
n9k 4b68023cf2 Add websocket ping/pong
Client and server both close the connection if they don't hear from the
other party after a timeout period. This is a failsafe and should
improve reliability.
2022-06-11 23:14:16 +00:00
n9k 4eaf9b56f7 Try to ensure websocket is closed when forgetting about it
Might not be necessary, but if it is then it prevents a sitation where a
websocket is still open but we've forgotten about it, so we will never
broadcast any new messages to it and the client will be practically frozen in
time until they disconnect and open a new websocket.

Also update the user's last_seen when the websocket is closed. This prevents a
user with js enabled who's actually idle being considered absent and being
rotated when their websocket accidentally closes for a few seconds.
2022-03-10 07:47:57 +13:00
n9k 829f3f004b Add licences 2022-03-08 16:41:47 +13:00
n9k b7313eec22 Captchas, require captcha initially, generalize notices to states 2022-02-22 16:25:43 +13:00
n9k 7058677000 Setup background tasks, create t_sunset_users task 2022-02-22 16:25:43 +13:00
n9k 1e6563c4a2 Some more project structure 2022-02-18 14:32:34 +13:00
n9k 7dbcd43f30 Logicaler project structure, see rest of commit message
Incoming requests are handled in anonstream/routes/. Route handlers
mainly depend on files in anonstream/, which in turn depend on files in
anonstream/helpers/ and anonstream/utils/. Utils are pure functions and
helpers are almost pure functions; they don't mutate state but they
do depend on the global app config.
2022-02-17 13:30:09 +13:00
n9k e77862f4ff Nojs chat, store all user names/colors in js, forget about inactive users
Project structure evolving a bit
2022-02-17 13:30:05 +13:00