Commit Graph

168 Commits

Author SHA1 Message Date
dakrk
0b0c0a5ed6 Handle ban command arguments as array
This provides a much more reliable way to handle arguments with spaces,
such as usernames.

The ban process's stdout and stderr are now redirected to the server,
in case they have output that would be good in the server's logs.
2023-10-22 15:42:39 +01:00
MDMCK10
43fddbc521 Various bug fixes and small additions
IMPORTANT:
This commit contains new config options.
Make sure your local config file is up to date with config.example.toml to avoid issues.

CHANGELOG:
- Fix crash exploit caused by abnormally long WebSocket messages
- Added config option for limiting the maximum amount of active connections from the same IP
- Made per-IP turn limiter configurable
- Fixed an issue where vote updates were not sent to clients in some cases
- Added warning about using qmpSockDir on Windows hosts
- Updated dependencies
- Removed unused code/imports
2023-09-12 00:25:57 +02:00
Elijah
d80d2c8ed9 don't send resolution changes to non-staff while screen hidden 2023-09-02 18:08:41 -04:00
Elijah
1cf2c4830f add hide screen opcode 2023-09-02 17:54:44 -04:00
Elijah
0814d9c3ed bump to es2022 2023-09-02 17:53:53 -04:00
Elijah
bae17c6a52 add turn whitelist and password support 2023-06-05 21:59:37 -04:00
Elijah
1cb19e93f9 no need to use a primitive splitting method when execa has it built in. Fixes a bug on windows when the path to QEMU has spaces 2023-06-05 21:59:16 -04:00
MDMCK10
ababbf57b5 Add (optional) Origin header check 2023-05-25 15:59:16 +02:00
MDMCK10
c66bd6d2ee We don't need that to be there anymore 2023-05-06 16:50:25 +02:00
dakrk
3f753c60da Trim usernames
Previously it was possible to "impersonate" (to those not looking closely) other users by putting whitespace before or after the name of choice. This commit eliminates that.
2023-05-06 15:21:18 +01:00
dakrk
41bf76ab0d Configurable chat history length
The previous default of 5 messages is utterly lame and didn't provide enough context to anything, and was also a downgrade from the old server as that had 10 messages by default (of which we're now going back to with this change).
2023-05-01 15:03:14 +01:00
MDMCK10
b7cba2f572 Change rename ratelimit to 3/60s 2023-04-27 16:30:28 +02:00
MDMCK10
dcee5bd157 We don't need that. 2023-04-07 20:36:56 +02:00
MDMCK10
432b8204f1 Let's try this again. 2023-04-06 21:59:37 +02:00
MDMCK10
3f2c814f1b Maybe not.
This commit reverts 31706c7, 983860f, 90b91bc.
2023-04-06 21:11:27 +02:00
MDMCK10
31706c7b93 fix small bug 2023-04-06 12:38:25 +02:00
MDMCK10
983860ff02 I hate race conditions 2023-04-05 20:34:15 +02:00
MDMCK10
90b91bc0e4 No more QMP deadlocks? It's more likely than you think. 2023-04-05 19:33:25 +02:00
MDMCK10
ef2e226803 Only allow one active turn per IP address 2023-04-05 17:04:21 +02:00
MDMCK10
a57e299988 Fix stupid bug 2023-03-30 20:30:07 +02:00
MDMCK10
7c62a3414a New opcode: view 2023-03-28 18:13:43 +02:00
MDMCK10
39c9832a72 Revert 1d9f06f
I guess we didn't need this after all.
2023-03-28 17:31:44 +02:00
MDMCK10
1052246531 Fix another bug related to b079c09 2023-03-28 16:29:32 +02:00
MDMCK10
b079c09237 Fix rank not persisting after username change 2023-03-28 15:53:17 +02:00
MDMCK10
1d9f06f9f5 This should never happen but let's add a check for it anyway 2023-03-28 15:44:07 +02:00
MDMCK10
81ed711fac This looks like something that should work 2023-03-27 01:05:18 +02:00
MDMCK10
7295da7cac Ignore username changes from muted users 2023-03-27 00:56:26 +02:00
Elijahr2411
a09d5fc6c1 Abstract the VM, so that we can use other hypervisors in the future 2023-02-25 15:34:59 -05:00
Elijahr2411
6c50219ac7 make the snapshots config value actually work oops 2023-02-25 00:28:39 -05:00
Elijahr2411
fe32d1e487 send motd after chat history so it's more visible 2023-02-25 00:18:14 -05:00
Elijahr2411
197036fa94 fix typo 2023-02-24 22:55:34 -05:00
Elijahr2411
ed5fda8021 Add proper logging 2023-02-24 22:54:28 -05:00
Elijahr2411
fb23f49a28 fix bug which broke turns if an admin disconnected while they had an indefinite turn 2023-02-23 16:45:57 -05:00
Elijah R
a931188b9e Disable proxying by default (example config should work out of the box) 2023-02-13 18:52:42 -05:00
sporb
c3c78fec2b add banner to readme + "frequently" asked questions (#4)
---------

Co-authored-by: Elijah R <62162399+elijahr2411@users.noreply.github.com>
2023-02-13 14:11:48 -05:00
elijahr2411
5e781d5205 Disable votes when turns are disabled 2023-02-12 18:15:58 -05:00
elijahr2411
7b66f7c8a3 Add ratelimit for reset votes 2023-02-12 18:15:12 -05:00
MDMCK10
5f603a88d9 Previous commit didn't work, let's try it again. 2023-02-11 20:52:25 +01:00
MDMCK10
25776c257f Change shutdown behavior (again)
I hope this works
2023-02-11 20:39:32 +01:00
Elijah R
07d0be6bd4 fix potential hang 2023-02-11 13:57:57 -05:00
MDMCK10
ab6fb07138 Change shutdown behavior
When a VM is shut down, execution will be continued instead of being restored.
2023-02-11 19:50:23 +01:00
MDMCK10
87cefdaaba Fix freezing on VM shutdown 2023-02-11 18:52:45 +01:00
MDMCK10
e7b56d18e6 Fix crash caused by new changes 2023-02-11 17:07:34 +01:00
MDMCK10
cea28ebf8c Add IPData, Windows support, bugfixes (#2)
* Add IPData, Windows support, bugfixes

Changes:
- Added IPData: mutes and votes are now tracked per-IP instead of per-user.
- Windows support: QMP over TCP can now be enabled in the config.
- Vote cooldown can now be specified in the config.
- Fixed bugs:
"Username is already taken" message appearing when it shouldn't

* Remove vote from closed connections

---------

Co-authored-by: Elijah R <62162399+elijahr2411@users.noreply.github.com>
2023-02-11 09:58:20 -05:00
Elijahr2411
006edd4453 Move captcha support to another branch until I get time to fix it
This reverts commit 626d32d22b.
2023-02-11 14:29:06 +00:00
elijahr2411
626d32d22b add captcha support 2023-02-10 08:52:52 -05:00
elijahr2411
82cbcc030e Add indefinite turn opcode 2023-02-09 20:49:27 -05:00
elijahr2411
66894726d7 Merge branch 'master' of https://github.com/computernewb/collabvm-1.2.ts 2023-02-09 20:09:27 -05:00
elijahr2411
5b59b1993b Add toggle turns opcode 2023-02-09 20:08:32 -05:00
Elijah R
d676b94f4a Merge pull request #1 from HolyNetworkAdapter/patch-1 2023-02-09 17:18:47 -05:00